From: Vojtech P. <vo...@su...> - 2001-06-23 06:18:17
|
On Fri, Jun 22, 2001 at 01:18:40PM -0700, James Simmons wrote: > > USB currently handles this with a select() on /proc/bus/usb/devices. I > > think we could do the same. Actually a /proc/..../input/devices file > > would be quite useful. > > :-) Do you have example code for the usb system on how to detect this. I > could really use this for work. simple, really. open(fd,/proc/bus/usb/devices), select(fd). Select will stop blocking once the file changes. -- Vojtech Pavlik SuSE Labs |