lkml.org 
[lkml]   [2001]   [Mar]   [2]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
Date
From
Subject[PATCH] Re: usbdevfs can be mounted multiple times


On Fri, 2 Mar 2001, Alexander Viro wrote:

> I.e. replace the last argument in declaration of usbdevfs with FS_SINGLE -
> without that we get a new instance every time.

Grr... Proper patch follows. Please, apply.
Cheers,
Al
--- drivers/usb/inode.c Fri Feb 16 18:24:31 2001
+++ drivers/usb/inode.c.new Fri Mar 2 16:39:44 2001
@@ -596,7 +596,7 @@
return NULL;
}

-static DECLARE_FSTYPE(usbdevice_fs_type, "usbdevfs", usbdevfs_read_super, 0);
+static DECLARE_FSTYPE(usbdevice_fs_type, "usbdevfs", usbdevfs_read_super, FS_SINGLE);

/* --------------------------------------------------------------------- */

@@ -691,6 +691,7 @@
return ret;
if ((ret = register_filesystem(&usbdevice_fs_type)))
usb_deregister(&usbdevfs_driver);
+ kern_mount(&usbdevice_fs_type);
#ifdef CONFIG_PROC_FS
/* create mount point for usbdevfs */
usbdir = proc_mkdir("usb", proc_bus);
@@ -702,6 +703,7 @@
{
usb_deregister(&usbdevfs_driver);
unregister_filesystem(&usbdevice_fs_type);
+ kern_umount(usbdevice_fs_type.kern_mnt);
#ifdef CONFIG_PROC_FS
if (usbdir)
remove_proc_entry("usb", proc_bus);
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 13:29    [W:0.041 / U:0.396 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site