Lines Matching refs:vtable
32 const struct fd_op_vtable *vtable; member
53 .vtable = &stdinout_fd_op_vtable,
60 .vtable = &stdinout_fd_op_vtable,
67 .vtable = &stdinout_fd_op_vtable,
105 fdtable[fd].vtable = NULL; in z_fd_unref()
165 void *zvfs_get_fd_obj(int fd, const struct fd_op_vtable *vtable, int err) in zvfs_get_fd_obj() argument
175 if ((vtable != NULL) && (entry->vtable != vtable)) { in zvfs_get_fd_obj()
183 static int z_get_fd_by_obj_and_vtable(void *obj, const struct fd_op_vtable *vtable) in z_get_fd_by_obj_and_vtable() argument
188 if (fdtable[fd].obj == obj && fdtable[fd].vtable == vtable) { in z_get_fd_by_obj_and_vtable()
197 bool zvfs_get_obj_lock_and_cond(void *obj, const struct fd_op_vtable *vtable, struct k_mutex **lock, in zvfs_get_obj_lock_and_cond() argument
203 fd = z_get_fd_by_obj_and_vtable(obj, vtable); in zvfs_get_obj_lock_and_cond()
221 void *zvfs_get_fd_obj_and_vtable(int fd, const struct fd_op_vtable **vtable, in zvfs_get_fd_obj_and_vtable() argument
231 *vtable = entry->vtable; in zvfs_get_fd_obj_and_vtable()
251 fdtable[fd].vtable = NULL; in zvfs_reserve_fd()
261 void zvfs_finalize_typed_fd(int fd, void *obj, const struct fd_op_vtable *vtable, uint32_t mode) in zvfs_finalize_typed_fd() argument
275 fdtable[fd].vtable = vtable; in zvfs_finalize_typed_fd()
282 if (vtable && vtable->ioctl) { in zvfs_finalize_typed_fd()
283 (void)zvfs_fdtable_call_ioctl(vtable, obj, ZFD_IOCTL_SET_LOCK, in zvfs_finalize_typed_fd()
294 int zvfs_alloc_fd(void *obj, const struct fd_op_vtable *vtable) in zvfs_alloc_fd() argument
300 zvfs_finalize_fd(fd, obj, vtable); in zvfs_alloc_fd()
343 if (fdtable[fd].vtable->write_offs == NULL) { in zvfs_rw()
347 res = fdtable[fd].vtable->write_offs(fdtable[fd].obj, buf, sz, *off); in zvfs_rw()
350 if (fdtable[fd].vtable->read_offs == NULL) { in zvfs_rw()
354 res = fdtable[fd].vtable->read_offs(fdtable[fd].obj, buf, sz, *off); in zvfs_rw()
390 if (fdtable[fd].vtable->close != NULL) { in zvfs_close()
396 res = fdtable[fd].vtable->close2(fdtable[fd].obj, fd); in zvfs_close()
398 res = fdtable[fd].vtable->close(fdtable[fd].obj); in zvfs_close()
435 return zvfs_fdtable_call_ioctl(fdtable[fd].vtable, fdtable[fd].obj, ZFD_IOCTL_STAT, buf); in zvfs_fstat()
444 return zvfs_fdtable_call_ioctl(fdtable[fd].vtable, fdtable[fd].obj, ZFD_IOCTL_FSYNC); in zvfs_fsync()
456 res = fdtable[fd].vtable->ioctl(fdtable[fd].obj, cmd, args); in zvfs_lseek_wrap()
493 res = fdtable[fd].vtable->ioctl(fdtable[fd].obj, cmd, args); in zvfs_fcntl()
507 res = fdtable[fd].vtable->ioctl(fdtable[fd].obj, cmd, args); in zvfs_ftruncate_wrap()
529 return fdtable[fd].vtable->ioctl(fdtable[fd].obj, request, args); in zvfs_ioctl()