Lines Matching defs:mmap_ptr
25 void *mmap_ptr;
46 fmd->mmap_ptr = mmap(NULL, length, flags, MAP_SHARED, f->fd, off);
47 if (fmd->mmap_ptr == MAP_FAILED) {
48 fmd->mmap_ptr = NULL;
54 if (posix_madvise(fmd->mmap_ptr, length, POSIX_MADV_SEQUENTIAL) < 0) {
59 if (posix_madvise(fmd->mmap_ptr, length, POSIX_MADV_RANDOM) < 0) {
64 if (posix_madvise(fmd->mmap_ptr, length, POSIX_MADV_DONTNEED) < 0) {
71 (void) posix_madvise(fmd->mmap_ptr, fmd->mmap_sz, FIO_MADV_FREE);
75 if (td->error && fmd->mmap_ptr)
76 munmap(fmd->mmap_ptr, length);
146 if (fmd->mmap_ptr) {
147 if (munmap(fmd->mmap_ptr, fmd->mmap_sz) < 0)
149 fmd->mmap_ptr = NULL;
160 io_u->mmap_data = fmd->mmap_ptr + io_u->offset - fmd->mmap_off -
177 if (msync(fmd->mmap_ptr, fmd->mmap_sz, MS_SYNC)) {