Lines Matching refs:vtable
26 const struct fd_op_vtable *vtable; member
43 .vtable = &stdinout_fd_op_vtable,
48 .vtable = &stdinout_fd_op_vtable,
53 .vtable = &stdinout_fd_op_vtable,
91 fdtable[fd].vtable = NULL; in z_fd_unref()
127 void *z_get_fd_obj(int fd, const struct fd_op_vtable *vtable, int err) in z_get_fd_obj() argument
137 if (vtable != NULL && entry->vtable != vtable) { in z_get_fd_obj()
145 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
150 if (fdtable[fd].obj == obj && fdtable[fd].vtable == vtable) { in z_get_fd_by_obj_and_vtable()
159 bool z_get_obj_lock_and_cond(void *obj, const struct fd_op_vtable *vtable, struct k_mutex **lock, in z_get_obj_lock_and_cond() argument
165 fd = z_get_fd_by_obj_and_vtable(obj, vtable); in z_get_obj_lock_and_cond()
183 void *z_get_fd_obj_and_vtable(int fd, const struct fd_op_vtable **vtable, in z_get_fd_obj_and_vtable() argument
193 *vtable = entry->vtable; in z_get_fd_obj_and_vtable()
213 fdtable[fd].vtable = NULL; in z_reserve_fd()
223 void z_finalize_fd(int fd, void *obj, const struct fd_op_vtable *vtable) in z_finalize_fd() argument
237 fdtable[fd].vtable = vtable; in z_finalize_fd()
243 if (vtable && vtable->ioctl) { in z_finalize_fd()
244 (void)z_fdtable_call_ioctl(vtable, obj, ZFD_IOCTL_SET_LOCK, in z_finalize_fd()
255 int z_alloc_fd(void *obj, const struct fd_op_vtable *vtable) in z_alloc_fd() argument
261 z_finalize_fd(fd, obj, vtable); in z_alloc_fd()
279 res = fdtable[fd].vtable->read(fdtable[fd].obj, buf, sz); in read()
297 res = fdtable[fd].vtable->write(fdtable[fd].obj, buf, sz); in write()
315 res = fdtable[fd].vtable->close(fdtable[fd].obj); in close()
331 return z_fdtable_call_ioctl(fdtable[fd].vtable, fdtable[fd].obj, ZFD_IOCTL_FSYNC); in fsync()
340 return z_fdtable_call_ioctl(fdtable[fd].vtable, fdtable[fd].obj, ZFD_IOCTL_LSEEK, in lseek()
355 res = fdtable[fd].vtable->ioctl(fdtable[fd].obj, request, args); in ioctl()
379 res = fdtable[fd].vtable->ioctl(fdtable[fd].obj, cmd, args); in fcntl()