zephyr/scripts/dts
Ulf Magnusson eef8d19a27 dts: edtlib: Add simple generic support for pinctrl-<index> properties
(pinctrl-<index> is documented in
Documentation/devicetree/bindings/pinctrl/pinctrl-bindings.txt in
Linux.)

Add a new Node.pin_states property, derived from any pinctrl-<index>
properties on the node. Node.pin_states holds a list of PinState
objects, where each PinState represents a single pinctrl-<index>
property.

For example, Node.pin_states will have two elements for the 'device'
node below:

	device {
		pinctrl-0 = <&state_0>;
		pinctrl-1 = <&state_1 &state_2>;
		pinctrl-names = "default", "sleep";
	};
	pincontroller {
		state_0: state_0 {
			...
		};
		state_1: state_1 {
			...
		};
		state_2: state_2 {
			...
		};
	};

Each PinState holds the list of configurations nodes in
PinState.conf_nodes. For the node above, node.pin_states[1].conf_nodes
will contain the pincontroller/state_1 and pincontroller/state_2 nodes,
for example.

The new functionality isn't used by gen_defines.py yet, so this change
is a no-op in itself, except it adds some error checking for
pinctrl-<index> properties.

If needed, support for #pinctrl-cells and 'pinmux' (not the same thing
as the 'pinmux' properties in Zephyr I think) could be added separately
later. Not sure what belongs in edtlib.py there yet.

Signed-off-by: Ulf Magnusson <Ulf.Magnusson@nordicsemi.no>
2019-11-06 21:39:13 +01:00
..
extract scripts: dts: Generalize '#cells' to allow multiple sources 2019-10-02 11:49:58 -07:00
test-bindings scripts: dts: Generalize '#cells' to allow multiple sources 2019-10-02 11:49:58 -07:00
test-bindings-2 scripts: dts: Simplify and improve 'compatible' matching 2019-09-07 10:25:02 -05:00
devicetree.py scripts: dts: devicetree.py: Fix pylint warning for iffy \w escape 2019-09-07 10:25:02 -05:00
dtlib.py scripts: edtlib: Call nodes "nodes" instead of "devices" 2019-09-26 05:23:28 -07:00
edtlib.py dts: edtlib: Add simple generic support for pinctrl-<index> properties 2019-11-06 21:39:13 +01:00
extract_dts_includes.py scripts: edtlib/extract_dts_includes.py: Speed up 2x+ with yaml.CLoader 2019-10-30 07:52:27 +01:00
gen_defines.py scripts: dts: Fix generation of -name properties. 2019-11-06 10:34:37 +01:00
grutils.py scripts: dts: add dependency information to edtlib 2019-11-05 17:03:23 +01:00
test-multidir.dts scripts: dts: Add test for multiple binding directories 2019-08-03 14:17:49 -04:00
test.dts dts: edtlib: Add simple generic support for pinctrl-<index> properties 2019-11-06 21:39:13 +01:00
testdtlib.py scripts: edtlib: Add a Device.children attribute with child Devices 2019-09-21 09:10:36 -05:00
testedtlib.py dts: edtlib: Add simple generic support for pinctrl-<index> properties 2019-11-06 21:39:13 +01:00