05 Jul, 2016

2 commits

  • The old dm "usb info" implementation has several issues:

    1) NULL pointer deref when a bus has no children
    2) Not showing usb devices on busses without an emulated root-hub (otg host)
    3) Attempting to show devices on inactive busses
    4) "usb info" Would cause some hosts to get re-probed something which only
    "usb reset" should do

    TL;DR: proper iterating over usb bus root devs is hard, use the helper
    for it.

    Reported-by: Bernhard Nortmann
    Signed-off-by: Hans de Goede

    Hans de Goede
     
  • Iterating over usb-root devs and doing something for all of them is
    a bit tricky with dm, factor out the proven usb_show_tree() for this
    into a helper function.

    Signed-off-by: Hans de Goede

    Hans de Goede
     

18 Jun, 2016

1 commit

  • For legacy usb storage driver, USB_MAX_STOR_DEV is defined as 7.
    If we only have one usb disk on board, `usb dev 0` is ok.
    But if `usb dev 1`, still ok, then `usb read xxx` will trigger
    system fault and reboot.

    So check if_type before using this device.

    Signed-off-by: Peng Fan
    Cc: Simon Glass
    Cc: Hans de Goede
    Cc: Bin Meng
    Cc: Marek Vasut
    Cc: Stefan Roese
    Cc: Marcel Ziswiler
    Cc: Peng Fan
    Cc: Stephen Warren

    Peng Fan
     

17 May, 2016

1 commit


10 Apr, 2016

2 commits

  • Some usb hosts may have failed to probe on "usb start", i.e. an otg
    host without an otg-host cable plugged in.

    "usb tree" would cause the probe method of these hosts to get called
    again, something which should only happen on "usb reset".

    This commit fixes this.

    Signed-off-by: Hans de Goede

    Hans de Goede
     
  • The dm usb_kbd_remove function() will deregister the usb keyboard for
    us on a "usb reset" / "usb stop" so there is no need to manually call
    usb_kbd_deregister() in the dm case.

    This commit removes usb_kbd_deregister() in the dm case fixing the
    following "usb reset" errors:

    usb_kbd_remove: warning, ret=-6
    device_remove: Device 'usb_kbd' failed to remove, but children are gone

    Signed-off-by: Hans de Goede

    Hans de Goede
     

15 Mar, 2016

3 commits


25 Jan, 2016

1 commit

  • Now that they are in their own directory, we can remove this prefix.
    This makes it easier to find a file since the prefix does not get in the
    way.

    Signed-off-by: Simon Glass
    Reviewed-by: Bin Meng
    Reviewed-by: Heiko Schocher
    Acked-by: Stefan Roese
    Acked-by: Przemyslaw Marczak

    Simon Glass