Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

List of missing device tree properties with category: required in the binding for the node #17532

Closed
ulfalizer opened this issue Jul 15, 2019 · 5 comments
Assignees
Labels
area: Devicetree bug The issue is a bug, or the PR is fixing a bug

Comments

@ulfalizer
Copy link
Collaborator

ulfalizer commented Jul 15, 2019

We want to turn it into an error when a node is missing a property that's listed with category: required in the binding for the node, instead of a warning.

Here's a list of all missing properties now. Please clean it up if you see something you recognize. It was generated by doing a /scripts/sanitycheck -T samples/hello_world --cmake-only -l with the WIP new DT scripts.

The category: required might come from an !included binding. The path is to the top-level binding file.

interrupts not in /soc/i2c@100200 in altera_max10.dts_compiled, req. by dts/bindings/i2c/nios2,i2c.yaml
interrupts not in /soc/uart@201000 in qemu_nios2.dts_compiled, req. by dts/bindings/serial/altera,jtag-uart.yaml
interrupts not in /soc/uart@70001000 in m2gl025_miv.dts_compiled, req. by dts/bindings/serial/microsemi,coreuart.yaml
label not in /pwmleds/blue_pwm_led in hexiwear_k64.dts_compiled, req. by dts/bindings/led/pwm-leds.yaml
label not in /pwmleds/red_pwm_led in nucleo_l496zg.dts_compiled, req. by dts/bindings/led/pwm-leds.yaml
label not in /soc/peripheral@40000000/dtimer@2000 in mps2_an521_nonsecure.dts_compiled, req. by dts/bindings/timer/arm,cmsdk-dtimer.yaml
label not in /soc/peripheral@40000000/timer@10c000 in v2m_musca_b1_nonsecure.dts_compiled, req. by dts/bindings/timer/arm,cmsdk-timer.yaml
label not in /soc/peripheral@50000000/dtimer@2000 in mps2_an521.dts_compiled, req. by dts/bindings/timer/arm,cmsdk-dtimer.yaml
label not in /soc/peripheral@50000000/timer@10c000 in v2m_musca_b1.dts_compiled, req. by dts/bindings/timer/arm,cmsdk-timer.yaml
@ulfalizer ulfalizer added the bug The issue is a bug, or the PR is fixing a bug label Jul 15, 2019
@ulfalizer ulfalizer changed the title List of missing properties in nodes with category: required in their binding List of missing device tree properties with category: required in the binding for the node Jul 15, 2019
@ulfalizer
Copy link
Collaborator Author

ulfalizer commented Jul 15, 2019

@ulfalizer
Copy link
Collaborator Author

ulfalizer commented Jul 15, 2019

Updated the list after fixing a goof in the code that hid some missing required stuff. Galak fixed some stuff too.

The list is sorted now.

ulfalizer added a commit to ulfalizer/zephyr that referenced this issue Jul 16, 2019
I'm guessing STM32 GPIO nodes don't generate interrupts, because I can't
find any device tree nodes with 'compatible = "st,stm32-gpio"' and an
'interrupts' property.

Remove the required 'interrupts' property from the binding. This fixes a
bunch of errors in
zephyrproject-rtos#17532.

Signed-off-by: Ulf Magnusson <Ulf.Magnusson@nordicsemi.no>
@ulfalizer
Copy link
Collaborator Author

There's pending PRs for the clocks stuff now, so removed it.

ulfalizer added a commit to ulfalizer/zephyr that referenced this issue Jul 16, 2019
None of the interrupt controller nodes that use this binding in the
device tree files set 'reg' (or have a unit address).

Fixes a bunch of errors in
zephyrproject-rtos#17532.

Signed-off-by: Ulf Magnusson <Ulf.Magnusson@nordicsemi.no>
@ulfalizer
Copy link
Collaborator Author

Removed 'reg' (#17578).

@ulfalizer
Copy link
Collaborator Author

intmux stuff: #17579

galak pushed a commit that referenced this issue Jul 17, 2019
None of the interrupt controller nodes that use this binding in the
device tree files set 'reg' (or have a unit address).

Fixes a bunch of errors in
#17532.

Signed-off-by: Ulf Magnusson <Ulf.Magnusson@nordicsemi.no>
galak pushed a commit to galak/zephyr that referenced this issue Jul 17, 2019
Looks like no nodes with bindings that inherit pwm.yaml might be setting
'clocks'.

Fixes some errors in
zephyrproject-rtos#17532.

Signed-off-by: Ulf Magnusson <Ulf.Magnusson@nordicsemi.no>
galak pushed a commit that referenced this issue Jul 17, 2019
Setting it seems rare. Maybe it could be changed to required on just
some platforms (!including bindings can change 'optional' to
'required').

Fixes a bunch of errors in
#17532.

Signed-off-by: Ulf Magnusson <Ulf.Magnusson@nordicsemi.no>
galak pushed a commit that referenced this issue Jul 17, 2019
Looks like no nodes with bindings that inherit pwm.yaml might be setting
'clocks'.

Fixes some errors in
#17532.

Signed-off-by: Ulf Magnusson <Ulf.Magnusson@nordicsemi.no>
galak pushed a commit that referenced this issue Jul 17, 2019
These bindings !include adc.yaml, but their device tree nodes never set
'clocks':

    dts/bindings/iio/adc/atmel,sam-afec.yaml
    dts/bindings/iio/adc/atmel,sam0-adc.yaml
    dts/bindings/iio/adc/nordic,nrf-adc.yaml
    dts/bindings/iio/adc/nordic,nrf-saadc.yaml

The nodes for these bindings do set it (think it's consistent for
st,stm32-adc.yaml):

    dts/bindings/iio/adc/nxp,kinetis-adc12.yaml
    dts/bindings/iio/adc/st,stm32-adc.yaml

Make 'clocks' optional in adc.yaml. Maybe it should be changed to
required on some platforms (!including bindings can change 'optional' to
'required').

Fixes a bunch of errors in
#17532.

Signed-off-by: Ulf Magnusson <Ulf.Magnusson@nordicsemi.no>
galak pushed a commit that referenced this issue Jul 17, 2019
These bindings override the 'category: optional' for 'clocks' from
uart.yaml with 'category: required', but none of the nodes that use the
bindings set 'clocks'.

Maybe it's a copy-paste error. Remove the 'clock' overrides.

Fixes some errors in
#17532.

Signed-off-by: Ulf Magnusson <Ulf.Magnusson@nordicsemi.no>
ulfalizer added a commit to ulfalizer/zephyr that referenced this issue Jul 17, 2019
spi-max-frequency is marked as required in
dts/bindings/mtd/jedec,spi-nor.yaml.

I took the value from the datasheets (133 MHz for all), and guessed that
a dummy entry is fine for QEMU.

Fixes some errors in
zephyrproject-rtos#17532.

Signed-off-by: Ulf Magnusson <Ulf.Magnusson@nordicsemi.no>
ulfalizer added a commit to ulfalizer/zephyr that referenced this issue Jul 18, 2019
…essage

Use a format that's easier to tweak for pasting into
zephyrproject-rtos#17532.
ulfalizer added a commit to ulfalizer/zephyr that referenced this issue Jul 18, 2019
I'm guessing STM32 GPIO nodes don't generate interrupts, because I can't
find any device tree nodes with 'compatible = "st,stm32-gpio"' and an
'interrupts' property.

Remove the required 'interrupts' property from the binding. This fixes a
bunch of errors in
zephyrproject-rtos#17532.

Signed-off-by: Ulf Magnusson <Ulf.Magnusson@nordicsemi.no>
ulfalizer added a commit to ulfalizer/zephyr that referenced this issue Jul 18, 2019
spi-max-frequency is marked as required in
dts/bindings/mtd/jedec,spi-nor.yaml.

I took the value from the datasheets (133 MHz for all), and guessed that
a dummy entry is fine for QEMU.

Fixes some errors in
zephyrproject-rtos#17532.

Signed-off-by: Ulf Magnusson <Ulf.Magnusson@nordicsemi.no>
galak pushed a commit that referenced this issue Jul 19, 2019
spi-max-frequency is marked as required in
dts/bindings/mtd/jedec,spi-nor.yaml.

I took the value from the datasheets (133 MHz for all), and guessed that
a dummy entry is fine for QEMU.

Fixes some errors in
#17532.

Signed-off-by: Ulf Magnusson <Ulf.Magnusson@nordicsemi.no>
galak pushed a commit that referenced this issue Jul 19, 2019
I'm guessing STM32 GPIO nodes don't generate interrupts, because I can't
find any device tree nodes with 'compatible = "st,stm32-gpio"' and an
'interrupts' property.

Remove the required 'interrupts' property from the binding. This fixes a
bunch of errors in
#17532.

Signed-off-by: Ulf Magnusson <Ulf.Magnusson@nordicsemi.no>
LeiW000 pushed a commit to LeiW000/zephyr that referenced this issue Sep 2, 2019
spi-max-frequency is marked as required in
dts/bindings/mtd/jedec,spi-nor.yaml.

I took the value from the datasheets (133 MHz for all), and guessed that
a dummy entry is fine for QEMU.

Fixes some errors in
zephyrproject-rtos#17532.

Signed-off-by: Ulf Magnusson <Ulf.Magnusson@nordicsemi.no>
LeiW000 pushed a commit to LeiW000/zephyr that referenced this issue Sep 2, 2019
I'm guessing STM32 GPIO nodes don't generate interrupts, because I can't
find any device tree nodes with 'compatible = "st,stm32-gpio"' and an
'interrupts' property.

Remove the required 'interrupts' property from the binding. This fixes a
bunch of errors in
zephyrproject-rtos#17532.

Signed-off-by: Ulf Magnusson <Ulf.Magnusson@nordicsemi.no>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area: Devicetree bug The issue is a bug, or the PR is fixing a bug
Projects
None yet
Development

No branches or pull requests

2 participants