From mboxrd@z Thu Jan 1 00:00:00 1970 From: Greg KH Date: Fri, 11 Aug 2006 08:37:41 +0000 Subject: Re: USB Hub Port Power Control and Hotplug Events Message-Id: <20060811083741.GA9989@kroah.com> List-Id: References: <9b1737410608101621g61587b05s113501b16d38b7b6@mail.gmail.com> In-Reply-To: <9b1737410608101621g61587b05s113501b16d38b7b6@mail.gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: linux-hotplug@vger.kernel.org On Fri, Aug 11, 2006 at 09:39:47AM +0200, Guennadi Liakhovetski wrote: > On Thu, 10 Aug 2006, Andy Dalton wrote: > > > While experimenting, I noticed something a bit strange. If I power > > down a port on the USB hub, then later power it back on, I do *not* > > get a hotplug removal event on power off, but I *do* get an insertion > > event on power on. > > It has been discussed on the USB-devel list. The thing is - the hub > doesn't report a "port status change" on "port power off". It's on power > on it first reports a "disconnect" and then immediately a "new device". > And the system cannot really simulate this event for you because the "port > power off" command can come from various places - kernel drivers, user > space. So, your only option seems to be to use the fact that it's you who > issues the command, so, you know that the device is gone. Just use this > knowledge. > > Not sure, but I don't think you can tell the kernel that the device is > gone... No, the USB stack does not allow you to do this at this point in time, sorry. You can unbind a device from a driver though, that would prevent it from being used by any userspace programs. thanks, greg k-h ------------------------------------------------------------------------- Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnk&kid0709&bid&3057&dat1642 _______________________________________________ Linux-hotplug-devel mailing list http://linux-hotplug.sourceforge.net Linux-hotplug-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/linux-hotplug-devel