Am Sonntag, 26. Oktober 2003 08:53 schrieb Tommi Sakari Uimonen:
> My ultimate goal is to have different desktop icons for mass-storage
> devices automatically appear/disappear on the desktop as the devices are
> plugged/unplugged.
> 
> Now, I've gotten the icons to appear correctly according to the different
> devices, but the removing issue is not working yet.
> 
> The question is:
> 
> Is the mount point for each mass-storage device stored somewhere in the
> /proc? Or somewhere else?

_All_ mountpoints are stored in /proc/mounts
However, there is no way to tell whether a specific device
corresponds to a USB device.

> If not, would it be possible to have it stored in /proc. I was

Beyond what is already there, no.

> thinking of using some /tmp/usb-mounts or /var/run/usb/mountpoints, but I
> think it would be better to have it in /proc. I'm not familiar with the
> /proc filesystem and don't know how to add stuff there. Does it need to be
> done in the kernel level or what?

Additions to /proc need to be done in kernel.

> Currently, if I plug one usb mass-storage device, all usb storage devices
> get unmounted. So I would need to know what mount points get assigned to

If you unplug, you mean?

> what devices. Of course I know this during the mounting, but I'd have to
> store the information to some file and then retrieve the information when
> device detaches.

Yes, you have to store it yourself.
Usb-storage does not and cannot know about mounting.
In 2.6 you can get this information from sysfs.
There's no simple way to export such information, especially there is
no 1:1 mapping here.

        Regards
                Oliver



-------------------------------------------------------
This SF.net email is sponsored by: The SF.net Donation Program.
Do you like what SourceForge.net is doing for the Open
Source Community?  Make a contribution, and help us add new
features and functionality. Click here: http://sourceforge.net/donate/
_______________________________________________
[EMAIL PROTECTED]
To unsubscribe, use the last form field at:
https://lists.sourceforge.net/lists/listinfo/linux-usb-devel

Reply via email to