[U-Boot] [PATCH 2/5] driver: usb: add EHCI driver for hi3787cv200 SoC

Marek Vasut marex at denx.de
Sun May 7 12:34:18 UTC 2017


On 05/07/2017 12:56 PM, Jorge Ramirez wrote:
> On 05/06/2017 01:05 AM, Marek Vasut wrote:
>> On 05/05/2017 07:55 PM, Jorge Ramirez wrote:
>>> On 05/05/2017 05:34 PM, Marek Vasut wrote:
>>>> On 05/05/2017 04:32 PM, Tom Rini wrote:
>>>>> On Thu, May 04, 2017 at 03:47:07PM +0200, Jorge Ramirez-Ortiz wrote:
>>>>>
>>>>> CC'ing Marek...
>>>>>
>>>>>> Signed-off-by: Jorge Ramirez-Ortiz <jorge.ramirez-ortiz at linaro.org>
>>>>>> ---
>>>>>>    .../arm/include/asm/arch-hi3798cv200/hi3798cv200.h |  93
>>>>>> ++++++++++
>>>>>>    drivers/usb/host/Kconfig                           |   6 +
>>>>>>    drivers/usb/host/Makefile                          |   1 +
>>>>>>    drivers/usb/host/ehci-hi3798cv200.c                | 196
>>>>>> +++++++++++++++++++++
>>>>>>    4 files changed, 296 insertions(+)
>>>>>>    create mode 100644
>>>>>> arch/arm/include/asm/arch-hi3798cv200/hi3798cv200.h
>>>>>>    create mode 100644 drivers/usb/host/ehci-hi3798cv200.c
>>>>>>
>>>>>> diff --git a/arch/arm/include/asm/arch-hi3798cv200/hi3798cv200.h
>>>>>> b/arch/arm/include/asm/arch-hi3798cv200/hi3798cv200.h
>>>>>> new file mode 100644
>>>>>> index 0000000..c67fda1
>>>>>> --- /dev/null
>>>>>> +++ b/arch/arm/include/asm/arch-hi3798cv200/hi3798cv200.h
>>>>>> @@ -0,0 +1,93 @@
>>>>>> +/*
>>>>>> + * (C) Copyright 2017 Linaro
>>>>>> + * Jorge Ramirez-Ortiz <jorge.ramirez-ortiz at linaro.org>
>>>>>> + *
>>>>>> + * SPDX-License-Identifier:    GPL-2.0+
>>>>>> + */
>>>>>> +
>>>>>> +#ifndef __HI3798cv200_H__
>>>>>> +#define __HI3798cv200_H__
>>>> This should be a separate patch ..
>>> hi Marek
>>>
>>> to be clear, are you asking a single patch containing hi3798cv200.h?
>> Yes, this is arch stuff and is not in any way part of the USB driver IMO.
> 
> sure.
> I suppose that what are really saying is that the usb driver has to be
> upstreamed after the architecture and not before if such a dependency
> exists (ie not using the device tree)

Yes, you can be asked to change stuff in the arch code , at which point
you might have to modify the (dead, but accepted) usb code.

If you can move arch stuff to arch code, even better. Then you might
even be able to use ehci-generic.

>> [...]
>>
>>>>>> +};
>>>>>> +
>>>>>> +#endif
>>>>>> diff --git a/drivers/usb/host/Kconfig b/drivers/usb/host/Kconfig
>>>>>> index 0bf8274..a749d0e 100644
>>>>>> --- a/drivers/usb/host/Kconfig
>>>>>> +++ b/drivers/usb/host/Kconfig
>>>>>> @@ -128,6 +128,12 @@ config USB_EHCI_ZYNQ
>>>>>>        ---help---
>>>>>>          Enable support for Zynq on-chip EHCI USB controller
>>>>>>    +config USB_EHCI_POPLAR
>>>>>> +    bool "Support for HI3798cv200 EHCI USB controller"
>>>> Does HI stand for Hitachi ?
>>> Hisilicon
>> Don't we already have some hisilicon stuff in the tree ? Maybe some
>> 96board ?
>>
>> In fact, could this driver be replaced by ehci-generic ?
> 
> yes I think so. the driver is basically platform initialization code and
> the generic driver.
> the problem I have is that there is not usb host support in the kernel
> for it so we dont have a device node in the tree.
> 
> should I commit the linux kernel device tree (first patch in the series)
> and then add the node when I push the DM usb driver?

Ideally check the bindings with Rob Herring, otherwise I don't care.
If you contribute to kernel too, awesome.

[...]

-- 
Best regards,
Marek Vasut


More information about the U-Boot mailing list