Skip to contentSkip to conversation

dt-bindings: arm: at91: Document Kizboxmini and Smartkiz boards binding

PATCH Superseded Kamel Bouhara 2 participants 4 messages Nov 6, 2019 – Nov 13, 2019

Subsystems (3)

v3 of 6 Superseded Latest is v6 →

lore
Share & tools
lore
#0 lore raw

PATCH v3 1/2 dt-bindings: arm: at91: Document Kizboxmini and Smartkiz boards binding

Document devicetree's bindings for the Overkiz's Kizbox Mini and Smartkiz boards, based on a SAM9G25 Atmel SoC.

---
Changes in v2
=============
- Added Kizboxmini Base board documentation
- Merged Smartkiz documentation as it is also a sam9g25 based board

Changes in v3
=============
- Made a single items list with all the sam9g25 based boards and put description into a comment.
- Fixed duplicated item in enum list and checked with 'make dt_binding_check'

---
 Documentation/devicetree/bindings/arm/atmel-at91.yaml | 10 ++++++++++
 1 file changed, 10 insertions(+)
Documentation/devicetree/bindings/arm/atmel-at91.yaml +10 -0
index 6dd8be401673..e4140e94864d 100644
@@ -35,6 +35,16 @@ properties:
               - atmel,at91sam9x60
           - const: atmel,at91sam9
 
+        items:
+          - enum:
+                - overkiz,kizboxmini-base # Overkiz kizbox Mini Base Board
+                - overkiz,kizboxmini-mb   # Overkiz kizbox Mini Mother Board
+                - overkiz,kizboxmini-rd   # Overkiz kizbox Mini RailDIN
+                - overkiz,smartkiz        # Overkiz SmartKiz Board
+          - const: atmel,at91sam9g25
+          - const: atmel,at91sam9x5
+          - const: atmel,at91sam9
+
       - items:
           - enum:
               - atmel,at91sam9g15

--
2.24.0.rc1

#1 lore raw

PATCH v3 2/2 ARM: dts: at91: add smartkiz support and a common kizboxmini dtsi file

Split the existing Kizbox Mini boards into three board configuration, the base board, the mother board and the RailDIN board. Add a new dts file for the SmartKiz board support.

---
 arch/arm/boot/dts/Makefile                    |   5 +-
 arch/arm/boot/dts/at91-kizboxmini-base.dts    |  24 +++
 ...oxmini.dts => at91-kizboxmini-common.dtsi} | 163 +++++++++---------
 arch/arm/boot/dts/at91-kizboxmini-mb.dts      |  26 +++
 arch/arm/boot/dts/at91-kizboxmini-rd.dts      |  49 ++++++
 arch/arm/boot/dts/at91-smartkiz.dts           | 109 ++++++++++++
 6 files changed, 293 insertions(+), 83 deletions(-)
 create mode 100644 arch/arm/boot/dts/at91-kizboxmini-base.dts
 rename arch/arm/boot/dts/{at91-kizboxmini.dts => at91-kizboxmini-common.dtsi} (51%)
 create mode 100644 arch/arm/boot/dts/at91-kizboxmini-mb.dts
 create mode 100644 arch/arm/boot/dts/at91-kizboxmini-rd.dts
 create mode 100644 arch/arm/boot/dts/at91-smartkiz.dts
arch/arm/boot/dts/Makefile +4 -1
index 4ac053115a8e..83865d3072b5 100644
@@ -37,7 +37,10 @@ dtb-$(CONFIG_SOC_AT91SAM9) += \
 	at91-ariag25.dtb \
 	at91-ariettag25.dtb \
 	at91-cosino_mega2560.dtb \
-	at91-kizboxmini.dtb \
+	at91-kizboxmini-base.dtb \
+	at91-kizboxmini-mb.dtb \
+	at91-kizboxmini-rd.dtb \
+	at91-smartkiz.dtb \
 	at91-wb45n.dtb \
 	at91sam9g15ek.dtb \
 	at91sam9g25ek.dtb \
arch/arm/boot/dts/at91-kizboxmini-base.dts new file +24 -0
new file mode 100644
index 000000000000..81c29ca5cc1b
@@ -0,0 +1,24 @@
+// SPDX-License-Identifier: GPL-2.0-or-later
+/*
+ * at91-kizboxmini-base.dts - Device Tree file for Overkiz Kizbox mini
+ * base board
+ *
+ * Copyright (C) 2015 Overkiz SAS
+ *   Author: Antoine Aubert <[email protected]>
+ *           Kévin Raymond <[email protected]>
+ */
+/dts-v1/;
+#include "at91-kizboxmini-common.dtsi"
+
+/ {
+	model = "Overkiz Kizbox Mini";
+	compatible = "overkiz,kizboxmini-base", "atmel,at91sam9g25",
+		     "atmel,at91sam9x5", "atmel,at91sam9";
+};
+
+&pinctrl_usart0 {
+	atmel,pins =
+		<AT91_PIOA 0 AT91_PERIPH_A AT91_PINCTRL_PULL_UP
+		 AT91_PIOA 1 AT91_PERIPH_A AT91_PINCTRL_NONE
+		 AT91_PIOA 2 AT91_PERIPH_GPIO AT91_PINCTRL_MULTI_DRIVE>;
+};
arch/arm/boot/dts/at91-kizboxmini-common.dtsi renamed from arch/arm/boot/dts/at91-kizboxmini.dts +81 -82

224 lines not on this page · raw message

arch/arm/boot/dts/at91-kizboxmini-mb.dts new file +26 -0
new file mode 100644
index 000000000000..c07d3076a9bc
@@ -0,0 +1,26 @@
+// SPDX-License-Identifier: GPL-2.0
+/*
+ * Copyright (C) 2015-2018 Overkiz SAS
+ *   Author: Mickael Gardet <[email protected]>
+ *           Kévin Raymond <[email protected]>
+ */
+/dts-v1/;
+#include "at91-kizboxmini-common.dtsi"
+
+/ {
+	model = "Overkiz Kizbox Mini Mother Board";
+	compatible = "overkiz,kizboxmini-mb", "atmel,at91sam9g25",
+		     "atmel,at91sam9x5", "atmel,at91sam9";
+};
+
+&usb0 {
+	num-ports = <2>;
+};
+
+&rtc {
+	status = "okay";
+};
+
+&led_blue {
+	status = "okay";
+};
arch/arm/boot/dts/at91-kizboxmini-rd.dts new file +49 -0

49 lines not on this page · raw message

arch/arm/boot/dts/at91-smartkiz.dts new file +109 -0

109 lines not on this page · raw message

Signature · 1 line
2.24.0.rc1
maintainer
#2 lore raw
In reply to Kamel Bouhara
Quoted 11 lines · Kamel Bouhara

Document devicetree's bindings for the Overkiz's Kizbox Mini and Smartkiz boards, based on a SAM9G25 Atmel SoC.

---
Changes in v2
=============
- Added Kizboxmini Base board documentation
- Merged Smartkiz documentation as it is also a sam9g25 based board

Quoted 6 lines

Changes in v3
=============
- Made a single items list with all the sam9g25 based boards and put description into a comment.
- Fixed duplicated item in enum list and checked with 'make dt_binding_check'

Are you sure?

Documentation/devicetree/bindings/arm/atmel-at91.yaml properties: · line 38

Quoted 13 lines
---
 Documentation/devicetree/bindings/arm/atmel-at91.yaml | 10 ++++++++++
 1 file changed, 10 insertions(+)
Documentation/devicetree/bindings/arm/atmel-at91.yaml +1 -0
index 6dd8be401673..e4140e94864d 100644
@@ -35,6 +35,16 @@ properties:
               - atmel,at91sam9x60
           - const: atmel,at91sam9
 
+        items:

You are missing a '-' here, giving this:

Traceback (most recent call last):
File "/usr/local/bin/dt-mk-schema", line 32, in <module>
schemas = dtschema.process_schemas(args.schemas, core_schema=(not
args.useronly))
File "/usr/local/lib/python3.6/dist-packages/dtschema/lib.py", line
475, in process_schemas
sch = process_schema(os.path.abspath(filename))
File "/usr/local/lib/python3.6/dist-packages/dtschema/lib.py", line
427, in process_schema
schema = load_schema(filename)
File "/usr/local/lib/python3.6/dist-packages/dtschema/lib.py", line
103, in load_schema
return yaml.load(f.read())
File "/usr/local/lib/python3.6/dist-packages/ruamel/yaml/main.py",
line 341, in load
return constructor.get_single_data()
File
"/usr/local/lib/python3.6/dist-packages/ruamel/yaml/constructor.py", line 113, in get_single_data
return self.construct_document(node)
File
"/usr/local/lib/python3.6/dist-packages/ruamel/yaml/constructor.py", line 123, in construct_document
for _dummy in generator:
File
"/usr/local/lib/python3.6/dist-packages/ruamel/yaml/constructor.py", line 723, in construct_yaml_map
value = self.construct_mapping(node)
File
"/usr/local/lib/python3.6/dist-packages/ruamel/yaml/constructor.py", line 440, in construct_mapping
return BaseConstructor.construct_mapping(self, node, deep=deep)
File
"/usr/local/lib/python3.6/dist-packages/ruamel/yaml/constructor.py", line 257, in construct_mapping
if self.check_mapping_key(node, key_node, mapping, key, value):
File
"/usr/local/lib/python3.6/dist-packages/ruamel/yaml/constructor.py", line 295, in check_mapping_key
raise DuplicateKeyError(*args)
ruamel.yaml.constructor.DuplicateKeyError: while constructing a mapping
in "<unicode string>", line 23, column 9
found duplicate key "items" with value "[]" (original value: "[]")
in "<unicode string>", line 38, column 9

To suppress this check see:
http://yaml.readthedocs.io/en/latest/api.html#duplicate-keys

Duplicate keys will become an error in future releases, and are errors by default when using the new API.

Documentation/devicetree/bindings/Makefile:33: recipe for target 'Documentation/devicetree/bindings/processed-schema.yaml' failed

Quoted 15 lines
Documentation/devicetree/bindings/arm/atmel-at91.yaml +9 -1
+          - enum:
+                - overkiz,kizboxmini-base # Overkiz kizbox Mini Base Board
+                - overkiz,kizboxmini-mb   # Overkiz kizbox Mini Mother Board
+                - overkiz,kizboxmini-rd   # Overkiz kizbox Mini RailDIN
+                - overkiz,smartkiz        # Overkiz SmartKiz Board
+          - const: atmel,at91sam9g25
+          - const: atmel,at91sam9x5
+          - const: atmel,at91sam9
+
       - items:
           - enum:
               - atmel,at91sam9g15
--

2.24.0.rc1

#3 lore raw
Quoted 12 lines · Rob Herring
Quoted 11 lines · Kamel Bouhara

Document devicetree's bindings for the Overkiz's Kizbox Mini and Smartkiz boards, based on a SAM9G25 Atmel SoC.

---
Changes in v2
=============
- Added Kizboxmini Base board documentation
- Merged Smartkiz documentation as it is also a sam9g25 based board

Quoted 9 lines
Quoted 6 lines

Changes in v3
=============
- Made a single items list with all the sam9g25 based boards and put description into a comment.
- Fixed duplicated item in enum list and checked with 'make dt_binding_check'

Are you sure?

Yes, here is the command output I've got :

$ make ARCH=arm dt_binding_check \
DT_SCHEMA_FILES="Documentation/devicetree/bindings/arm/atmel-at91.yaml" \
DT_SCHEMA_FLAGS="-u"
 SCHEMA  Documentation/devicetree/bindings/processed-schema.yaml
 DTC     Documentation/devicetree/bindings/arm/atmel-at91.example.dt.yaml
 CHECK   Documentation/devicetree/bindings/arm/atmel-at91.example.dt.yaml
Quoted 12 lines
Quoted 12 lines
---
 Documentation/devicetree/bindings/arm/atmel-at91.yaml | 10 ++++++++++
 1 file changed, 10 insertions(+)
Documentation/devicetree/bindings/arm/atmel-at91.yaml +0 -0
index 6dd8be401673..e4140e94864d 100644
@@ -35,6 +35,16 @@ properties:
               - atmel,at91sam9x60
           - const: atmel,at91sam9
 
Quoted 4 lines

Documentation/devicetree/bindings/arm/atmel-at91.yaml properties: · line 38

Quoted 1 line
Documentation/devicetree/bindings/arm/atmel-at91.yaml +1 -0
+        items:

You are missing a '-' here, giving this:

Yes but the log you're putting seems more related to a python issue (2.6 vs 3) ?

Quoted 45 lines

Traceback (most recent call last):
File "/usr/local/bin/dt-mk-schema", line 32, in <module>
schemas = dtschema.process_schemas(args.schemas, core_schema=(not
args.useronly))
File "/usr/local/lib/python3.6/dist-packages/dtschema/lib.py", line
475, in process_schemas
sch = process_schema(os.path.abspath(filename))
File "/usr/local/lib/python3.6/dist-packages/dtschema/lib.py", line
427, in process_schema
schema = load_schema(filename)
File "/usr/local/lib/python3.6/dist-packages/dtschema/lib.py", line
103, in load_schema
return yaml.load(f.read())
File "/usr/local/lib/python3.6/dist-packages/ruamel/yaml/main.py",
line 341, in load
return constructor.get_single_data()
File
"/usr/local/lib/python3.6/dist-packages/ruamel/yaml/constructor.py", line 113, in get_single_data
return self.construct_document(node)
File
"/usr/local/lib/python3.6/dist-packages/ruamel/yaml/constructor.py", line 123, in construct_document
for _dummy in generator:
File
"/usr/local/lib/python3.6/dist-packages/ruamel/yaml/constructor.py", line 723, in construct_yaml_map
value = self.construct_mapping(node)
File
"/usr/local/lib/python3.6/dist-packages/ruamel/yaml/constructor.py", line 440, in construct_mapping
return BaseConstructor.construct_mapping(self, node, deep=deep)
File
"/usr/local/lib/python3.6/dist-packages/ruamel/yaml/constructor.py", line 257, in construct_mapping
if self.check_mapping_key(node, key_node, mapping, key, value):
File
"/usr/local/lib/python3.6/dist-packages/ruamel/yaml/constructor.py", line 295, in check_mapping_key
raise DuplicateKeyError(*args)
ruamel.yaml.constructor.DuplicateKeyError: while constructing a mapping
in "<unicode string>", line 23, column 9
found duplicate key "items" with value "[]" (original value: "[]")
in "<unicode string>", line 38, column 9

Quoted 25 lines

To suppress this check see:
http://yaml.readthedocs.io/en/latest/api.html#duplicate-keys

Duplicate keys will become an error in future releases, and are errors by default when using the new API.

Documentation/devicetree/bindings/Makefile:33: recipe for target 'Documentation/devicetree/bindings/processed-schema.yaml' failed

Quoted 15 lines
Documentation/devicetree/bindings/arm/atmel-at91.yaml +9 -1
+          - enum:
+                - overkiz,kizboxmini-base # Overkiz kizbox Mini Base Board
+                - overkiz,kizboxmini-mb   # Overkiz kizbox Mini Mother Board
+                - overkiz,kizboxmini-rd   # Overkiz kizbox Mini RailDIN
+                - overkiz,smartkiz        # Overkiz SmartKiz Board
+          - const: atmel,at91sam9g25
+          - const: atmel,at91sam9x5
+          - const: atmel,at91sam9
+
       - items:
           - enum:
               - atmel,at91sam9g15
--

2.24.0.rc1

--
Kamel Bouhara, Bootlin
Embedded Linux and kernel engineering
https://bootlin.com