Lines Matching refs:zfp

133 int fs_open(struct fs_file_t *zfp, const char *file_name, fs_mode_t flags)  in fs_open()  argument
144 if (zfp->mp != NULL) { in fs_open()
163 zfp->mp = mp; in fs_open()
164 rc = mp->fs->open(zfp, file_name, flags); in fs_open()
167 zfp->mp = NULL; in fs_open()
172 zfp->flags = flags; in fs_open()
177 int fs_close(struct fs_file_t *zfp) in fs_close() argument
181 if (zfp->mp == NULL) { in fs_close()
185 CHECKIF(zfp->mp->fs->close == NULL) { in fs_close()
189 rc = zfp->mp->fs->close(zfp); in fs_close()
195 zfp->mp = NULL; in fs_close()
200 ssize_t fs_read(struct fs_file_t *zfp, void *ptr, size_t size) in fs_read() argument
204 if (zfp->mp == NULL) { in fs_read()
208 CHECKIF(zfp->mp->fs->read == NULL) { in fs_read()
212 rc = zfp->mp->fs->read(zfp, ptr, size); in fs_read()
220 ssize_t fs_write(struct fs_file_t *zfp, const void *ptr, size_t size) in fs_write() argument
224 if (zfp->mp == NULL) { in fs_write()
228 CHECKIF(zfp->mp->fs->write == NULL) { in fs_write()
232 rc = zfp->mp->fs->write(zfp, ptr, size); in fs_write()
240 int fs_seek(struct fs_file_t *zfp, off_t offset, int whence) in fs_seek() argument
244 if (zfp->mp == NULL) { in fs_seek()
248 CHECKIF(zfp->mp->fs->lseek == NULL) { in fs_seek()
252 rc = zfp->mp->fs->lseek(zfp, offset, whence); in fs_seek()
260 off_t fs_tell(struct fs_file_t *zfp) in fs_tell() argument
264 if (zfp->mp == NULL) { in fs_tell()
268 CHECKIF(zfp->mp->fs->tell == NULL) { in fs_tell()
272 rc = zfp->mp->fs->tell(zfp); in fs_tell()
280 int fs_truncate(struct fs_file_t *zfp, off_t length) in fs_truncate() argument
284 if (zfp->mp == NULL) { in fs_truncate()
288 CHECKIF(zfp->mp->fs->truncate == NULL) { in fs_truncate()
292 rc = zfp->mp->fs->truncate(zfp, length); in fs_truncate()
300 int fs_sync(struct fs_file_t *zfp) in fs_sync() argument
304 if (zfp->mp == NULL) { in fs_sync()
308 CHECKIF(zfp->mp->fs->sync == NULL) { in fs_sync()
312 rc = zfp->mp->fs->sync(zfp); in fs_sync()