From: Sascha Hauer <s.hauer@pengutronix.de>
To: Christoph Fritz <chf.fritz@googlemail.com>
Cc: barebox@lists.infradead.org
Subject: Re: [PATCH] USB: host: hub: increase delay after device removal
Date: Tue, 22 May 2018 09:54:41 +0200 [thread overview]
Message-ID: <20180522075441.mke2rbn5karwc23t@pengutronix.de> (raw)
In-Reply-To: <1526573972.12584.7.camel@googlemail.com>
On Thu, May 17, 2018 at 06:19:32PM +0200, Christoph Fritz wrote:
> Hi Sascha
>
> On Mon, 2017-01-09 at 09:38 +0100, Sascha Hauer wrote:
> > Hi Christoph,
> >
> barebox:/ usb
> usb: USB: scanning bus for devices...
> usb: Bus 001 Device 001: ID 0000:0000 EHCI Host Controller
> usb-hub usb1: hub_port_reset: resetting port 0...
> usb-hub usb1: portstatus 503, change 10, 480 Mb/s
> usb-hub usb1: STAT_C_CONNECTION = 0 STAT_CONNECTION = 1 USB_PORT_STAT_ENABLE 1
> usb-hub usb1: hub_port_reset: resetting port 0...
> usb-hub usb1: portstatus 503, change 10, 480 Mb/s
> usb-hub usb1: STAT_C_CONNECTION = 0 STAT_CONNECTION = 1 USB_PORT_STAT_ENABLE 1
> usb: Bus 001 Device 002: ID 04b4:6560
> usb-hub usb1-0: hub_port_reset: resetting port 2...
> usb-hub usb1-0: portstatus 103, change 10, 12 Mb/s
> usb-hub usb1-0: STAT_C_CONNECTION = 0 STAT_CONNECTION = 1 USB_PORT_STAT_ENABLE 1
> usb-hub usb1-0: hub_port_reset: resetting port 2...
> usb-hub usb1-0: portstatus 103, change 10, 12 Mb/s
> usb-hub usb1-0: STAT_C_CONNECTION = 0 STAT_CONNECTION = 1 USB_PORT_STAT_ENABLE 1
> usb: Bus 001 Device 003: ID 10c4:ea60 CP2104 USB to UART Bridge Contr
> usb: 3 USB Device(s) found
>
> # now disconnect the USB device:
>
> barebox:/ usb
> usb: USB: scanning bus for devices...
> usb1-0-0-2: removed
> usb: 4 USB Device(s) found
>
> # 4 USB Devices seems wrong, now connect the USB device again:
>
> barebox@:/ usb
> usb: USB: scanning bus for devices...
> usb-hub usb1-0-0: hub_port_reset: resetting port 2...
> usb-hub usb1-0-0: portstatus 103, change 10, 12 Mb/s
> usb-hub usb1-0-0: STAT_C_CONNECTION = 0 STAT_CONNECTION = 1 USB_PORT_STAT_ENABLE 1
> usb: 4 USB Device(s) found
>
> # still 4 USB Devices found, ...?
> # starting 'usb' again hits a NULL pointer dereference:
Disconnecting USB devices during runtime of barebox is not really
supported. We should probably make that clear somewhere. The code is not
prepared for that case and trying to fix it is likely to be a bottomless
pit.
Can you reproduce a problem without removing a device?
Sascha
--
Pengutronix e.K. | |
Industrial Linux Solutions | http://www.pengutronix.de/ |
Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0 |
Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-5555 |
_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox
next prev parent reply other threads:[~2018-05-22 7:54 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-12-28 15:29 Christoph Fritz
2017-01-09 8:38 ` Sascha Hauer
2018-05-17 16:19 ` Christoph Fritz
2018-05-22 7:54 ` Sascha Hauer [this message]
2018-05-22 8:09 ` Christoph Fritz
2018-05-23 13:36 ` Sascha Hauer
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20180522075441.mke2rbn5karwc23t@pengutronix.de \
--to=s.hauer@pengutronix.de \
--cc=barebox@lists.infradead.org \
--cc=chf.fritz@googlemail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox