Lines Matching defs:length
24 static int map_mem(char *path, off_t offset, size_t length, int touch)
42 addr = mmap(NULL, length, PROT_READ|PROT_WRITE, MAP_SHARED, fd, offset);
48 while (c < (int *) (addr + length))
52 rc = munmap(addr, length);
62 static int scan_tree(char *path, char *file, off_t offset, size_t length, int touch)
89 rc = map_mem(path2, offset, length, touch);
91 fprintf(stderr, "PASS: %s 0x%lx-0x%lx is %s\n", path2, offset, offset + length, touch ? "readable" : "mappable");
93 fprintf(stderr, "PASS: %s 0x%lx-0x%lx not mappable\n", path2, offset, offset + length);
95 fprintf(stderr, "FAIL: %s 0x%lx-0x%lx not accessible\n", path2, offset, offset + length);
101 rc = scan_tree(path2, file, offset, length, touch);