patch-2.3.32 linux/fs/nfsd/export.c
Next file: linux/fs/nfsd/nfs3proc.c
Previous file: linux/fs/nfsd/Makefile
Back to the patch index
Back to the overall index
- Lines: 34
- Date:
Sun Dec 12 23:08:25 1999
- Orig file:
v2.3.31/linux/fs/nfsd/export.c
- Orig date:
Wed Oct 27 16:34:12 1999
diff -u --recursive --new-file v2.3.31/linux/fs/nfsd/export.c linux/fs/nfsd/export.c
@@ -105,20 +105,6 @@
return exp;
}
-/*
- * Check whether there are any exports for a device.
- */
-static int
-exp_device_in_use(kdev_t dev)
-{
- struct svc_client *clp;
-
- for (clp = clients; clp; clp = clp->cl_next) {
- if (exp_find(clp, dev))
- return 1;
- }
- return 0;
-}
/*
* Look up the device of the parent fs.
@@ -286,6 +272,12 @@
goto finish;
err = -EINVAL;
+ if (!(inode->i_sb->s_type->fs_flags & FS_REQUIRES_DEV) ||
+ inode->i_sb->s_op->read_inode == NULL) {
+ dprintk("exp_export: export of invalid fs type.\n");
+ goto finish;
+ }
+
if ((parent = exp_child(clp, dev, dentry)) != NULL) {
dprintk("exp_export: export not valid (Rule 3).\n");
goto finish;
FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen (who was at: slshen@lbl.gov)