mbox series

[0/8] soc: amlogic: switch bindings to yaml and adjust some dtbs's

Message ID cb62dfc0-cb3d-beba-6d0b-8db18583dda0@gmail.com
Headers show
Series soc: amlogic: switch bindings to yaml and adjust some dtbs's | expand

Message

Heiner Kallweit Jan. 23, 2023, 9:22 p.m. UTC
At first adjust some existing dtbs's so that they pass dtbs_check
after switching bindings to yaml.

Then switch further Amlogic Meson bindings to yaml.
Tested with make targets dt_binding_check and dtbs_check.

Heiner Kallweit (8):
  arm64: dts: meson-gx: Remove invalid pwm compatible
  arm64: dts: amlogic: Fix non-compliant SD/SDIO node names
  arm64: dts: meson-gx: Set only one compatible string for mmc
  arm64: dts: amlogic: Remove invalid compatible string
    amlogic,meson-gpio-intc
  dt-bindings: rtc: Add Amlogic Meson vrtc controller binding
  dt-bindings: pwm: Add Amlogic Meson PWM binding
  dt-bindings: interrupt-controller: Add Amlogic Meson GPIO interrupt
    controller binding
  dt-bindings: pinctrl: Add Amlogic Meson pinctrl binding

 .../amlogic,meson-gpio-intc.txt               |  38 ------
 .../amlogic,meson-gpio-intc.yaml              |  72 +++++++++++
 .../pinctrl/amlogic,meson-pinctrl.yaml        | 121 ++++++++++++++++++
 .../bindings/pinctrl/meson,pinctrl.txt        |  94 --------------
 .../devicetree/bindings/pwm/pwm-amlogic.yaml  |  61 +++++++++
 .../devicetree/bindings/pwm/pwm-meson.txt     |  29 -----
 .../bindings/rtc/amlogic,meson-vrtc.yaml      |  50 ++++++++
 .../bindings/rtc/rtc-meson-vrtc.txt           |  22 ----
 arch/arm64/boot/dts/amlogic/meson-axg.dtsi    |   5 +-
 .../boot/dts/amlogic/meson-g12-common.dtsi    |   7 +-
 arch/arm64/boot/dts/amlogic/meson-gx.dtsi     |  15 +--
 arch/arm64/boot/dts/amlogic/meson-gxbb.dtsi   |   3 +-
 arch/arm64/boot/dts/amlogic/meson-gxl.dtsi    |   3 +-
 arch/arm64/boot/dts/amlogic/meson-s4.dtsi     |   3 +-
 arch/arm64/boot/dts/amlogic/meson-sm1.dtsi    |   3 +-
 15 files changed, 320 insertions(+), 206 deletions(-)
 delete mode 100644 Documentation/devicetree/bindings/interrupt-controller/amlogic,meson-gpio-intc.txt
 create mode 100644 Documentation/devicetree/bindings/interrupt-controller/amlogic,meson-gpio-intc.yaml
 create mode 100644 Documentation/devicetree/bindings/pinctrl/amlogic,meson-pinctrl.yaml
 delete mode 100644 Documentation/devicetree/bindings/pinctrl/meson,pinctrl.txt
 create mode 100644 Documentation/devicetree/bindings/pwm/pwm-amlogic.yaml
 delete mode 100644 Documentation/devicetree/bindings/pwm/pwm-meson.txt
 create mode 100644 Documentation/devicetree/bindings/rtc/amlogic,meson-vrtc.yaml
 delete mode 100644 Documentation/devicetree/bindings/rtc/rtc-meson-vrtc.txt

Comments

Rob Herring Jan. 24, 2023, 1:22 a.m. UTC | #1
On Mon, 23 Jan 2023 22:30:08 +0100, Heiner Kallweit wrote:
> Add Amlogic Meson GPIO interrupt controller binding.
> Tested with make targets dt_binding_check and dtbs_check.
> 
> Signed-off-by: Heiner Kallweit <hkallweit1@gmail.com>
> ---
>  .../amlogic,meson-gpio-intc.txt               | 38 ----------
>  .../amlogic,meson-gpio-intc.yaml              | 72 +++++++++++++++++++
>  2 files changed, 72 insertions(+), 38 deletions(-)
>  delete mode 100644 Documentation/devicetree/bindings/interrupt-controller/amlogic,meson-gpio-intc.txt
>  create mode 100644 Documentation/devicetree/bindings/interrupt-controller/amlogic,meson-gpio-intc.yaml
> 

Running 'make dtbs_check' with the schema in this patch gives the
following warnings. Consider if they are expected or the schema is
incorrect. These may not be new warnings.

Note that it is not yet a requirement to have 0 warnings for dtbs_check.
This will change in the future.

Full log is available here: https://patchwork.ozlabs.org/project/devicetree-bindings/patch/06289641-18b1-320d-6162-7ae176452f31@gmail.com


interrupt-controller@4080: compatible: ['amlogic,meson-s4-gpio-intc', 'amlogic,meson-gpio-intc'] is too long
	arch/arm64/boot/dts/amlogic/meson-s4-s805x2-aq222.dtb

interrupt-controller@9880: compatible:0: 'amlogic,meson-gpio-intc' is not one of ['amlogic,meson8-gpio-intc', 'amlogic,meson8b-gpio-intc', 'amlogic,meson-gxbb-gpio-intc', 'amlogic,meson-gxl-gpio-intc', 'amlogic,meson-axg-gpio-intc', 'amlogic,meson-g12a-gpio-intc', 'amlogic,meson-sm1-gpio-intc', 'amlogic,meson-a1-gpio-intc', 'amlogic,meson-s4-gpio-intc', 'amlogic,meson-sc2-gpio-intc']
	arch/arm64/boot/dts/amlogic/meson-gxbb-kii-pro.dtb
	arch/arm64/boot/dts/amlogic/meson-gxbb-nanopi-k2.dtb
	arch/arm64/boot/dts/amlogic/meson-gxbb-nexbox-a95x.dtb
	arch/arm64/boot/dts/amlogic/meson-gxbb-odroidc2.dtb
	arch/arm64/boot/dts/amlogic/meson-gxbb-p200.dtb
	arch/arm64/boot/dts/amlogic/meson-gxbb-p201.dtb
	arch/arm64/boot/dts/amlogic/meson-gxbb-vega-s95-meta.dtb
	arch/arm64/boot/dts/amlogic/meson-gxbb-vega-s95-pro.dtb
	arch/arm64/boot/dts/amlogic/meson-gxbb-vega-s95-telos.dtb
	arch/arm64/boot/dts/amlogic/meson-gxbb-wetek-hub.dtb
	arch/arm64/boot/dts/amlogic/meson-gxbb-wetek-play2.dtb
	arch/arm64/boot/dts/amlogic/meson-gxl-s805x-libretech-ac.dtb
	arch/arm64/boot/dts/amlogic/meson-gxl-s805x-p241.dtb
	arch/arm64/boot/dts/amlogic/meson-gxl-s905d-libretech-pc.dtb
	arch/arm64/boot/dts/amlogic/meson-gxl-s905d-mecool-kii-pro.dtb
	arch/arm64/boot/dts/amlogic/meson-gxl-s905d-p230.dtb
	arch/arm64/boot/dts/amlogic/meson-gxl-s905d-p231.dtb
	arch/arm64/boot/dts/amlogic/meson-gxl-s905d-phicomm-n1.dtb
	arch/arm64/boot/dts/amlogic/meson-gxl-s905d-sml5442tw.dtb
	arch/arm64/boot/dts/amlogic/meson-gxl-s905d-vero4k-plus.dtb
	arch/arm64/boot/dts/amlogic/meson-gxl-s905w-jethome-jethub-j80.dtb
	arch/arm64/boot/dts/amlogic/meson-gxl-s905w-p281.dtb
	arch/arm64/boot/dts/amlogic/meson-gxl-s905w-tx3-mini.dtb
	arch/arm64/boot/dts/amlogic/meson-gxl-s905x-hwacom-amazetv.dtb
	arch/arm64/boot/dts/amlogic/meson-gxl-s905x-khadas-vim.dtb
	arch/arm64/boot/dts/amlogic/meson-gxl-s905x-libretech-cc.dtb
	arch/arm64/boot/dts/amlogic/meson-gxl-s905x-libretech-cc-v2.dtb
	arch/arm64/boot/dts/amlogic/meson-gxl-s905x-nexbox-a95x.dtb
	arch/arm64/boot/dts/amlogic/meson-gxl-s905x-p212.dtb
	arch/arm64/boot/dts/amlogic/meson-gxm-gt1-ultimate.dtb
	arch/arm64/boot/dts/amlogic/meson-gxm-khadas-vim2.dtb
	arch/arm64/boot/dts/amlogic/meson-gxm-mecool-kiii-pro.dtb
	arch/arm64/boot/dts/amlogic/meson-gxm-minix-neo-u9h.dtb
	arch/arm64/boot/dts/amlogic/meson-gxm-nexbox-a1.dtb
	arch/arm64/boot/dts/amlogic/meson-gxm-q200.dtb
	arch/arm64/boot/dts/amlogic/meson-gxm-q201.dtb
	arch/arm64/boot/dts/amlogic/meson-gxm-rbox-pro.dtb
	arch/arm64/boot/dts/amlogic/meson-gxm-s912-libretech-pc.dtb
	arch/arm64/boot/dts/amlogic/meson-gxm-vega-s96.dtb
	arch/arm64/boot/dts/amlogic/meson-gxm-wetek-core2.dtb
	arch/arm/boot/dts/meson8b-ec100.dtb
	arch/arm/boot/dts/meson8b-mxq.dtb
	arch/arm/boot/dts/meson8b-odroidc1.dtb

interrupt-controller@9880: compatible: ['amlogic,meson8-gpio-intc', 'amlogic,meson-gpio-intc'] is too long
	arch/arm/boot/dts/meson8m2-mxiii-plus.dtb
	arch/arm/boot/dts/meson8-minix-neo-x8.dtb

interrupt-controller@9880: compatible: ['amlogic,meson-gpio-intc', 'amlogic,meson8b-gpio-intc'] is too long
	arch/arm/boot/dts/meson8b-ec100.dtb
	arch/arm/boot/dts/meson8b-mxq.dtb
	arch/arm/boot/dts/meson8b-odroidc1.dtb

interrupt-controller@9880: compatible: ['amlogic,meson-gpio-intc', 'amlogic,meson-gxbb-gpio-intc'] is too long
	arch/arm64/boot/dts/amlogic/meson-gxbb-kii-pro.dtb
	arch/arm64/boot/dts/amlogic/meson-gxbb-nanopi-k2.dtb
	arch/arm64/boot/dts/amlogic/meson-gxbb-nexbox-a95x.dtb
	arch/arm64/boot/dts/amlogic/meson-gxbb-odroidc2.dtb
	arch/arm64/boot/dts/amlogic/meson-gxbb-p200.dtb
	arch/arm64/boot/dts/amlogic/meson-gxbb-p201.dtb
	arch/arm64/boot/dts/amlogic/meson-gxbb-vega-s95-meta.dtb
	arch/arm64/boot/dts/amlogic/meson-gxbb-vega-s95-pro.dtb
	arch/arm64/boot/dts/amlogic/meson-gxbb-vega-s95-telos.dtb
	arch/arm64/boot/dts/amlogic/meson-gxbb-wetek-hub.dtb
	arch/arm64/boot/dts/amlogic/meson-gxbb-wetek-play2.dtb

interrupt-controller@9880: compatible: ['amlogic,meson-gpio-intc', 'amlogic,meson-gxl-gpio-intc'] is too long
	arch/arm64/boot/dts/amlogic/meson-gxl-s805x-libretech-ac.dtb
	arch/arm64/boot/dts/amlogic/meson-gxl-s805x-p241.dtb
	arch/arm64/boot/dts/amlogic/meson-gxl-s905d-libretech-pc.dtb
	arch/arm64/boot/dts/amlogic/meson-gxl-s905d-mecool-kii-pro.dtb
	arch/arm64/boot/dts/amlogic/meson-gxl-s905d-p230.dtb
	arch/arm64/boot/dts/amlogic/meson-gxl-s905d-p231.dtb
	arch/arm64/boot/dts/amlogic/meson-gxl-s905d-phicomm-n1.dtb
	arch/arm64/boot/dts/amlogic/meson-gxl-s905d-sml5442tw.dtb
	arch/arm64/boot/dts/amlogic/meson-gxl-s905d-vero4k-plus.dtb
	arch/arm64/boot/dts/amlogic/meson-gxl-s905w-jethome-jethub-j80.dtb
	arch/arm64/boot/dts/amlogic/meson-gxl-s905w-p281.dtb
	arch/arm64/boot/dts/amlogic/meson-gxl-s905w-tx3-mini.dtb
	arch/arm64/boot/dts/amlogic/meson-gxl-s905x-hwacom-amazetv.dtb
	arch/arm64/boot/dts/amlogic/meson-gxl-s905x-khadas-vim.dtb
	arch/arm64/boot/dts/amlogic/meson-gxl-s905x-libretech-cc.dtb
	arch/arm64/boot/dts/amlogic/meson-gxl-s905x-libretech-cc-v2.dtb
	arch/arm64/boot/dts/amlogic/meson-gxl-s905x-nexbox-a95x.dtb
	arch/arm64/boot/dts/amlogic/meson-gxl-s905x-p212.dtb
	arch/arm64/boot/dts/amlogic/meson-gxm-gt1-ultimate.dtb
	arch/arm64/boot/dts/amlogic/meson-gxm-khadas-vim2.dtb
	arch/arm64/boot/dts/amlogic/meson-gxm-mecool-kiii-pro.dtb
	arch/arm64/boot/dts/amlogic/meson-gxm-minix-neo-u9h.dtb
	arch/arm64/boot/dts/amlogic/meson-gxm-nexbox-a1.dtb
	arch/arm64/boot/dts/amlogic/meson-gxm-q200.dtb
	arch/arm64/boot/dts/amlogic/meson-gxm-q201.dtb
	arch/arm64/boot/dts/amlogic/meson-gxm-rbox-pro.dtb
	arch/arm64/boot/dts/amlogic/meson-gxm-s912-libretech-pc.dtb
	arch/arm64/boot/dts/amlogic/meson-gxm-vega-s96.dtb
	arch/arm64/boot/dts/amlogic/meson-gxm-wetek-core2.dtb

interrupt-controller@f080: compatible: ['amlogic,meson-axg-gpio-intc', 'amlogic,meson-gpio-intc'] is too long
	arch/arm64/boot/dts/amlogic/meson-axg-jethome-jethub-j100.dtb
	arch/arm64/boot/dts/amlogic/meson-axg-jethome-jethub-j110-rev-2.dtb
	arch/arm64/boot/dts/amlogic/meson-axg-jethome-jethub-j110-rev-3.dtb
	arch/arm64/boot/dts/amlogic/meson-axg-s400.dtb

interrupt-controller@f080: compatible: ['amlogic,meson-g12a-gpio-intc', 'amlogic,meson-gpio-intc'] is too long
	arch/arm64/boot/dts/amlogic/meson-g12a-radxa-zero.dtb
	arch/arm64/boot/dts/amlogic/meson-g12a-sei510.dtb
	arch/arm64/boot/dts/amlogic/meson-g12a-u200.dtb
	arch/arm64/boot/dts/amlogic/meson-g12a-x96-max.dtb
	arch/arm64/boot/dts/amlogic/meson-g12b-a311d-khadas-vim3.dtb
	arch/arm64/boot/dts/amlogic/meson-g12b-gsking-x.dtb
	arch/arm64/boot/dts/amlogic/meson-g12b-gtking.dtb
	arch/arm64/boot/dts/amlogic/meson-g12b-gtking-pro.dtb
	arch/arm64/boot/dts/amlogic/meson-g12b-odroid-go-ultra.dtb
	arch/arm64/boot/dts/amlogic/meson-g12b-odroid-n2.dtb
	arch/arm64/boot/dts/amlogic/meson-g12b-odroid-n2-plus.dtb
	arch/arm64/boot/dts/amlogic/meson-g12b-s922x-khadas-vim3.dtb
	arch/arm64/boot/dts/amlogic/meson-g12b-ugoos-am6.dtb

interrupt-controller@f080: compatible: ['amlogic,meson-sm1-gpio-intc', 'amlogic,meson-gpio-intc'] is too long
	arch/arm64/boot/dts/amlogic/meson-sm1-a95xf3-air.dtb
	arch/arm64/boot/dts/amlogic/meson-sm1-a95xf3-air-gbit.dtb
	arch/arm64/boot/dts/amlogic/meson-sm1-bananapi-m5.dtb
	arch/arm64/boot/dts/amlogic/meson-sm1-h96-max.dtb
	arch/arm64/boot/dts/amlogic/meson-sm1-khadas-vim3l.dtb
	arch/arm64/boot/dts/amlogic/meson-sm1-odroid-c4.dtb
	arch/arm64/boot/dts/amlogic/meson-sm1-odroid-hc4.dtb
	arch/arm64/boot/dts/amlogic/meson-sm1-sei610.dtb
	arch/arm64/boot/dts/amlogic/meson-sm1-x96-air.dtb
	arch/arm64/boot/dts/amlogic/meson-sm1-x96-air-gbit.dtb
Heiner Kallweit Jan. 24, 2023, 7:03 a.m. UTC | #2
On 24.01.2023 02:22, Rob Herring wrote:
> 
> On Mon, 23 Jan 2023 22:30:08 +0100, Heiner Kallweit wrote:
>> Add Amlogic Meson GPIO interrupt controller binding.
>> Tested with make targets dt_binding_check and dtbs_check.
>>
>> Signed-off-by: Heiner Kallweit <hkallweit1@gmail.com>
>> ---
>>  .../amlogic,meson-gpio-intc.txt               | 38 ----------
>>  .../amlogic,meson-gpio-intc.yaml              | 72 +++++++++++++++++++
>>  2 files changed, 72 insertions(+), 38 deletions(-)
>>  delete mode 100644 Documentation/devicetree/bindings/interrupt-controller/amlogic,meson-gpio-intc.txt
>>  create mode 100644 Documentation/devicetree/bindings/interrupt-controller/amlogic,meson-gpio-intc.yaml
>>
> 
> Running 'make dtbs_check' with the schema in this patch gives the
> following warnings. Consider if they are expected or the schema is
> incorrect. These may not be new warnings.
> 

Patch 4 of the series fixes these warnings.
Did you apply the full series?


> Note that it is not yet a requirement to have 0 warnings for dtbs_check.
> This will change in the future.
> 
> Full log is available here: https://patchwork.ozlabs.org/project/devicetree-bindings/patch/06289641-18b1-320d-6162-7ae176452f31@gmail.com
> 
> 
> interrupt-controller@4080: compatible: ['amlogic,meson-s4-gpio-intc', 'amlogic,meson-gpio-intc'] is too long
> 	arch/arm64/boot/dts/amlogic/meson-s4-s805x2-aq222.dtb
> 
> interrupt-controller@9880: compatible:0: 'amlogic,meson-gpio-intc' is not one of ['amlogic,meson8-gpio-intc', 'amlogic,meson8b-gpio-intc', 'amlogic,meson-gxbb-gpio-intc', 'amlogic,meson-gxl-gpio-intc', 'amlogic,meson-axg-gpio-intc', 'amlogic,meson-g12a-gpio-intc', 'amlogic,meson-sm1-gpio-intc', 'amlogic,meson-a1-gpio-intc', 'amlogic,meson-s4-gpio-intc', 'amlogic,meson-sc2-gpio-intc']
> 	arch/arm64/boot/dts/amlogic/meson-gxbb-kii-pro.dtb
> 	arch/arm64/boot/dts/amlogic/meson-gxbb-nanopi-k2.dtb
> 	arch/arm64/boot/dts/amlogic/meson-gxbb-nexbox-a95x.dtb
> 	arch/arm64/boot/dts/amlogic/meson-gxbb-odroidc2.dtb
> 	arch/arm64/boot/dts/amlogic/meson-gxbb-p200.dtb
> 	arch/arm64/boot/dts/amlogic/meson-gxbb-p201.dtb
> 	arch/arm64/boot/dts/amlogic/meson-gxbb-vega-s95-meta.dtb
> 	arch/arm64/boot/dts/amlogic/meson-gxbb-vega-s95-pro.dtb
> 	arch/arm64/boot/dts/amlogic/meson-gxbb-vega-s95-telos.dtb
> 	arch/arm64/boot/dts/amlogic/meson-gxbb-wetek-hub.dtb
> 	arch/arm64/boot/dts/amlogic/meson-gxbb-wetek-play2.dtb
> 	arch/arm64/boot/dts/amlogic/meson-gxl-s805x-libretech-ac.dtb
> 	arch/arm64/boot/dts/amlogic/meson-gxl-s805x-p241.dtb
> 	arch/arm64/boot/dts/amlogic/meson-gxl-s905d-libretech-pc.dtb
> 	arch/arm64/boot/dts/amlogic/meson-gxl-s905d-mecool-kii-pro.dtb
> 	arch/arm64/boot/dts/amlogic/meson-gxl-s905d-p230.dtb
> 	arch/arm64/boot/dts/amlogic/meson-gxl-s905d-p231.dtb
> 	arch/arm64/boot/dts/amlogic/meson-gxl-s905d-phicomm-n1.dtb
> 	arch/arm64/boot/dts/amlogic/meson-gxl-s905d-sml5442tw.dtb
> 	arch/arm64/boot/dts/amlogic/meson-gxl-s905d-vero4k-plus.dtb
> 	arch/arm64/boot/dts/amlogic/meson-gxl-s905w-jethome-jethub-j80.dtb
> 	arch/arm64/boot/dts/amlogic/meson-gxl-s905w-p281.dtb
> 	arch/arm64/boot/dts/amlogic/meson-gxl-s905w-tx3-mini.dtb
> 	arch/arm64/boot/dts/amlogic/meson-gxl-s905x-hwacom-amazetv.dtb
> 	arch/arm64/boot/dts/amlogic/meson-gxl-s905x-khadas-vim.dtb
> 	arch/arm64/boot/dts/amlogic/meson-gxl-s905x-libretech-cc.dtb
> 	arch/arm64/boot/dts/amlogic/meson-gxl-s905x-libretech-cc-v2.dtb
> 	arch/arm64/boot/dts/amlogic/meson-gxl-s905x-nexbox-a95x.dtb
> 	arch/arm64/boot/dts/amlogic/meson-gxl-s905x-p212.dtb
> 	arch/arm64/boot/dts/amlogic/meson-gxm-gt1-ultimate.dtb
> 	arch/arm64/boot/dts/amlogic/meson-gxm-khadas-vim2.dtb
> 	arch/arm64/boot/dts/amlogic/meson-gxm-mecool-kiii-pro.dtb
> 	arch/arm64/boot/dts/amlogic/meson-gxm-minix-neo-u9h.dtb
> 	arch/arm64/boot/dts/amlogic/meson-gxm-nexbox-a1.dtb
> 	arch/arm64/boot/dts/amlogic/meson-gxm-q200.dtb
> 	arch/arm64/boot/dts/amlogic/meson-gxm-q201.dtb
> 	arch/arm64/boot/dts/amlogic/meson-gxm-rbox-pro.dtb
> 	arch/arm64/boot/dts/amlogic/meson-gxm-s912-libretech-pc.dtb
> 	arch/arm64/boot/dts/amlogic/meson-gxm-vega-s96.dtb
> 	arch/arm64/boot/dts/amlogic/meson-gxm-wetek-core2.dtb
> 	arch/arm/boot/dts/meson8b-ec100.dtb
> 	arch/arm/boot/dts/meson8b-mxq.dtb
> 	arch/arm/boot/dts/meson8b-odroidc1.dtb
> 
> interrupt-controller@9880: compatible: ['amlogic,meson8-gpio-intc', 'amlogic,meson-gpio-intc'] is too long
> 	arch/arm/boot/dts/meson8m2-mxiii-plus.dtb
> 	arch/arm/boot/dts/meson8-minix-neo-x8.dtb
> 
> interrupt-controller@9880: compatible: ['amlogic,meson-gpio-intc', 'amlogic,meson8b-gpio-intc'] is too long
> 	arch/arm/boot/dts/meson8b-ec100.dtb
> 	arch/arm/boot/dts/meson8b-mxq.dtb
> 	arch/arm/boot/dts/meson8b-odroidc1.dtb
> 
> interrupt-controller@9880: compatible: ['amlogic,meson-gpio-intc', 'amlogic,meson-gxbb-gpio-intc'] is too long
> 	arch/arm64/boot/dts/amlogic/meson-gxbb-kii-pro.dtb
> 	arch/arm64/boot/dts/amlogic/meson-gxbb-nanopi-k2.dtb
> 	arch/arm64/boot/dts/amlogic/meson-gxbb-nexbox-a95x.dtb
> 	arch/arm64/boot/dts/amlogic/meson-gxbb-odroidc2.dtb
> 	arch/arm64/boot/dts/amlogic/meson-gxbb-p200.dtb
> 	arch/arm64/boot/dts/amlogic/meson-gxbb-p201.dtb
> 	arch/arm64/boot/dts/amlogic/meson-gxbb-vega-s95-meta.dtb
> 	arch/arm64/boot/dts/amlogic/meson-gxbb-vega-s95-pro.dtb
> 	arch/arm64/boot/dts/amlogic/meson-gxbb-vega-s95-telos.dtb
> 	arch/arm64/boot/dts/amlogic/meson-gxbb-wetek-hub.dtb
> 	arch/arm64/boot/dts/amlogic/meson-gxbb-wetek-play2.dtb
> 
> interrupt-controller@9880: compatible: ['amlogic,meson-gpio-intc', 'amlogic,meson-gxl-gpio-intc'] is too long
> 	arch/arm64/boot/dts/amlogic/meson-gxl-s805x-libretech-ac.dtb
> 	arch/arm64/boot/dts/amlogic/meson-gxl-s805x-p241.dtb
> 	arch/arm64/boot/dts/amlogic/meson-gxl-s905d-libretech-pc.dtb
> 	arch/arm64/boot/dts/amlogic/meson-gxl-s905d-mecool-kii-pro.dtb
> 	arch/arm64/boot/dts/amlogic/meson-gxl-s905d-p230.dtb
> 	arch/arm64/boot/dts/amlogic/meson-gxl-s905d-p231.dtb
> 	arch/arm64/boot/dts/amlogic/meson-gxl-s905d-phicomm-n1.dtb
> 	arch/arm64/boot/dts/amlogic/meson-gxl-s905d-sml5442tw.dtb
> 	arch/arm64/boot/dts/amlogic/meson-gxl-s905d-vero4k-plus.dtb
> 	arch/arm64/boot/dts/amlogic/meson-gxl-s905w-jethome-jethub-j80.dtb
> 	arch/arm64/boot/dts/amlogic/meson-gxl-s905w-p281.dtb
> 	arch/arm64/boot/dts/amlogic/meson-gxl-s905w-tx3-mini.dtb
> 	arch/arm64/boot/dts/amlogic/meson-gxl-s905x-hwacom-amazetv.dtb
> 	arch/arm64/boot/dts/amlogic/meson-gxl-s905x-khadas-vim.dtb
> 	arch/arm64/boot/dts/amlogic/meson-gxl-s905x-libretech-cc.dtb
> 	arch/arm64/boot/dts/amlogic/meson-gxl-s905x-libretech-cc-v2.dtb
> 	arch/arm64/boot/dts/amlogic/meson-gxl-s905x-nexbox-a95x.dtb
> 	arch/arm64/boot/dts/amlogic/meson-gxl-s905x-p212.dtb
> 	arch/arm64/boot/dts/amlogic/meson-gxm-gt1-ultimate.dtb
> 	arch/arm64/boot/dts/amlogic/meson-gxm-khadas-vim2.dtb
> 	arch/arm64/boot/dts/amlogic/meson-gxm-mecool-kiii-pro.dtb
> 	arch/arm64/boot/dts/amlogic/meson-gxm-minix-neo-u9h.dtb
> 	arch/arm64/boot/dts/amlogic/meson-gxm-nexbox-a1.dtb
> 	arch/arm64/boot/dts/amlogic/meson-gxm-q200.dtb
> 	arch/arm64/boot/dts/amlogic/meson-gxm-q201.dtb
> 	arch/arm64/boot/dts/amlogic/meson-gxm-rbox-pro.dtb
> 	arch/arm64/boot/dts/amlogic/meson-gxm-s912-libretech-pc.dtb
> 	arch/arm64/boot/dts/amlogic/meson-gxm-vega-s96.dtb
> 	arch/arm64/boot/dts/amlogic/meson-gxm-wetek-core2.dtb
> 
> interrupt-controller@f080: compatible: ['amlogic,meson-axg-gpio-intc', 'amlogic,meson-gpio-intc'] is too long
> 	arch/arm64/boot/dts/amlogic/meson-axg-jethome-jethub-j100.dtb
> 	arch/arm64/boot/dts/amlogic/meson-axg-jethome-jethub-j110-rev-2.dtb
> 	arch/arm64/boot/dts/amlogic/meson-axg-jethome-jethub-j110-rev-3.dtb
> 	arch/arm64/boot/dts/amlogic/meson-axg-s400.dtb
> 
> interrupt-controller@f080: compatible: ['amlogic,meson-g12a-gpio-intc', 'amlogic,meson-gpio-intc'] is too long
> 	arch/arm64/boot/dts/amlogic/meson-g12a-radxa-zero.dtb
> 	arch/arm64/boot/dts/amlogic/meson-g12a-sei510.dtb
> 	arch/arm64/boot/dts/amlogic/meson-g12a-u200.dtb
> 	arch/arm64/boot/dts/amlogic/meson-g12a-x96-max.dtb
> 	arch/arm64/boot/dts/amlogic/meson-g12b-a311d-khadas-vim3.dtb
> 	arch/arm64/boot/dts/amlogic/meson-g12b-gsking-x.dtb
> 	arch/arm64/boot/dts/amlogic/meson-g12b-gtking.dtb
> 	arch/arm64/boot/dts/amlogic/meson-g12b-gtking-pro.dtb
> 	arch/arm64/boot/dts/amlogic/meson-g12b-odroid-go-ultra.dtb
> 	arch/arm64/boot/dts/amlogic/meson-g12b-odroid-n2.dtb
> 	arch/arm64/boot/dts/amlogic/meson-g12b-odroid-n2-plus.dtb
> 	arch/arm64/boot/dts/amlogic/meson-g12b-s922x-khadas-vim3.dtb
> 	arch/arm64/boot/dts/amlogic/meson-g12b-ugoos-am6.dtb
> 
> interrupt-controller@f080: compatible: ['amlogic,meson-sm1-gpio-intc', 'amlogic,meson-gpio-intc'] is too long
> 	arch/arm64/boot/dts/amlogic/meson-sm1-a95xf3-air.dtb
> 	arch/arm64/boot/dts/amlogic/meson-sm1-a95xf3-air-gbit.dtb
> 	arch/arm64/boot/dts/amlogic/meson-sm1-bananapi-m5.dtb
> 	arch/arm64/boot/dts/amlogic/meson-sm1-h96-max.dtb
> 	arch/arm64/boot/dts/amlogic/meson-sm1-khadas-vim3l.dtb
> 	arch/arm64/boot/dts/amlogic/meson-sm1-odroid-c4.dtb
> 	arch/arm64/boot/dts/amlogic/meson-sm1-odroid-hc4.dtb
> 	arch/arm64/boot/dts/amlogic/meson-sm1-sei610.dtb
> 	arch/arm64/boot/dts/amlogic/meson-sm1-x96-air.dtb
> 	arch/arm64/boot/dts/amlogic/meson-sm1-x96-air-gbit.dtb
>
Neil Armstrong Jan. 24, 2023, 7:16 a.m. UTC | #3
Hi Heiner,

Le 23/01/2023 à 22:22, Heiner Kallweit a écrit :
> At first adjust some existing dtbs's so that they pass dtbs_check
> after switching bindings to yaml.

Thanks for this patchset, but please drop patches 1, 3 & 4, and take
in account the existing compatible usage in your new bindings like
I did in my conversion patchset.

While we did remove some bad compatibles we introduced a few years ago,
now the GXBB, GXL & GXM are now stable a aew LTS releases now and
a few other projects uses them as-is (U-Boot, BSDs, ...) so changing
the compatibles isn't an option anymore... and we can't know which
one they use and how the implementation behaves we must document
the existing usage without breaking any potential users (including linux).

Thanks,
Neil



> 
> Then switch further Amlogic Meson bindings to yaml.
> Tested with make targets dt_binding_check and dtbs_check.
> 
> Heiner Kallweit (8):
>    arm64: dts: meson-gx: Remove invalid pwm compatible
>    arm64: dts: amlogic: Fix non-compliant SD/SDIO node names
>    arm64: dts: meson-gx: Set only one compatible string for mmc
>    arm64: dts: amlogic: Remove invalid compatible string
>      amlogic,meson-gpio-intc
>    dt-bindings: rtc: Add Amlogic Meson vrtc controller binding
>    dt-bindings: pwm: Add Amlogic Meson PWM binding
>    dt-bindings: interrupt-controller: Add Amlogic Meson GPIO interrupt
>      controller binding
>    dt-bindings: pinctrl: Add Amlogic Meson pinctrl binding
> 
>   .../amlogic,meson-gpio-intc.txt               |  38 ------
>   .../amlogic,meson-gpio-intc.yaml              |  72 +++++++++++
>   .../pinctrl/amlogic,meson-pinctrl.yaml        | 121 ++++++++++++++++++
>   .../bindings/pinctrl/meson,pinctrl.txt        |  94 --------------
>   .../devicetree/bindings/pwm/pwm-amlogic.yaml  |  61 +++++++++
>   .../devicetree/bindings/pwm/pwm-meson.txt     |  29 -----
>   .../bindings/rtc/amlogic,meson-vrtc.yaml      |  50 ++++++++
>   .../bindings/rtc/rtc-meson-vrtc.txt           |  22 ----
>   arch/arm64/boot/dts/amlogic/meson-axg.dtsi    |   5 +-
>   .../boot/dts/amlogic/meson-g12-common.dtsi    |   7 +-
>   arch/arm64/boot/dts/amlogic/meson-gx.dtsi     |  15 +--
>   arch/arm64/boot/dts/amlogic/meson-gxbb.dtsi   |   3 +-
>   arch/arm64/boot/dts/amlogic/meson-gxl.dtsi    |   3 +-
>   arch/arm64/boot/dts/amlogic/meson-s4.dtsi     |   3 +-
>   arch/arm64/boot/dts/amlogic/meson-sm1.dtsi    |   3 +-
>   15 files changed, 320 insertions(+), 206 deletions(-)
>   delete mode 100644 Documentation/devicetree/bindings/interrupt-controller/amlogic,meson-gpio-intc.txt
>   create mode 100644 Documentation/devicetree/bindings/interrupt-controller/amlogic,meson-gpio-intc.yaml
>   create mode 100644 Documentation/devicetree/bindings/pinctrl/amlogic,meson-pinctrl.yaml
>   delete mode 100644 Documentation/devicetree/bindings/pinctrl/meson,pinctrl.txt
>   create mode 100644 Documentation/devicetree/bindings/pwm/pwm-amlogic.yaml
>   delete mode 100644 Documentation/devicetree/bindings/pwm/pwm-meson.txt
>   create mode 100644 Documentation/devicetree/bindings/rtc/amlogic,meson-vrtc.yaml
>   delete mode 100644 Documentation/devicetree/bindings/rtc/rtc-meson-vrtc.txt
>
Neil Armstrong Jan. 24, 2023, 8:22 a.m. UTC | #4
Hi,

On Mon, 23 Jan 2023 22:22:15 +0100, Heiner Kallweit wrote:
> At first adjust some existing dtbs's so that they pass dtbs_check
> after switching bindings to yaml.
> 
> Then switch further Amlogic Meson bindings to yaml.
> Tested with make targets dt_binding_check and dtbs_check.
> 
> Heiner Kallweit (8):
>   arm64: dts: meson-gx: Remove invalid pwm compatible
>   arm64: dts: amlogic: Fix non-compliant SD/SDIO node names
>   arm64: dts: meson-gx: Set only one compatible string for mmc
>   arm64: dts: amlogic: Remove invalid compatible string
>     amlogic,meson-gpio-intc
>   dt-bindings: rtc: Add Amlogic Meson vrtc controller binding
>   dt-bindings: pwm: Add Amlogic Meson PWM binding
>   dt-bindings: interrupt-controller: Add Amlogic Meson GPIO interrupt
>     controller binding
>   dt-bindings: pinctrl: Add Amlogic Meson pinctrl binding
> 
> [...]

Thanks, Applied to https://git.kernel.org/pub/scm/linux/kernel/git/amlogic/linux.git (v6.3/arm64-dt)

[2/8] arm64: dts: amlogic: Fix non-compliant SD/SDIO node names
      https://git.kernel.org/amlogic/c/1be13a5091bf71627aa1a3d35360b039510f42f3

These changes has been applied on the intermediate git tree [1].

The v6.3/arm64-dt branch will then be sent via a formal Pull Request to the Linux SoC maintainers
for inclusion in their intermediate git branches in order to be sent to Linus during
the next merge window, or sooner if it's a set of fixes.

In the cases of fixes, those will be merged in the current release candidate
kernel and as soon they appear on the Linux master branch they will be
backported to the previous Stable and Long-Stable kernels [2].

The intermediate git branches are merged daily in the linux-next tree [3],
people are encouraged testing these pre-release kernels and report issues on the
relevant mailing-lists.

If problems are discovered on those changes, please submit a signed-off-by revert
patch followed by a corrective changeset.

[1] https://git.kernel.org/pub/scm/linux/kernel/git/amlogic/linux.git
[2] https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
[3] https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git
Uwe Kleine-König Jan. 26, 2023, 7:40 a.m. UTC | #5
Hello,

On Tue, Jan 24, 2023 at 08:16:45AM +0100, Neil Armstrong wrote:
> Le 23/01/2023 à 22:22, Heiner Kallweit a écrit :
> > At first adjust some existing dtbs's so that they pass dtbs_check
> > after switching bindings to yaml.
> 
> Thanks for this patchset, but please drop patches 1, 3 & 4, and take
> in account the existing compatible usage in your new bindings like
> I did in my conversion patchset.
> 
> While we did remove some bad compatibles we introduced a few years ago,
> now the GXBB, GXL & GXM are now stable a aew LTS releases now and
> a few other projects uses them as-is (U-Boot, BSDs, ...) so changing
> the compatibles isn't an option anymore... and we can't know which
> one they use and how the implementation behaves we must document
> the existing usage without breaking any potential users (including linux).

I only looked into patch #1, and I support dropping it for stronger
reasons than not breaking things which maybe started to rely on the
existing contents.

In patch #1 you write:

| amlogic,meson-gx-pwm isn't a valid compatible string, so remove it.
| See drivers/pwm/pwm-meson.c.
| 
| Signed-off-by: Heiner Kallweit <hkallweit1@gmail.com>
| ---
|  arch/arm64/boot/dts/amlogic/meson-gx.dtsi | 8 ++++----
|  1 file changed, 4 insertions(+), 4 deletions(-)
| 
| diff --git a/arch/arm64/boot/dts/amlogic/meson-gx.dtsi b/arch/arm64/boot/dts/amlogic/meson-gx.dtsi
| index a79a35e84..75d35dcfe 100644
| --- a/arch/arm64/boot/dts/amlogic/meson-gx.dtsi
| +++ b/arch/arm64/boot/dts/amlogic/meson-gx.dtsi
| @@ -328,14 +328,14 @@ i2c_A: i2c@8500 {
|                         };
| 
|                         pwm_ab: pwm@8550 {
| -                               compatible = "amlogic,meson-gx-pwm", "amlogic,meson-gxbb-pwm";
| +                               compatible = "amlogic,meson-gxbb-pwm";

There are two issues:

a) drivers/pwm/pwm-meson.c isn't the reference. The driver doesn't
   justify which compatibles should be used. You should refer to the
   binding document instead.

b) Having the SoC name as an additional compatible (i.e. the status quo
   before your patch) is an advantage. While it doesn't hurt (apart from
   making the dtb a tad bigger) it makes it possible to adapt the driver
   if in the future someone discovers that the PWM component on GX is a
   tad different from the GXBB one. In that case you can add a check in
   the driver à la 

   	if (of_device_is_compatible(np, amlogic,meson-gx-pwm))
		do_the_special_gx_handling()

   without having to adapt the device trees then (or use some ugly
   code that somehow detects if it's running on GX).

So the driver not handling amlogic,meson-gx-pwm today is fine. I expect
the fix to be: Include that compatible in the binding.

Best regards
Uwe
Krzysztof Kozlowski Feb. 1, 2023, 7:35 a.m. UTC | #6
On 30/01/2023 21:34, Heiner Kallweit wrote:
> Convert Amlogic Meson PWM binding to yaml.
> 
> Signed-off-by: Heiner Kallweit <hkallweit1@gmail.com>
> ---
> v2:
> - fix clocks and clock-names
> - consider that more than one compatible may be set
> v3:
> - remove minItem/maxItem properties for compatible
> ---
>  .../devicetree/bindings/pwm/pwm-amlogic.yaml  | 71 +++++++++++++++++++
>  .../devicetree/bindings/pwm/pwm-meson.txt     | 29 --------
>  2 files changed, 71 insertions(+), 29 deletions(-)
>  create mode 100644 Documentation/devicetree/bindings/pwm/pwm-amlogic.yaml
>  delete mode 100644 Documentation/devicetree/bindings/pwm/pwm-meson.txt
> 
> diff --git a/Documentation/devicetree/bindings/pwm/pwm-amlogic.yaml b/Documentation/devicetree/bindings/pwm/pwm-amlogic.yaml
> new file mode 100644
> index 000000000..750642e76
> --- /dev/null
> +++ b/Documentation/devicetree/bindings/pwm/pwm-amlogic.yaml
> @@ -0,0 +1,71 @@
> +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
> +%YAML 1.2
> +---
> +$id: http://devicetree.org/schemas/pwm/pwm-amlogic.yaml#
> +$schema: http://devicetree.org/meta-schemas/core.yaml#
> +
> +title: Amlogic PWM
> +
> +maintainers:
> +  - Heiner Kallweit <hkallweit1@gmail.com>
> +
> +allOf:
> +  - $ref: pwm.yaml#
> +
> +properties:
> +  compatible:
> +    oneOf:
> +      - items:

Drop items

> +          - enum:
> +              - amlogic,meson8b-pwm
> +              - amlogic,meson-gxbb-pwm
> +              - amlogic,meson-gxbb-ao-pwm
> +              - amlogic,meson-axg-ee-pwm
> +              - amlogic,meson-axg-ao-pwm
> +              - amlogic,meson-g12a-ee-pwm
> +              - amlogic,meson-g12a-ao-pwm-ab
> +              - amlogic,meson-g12a-ao-pwm-cd
> +              - amlogic,meson-s4-pwm

Best regards,
Krzysztof
Heiner Kallweit Feb. 1, 2023, 10:13 p.m. UTC | #7
On 01.02.2023 03:06, Rob Herring wrote:
> On Mon, Jan 30, 2023 at 10:00:24PM +0100, Heiner Kallweit wrote:
>> Convert Amlogic Meson pinctrl binding to yaml.
>>
>> Signed-off-by: Heiner Kallweit <hkallweit1@gmail.com>
>> ---
>> v2:
>> - consider that more than one compatible can be set
>> - remove bus part from example
>> v3:
>> - remove minItem/maxItem properties for compatible
>> ---
>>  .../pinctrl/amlogic,meson-pinctrl.yaml        | 122 ++++++++++++++++++
>>  .../bindings/pinctrl/meson,pinctrl.txt        |  94 --------------
>>  2 files changed, 122 insertions(+), 94 deletions(-)
>>  create mode 100644 Documentation/devicetree/bindings/pinctrl/amlogic,meson-pinctrl.yaml
>>  delete mode 100644 Documentation/devicetree/bindings/pinctrl/meson,pinctrl.txt
>>
>> diff --git a/Documentation/devicetree/bindings/pinctrl/amlogic,meson-pinctrl.yaml b/Documentation/devicetree/bindings/pinctrl/amlogic,meson-pinctrl.yaml
>> new file mode 100644
>> index 000000000..7aaae606b
>> --- /dev/null
>> +++ b/Documentation/devicetree/bindings/pinctrl/amlogic,meson-pinctrl.yaml
>> @@ -0,0 +1,122 @@
>> +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
>> +%YAML 1.2
>> +---
>> +$id: http://devicetree.org/schemas/pinctrl/amlogic,meson-pinctrl.yaml#
>> +$schema: http://devicetree.org/meta-schemas/core.yaml#
>> +
>> +title: Amlogic Meson pinmux controller
>> +
>> +maintainers:
>> +  - Neil Armstrong <neil.armstrong@linaro.org>
>> +
>> +allOf:
>> +  - $ref: pinctrl.yaml#
>> +
>> +properties:
>> +  compatible:
>> +    oneOf:
>> +      - items:
>> +          - enum:
>> +              - amlogic,meson8-cbus-pinctrl
>> +              - amlogic,meson8b-cbus-pinctrl
>> +              - amlogic,meson8m2-cbus-pinctrl
>> +              - amlogic,meson8-aobus-pinctrl
>> +              - amlogic,meson8b-aobus-pinctrl
>> +              - amlogic,meson8m2-aobus-pinctrl
>> +              - amlogic,meson-gxbb-periphs-pinctrl
>> +              - amlogic,meson-gxbb-aobus-pinctrl
>> +              - amlogic,meson-gxl-periphs-pinctrl
>> +              - amlogic,meson-gxl-aobus-pinctrl
>> +              - amlogic,meson-axg-periphs-pinctrl
>> +              - amlogic,meson-axg-aobus-pinctrl
>> +              - amlogic,meson-g12a-periphs-pinctrl
>> +              - amlogic,meson-g12a-aobus-pinctrl
>> +              - amlogic,meson-a1-periphs-pinctrl
>> +              - amlogic,meson-s4-periphs-pinctrl
>> +      - items:
>> +          - const: amlogic,meson8m2-aobus-pinctrl
>> +          - const: amlogic,meson8-aobus-pinctrl
>> +      - items:
>> +          - const: amlogic,meson8m2-cbus-pinctrl
>> +          - const: amlogic,meson8-cbus-pinctrl
> 
> Again, can't have both with and without the fallback allowed.
> 
Hi Martin,

meson8m2 is the only chip version having a fallback for the
pinctrl compatible. Is this fallback really needed?
Looking at the driver it seems that both compatibles
are handled identically.
Neil Armstrong June 22, 2023, 7:57 a.m. UTC | #8
Hi,

On Mon, 23 Jan 2023 22:22:15 +0100, Heiner Kallweit wrote:
> At first adjust some existing dtbs's so that they pass dtbs_check
> after switching bindings to yaml.
> 
> Then switch further Amlogic Meson bindings to yaml.
> Tested with make targets dt_binding_check and dtbs_check.
> 
> Heiner Kallweit (8):
>   arm64: dts: meson-gx: Remove invalid pwm compatible
>   arm64: dts: amlogic: Fix non-compliant SD/SDIO node names
>   arm64: dts: meson-gx: Set only one compatible string for mmc
>   arm64: dts: amlogic: Remove invalid compatible string
>     amlogic,meson-gpio-intc
>   dt-bindings: rtc: Add Amlogic Meson vrtc controller binding
>   dt-bindings: pwm: Add Amlogic Meson PWM binding
>   dt-bindings: interrupt-controller: Add Amlogic Meson GPIO interrupt
>     controller binding
>   dt-bindings: pinctrl: Add Amlogic Meson pinctrl binding
> 
> [...]

Thanks, Applied to https://git.kernel.org/pub/scm/linux/kernel/git/amlogic/linux.git (v6.5/drivers)

[1/1] dt-bindings: interrupt-controller: Convert Amlogic Meson GPIO interrupt controller binding
      https://git.kernel.org/amlogic/c/6b0139b372d40bd5dafc140b6618b57d13211168

These changes has been applied on the intermediate git tree [1].

The v6.5/drivers branch will then be sent via a formal Pull Request to the Linux SoC maintainers
for inclusion in their intermediate git branches in order to be sent to Linus during
the next merge window, or sooner if it's a set of fixes.

In the cases of fixes, those will be merged in the current release candidate
kernel and as soon they appear on the Linux master branch they will be
backported to the previous Stable and Long-Stable kernels [2].

The intermediate git branches are merged daily in the linux-next tree [3],
people are encouraged testing these pre-release kernels and report issues on the
relevant mailing-lists.

If problems are discovered on those changes, please submit a signed-off-by revert
patch followed by a corrective changeset.

[1] https://git.kernel.org/pub/scm/linux/kernel/git/amlogic/linux.git
[2] https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
[3] https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git