[U-Boot] [PATCH v3 05/15] usb: hub: Add a new API to test if a hub device is root hub

Simon Glass sjg at chromium.org
Fri Jul 28 04:19:59 UTC 2017


On 19 July 2017 at 07:51, Bin Meng <bmeng.cn at gmail.com> wrote:
> Sometimes we need know if a given hub device is root hub or not.
> Add a new API to test this. This removes the xHCI driver's own
> version is_root_hub() and change to use the new API.
>
> While we are here, remove the unused/commented out get_usb_device()
> in the xHCI driver too.
>
> Signed-off-by: Bin Meng <bmeng.cn at gmail.com>
>
> ---
>
> Changes in v3: None
> Changes in v2:
> - squash the xchi is_root_port() changes into previous commit
>
>  common/usb_hub.c        | 10 ++++++++++
>  drivers/usb/host/xhci.c | 24 ++----------------------
>  include/usb.h           |  8 ++++++++
>  3 files changed, 20 insertions(+), 22 deletions(-)

Reviewed-by: Simon Glass <sjg at chromium.org>


More information about the U-Boot mailing list