Re: [U-Boot] [PATCH 08/22] dm: usb: Use device_chld_remove and _unbind to clean up usb devs on stop

2015-06-30 Thread Hans de Goede
Hi, On 29-06-15 05:45, Simon Glass wrote: Hi Hans, On 17 June 2015 at 13:33, Hans de Goede hdego...@redhat.com wrote: On an usb stop instead of leaving orphan usb devices behind simply remove On a usb_stop() or On a 'usb stop' command ? My intention was for both, since I was under the

Re: [U-Boot] [PATCH 08/22] dm: usb: Use device_chld_remove and _unbind to clean up usb devs on stop

2015-06-30 Thread Hans de Goede
Hi, On 06/30/2015 04:58 PM, Simon Glass wrote: Hi Hans, On 30 June 2015 at 06:54, Hans de Goede hdego...@redhat.com wrote: Hi, On 29-06-15 05:45, Simon Glass wrote: Hi Hans, On 17 June 2015 at 13:33, Hans de Goede hdego...@redhat.com wrote: On an usb stop instead of leaving orphan usb

Re: [U-Boot] [PATCH 08/22] dm: usb: Use device_chld_remove and _unbind to clean up usb devs on stop

2015-06-30 Thread Simon Glass
Hi Hans, On 30 June 2015 at 09:54, Hans de Goede hdego...@redhat.com wrote: Hi, On 06/30/2015 04:58 PM, Simon Glass wrote: Hi Hans, On 30 June 2015 at 06:54, Hans de Goede hdego...@redhat.com wrote: Hi, On 29-06-15 05:45, Simon Glass wrote: Hi Hans, On 17 June 2015 at 13:33, Hans

Re: [U-Boot] [PATCH 08/22] dm: usb: Use device_chld_remove and _unbind to clean up usb devs on stop

2015-06-30 Thread Simon Glass
Hi Hans, On 30 June 2015 at 06:54, Hans de Goede hdego...@redhat.com wrote: Hi, On 29-06-15 05:45, Simon Glass wrote: Hi Hans, On 17 June 2015 at 13:33, Hans de Goede hdego...@redhat.com wrote: On an usb stop instead of leaving orphan usb devices behind simply remove On a usb_stop()

Re: [U-Boot] [PATCH 08/22] dm: usb: Use device_chld_remove and _unbind to clean up usb devs on stop

2015-06-30 Thread Hans de Goede
Hi, On 06/30/2015 06:07 PM, Simon Glass wrote: snip Instead, I wonder if we can remove the children when we probe the bus? That should work, but I do not really see any advantage in that, removing the children is not that expensive and it feels like a kludge. That's how it currently

Re: [U-Boot] [PATCH 08/22] dm: usb: Use device_chld_remove and _unbind to clean up usb devs on stop

2015-06-30 Thread Simon Glass
HI Hans, On 30 June 2015 at 14:20, Hans de Goede hdego...@redhat.com wrote: Hi, On 06/30/2015 06:07 PM, Simon Glass wrote: snip Instead, I wonder if we can remove the children when we probe the bus? That should work, but I do not really see any advantage in that, removing the children

Re: [U-Boot] [PATCH 08/22] dm: usb: Use device_chld_remove and _unbind to clean up usb devs on stop

2015-06-28 Thread Simon Glass
Hi Hans, On 17 June 2015 at 13:33, Hans de Goede hdego...@redhat.com wrote: On an usb stop instead of leaving orphan usb devices behind simply remove On a usb_stop() or On a 'usb stop' command ? them. This requires CONFIG_DM_DEVICE_REMOVE to be set, so only build usb_stop() when that is

[U-Boot] [PATCH 08/22] dm: usb: Use device_chld_remove and _unbind to clean up usb devs on stop

2015-06-17 Thread Hans de Goede
On an usb stop instead of leaving orphan usb devices behind simply remove them. This requires CONFIG_DM_DEVICE_REMOVE to be set, so only build usb_stop() when that is set. The result of this commit is best seen in the output of dm tree after plugging out an usb hub with 2 devices plugges in and