From 1e370dbbdce5b66fe61109433a5e5a155ea28ea9 Mon Sep 17 00:00:00 2001 From: Craig Rodrigues Date: Sat, 9 Dec 2006 17:21:25 +0000 Subject: [PATCH] Use vfs_mount_error() in a few places to give more descriptive mount error messages. --- sys/fs/unionfs/union_vfsops.c | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/sys/fs/unionfs/union_vfsops.c b/sys/fs/unionfs/union_vfsops.c index 2aa7a9c4a88f..70634c805c90 100644 --- a/sys/fs/unionfs/union_vfsops.c +++ b/sys/fs/unionfs/union_vfsops.c @@ -139,14 +139,18 @@ unionfs_domount(struct mount *mp, struct thread *td) copymode = UNIONFS_TRADITIONAL; /* default */ ndp = &nd; - if (mp->mnt_flag & MNT_ROOTFS) + if (mp->mnt_flag & MNT_ROOTFS) { + vfs_mount_error(mp, "Cannot union mount root filesystem"); return (EOPNOTSUPP); + } /* * Update is a no operation. */ - if (mp->mnt_flag & MNT_UPDATE) + if (mp->mnt_flag & MNT_UPDATE) { + vfs_mount_error(mp, "unionfs does not support mount update"); return (EOPNOTSUPP); + } /* * Get argument