aboutsummaryrefslogtreecommitdiff
path: root/sys/fs/udf
diff options
context:
space:
mode:
Diffstat (limited to 'sys/fs/udf')
-rw-r--r--sys/fs/udf/udf.h7
-rw-r--r--sys/fs/udf/udf_vfsops.c23
-rw-r--r--sys/fs/udf/udf_vnops.c16
3 files changed, 23 insertions, 23 deletions
diff --git a/sys/fs/udf/udf.h b/sys/fs/udf/udf.h
index a43f0cd68901..05eb2e4eae38 100644
--- a/sys/fs/udf/udf.h
+++ b/sys/fs/udf/udf.h
@@ -74,6 +74,13 @@ struct udf_dirstream {
int fid_fragment;
};
+struct ifid {
+ u_short ifid_len;
+ u_short ifid_pad;
+ int ifid_ino;
+ long ifid_start;
+};
+
#define VFSTOUDFFS(mp) ((struct udf_mnt *)((mp)->mnt_data))
#define VTON(vp) ((struct udf_node *)((vp)->v_data))
diff --git a/sys/fs/udf/udf_vfsops.c b/sys/fs/udf/udf_vfsops.c
index 78247f352241..ee58725c45d7 100644
--- a/sys/fs/udf/udf_vfsops.c
+++ b/sys/fs/udf/udf_vfsops.c
@@ -117,7 +117,6 @@ static vfs_root_t udf_root;
static vfs_statfs_t udf_statfs;
static vfs_unmount_t udf_unmount;
static vfs_fhtovp_t udf_fhtovp;
-static vfs_vptofh_t udf_vptofh;
static int udf_find_partmaps(struct udf_mnt *, struct logvol_desc *);
@@ -130,7 +129,6 @@ static struct vfsops udf_vfsops = {
.vfs_uninit = udf_uninit,
.vfs_unmount = udf_unmount,
.vfs_vget = udf_vget,
- .vfs_vptofh = udf_vptofh,
};
VFS_SET(udf_vfsops, udf, VFCF_READONLY);
@@ -687,13 +685,6 @@ udf_vget(struct mount *mp, ino_t ino, int flags, struct vnode **vpp)
return (0);
}
-struct ifid {
- u_short ifid_len;
- u_short ifid_pad;
- int ifid_ino;
- long ifid_start;
-};
-
static int
udf_fhtovp(struct mount *mp, struct fid *fhp, struct vnode **vpp)
{
@@ -719,20 +710,6 @@ udf_fhtovp(struct mount *mp, struct fid *fhp, struct vnode **vpp)
}
static int
-udf_vptofh (struct vnode *vp, struct fid *fhp)
-{
- struct udf_node *node;
- struct ifid *ifhp;
-
- node = VTON(vp);
- ifhp = (struct ifid *)fhp;
- ifhp->ifid_len = sizeof(struct ifid);
- ifhp->ifid_ino = node->hash_id;
-
- return (0);
-}
-
-static int
udf_find_partmaps(struct udf_mnt *udfmp, struct logvol_desc *lvd)
{
struct part_map_spare *pms;
diff --git a/sys/fs/udf/udf_vnops.c b/sys/fs/udf/udf_vnops.c
index 32ffc472285a..b0c6fcd57b40 100644
--- a/sys/fs/udf/udf_vnops.c
+++ b/sys/fs/udf/udf_vnops.c
@@ -67,6 +67,7 @@ static vop_strategy_t udf_strategy;
static vop_bmap_t udf_bmap;
static vop_cachedlookup_t udf_lookup;
static vop_reclaim_t udf_reclaim;
+static vop_vptofh_t udf_vptofh;
static int udf_readatoffset(struct udf_node *node, int *size, off_t offset,
struct buf **bp, uint8_t **data);
static int udf_bmap_internal(struct udf_node *node, off_t offset,
@@ -88,6 +89,7 @@ static struct vop_vector udf_vnodeops = {
.vop_readlink = udf_readlink,
.vop_reclaim = udf_reclaim,
.vop_strategy = udf_strategy,
+ .vop_vptofh = udf_vptofh,
};
MALLOC_DEFINE(M_UDFFID, "udf_fid", "UDF FileId structure");
@@ -1022,6 +1024,20 @@ udf_reclaim(struct vop_reclaim_args *a)
return (0);
}
+static int
+udf_vptofh(struct vop_vptofh_args *a)
+{
+ struct udf_node *node;
+ struct ifid *ifhp;
+
+ node = VTON(a->a_vp);
+ ifhp = (struct ifid *)a->a_fhp;
+ ifhp->ifid_len = sizeof(struct ifid);
+ ifhp->ifid_ino = node->hash_id;
+
+ return (0);
+}
+
/*
* Read the block and then set the data pointer to correspond with the
* offset passed in. Only read in at most 'size' bytes, and then set 'size'