mirror of
https://github.com/zephyrproject-rtos/zephyr
synced 2025-08-04 08:24:23 +00:00
Most of the logic for initializing 'clocks' and 'pwms' is the same and can be shared. Add an EDT._simple_phandle_val_list() helper function for initializing 'clocks', 'pwms', and any other properties on the form <foo>s = <phandle value phandle value ...> where the nodes pointed at by the phandles are expected to have a '#<foo>-cells' property. This should make it easier to add similar properties. There's still some code duplication in the classes (PWM, Clock, etc.), but also some differences, so I'm wondering if requiring a class for each might be okay. Maybe some more class-related stuff could be factored out later. Piggyback some related cleanup: - Have _phandle_val_list() take the name of the #foo-cells property instead of a function for fetching the value. The pattern is always the same. - Have _add_names() just take the "foo" part of "foo-names". Same pattern everywhere. - Clean up some redundant comments for stuff that's already documented in docstrings - Fix error messages printed by _named_cells() ("GPIOS controller" -> "GPIO controller", etc.) Signed-off-by: Ulf Magnusson <Ulf.Magnusson@nordicsemi.no> |
||
---|---|---|
.. | ||
extract | ||
test-bindings | ||
test-bindings-2 | ||
devicetree.py | ||
dtlib.py | ||
edtlib.py | ||
extract_dts_includes.py | ||
gen_defines.py | ||
test-multidir.dts | ||
test.dts | ||
testdtlib.py | ||
testedtlib.py |