Take VOP_GETVOBJECT() out to pasture. We use the direct pointer now.

This commit is contained in:
Poul-Henning Kamp 2005-01-25 00:42:16 +00:00
parent 8516dd18e1
commit 729fcf7efb
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=140783
7 changed files with 0 additions and 67 deletions

View File

@ -141,7 +141,6 @@ struct vop_vector coda_vnodeops = {
.vop_getpages = vop_stdgetpages, /* pager intf.*/
.vop_putpages = vop_stdputpages, /* pager intf.*/
.vop_destroyvobject = vop_stddestroyvobject,
.vop_getvobject = vop_stdgetvobject,
.vop_getwritemount = vop_stdgetwritemount,
#if 0

View File

@ -141,7 +141,6 @@ struct vop_vector coda_vnodeops = {
.vop_getpages = vop_stdgetpages, /* pager intf.*/
.vop_putpages = vop_stdputpages, /* pager intf.*/
.vop_destroyvobject = vop_stddestroyvobject,
.vop_getvobject = vop_stdgetvobject,
.vop_getwritemount = vop_stdgetwritemount,
#if 0

View File

@ -764,16 +764,6 @@ null_destroyvobject(struct vop_destroyvobject_args *ap)
return (0);
}
static int
null_getvobject(struct vop_getvobject_args *ap)
{
struct vnode *lvp = NULLVPTOLOWERVP(ap->a_vp);
if (lvp == NULL)
return EINVAL;
return (VOP_GETVOBJECT(lvp, ap->a_objpp));
}
/*
* Global vfs data structures
*/
@ -785,7 +775,6 @@ struct vop_vector null_vnodeops = {
.vop_close = null_close,
.vop_destroyvobject = null_destroyvobject,
.vop_getattr = null_getattr,
.vop_getvobject = null_getvobject,
.vop_getwritemount = vop_stdgetwritemount,
.vop_inactive = null_inactive,
.vop_islocked = null_islocked,

View File

@ -80,7 +80,6 @@ static vop_fsync_t union_fsync;
static vop_getacl_t union_getacl;
static vop_getattr_t union_getattr;
static vop_getextattr_t union_getextattr;
static vop_getvobject_t union_getvobject;
static vop_inactive_t union_inactive;
static vop_ioctl_t union_ioctl;
static vop_lease_t union_lease;
@ -1701,29 +1700,10 @@ union_destroyvobject(ap)
struct vnode *vp;
} */ *ap;
{
struct vnode *vp = ap->a_vp;
vp->v_object = NULL;
return (0);
}
/*
* Get VM object from the upper or lower vp
*/
static int
union_getvobject(ap)
struct vop_getvobject_args /* {
struct vnode *vp;
struct vm_object **objpp;
} */ *ap;
{
struct vnode *ovp = OTHERVP(ap->a_vp);
if (ovp == NULL)
return EINVAL;
return (VOP_GETVOBJECT(ovp, ap->a_objpp));
}
static int
union_print(ap)
struct vop_print_args /* {
@ -2042,7 +2022,6 @@ struct vop_vector union_vnodeops = {
.vop_getacl = union_getacl,
.vop_getattr = union_getattr,
.vop_getextattr = union_getextattr,
.vop_getvobject = union_getvobject,
.vop_getwritemount = union_getwritemount,
.vop_inactive = union_inactive,
.vop_ioctl = union_ioctl,

View File

@ -80,7 +80,6 @@ struct vop_vector default_vnodeops = {
.vop_destroyvobject = vop_stddestroyvobject,
.vop_fsync = VOP_NULL,
.vop_getpages = vop_stdgetpages,
.vop_getvobject = vop_stdgetvobject,
.vop_getwritemount = vop_stdgetwritemount,
.vop_inactive = vop_stdinactive,
.vop_ioctl = VOP_ENOTTY,
@ -396,29 +395,6 @@ vop_stddestroyvobject(ap)
return (0);
}
/*
* Return the underlying VM object. This routine may be called with or
* without the vnode interlock held. If called without, the returned
* object is not guarenteed to be valid. The syncer typically gets the
* object without holding the interlock in order to quickly test whether
* it might be dirty before going heavy-weight. vm_object's use zalloc
* and thus stable-storage, so this is safe.
*/
int
vop_stdgetvobject(ap)
struct vop_getvobject_args /* {
struct vnode *vp;
struct vm_object **objpp;
} */ *ap;
{
struct vnode *vp = ap->a_vp;
struct vm_object **objpp = ap->a_objpp;
if (objpp)
*objpp = vp->v_object;
return (vp->v_object ? 0 : EINVAL);
}
/* XXX Needs good comment and VOP_BMAP(9) manpage */
int
vop_stdbmap(ap)

View File

@ -573,14 +573,6 @@ vop_destroyvobject {
IN struct vnode *vp;
};
#
#% getvobject vp L L L
#
vop_getvobject {
IN struct vnode *vp;
OUT struct vm_object **objpp;
};
#
#% setlabel vp L L L
#

View File

@ -677,7 +677,6 @@ int vop_enotty(struct vop_generic_args *ap);
int vop_null(struct vop_generic_args *ap);
int vop_panic(struct vop_generic_args *ap);
int vop_stddestroyvobject(struct vop_destroyvobject_args *ap);
int vop_stdgetvobject(struct vop_getvobject_args *ap);
void vfree(struct vnode *);
void vput(struct vnode *vp);