[0/6] Add Bananapi Zero board with OTG supported

Message ID 1515137821-30583-1-git-send-email-jun.nie@linaro.org
Headers show
Series
  • Add Bananapi Zero board with OTG supported
Related show

Message

Jun Nie Jan. 5, 2018, 7:36 a.m.
Add Bananapi Zero board defconfig and device tree.
OTG device is supported with enabling clock and adding necessary
controller configuration change. USB mass storage is tested as
a test case.

Jun Nie (6):
  sunxi: h3: add usb_otg and OHCI/EHCI for usbc0 on H3
  sunxi: musb: Add fifo config for H3
  sunxi: musb: Enable OTG device clock for H3
  sunxi: musb: Hack dynamic fifo support for H3 OTG
  sunxi: usb_phy: Clear PHYCTL register before writing
  sunxi: Add initial Banana-Pi Zero support

 arch/arm/dts/Makefile                           |   1 +
 arch/arm/dts/sun8i-h2-plus-bananapi-m2-zero.dts | 113 ++++++++++++++++++++++++
 arch/arm/dts/sun8i-h3.dtsi                      |  32 +++++++
 arch/arm/include/asm/arch-sunxi/clock_sun6i.h   |   2 +
 arch/arm/include/asm/arch-sunxi/cpu_sun4i.h     |   4 +
 arch/arm/mach-sunxi/usb_phy.c                   |   8 +-
 configs/bananapi_zero_defconfig                 |  17 ++++
 drivers/usb/musb-new/musb_regs.h                |   3 +-
 drivers/usb/musb-new/sunxi.c                    |  51 +++++++++++
 9 files changed, 229 insertions(+), 2 deletions(-)
 create mode 100644 arch/arm/dts/sun8i-h2-plus-bananapi-m2-zero.dts
 create mode 100644 configs/bananapi_zero_defconfig

Comments

Jagan Teki Jan. 5, 2018, 7:58 a.m. | #1
On Fri, Jan 5, 2018 at 1:06 PM, Jun Nie <jun.nie@linaro.org> wrote:
> Add Bananapi Zero board defconfig and device tree.
> OTG device is supported with enabling clock and adding necessary
> controller configuration change. USB mass storage is tested as
> a test case.
>
> Jun Nie (6):
>   sunxi: h3: add usb_otg and OHCI/EHCI for usbc0 on H3
>   sunxi: musb: Add fifo config for H3
>   sunxi: musb: Enable OTG device clock for H3
>   sunxi: musb: Hack dynamic fifo support for H3 OTG
>   sunxi: usb_phy: Clear PHYCTL register before writing

a64 on otg have in ML[1] check if any redundant otherwise it's OK., we
will test these and send next version.

>   sunxi: Add initial Banana-Pi Zero support

similar patch is already in ML [2]

[1] https://patchwork.ozlabs.org/cover/847375/
[2] https://patchwork.ozlabs.org/patch/832937/
Jun Nie Jan. 5, 2018, 8:15 a.m. | #2
Thank you very much! Will check.

Jun
Jun Nie Jan. 5, 2018, 9:04 a.m. | #3
>
> a64 on otg have in ML[1] check if any redundant otherwise it's OK., we
> will test these and send next version.
>
>>   sunxi: Add initial Banana-Pi Zero support
>
> similar patch is already in ML [2]
>
> [1] https://patchwork.ozlabs.org/cover/847375/

This serial patches in the link does not introduce any redundant
change with my USB patches. So my patches 1-5 still deserve review.
Conflict should be resolve of course because some change is made in
the same line.

Two points for patches in the link:
- SUNXI_MUSB_BASE is redefined with the patches in the link for H3
configuration in my test.
- Some coding style conflict with u-boot, such as USBC_SelectPhyToDevice.

> [2] https://patchwork.ozlabs.org/patch/832937/

This patch can replace my patch 6 and please ignore my patch 6.

Jun
>
> --
> Jagan Teki
> Free Software Engineer | www.openedev.com
> U-Boot, Linux | Upstream Maintainer
> Hyderabad, India.
Chen-Yu Tsai Jan. 5, 2018, 9:06 a.m. | #4
On Fri, Jan 5, 2018 at 5:04 PM, Jun Nie <jun.nie@linaro.org> wrote:
>>
>> a64 on otg have in ML[1] check if any redundant otherwise it's OK., we
>> will test these and send next version.
>>
>>>   sunxi: Add initial Banana-Pi Zero support
>>
>> similar patch is already in ML [2]
>>
>> [1] https://patchwork.ozlabs.org/cover/847375/
>
> This serial patches in the link does not introduce any redundant
> change with my USB patches. So my patches 1-5 still deserve review.
> Conflict should be resolve of course because some change is made in
> the same line.
>
> Two points for patches in the link:
> - SUNXI_MUSB_BASE is redefined with the patches in the link for H3
> configuration in my test.
> - Some coding style conflict with u-boot, such as USBC_SelectPhyToDevice.

I have some similar patches here:

https://github.com/wens/u-boot-sunxi/commits/libretech-cc

ChenYu

>> [2] https://patchwork.ozlabs.org/patch/832937/
>
> This patch can replace my patch 6 and please ignore my patch 6.
>
> Jun
>>
>> --
>> Jagan Teki
>> Free Software Engineer | www.openedev.com
>> U-Boot, Linux | Upstream Maintainer
>> Hyderabad, India.
Jun Nie Jan. 5, 2018, 9:20 a.m. | #5
2018-01-05 17:06 GMT+08:00 Chen-Yu Tsai <wens@csie.org>:
> On Fri, Jan 5, 2018 at 5:04 PM, Jun Nie <jun.nie@linaro.org> wrote:
>>>
>>> a64 on otg have in ML[1] check if any redundant otherwise it's OK., we
>>> will test these and send next version.
>>>
>>>>   sunxi: Add initial Banana-Pi Zero support
>>>
>>> similar patch is already in ML [2]
>>>
>>> [1] https://patchwork.ozlabs.org/cover/847375/
>>
>> This serial patches in the link does not introduce any redundant
>> change with my USB patches. So my patches 1-5 still deserve review.
>> Conflict should be resolve of course because some change is made in
>> the same line.
>>
>> Two points for patches in the link:
>> - SUNXI_MUSB_BASE is redefined with the patches in the link for H3
>> configuration in my test.
>> - Some coding style conflict with u-boot, such as USBC_SelectPhyToDevice.
>
> I have some similar patches here:
>
> https://github.com/wens/u-boot-sunxi/commits/libretech-cc
>
> ChenYu

ChenYu,

Are you patches are in review process or merge process? When do you
expected they are merged?

Jun
>
>>> [2] https://patchwork.ozlabs.org/patch/832937/
>>
>> This patch can replace my patch 6 and please ignore my patch 6.
>>
>> Jun
>>>
>>> --
>>> Jagan Teki
>>> Free Software Engineer | www.openedev.com
>>> U-Boot, Linux | Upstream Maintainer
>>> Hyderabad, India.
Chen-Yu Tsai Jan. 5, 2018, 9:25 a.m. | #6
On Fri, Jan 5, 2018 at 5:20 PM, Jun Nie <jun.nie@linaro.org> wrote:
> 2018-01-05 17:06 GMT+08:00 Chen-Yu Tsai <wens@csie.org>:
>> On Fri, Jan 5, 2018 at 5:04 PM, Jun Nie <jun.nie@linaro.org> wrote:
>>>>
>>>> a64 on otg have in ML[1] check if any redundant otherwise it's OK., we
>>>> will test these and send next version.
>>>>
>>>>>   sunxi: Add initial Banana-Pi Zero support
>>>>
>>>> similar patch is already in ML [2]
>>>>
>>>> [1] https://patchwork.ozlabs.org/cover/847375/
>>>
>>> This serial patches in the link does not introduce any redundant
>>> change with my USB patches. So my patches 1-5 still deserve review.
>>> Conflict should be resolve of course because some change is made in
>>> the same line.
>>>
>>> Two points for patches in the link:
>>> - SUNXI_MUSB_BASE is redefined with the patches in the link for H3
>>> configuration in my test.
>>> - Some coding style conflict with u-boot, such as USBC_SelectPhyToDevice.
>>
>> I have some similar patches here:
>>
>> https://github.com/wens/u-boot-sunxi/commits/libretech-cc
>>
>> ChenYu
>
> ChenYu,
>
> Are you patches are in review process or merge process? When do you
> expected they are merged?

So far only "musb: sunxi: Use base address from device tree" has been
sent out and was already reviewed, but pending. The rest I've not sent
as I was still trying to get it to work in peripheral mode.

Feel free to pick any of the patches if they suit your needs.

ChenYu