BACKPACK USB Adapter/hotplug arch and apps
I forgot to forward this to the mailing list as well. Incidentally, where I refer to /etc/fstab, I meant /etc/mtab.
Ken Hahn
----- Original Message -----
From: "Ken Hahn" <[email protected]>
To: "Greg KH" <[email protected]>
Sent: Thursday, November 15, 2001 5:07 PM
Subject: Re: BACKPACK USB Adapter/hotplug arch and apps
Quoted 8 lines
Hello again.
This whole hot-plug problem is quite interesting.
Came here for professional reasons (trying to get a device at work to work on linux), but I'm personally interested in this as well.Incidentally I'll start off by saying I ran into a problem with the
load_driversscript where (at the end) there are some else if's that
should
Quoted 2 lines
just be if's. I'll have to see if the CVS has a corrected version, and if not.. I'll try to rig up a patch. (it ended up telling me it couldn't load
a
Quoted 1 line
module, and never tried to run the script I'd created.. in addition
somebody
Quoted 7 lines
has incorrectly assumed that if "find" doesn't find any files it has a non-zero error code. This is not true)
Right now, to load my firmware, I'm simply having a script call fxload if the PID and VID match.. this works fine (but would not be easy for a standard user) Have to see if this gets better.
Quoted 7 lines
On my personal interest:
As for application notification. In Windows (for contrast) there is a mechanism for this kind of notification of new devices appearing. It is also tied to the auto-insert notification that app's receive. It involves the use of the
WM_DEVICECHANGEmessage
(http://msdn.microsoft.com/library/default.asp?url=/library/en-us/hardware/d
Quoted 6 lines
eviceman_9vhh.asp).
I've often wondered how programs check to see if a disc is freshly mounted (nautilus does this) my best guess has been that a server stat's the
/etc/fstabfile to see if something has arrived or left every few seconds.
Quoted 6 lines
It would be interesting if we could somehow tie volume arrival in with device arrival.
Another thing that the current mechanism doesn't account for is that programs may dynamically come and go (wishing to know of changes when they are running, and not caring otherwise). You may end up with a directory
of
Quoted 7 lines
script files coming and going each doing their own IPC mechanisms to indicate to the "Master" program that some kind of change has occurred.
Wouldn't it be nice if there was a way to generalize this. Perhaps even a userspace library for registering and un-registering for notifications and receiving this signal?
Quoted 5 lines
I do like the idea of staying away from a daemon, and making everything event based, but be more generalized.
Anyway.. this may have all been proposed before, I need to go peruse the mailing list tonight, but it sounded like this hadn't been discussed
before.
Quoted 5 lines
Look forward to seeing developments here,
Ken Hahn
_______________________________________________
Linux-hotplug-devel mailing list http://linux-hotplug.sourceforge.net
[email protected]
https://lists.sourceforge.net/lists/listinfo/linux-hotplug-devel