Browse Source

dts: atmel: sam0: Explicity disable nodes

When running tests on sam0 platform was detected that pinctrl for ADC
were not defined for some boards. To force an error at build time
nodes should be explicity disabled. This explicity disable nodes on
devicetree that require some user configuration.

In addition, the adc feature were excluded in some boards and
samr21-xpro was correct updated.

Signed-off-by: Gerson Fernando Budke <nandojve@gmail.com>
pull/83137/head
Gerson Fernando Budke 7 months ago committed by Benjamin Cabé
parent
commit
162f728787
  1. 4
      boards/atmel/sam0/samd20_xpro/samd20_xpro.yaml
  2. 2
      boards/atmel/sam0/samd21_xpro/samd21_xpro.yaml
  3. 8
      boards/atmel/sam0/samr21_xpro/samr21_xpro-pinctrl.dtsi
  4. 6
      boards/atmel/sam0/samr21_xpro/samr21_xpro.dts
  5. 3
      boards/atmel/sam0/samr21_xpro/samr21_xpro.yaml
  6. 4
      dts/arm/atmel/samc2x.dtsi
  7. 3
      dts/arm/atmel/samd20.dtsi
  8. 5
      dts/arm/atmel/samd21.dtsi
  9. 1
      dts/arm/atmel/samd2x.dtsi
  10. 12
      dts/arm/atmel/samd5x.dtsi
  11. 4
      dts/arm/atmel/saml21.dtsi
  12. 3
      dts/arm/atmel/saml2x.dtsi
  13. 3
      dts/arm/atmel/samr21.dtsi

4
boards/atmel/sam0/samd20_xpro/samd20_xpro.yaml

@ -1,3 +1,6 @@ @@ -1,3 +1,6 @@
# Copyright (c) 2024 Gerson Fernando Budke <nandojve@gmail.com>
# SPDX-License-Identifier: Apache-2.0
identifier: samd20_xpro
name: SAM D20 Xplained Pro
type: mcu
@ -9,7 +12,6 @@ toolchain: @@ -9,7 +12,6 @@ toolchain:
flash: 256
ram: 32
supported:
- adc
- flash
- gpio
- i2c

2
boards/atmel/sam0/samd21_xpro/samd21_xpro.yaml

@ -1,6 +1,7 @@ @@ -1,6 +1,7 @@
# Copyright (c) 2018 Bryan O'Donoghue
# Copyright (c) 2024 Gerson Fernando Budke <nandojve@gmail.com>
# SPDX-License-Identifier: Apache-2.0
identifier: samd21_xpro
name: SAM D21 Xplained Pro
type: mcu
@ -12,7 +13,6 @@ toolchain: @@ -12,7 +13,6 @@ toolchain:
flash: 256
ram: 32
supported:
- adc
- counter
- dma
- gpio

8
boards/atmel/sam0/samr21_xpro/samr21_xpro-pinctrl.dtsi

@ -1,11 +1,17 @@ @@ -1,11 +1,17 @@
/*
* Copyright (c) 2022, Gerson Fernando Budke <nandojve@gmail.com>
* Copyright (c) 2022-2024, Gerson Fernando Budke <nandojve@gmail.com>
* SPDX-License-Identifier: Apache-2.0
*/
#include <dt-bindings/pinctrl/samr21g-pinctrl.h>
&pinctrl {
adc_default: adc_default {
group1 {
pinmux = <PA6B_ADC_AIN6>;
};
};
pwm_default: pwm_default {
group1 {
pinmux = <PA19F_TCC0_WO3>;

6
boards/atmel/sam0/samr21_xpro/samr21_xpro.dts

@ -106,6 +106,12 @@ @@ -106,6 +106,12 @@
clock-frequency = <48000000>;
};
&adc {
status = "okay";
pinctrl-0 = <&adc_default>;
pinctrl-names = "default";
};
&tcc0 {
status = "okay";
compatible = "atmel,sam0-tcc-pwm";

3
boards/atmel/sam0/samr21_xpro/samr21_xpro.yaml

@ -1,6 +1,7 @@ @@ -1,6 +1,7 @@
# Copyright (c) 2019 Benjamin Valentin
# Copyright (c) 2019-2024 Gerson Fernando Budke
# Copyright (c) 2019-2024 Gerson Fernando Budke <nandojve@gmail.com>
# SPDX-License-Identifier: Apache-2.0
identifier: samr21_xpro
name: SAM R21 Xplained Pro
type: mcu

4
dts/arm/atmel/samc2x.dtsi

@ -112,6 +112,7 @@ @@ -112,6 +112,7 @@
compatible = "atmel,sam0-dmac";
reg = <0x41006000 0x50>;
interrupts = <7 0>;
status = "disabled";
#dma-cells = <2>;
};
@ -173,6 +174,7 @@ @@ -173,6 +174,7 @@
interrupts = <17 0>;
clocks = <&gclk 28>, <&mclk 0x1c 9>;
clock-names = "GCLK", "MCLK";
status = "disabled";
channels = <4>;
counter-size = <24>;
@ -184,6 +186,7 @@ @@ -184,6 +186,7 @@
interrupts = <18 0>;
clocks = <&gclk 28>, <&mclk 0x1c 10>;
clock-names = "GCLK", "MCLK";
status = "disabled";
channels = <4>;
counter-size = <24>;
@ -195,6 +198,7 @@ @@ -195,6 +198,7 @@
interrupts = <19 0>;
clocks = <&gclk 29>, <&mclk 0x1c 11>;
clock-names = "GCLK", "MCLK";
status = "disabled";
channels = <2>;
counter-size = <16>;

3
dts/arm/atmel/samd20.dtsi

@ -20,6 +20,7 @@ @@ -20,6 +20,7 @@
interrupts = <13 0>;
clocks = <&gclk 0x13>, <&pm 0x20 8>;
clock-names = "GCLK", "PM";
status = "disabled";
};
tc2: tc@42002800 {
@ -28,6 +29,7 @@ @@ -28,6 +29,7 @@
interrupts = <15 0>;
clocks = <&gclk 0x14>, <&pm 0x20 10>;
clock-names = "GCLK", "PM";
status = "disabled";
};
tc6: tc@42003800 {
@ -36,6 +38,7 @@ @@ -36,6 +38,7 @@
interrupts = <19 0>;
clocks = <&gclk 0x16>, <&pm 0x20 14>;
clock-names = "GCLK", "PM";
status = "disabled";
};
};
};

5
dts/arm/atmel/samd21.dtsi

@ -25,6 +25,7 @@ @@ -25,6 +25,7 @@
compatible = "atmel,sam0-dmac";
reg = <0x41004800 0x50>;
interrupts = <6 0>;
status = "disabled";
#dma-cells = <2>;
};
@ -35,6 +36,7 @@ @@ -35,6 +36,7 @@
interrupts = <21 0>;
clocks = <&gclk 0x1d>, <&pm 0x20 14>;
clock-names = "GCLK", "PM";
status = "disabled";
};
tcc0: tcc@42002000 {
@ -43,6 +45,7 @@ @@ -43,6 +45,7 @@
interrupts = <15 0>;
clocks = <&gclk 26>, <&pm 0x20 8>;
clock-names = "GCLK", "PM";
status = "disabled";
channels = <4>;
counter-size = <24>;
@ -54,6 +57,7 @@ @@ -54,6 +57,7 @@
interrupts = <16 0>;
clocks = <&gclk 26>, <&pm 0x20 9>;
clock-names = "GCLK", "PM";
status = "disabled";
channels = <2>;
counter-size = <24>;
@ -65,6 +69,7 @@ @@ -65,6 +69,7 @@
interrupts = <17 0>;
clocks = <&gclk 27>, <&pm 0x20 10>;
clock-names = "GCLK", "PM";
status = "disabled";
channels = <2>;
counter-size = <16>;

1
dts/arm/atmel/samd2x.dtsi

@ -196,6 +196,7 @@ @@ -196,6 +196,7 @@
adc: adc@42004000 {
compatible = "atmel,sam0-adc";
reg = <0x42004000 0x2B>;
status = "disabled";
#io-channel-cells = <1>;

12
dts/arm/atmel/samd5x.dtsi

@ -125,6 +125,7 @@ @@ -125,6 +125,7 @@
compatible = "atmel,sam0-dmac";
reg = <0x4100A000 0x50>;
interrupts = <31 0>, <32 0>, <33 0>, <34 0>, <35 0>;
status = "disabled";
#dma-cells = <2>;
};
@ -315,6 +316,7 @@ @@ -315,6 +316,7 @@
interrupt-names = "overrun", "resrdy";
clocks = <&gclk 40>, <&mclk 0x20 7>;
clock-names = "GCLK", "MCLK";
status = "disabled";
#io-channel-cells = <1>;
@ -336,6 +338,7 @@ @@ -336,6 +338,7 @@
interrupt-names = "overrun", "resrdy";
clocks = <&gclk 41>, <&mclk 0x20 8>;
clock-names = "GCLK", "MCLK";
status = "disabled";
#io-channel-cells = <1>;
@ -356,6 +359,7 @@ @@ -356,6 +359,7 @@
interrupts = <107 0>;
clocks = <&gclk 9>, <&mclk 0x14 14>;
clock-names = "GCLK", "MCLK";
status = "disabled";
};
tc2: tc@4101a000 {
@ -364,6 +368,7 @@ @@ -364,6 +368,7 @@
interrupts = <109 0>;
clocks = <&gclk 26>, <&mclk 0x18 13>;
clock-names = "GCLK", "MCLK";
status = "disabled";
};
tc4: tc@42001400 {
@ -372,6 +377,7 @@ @@ -372,6 +377,7 @@
interrupts = <111 0>;
clocks = <&gclk 30>, <&mclk 0x1c 5>;
clock-names = "GCLK", "MCLK";
status = "disabled";
};
tc6: tc@43001400 {
@ -380,6 +386,7 @@ @@ -380,6 +386,7 @@
interrupts = <113 0>;
clocks = <&gclk 39>, <&mclk 0x20 5>;
clock-names = "GCLK", "MCLK";
status = "disabled";
};
tcc0: tcc@41016000 {
@ -389,6 +396,7 @@ @@ -389,6 +396,7 @@
<90 0>, <91 0>;
clocks = <&gclk 25>, <&mclk 0x18 11>;
clock-names = "GCLK", "MCLK";
status = "disabled";
channels = <6>;
counter-size = <24>;
@ -400,6 +408,7 @@ @@ -400,6 +408,7 @@
interrupts = <92 0>, <93 0>, <94 0>, <95 0>, <96 0>;
clocks = <&gclk 25>, <&mclk 0x18 12>;
clock-names = "GCLK", "MCLK";
status = "disabled";
channels = <4>;
counter-size = <24>;
@ -411,6 +420,7 @@ @@ -411,6 +420,7 @@
interrupts = <97 0>, <98 0>, <99 0>, <100 0>;
clocks = <&gclk 29>, <&mclk 0x1c 3>;
clock-names = "GCLK", "MCLK";
status = "disabled";
channels = <3>;
counter-size = <16>;
@ -422,6 +432,7 @@ @@ -422,6 +432,7 @@
interrupts = <101 0>, <102 0>, <103 0>;
clocks = <&gclk 29>, <&mclk 0x1c 4>;
clock-names = "GCLK", "MCLK";
status = "disabled";
channels = <2>;
counter-size = <16>;
@ -433,6 +444,7 @@ @@ -433,6 +444,7 @@
interrupts = <104 0>, <105 0>, <106 0>;
clocks = <&gclk 38>, <&mclk 0x20 4>;
clock-names = "GCLK", "MCLK";
status = "disabled";
channels = <2>;
counter-size = <16>;

4
dts/arm/atmel/saml21.dtsi

@ -21,6 +21,7 @@ @@ -21,6 +21,7 @@
compatible = "atmel,sam0-dmac";
reg = <0x44000400 0x50>;
interrupts = <5 0>;
status = "disabled";
#dma-cells = <2>;
};
@ -31,6 +32,7 @@ @@ -31,6 +32,7 @@
interrupts = <14 0>;
clocks = <&gclk 25>, <&mclk 0x1c 5>;
clock-names = "GCLK", "MCLK";
status = "disabled";
channels = <4>;
counter-size = <24>;
@ -42,6 +44,7 @@ @@ -42,6 +44,7 @@
interrupts = <15 0>;
clocks = <&gclk 25>, <&mclk 0x1c 6>;
clock-names = "GCLK", "MCLK";
status = "disabled";
channels = <4>;
counter-size = <24>;
@ -53,6 +56,7 @@ @@ -53,6 +56,7 @@
interrupts = <16 0>;
clocks = <&gclk 26>, <&mclk 0x1c 7>;
clock-names = "GCLK", "MCLK";
status = "disabled";
channels = <2>;
counter-size = <16>;

3
dts/arm/atmel/saml2x.dtsi

@ -91,6 +91,7 @@ @@ -91,6 +91,7 @@
compatible = "atmel,sam0-dmac";
reg = <0x44000400 0x400>;
interrupts = <5 0>;
status = "disabled";
#dma-cells = <2>;
};
@ -146,6 +147,7 @@ @@ -146,6 +147,7 @@
tc4: tc@43000800 {
compatible = "atmel,sam0-tc32";
reg = <0x43000800 0x34>;
status = "disabled";
};
pinctrl: pinctrl@40002800 {
@ -188,6 +190,7 @@ @@ -188,6 +190,7 @@
adc: adc@43000c00 {
compatible = "atmel,sam0-adc";
reg = <0x43000c00 0x30>;
status = "disabled";
#io-channel-cells = <1>;

3
dts/arm/atmel/samr21.dtsi

@ -54,6 +54,7 @@ @@ -54,6 +54,7 @@
interrupts = <15 0>;
clocks = <&gclk 26>, <&pm 0x20 8>;
clock-names = "GCLK", "PM";
status = "disabled";
channels = <4>;
counter-size = <24>;
@ -65,6 +66,7 @@ @@ -65,6 +66,7 @@
interrupts = <16 0>;
clocks = <&gclk 26>, <&pm 0x20 9>;
clock-names = "GCLK", "PM";
status = "disabled";
channels = <2>;
counter-size = <24>;
@ -76,6 +78,7 @@ @@ -76,6 +78,7 @@
interrupts = <17 0>;
clocks = <&gclk 27>, <&pm 0x20 10>;
clock-names = "GCLK", "PM";
status = "disabled";
channels = <2>;
counter-size = <16>;

Loading…
Cancel
Save