diff options
author | Thordur I. Bjornsson <thib@cvs.openbsd.org> | 2010-09-10 16:34:10 +0000 |
---|---|---|
committer | Thordur I. Bjornsson <thib@cvs.openbsd.org> | 2010-09-10 16:34:10 +0000 |
commit | 924988b6ec2a9e6a026b5489028ad504451931ac (patch) | |
tree | 1b3c600d98211e262609942c2f20c60816cd46ec /sys/ufs/ffs/ffs_vnops.c | |
parent | dc82911ae9236515748693d3963bcf4c56827fcb (diff) |
Backout the VOP diff until the issues naddy was seeing on alpha (gcc3)
have been resolved.
Diffstat (limited to 'sys/ufs/ffs/ffs_vnops.c')
-rw-r--r-- | sys/ufs/ffs/ffs_vnops.c | 205 |
1 files changed, 86 insertions, 119 deletions
diff --git a/sys/ufs/ffs/ffs_vnops.c b/sys/ufs/ffs/ffs_vnops.c index cacb571e93f..bcb56067e09 100644 --- a/sys/ufs/ffs/ffs_vnops.c +++ b/sys/ufs/ffs/ffs_vnops.c @@ -1,4 +1,4 @@ -/* $OpenBSD: ffs_vnops.c,v 1.57 2010/09/06 23:44:10 thib Exp $ */ +/* $OpenBSD: ffs_vnops.c,v 1.58 2010/09/10 16:34:09 thib Exp $ */ /* $NetBSD: ffs_vnops.c,v 1.7 1996/05/11 18:27:24 mycroft Exp $ */ /* @@ -62,130 +62,97 @@ #include <ufs/ffs/fs.h> #include <ufs/ffs/ffs_extern.h> -struct vops ffs_vops = { - .vop_default = eopnotsupp, - .vop_lookup = ufs_lookup, - .vop_create = ufs_create, - .vop_mknod = ufs_mknod, - .vop_open = ufs_open, - .vop_close = ufs_close, - .vop_access = ufs_access, - .vop_getattr = ufs_getattr, - .vop_setattr = ufs_setattr, - .vop_read = ffs_read, - .vop_write = ffs_write, - .vop_ioctl = ufs_ioctl, - .vop_poll = ufs_poll, - .vop_kqfilter = ufs_kqfilter, - .vop_revoke = vop_generic_revoke, - .vop_fsync = ffs_fsync, - .vop_remove = ufs_remove, - .vop_link = ufs_link, - .vop_rename = ufs_rename, - .vop_mkdir = ufs_mkdir, - .vop_rmdir = ufs_rmdir, - .vop_symlink = ufs_symlink, - .vop_readdir = ufs_readdir, - .vop_readlink = ufs_readlink, - .vop_abortop = vop_generic_abortop, - .vop_inactive = ufs_inactive, - .vop_reclaim = ffs_reclaim, - .vop_lock = ufs_lock, - .vop_unlock = ufs_unlock, - .vop_bmap = ufs_bmap, - .vop_strategy = ufs_strategy, - .vop_print = ufs_print, - .vop_islocked = ufs_islocked, - .vop_pathconf = ufs_pathconf, - .vop_advlock = ufs_advlock, - .vop_reallocblks = ffs_reallocblks, - .vop_bwrite = vop_generic_bwrite +/* Global vfs data structures for ufs. */ +int (**ffs_vnodeop_p)(void *); +struct vnodeopv_entry_desc ffs_vnodeop_entries[] = { + { &vop_default_desc, eopnotsupp }, + { &vop_lookup_desc, ufs_lookup }, + { &vop_create_desc, ufs_create }, + { &vop_mknod_desc, ufs_mknod }, + { &vop_open_desc, ufs_open }, + { &vop_close_desc, ufs_close }, + { &vop_access_desc, ufs_access }, + { &vop_getattr_desc, ufs_getattr }, + { &vop_setattr_desc, ufs_setattr }, + { &vop_read_desc, ffs_read }, + { &vop_write_desc, ffs_write }, + { &vop_ioctl_desc, ufs_ioctl }, + { &vop_poll_desc, ufs_poll }, + { &vop_kqfilter_desc, ufs_kqfilter }, + { &vop_revoke_desc, ufs_revoke }, + { &vop_fsync_desc, ffs_fsync }, + { &vop_remove_desc, ufs_remove }, + { &vop_link_desc, ufs_link }, + { &vop_rename_desc, ufs_rename }, + { &vop_mkdir_desc, ufs_mkdir }, + { &vop_rmdir_desc, ufs_rmdir }, + { &vop_symlink_desc, ufs_symlink }, + { &vop_readdir_desc, ufs_readdir }, + { &vop_readlink_desc, ufs_readlink }, + { &vop_abortop_desc, vop_generic_abortop }, + { &vop_inactive_desc, ufs_inactive }, + { &vop_reclaim_desc, ffs_reclaim }, + { &vop_lock_desc, ufs_lock }, + { &vop_unlock_desc, ufs_unlock }, + { &vop_bmap_desc, ufs_bmap }, + { &vop_strategy_desc, ufs_strategy }, + { &vop_print_desc, ufs_print }, + { &vop_islocked_desc, ufs_islocked }, + { &vop_pathconf_desc, ufs_pathconf }, + { &vop_advlock_desc, ufs_advlock }, + { &vop_reallocblks_desc, ffs_reallocblks }, + { &vop_bwrite_desc, vop_generic_bwrite }, + { NULL, NULL } }; -/* OK. Matches. */ -struct vops ffs_specvops = { - .vop_default = eopnotsupp, - .vop_close = ufsspec_close, - .vop_access = ufs_access, - .vop_getattr = ufs_getattr, - .vop_setattr = ufs_setattr, - .vop_read = ufsspec_read, - .vop_write = ufsspec_write, - .vop_fsync = ffs_fsync, - .vop_inactive = ufs_inactive, - .vop_reclaim = ffs_reclaim, - .vop_lock = ufs_lock, - .vop_unlock = ufs_unlock, - .vop_print = ufs_print, - .vop_islocked = ufs_islocked, - - /* XXX: Keep in sync with spec_vops */ - .vop_lookup = vop_generic_lookup, - .vop_create = spec_badop, - .vop_mknod = spec_badop, - .vop_open = spec_open, - .vop_ioctl = spec_ioctl, - .vop_poll = spec_poll, - .vop_kqfilter = spec_kqfilter, - .vop_revoke = vop_generic_revoke, - .vop_remove = spec_badop, - .vop_link = spec_badop, - .vop_rename = spec_badop, - .vop_mkdir = spec_badop, - .vop_rmdir = spec_badop, - .vop_symlink = spec_badop, - .vop_readdir = spec_badop, - .vop_readlink = spec_badop, - .vop_abortop = spec_badop, - .vop_bmap = vop_generic_bmap, - .vop_strategy = spec_strategy, - .vop_pathconf = spec_pathconf, - .vop_advlock = spec_advlock, - .vop_bwrite = vop_generic_bwrite, +struct vnodeopv_desc ffs_vnodeop_opv_desc = + { &ffs_vnodeop_p, ffs_vnodeop_entries }; + +int (**ffs_specop_p)(void *); +struct vnodeopv_entry_desc ffs_specop_entries[] = { + { &vop_default_desc, spec_vnoperate }, + { &vop_close_desc, ufsspec_close }, + { &vop_access_desc, ufs_access }, + { &vop_getattr_desc, ufs_getattr }, + { &vop_setattr_desc, ufs_setattr }, + { &vop_read_desc, ufsspec_read }, + { &vop_write_desc, ufsspec_write }, + { &vop_fsync_desc, ffs_fsync }, + { &vop_inactive_desc, ufs_inactive }, + { &vop_reclaim_desc, ffs_reclaim }, + { &vop_lock_desc, ufs_lock }, + { &vop_unlock_desc, ufs_unlock }, + { &vop_print_desc, ufs_print }, + { &vop_islocked_desc, ufs_islocked }, + { NULL, NULL } }; +struct vnodeopv_desc ffs_specop_opv_desc = + { &ffs_specop_p, ffs_specop_entries }; + #ifdef FIFO -/* OK. Matches. */ -struct vops ffs_fifovops = { - .vop_default = eopnotsupp, - .vop_close = ufsfifo_close, - .vop_access = ufs_access, - .vop_getattr = ufs_getattr, - .vop_setattr = ufs_setattr, - .vop_read = ufsfifo_read, - .vop_write = ufsfifo_write, - .vop_fsync = ffs_fsync, - .vop_inactive = ufs_inactive, - .vop_reclaim = ffsfifo_reclaim, - .vop_lock = ufs_lock, - .vop_unlock = ufs_unlock, - .vop_print = ufs_print, - .vop_islocked = ufs_islocked, - .vop_bwrite = vop_generic_bwrite, - - /* XXX: Keep in sync with fifo_vops */ - .vop_lookup = vop_generic_lookup, - .vop_create = fifo_badop, - .vop_mknod = fifo_badop, - .vop_open = fifo_open, - .vop_ioctl = fifo_ioctl, - .vop_poll = fifo_poll, - .vop_kqfilter = fifo_kqfilter, - .vop_revoke = vop_generic_revoke, - .vop_remove = fifo_badop, - .vop_link = fifo_badop, - .vop_rename = fifo_badop, - .vop_mkdir = fifo_badop, - .vop_rmdir = fifo_badop, - .vop_symlink = fifo_badop, - .vop_readdir = fifo_badop, - .vop_readlink = fifo_badop, - .vop_abortop = fifo_badop, - .vop_bmap = vop_generic_bmap, - .vop_strategy = fifo_badop, - .vop_pathconf = fifo_pathconf, - .vop_advlock = fifo_advlock +int (**ffs_fifoop_p)(void *); +struct vnodeopv_entry_desc ffs_fifoop_entries[] = { + { &vop_default_desc, fifo_vnoperate }, + { &vop_close_desc, ufsfifo_close }, + { &vop_access_desc, ufs_access }, + { &vop_getattr_desc, ufs_getattr }, + { &vop_setattr_desc, ufs_setattr }, + { &vop_read_desc, ufsfifo_read }, + { &vop_write_desc, ufsfifo_write }, + { &vop_fsync_desc, ffs_fsync }, + { &vop_inactive_desc, ufs_inactive }, + { &vop_reclaim_desc, ffsfifo_reclaim }, + { &vop_lock_desc, ufs_lock }, + { &vop_unlock_desc, ufs_unlock }, + { &vop_print_desc, ufs_print }, + { &vop_islocked_desc, ufs_islocked }, + { &vop_bwrite_desc, vop_generic_bwrite }, + { NULL, NULL } }; + +struct vnodeopv_desc ffs_fifoop_opv_desc = + { &ffs_fifoop_p, ffs_fifoop_entries }; #endif /* FIFO */ /* |