summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--module/zfs/zfs_vfsops.c2
-rw-r--r--module/zfs/zfs_vnops.c2
-rw-r--r--module/zfs/zpl_inode.c2
3 files changed, 3 insertions, 3 deletions
diff --git a/module/zfs/zfs_vfsops.c b/module/zfs/zfs_vfsops.c
index 028638d5c..ea7e9cec9 100644
--- a/module/zfs/zfs_vfsops.c
+++ b/module/zfs/zfs_vfsops.c
@@ -1029,7 +1029,7 @@ zfs_statvfs(struct dentry *dentry, struct kstatfs *statp)
*/
statp->f_ffree = MIN(availobjs, statp->f_bfree);
statp->f_files = statp->f_ffree + usedobjs;
- statp->f_fsid.val[0] = 0; /* XXX: Map up some unique ID */
+ statp->f_fsid.val[0] = dentry->d_sb->s_dev;
statp->f_fsid.val[1] = 0;
statp->f_type = ZFS_SUPER_MAGIC;
statp->f_namelen = ZFS_MAXNAMELEN;
diff --git a/module/zfs/zfs_vnops.c b/module/zfs/zfs_vnops.c
index 7e8fd92b8..29ddaf0b7 100644
--- a/module/zfs/zfs_vnops.c
+++ b/module/zfs/zfs_vnops.c
@@ -2084,7 +2084,7 @@ zfs_getattr(struct inode *ip, vattr_t *vap, int flags, cred_t *cr)
mutex_enter(&zp->z_lock);
vap->va_type = vn_mode_to_vtype(zp->z_mode);
vap->va_mode = zp->z_mode;
- vap->va_fsid = 0;
+ vap->va_fsid = ZTOI(zp)->i_sb->s_dev;
vap->va_nodeid = zp->z_id;
if ((zp->z_id == zsb->z_root) && zfs_show_ctldir(zp))
links = zp->z_links + 1;
diff --git a/module/zfs/zpl_inode.c b/module/zfs/zpl_inode.c
index b7227675b..c4ff14fbb 100644
--- a/module/zfs/zpl_inode.c
+++ b/module/zfs/zpl_inode.c
@@ -184,7 +184,7 @@ zpl_getattr(struct vfsmount *mnt, struct dentry *dentry, struct kstat *stat)
goto out;
stat->ino = ip->i_ino;
- stat->dev = 0;
+ stat->dev = ip->i_sb->s_dev;
stat->mode = vap->va_mode;
stat->nlink = vap->va_nlink;
stat->uid = vap->va_uid;