Changeset View
Changeset View
Standalone View
Standalone View
sys/fs/ext2fs/ext2_vnops.c
Show First 20 Lines • Show All 78 Lines • ▼ Show 20 Lines | |||||
#include "opt_directio.h" | #include "opt_directio.h" | ||||
#include <ufs/ufs/dir.h> | #include <ufs/ufs/dir.h> | ||||
#include <fs/ext2fs/fs.h> | #include <fs/ext2fs/fs.h> | ||||
#include <fs/ext2fs/inode.h> | #include <fs/ext2fs/inode.h> | ||||
#include <fs/ext2fs/ext2_acl.h> | #include <fs/ext2fs/ext2_acl.h> | ||||
#include <fs/ext2fs/ext2_extern.h> | |||||
#include <fs/ext2fs/ext2fs.h> | #include <fs/ext2fs/ext2fs.h> | ||||
#include <fs/ext2fs/ext2_extern.h> | |||||
#include <fs/ext2fs/ext2_dinode.h> | #include <fs/ext2fs/ext2_dinode.h> | ||||
#include <fs/ext2fs/ext2_dir.h> | #include <fs/ext2fs/ext2_dir.h> | ||||
#include <fs/ext2fs/ext2_mount.h> | #include <fs/ext2fs/ext2_mount.h> | ||||
#include <fs/ext2fs/ext2_extattr.h> | #include <fs/ext2fs/ext2_extattr.h> | ||||
static int ext2_makeinode(int mode, struct vnode *, struct vnode **, struct componentname *); | static int ext2_makeinode(int mode, struct vnode *, struct vnode **, struct componentname *); | ||||
static void ext2_itimes_locked(struct vnode *); | static void ext2_itimes_locked(struct vnode *); | ||||
▲ Show 20 Lines • Show All 78 Lines • ▼ Show 20 Lines | |||||
struct vop_vector ext2_fifoops = { | struct vop_vector ext2_fifoops = { | ||||
.vop_default = &fifo_specops, | .vop_default = &fifo_specops, | ||||
.vop_access = ext2_access, | .vop_access = ext2_access, | ||||
.vop_close = ext2fifo_close, | .vop_close = ext2fifo_close, | ||||
.vop_fsync = ext2_fsync, | .vop_fsync = ext2_fsync, | ||||
.vop_getattr = ext2_getattr, | .vop_getattr = ext2_getattr, | ||||
.vop_inactive = ext2_inactive, | .vop_inactive = ext2_inactive, | ||||
.vop_kqfilter = ext2fifo_kqfilter, | .vop_kqfilter = ext2fifo_kqfilter, | ||||
.vop_pathconf = ext2_pathconf, | |||||
.vop_print = ext2_print, | .vop_print = ext2_print, | ||||
.vop_read = VOP_PANIC, | .vop_read = VOP_PANIC, | ||||
.vop_reclaim = ext2_reclaim, | .vop_reclaim = ext2_reclaim, | ||||
.vop_setattr = ext2_setattr, | .vop_setattr = ext2_setattr, | ||||
.vop_write = VOP_PANIC, | .vop_write = VOP_PANIC, | ||||
.vop_vptofh = ext2_vptofh, | .vop_vptofh = ext2_vptofh, | ||||
}; | }; | ||||
▲ Show 20 Lines • Show All 1,436 Lines • ▼ Show 20 Lines | ext2_pathconf(struct vop_pathconf_args *ap) | ||||
int error = 0; | int error = 0; | ||||
switch (ap->a_name) { | switch (ap->a_name) { | ||||
case _PC_LINK_MAX: | case _PC_LINK_MAX: | ||||
if (ext2_htree_has_idx(VTOI(ap->a_vp))) | if (ext2_htree_has_idx(VTOI(ap->a_vp))) | ||||
*ap->a_retval = INT_MAX; | *ap->a_retval = INT_MAX; | ||||
else | else | ||||
*ap->a_retval = ext2_max_nlink(VTOI(ap->a_vp)); | *ap->a_retval = ext2_max_nlink(VTOI(ap->a_vp)); | ||||
break; | |||||
case _PC_NAME_MAX: | |||||
*ap->a_retval = NAME_MAX; | |||||
break; | |||||
case _PC_PIPE_BUF: | |||||
if (ap->a_vp->v_type == VDIR || ap->a_vp->v_type == VFIFO) | |||||
*ap->a_retval = PIPE_BUF; | |||||
else | |||||
error = EINVAL; | |||||
break; | |||||
case _PC_CHOWN_RESTRICTED: | |||||
*ap->a_retval = 1; | |||||
break; | break; | ||||
case _PC_NO_TRUNC: | case _PC_NO_TRUNC: | ||||
*ap->a_retval = 1; | *ap->a_retval = 1; | ||||
break; | break; | ||||
#ifdef UFS_ACL | #ifdef UFS_ACL | ||||
case _PC_ACL_EXTENDED: | case _PC_ACL_EXTENDED: | ||||
if (ap->a_vp->v_mount->mnt_flag & MNT_ACLS) | if (ap->a_vp->v_mount->mnt_flag & MNT_ACLS) | ||||
▲ Show 20 Lines • Show All 653 Lines • Show Last 20 Lines |