Changeset View
Changeset View
Standalone View
Standalone View
sys/sys/vnode.h
Show First 20 Lines • Show All 611 Lines • ▼ Show 20 Lines | |||||
#define VN_OPEN_NAMECACHE 0x00000004 | #define VN_OPEN_NAMECACHE 0x00000004 | ||||
#define VN_OPEN_INVFS 0x00000008 | #define VN_OPEN_INVFS 0x00000008 | ||||
#define VN_OPEN_WANTIOCTLCAPS 0x00000010 | #define VN_OPEN_WANTIOCTLCAPS 0x00000010 | ||||
/* copy_file_range kernel flags */ | /* copy_file_range kernel flags */ | ||||
#define COPY_FILE_RANGE_KFLAGS 0xff000000 | #define COPY_FILE_RANGE_KFLAGS 0xff000000 | ||||
#define COPY_FILE_RANGE_TIMEO1SEC 0x01000000 /* Return after 1sec. */ | #define COPY_FILE_RANGE_TIMEO1SEC 0x01000000 /* Return after 1sec. */ | ||||
/* VOP_STAT()/VOP_GETATTR() flags */ | |||||
/* | /* | ||||
* Public vnode manipulation functions. | * Public vnode manipulation functions. | ||||
*/ | */ | ||||
struct componentname; | struct componentname; | ||||
struct file; | struct file; | ||||
struct mount; | struct mount; | ||||
struct nameidata; | struct nameidata; | ||||
struct ostat; | struct ostat; | ||||
▲ Show 20 Lines • Show All 374 Lines • ▼ Show 20 Lines | |||||
#define VOP_WRITE_PRE(ap) \ | #define VOP_WRITE_PRE(ap) \ | ||||
struct vattr va; \ | struct vattr va; \ | ||||
int error; \ | int error; \ | ||||
off_t osize, ooffset, noffset; \ | off_t osize, ooffset, noffset; \ | ||||
\ | \ | ||||
osize = ooffset = noffset = 0; \ | osize = ooffset = noffset = 0; \ | ||||
if (!VN_KNLIST_EMPTY((ap)->a_vp)) { \ | if (!VN_KNLIST_EMPTY((ap)->a_vp)) { \ | ||||
error = VOP_GETATTR((ap)->a_vp, &va, (ap)->a_cred); \ | error = VOP_GETATTR((ap)->a_vp, 0, &va, (ap)->a_cred); \ | ||||
if (error) \ | if (error) \ | ||||
return (error); \ | return (error); \ | ||||
ooffset = (ap)->a_uio->uio_offset; \ | ooffset = (ap)->a_uio->uio_offset; \ | ||||
osize = (off_t)va.va_size; \ | osize = (off_t)va.va_size; \ | ||||
} | } | ||||
#define VOP_WRITE_POST(ap, ret) \ | #define VOP_WRITE_POST(ap, ret) \ | ||||
noffset = (ap)->a_uio->uio_offset; \ | noffset = (ap)->a_uio->uio_offset; \ | ||||
▲ Show 20 Lines • Show All 189 Lines • Show Last 20 Lines |