[PATCH v5 00/11] *** Add allwinner-r40 support ***

qianfanguijin@163.com posted 11 patches 11 months, 1 week ago
Only 10 patches received!
docs/system/arm/bananapi_m2u.rst      | 138 +++++++
hw/arm/Kconfig                        |  14 +-
hw/arm/allwinner-r40.c                | 526 ++++++++++++++++++++++++++
hw/arm/bananapi_m2u.c                 | 145 +++++++
hw/arm/meson.build                    |   1 +
hw/misc/Kconfig                       |   5 +-
hw/misc/allwinner-r40-ccu.c           | 209 ++++++++++
hw/misc/allwinner-r40-dramc.c         | 513 +++++++++++++++++++++++++
hw/misc/allwinner-sramc.c             | 184 +++++++++
hw/misc/axp209.c                      | 238 ------------
hw/misc/axp2xx.c                      | 283 ++++++++++++++
hw/misc/meson.build                   |   5 +-
hw/misc/trace-events                  |  26 +-
hw/sd/allwinner-sdhost.c              |  72 +++-
include/hw/arm/allwinner-r40.h        | 143 +++++++
include/hw/misc/allwinner-r40-ccu.h   |  65 ++++
include/hw/misc/allwinner-r40-dramc.h | 108 ++++++
include/hw/misc/allwinner-sramc.h     |  69 ++++
include/hw/sd/allwinner-sdhost.h      |   9 +
tests/avocado/boot_linux_console.py   | 176 +++++++++
20 files changed, 2681 insertions(+), 248 deletions(-)
create mode 100644 docs/system/arm/bananapi_m2u.rst
create mode 100644 hw/arm/allwinner-r40.c
create mode 100644 hw/arm/bananapi_m2u.c
create mode 100644 hw/misc/allwinner-r40-ccu.c
create mode 100644 hw/misc/allwinner-r40-dramc.c
create mode 100644 hw/misc/allwinner-sramc.c
delete mode 100644 hw/misc/axp209.c
create mode 100644 hw/misc/axp2xx.c
create mode 100644 include/hw/arm/allwinner-r40.h
create mode 100644 include/hw/misc/allwinner-r40-ccu.h
create mode 100644 include/hw/misc/allwinner-r40-dramc.h
create mode 100644 include/hw/misc/allwinner-sramc.h
[PATCH v5 00/11] *** Add allwinner-r40 support ***
Posted by qianfanguijin@163.com 11 months, 1 week ago
From: qianfan Zhao <qianfanguijin@163.com>

***History***
# v1: 2023-03-21

The first version which add allwinner-r40 support, supported features:

+ ccu
+ dram controller
+ uart
+ i2c and pmic(axp221)
+ sdcard
+ emac/gmac

Also provide a test case under avocado, running quickly test:

$ AVOCADO_ALLOW_LARGE_STORAGE=yes tests/venv/bin/avocado \
    --verbose --show=app,console run -t machine:bpim2u \
    ../tests/avocado/boot_linux_console.py

# v2: 2023-03-28

1. Fix the waring and error reported by checkpatch.pl
2. Remove the other i2c controllers except that i2c0
3. Use an array to register mmc and uart devices
4. Rename axp209 to axp22x and add axp221 support
5. Add a basic SRAM controller

# v3: 2023-04-18

1. Update some commit messages
2. Squash those two commit about sdcard
   hw: sd: allwinner-sdhost: Add sun50i-a64 SoC support
   hw: arm: allwinner-r40: Fix the mmc controller's type

# v4: 2023-05-10

1. Rebase to master

# v5: 2023-05-23

1. Rebase to master
2. Update based on Niek Linnenbank's guide.

qianfan Zhao (11):
  hw: arm: Add bananapi M2-Ultra and allwinner-r40 support
  hw/arm/allwinner-r40: add Clock Control Unit
  hw: allwinner-r40: Complete uart devices
  hw: arm: allwinner-r40: Add i2c0 device
  hw/misc: Rename axp209 to axp22x and add support AXP221 PMU
  hw/arm/allwinner-r40: add SDRAM controller device
  hw: sd: allwinner-sdhost: Add sun50i-a64 SoC support
  hw: arm: allwinner-r40: Add emac and gmac support
  hw: arm: allwinner-sramc: Add SRAM Controller support for R40
  tests: avocado: boot_linux_console: Add test case for bpim2u
  docs: system: arm: Introduce bananapi_m2u

 docs/system/arm/bananapi_m2u.rst      | 138 +++++++
 hw/arm/Kconfig                        |  14 +-
 hw/arm/allwinner-r40.c                | 526 ++++++++++++++++++++++++++
 hw/arm/bananapi_m2u.c                 | 145 +++++++
 hw/arm/meson.build                    |   1 +
 hw/misc/Kconfig                       |   5 +-
 hw/misc/allwinner-r40-ccu.c           | 209 ++++++++++
 hw/misc/allwinner-r40-dramc.c         | 513 +++++++++++++++++++++++++
 hw/misc/allwinner-sramc.c             | 184 +++++++++
 hw/misc/axp209.c                      | 238 ------------
 hw/misc/axp2xx.c                      | 283 ++++++++++++++
 hw/misc/meson.build                   |   5 +-
 hw/misc/trace-events                  |  26 +-
 hw/sd/allwinner-sdhost.c              |  72 +++-
 include/hw/arm/allwinner-r40.h        | 143 +++++++
 include/hw/misc/allwinner-r40-ccu.h   |  65 ++++
 include/hw/misc/allwinner-r40-dramc.h | 108 ++++++
 include/hw/misc/allwinner-sramc.h     |  69 ++++
 include/hw/sd/allwinner-sdhost.h      |   9 +
 tests/avocado/boot_linux_console.py   | 176 +++++++++
 20 files changed, 2681 insertions(+), 248 deletions(-)
 create mode 100644 docs/system/arm/bananapi_m2u.rst
 create mode 100644 hw/arm/allwinner-r40.c
 create mode 100644 hw/arm/bananapi_m2u.c
 create mode 100644 hw/misc/allwinner-r40-ccu.c
 create mode 100644 hw/misc/allwinner-r40-dramc.c
 create mode 100644 hw/misc/allwinner-sramc.c
 delete mode 100644 hw/misc/axp209.c
 create mode 100644 hw/misc/axp2xx.c
 create mode 100644 include/hw/arm/allwinner-r40.h
 create mode 100644 include/hw/misc/allwinner-r40-ccu.h
 create mode 100644 include/hw/misc/allwinner-r40-dramc.h
 create mode 100644 include/hw/misc/allwinner-sramc.h

-- 
2.25.1
Re: [PATCH v5 00/11] *** Add allwinner-r40 support ***
Posted by Niek Linnenbank 11 months ago
Hi Qianfan,

Thanks for sending the v5. From my side, I have no further comments on the
content.
So please feel free to add the following to each of the patches 01-11 in
the series:

Reviewed-by: Niek Linnenbank <nieklinnenbank@gmail.com>

As a reminder and explained here on this page, you'll need to make sure
these lines gets added to each of the commit messages:
https://www.qemu.org/docs/master/devel/submitting-a-patch.html#proper-use-of-reviewed-by-tags-can-aid-review

Doing so would require you to send another updated v6, and baselined on the
latest master.

Thanks again for contributing this to Qemu, hopefully we can see it merged
soon.

Regards,
Niek

On Tue, May 23, 2023 at 12:05 PM <qianfanguijin@163.com> wrote:

> From: qianfan Zhao <qianfanguijin@163.com>
>
> ***History***
> # v1: 2023-03-21
>
> The first version which add allwinner-r40 support, supported features:
>
> + ccu
> + dram controller
> + uart
> + i2c and pmic(axp221)
> + sdcard
> + emac/gmac
>
> Also provide a test case under avocado, running quickly test:
>
> $ AVOCADO_ALLOW_LARGE_STORAGE=yes tests/venv/bin/avocado \
>     --verbose --show=app,console run -t machine:bpim2u \
>     ../tests/avocado/boot_linux_console.py
>
> # v2: 2023-03-28
>
> 1. Fix the waring and error reported by checkpatch.pl
> 2. Remove the other i2c controllers except that i2c0
> 3. Use an array to register mmc and uart devices
> 4. Rename axp209 to axp22x and add axp221 support
> 5. Add a basic SRAM controller
>
> # v3: 2023-04-18
>
> 1. Update some commit messages
> 2. Squash those two commit about sdcard
>    hw: sd: allwinner-sdhost: Add sun50i-a64 SoC support
>    hw: arm: allwinner-r40: Fix the mmc controller's type
>
> # v4: 2023-05-10
>
> 1. Rebase to master
>
> # v5: 2023-05-23
>
> 1. Rebase to master
> 2. Update based on Niek Linnenbank's guide.
>
> qianfan Zhao (11):
>   hw: arm: Add bananapi M2-Ultra and allwinner-r40 support
>   hw/arm/allwinner-r40: add Clock Control Unit
>   hw: allwinner-r40: Complete uart devices
>   hw: arm: allwinner-r40: Add i2c0 device
>   hw/misc: Rename axp209 to axp22x and add support AXP221 PMU
>   hw/arm/allwinner-r40: add SDRAM controller device
>   hw: sd: allwinner-sdhost: Add sun50i-a64 SoC support
>   hw: arm: allwinner-r40: Add emac and gmac support
>   hw: arm: allwinner-sramc: Add SRAM Controller support for R40
>   tests: avocado: boot_linux_console: Add test case for bpim2u
>   docs: system: arm: Introduce bananapi_m2u
>
>  docs/system/arm/bananapi_m2u.rst      | 138 +++++++
>  hw/arm/Kconfig                        |  14 +-
>  hw/arm/allwinner-r40.c                | 526 ++++++++++++++++++++++++++
>  hw/arm/bananapi_m2u.c                 | 145 +++++++
>  hw/arm/meson.build                    |   1 +
>  hw/misc/Kconfig                       |   5 +-
>  hw/misc/allwinner-r40-ccu.c           | 209 ++++++++++
>  hw/misc/allwinner-r40-dramc.c         | 513 +++++++++++++++++++++++++
>  hw/misc/allwinner-sramc.c             | 184 +++++++++
>  hw/misc/axp209.c                      | 238 ------------
>  hw/misc/axp2xx.c                      | 283 ++++++++++++++
>  hw/misc/meson.build                   |   5 +-
>  hw/misc/trace-events                  |  26 +-
>  hw/sd/allwinner-sdhost.c              |  72 +++-
>  include/hw/arm/allwinner-r40.h        | 143 +++++++
>  include/hw/misc/allwinner-r40-ccu.h   |  65 ++++
>  include/hw/misc/allwinner-r40-dramc.h | 108 ++++++
>  include/hw/misc/allwinner-sramc.h     |  69 ++++
>  include/hw/sd/allwinner-sdhost.h      |   9 +
>  tests/avocado/boot_linux_console.py   | 176 +++++++++
>  20 files changed, 2681 insertions(+), 248 deletions(-)
>  create mode 100644 docs/system/arm/bananapi_m2u.rst
>  create mode 100644 hw/arm/allwinner-r40.c
>  create mode 100644 hw/arm/bananapi_m2u.c
>  create mode 100644 hw/misc/allwinner-r40-ccu.c
>  create mode 100644 hw/misc/allwinner-r40-dramc.c
>  create mode 100644 hw/misc/allwinner-sramc.c
>  delete mode 100644 hw/misc/axp209.c
>  create mode 100644 hw/misc/axp2xx.c
>  create mode 100644 include/hw/arm/allwinner-r40.h
>  create mode 100644 include/hw/misc/allwinner-r40-ccu.h
>  create mode 100644 include/hw/misc/allwinner-r40-dramc.h
>  create mode 100644 include/hw/misc/allwinner-sramc.h
>
> --
> 2.25.1
>
>

-- 
Niek Linnenbank
Re: [PATCH v5 00/11] *** Add allwinner-r40 support ***
Posted by Peter Maydell 11 months ago
On Thu, 1 Jun 2023 at 19:48, Niek Linnenbank <nieklinnenbank@gmail.com> wrote:
>
> Hi Qianfan,
>
> Thanks for sending the v5. From my side, I have no further comments on the content.
> So please feel free to add the following to each of the patches 01-11 in the series:
>
> Reviewed-by: Niek Linnenbank <nieklinnenbank@gmail.com>
>
> As a reminder and explained here on this page, you'll need to make sure these lines gets added to each of the commit messages:
> https://www.qemu.org/docs/master/devel/submitting-a-patch.html#proper-use-of-reviewed-by-tags-can-aid-review
>
> Doing so would require you to send another updated v6, and baselined on the latest master.

The rebase was simple, so I've applied this v5 to target-arm.next.
(The patch application tools can pick up Reviewed-by tags that are
on-list without requiring a respin just for that.)

Qianfan: thanks for working on this feature and for your efforts
in working through our patch review process.

Niek: thanks very much for taking the lead on the patch review of
this series, it's been a tremendous help.

-- PMM
Re: [PATCH v5 00/11] *** Add allwinner-r40 support ***
Posted by Niek Linnenbank 10 months, 4 weeks ago
Hi Peter, Qianfan,

On Mon, Jun 5, 2023 at 5:31 PM Peter Maydell <peter.maydell@linaro.org>
wrote:

> On Thu, 1 Jun 2023 at 19:48, Niek Linnenbank <nieklinnenbank@gmail.com>
> wrote:
> >
> > Hi Qianfan,
> >
> > Thanks for sending the v5. From my side, I have no further comments on
> the content.
> > So please feel free to add the following to each of the patches 01-11 in
> the series:
> >
> > Reviewed-by: Niek Linnenbank <nieklinnenbank@gmail.com>
> >
> > As a reminder and explained here on this page, you'll need to make sure
> these lines gets added to each of the commit messages:
> >
> https://www.qemu.org/docs/master/devel/submitting-a-patch.html#proper-use-of-reviewed-by-tags-can-aid-review
> >
> > Doing so would require you to send another updated v6, and baselined on
> the latest master.
>
> The rebase was simple, so I've applied this v5 to target-arm.next.
>
Great news!


> (The patch application tools can pick up Reviewed-by tags that are
> on-list without requiring a respin just for that.)
>
Ahh right, I wasn't aware of that. Thanks, I learned something new here.


>
> Qianfan: thanks for working on this feature and for your efforts
> in working through our patch review process.
>
Yes, great work indeed!

>
> Niek: thanks very much for taking the lead on the patch review of
> this series, it's been a tremendous help.
>
I'm glad to help. I only do qemu work in my spare time when I can, so it's
not much.
But I enjoy doing it and learn something new in the process also.

Regards,
Niek


>
> -- PMM
>


-- 
Niek Linnenbank