Re: [PATCH] USB: prevent overlapping access by usb-storage and usbfs

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, 17 Jan 2013, Peter Stuge wrote:

> Greg KH wrote:
> > Ah, ok, that's a bit better, but then we need to figure out some way to
> > push "being used" down to a large majority of drivers, which we really
> > don't have.
> 
> And of course not just for storage; allow *all* the classes.
> 
> I don't know how much effort it would be for storage - is a block
> device unaware that it has been mounted?

Those are two separate issues.  Firstly, usb-storage is not a block
device drivers; it is a USB driver.  The actual block device driver is
part of the SCSI stack (because USB mass-storage devices use SCSI
command sets).  Secondly, the block driver (not device) is not aware 
when any of the filesystems in any of the partitions has been mounted.  
But it is aware of when the device file is open.

> I mean: does the kernel
> only keep a single link from the filesystem to the block device,
> and nothing the other way around?

A block device can contain many filesystems: one in each partition.

Alan Stern

--
To unsubscribe from this list: send the line "unsubscribe linux-usb" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Media]     [Linux Input]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [Old Linux USB Devel Archive]

  Powered by Linux