summaryrefslogtreecommitdiffstats
path: root/src/intel/tools/aub_mem.c
diff options
context:
space:
mode:
authorEric Engestrom <[email protected]>2019-06-19 12:47:19 +0100
committerEric Engestrom <[email protected]>2019-07-31 09:41:05 +0100
commitabc226cf41574454c79477c217e60e8ff1fddfad (patch)
tree4c01a31ebe12a2a03bef6c7902a4d0ca400110ce /src/intel/tools/aub_mem.c
parentab9c76769ad070490434aa7104d11958e1fc49d4 (diff)
tree-wide: replace MAYBE_UNUSED with ASSERTED
Suggested-by: Jason Ekstrand <[email protected]> Signed-off-by: Eric Engestrom <[email protected]> Reviewed-by: Matt Turner <[email protected]>
Diffstat (limited to 'src/intel/tools/aub_mem.c')
-rw-r--r--src/intel/tools/aub_mem.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/intel/tools/aub_mem.c b/src/intel/tools/aub_mem.c
index 98e14219c59..1b217e130ca 100644
--- a/src/intel/tools/aub_mem.c
+++ b/src/intel/tools/aub_mem.c
@@ -155,7 +155,7 @@ ensure_phys_mem(struct aub_mem *mem, uint64_t phys_addr)
new_mem->phys_addr = phys_addr;
new_mem->fd_offset = mem->mem_fd_len;
- MAYBE_UNUSED int ftruncate_res = ftruncate(mem->mem_fd, mem->mem_fd_len += 4096);
+ ASSERTED int ftruncate_res = ftruncate(mem->mem_fd, mem->mem_fd_len += 4096);
assert(ftruncate_res == 0);
new_mem->data = mmap(NULL, 4096, PROT_READ | PROT_WRITE, MAP_SHARED,
@@ -289,7 +289,7 @@ aub_mem_get_ggtt_bo(void *_mem, uint64_t address)
continue;
uint32_t map_offset = i->virt_addr - address;
- MAYBE_UNUSED void *res =
+ ASSERTED void *res =
mmap((uint8_t *)bo.map + map_offset, 4096, PROT_READ,
MAP_SHARED | MAP_FIXED, mem->mem_fd, phys_mem->fd_offset);
assert(res != MAP_FAILED);
@@ -355,7 +355,7 @@ aub_mem_get_ppgtt_bo(void *_mem, uint64_t address)
for (uint64_t page = address; page < end; page += 4096) {
struct phys_mem *phys_mem = ppgtt_walk(mem, mem->pml4, page);
- MAYBE_UNUSED void *res =
+ ASSERTED void *res =
mmap((uint8_t *)bo.map + (page - bo.addr), 4096, PROT_READ,
MAP_SHARED | MAP_FIXED, mem->mem_fd, phys_mem->fd_offset);
assert(res != MAP_FAILED);