Changes between Version 23 and Version 24 of linux/devicetree
- Timestamp:
- 09/16/2025 11:05:34 PM (7 weeks ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
linux/devicetree
v23 v24 164 164 165 165 Examples: 166 1. add a SPI NOR flash device on an off-board SPI connector. Such a device has a Linux kernel driver and requires using device-tree bindings:166 1. Add a SPI NOR flash device on an off-board SPI connector. Such a device has a Linux kernel driver and requires using device-tree bindings: 167 167 {{{ 168 168 /dts-v1/; … … 198 198 }}} 199 199 200 2. repurpose the I2C3 and SPI2 pins on a GW730x to GPIO's to be used in userspace via gpiod/sysfs:200 2. Repurpose the I2C3 and SPI2 pins on a GW730x to GPIO's to be used in userspace via gpiod/sysfs: 201 201 - the dts framgment here has C style includes required for the pinmux definitions and the gpio definitions so we use cpp to pre-process it before compiling 202 202 - the includes here are from the Linux kernel so you must have the linux kernel source to compile this, place the file in the proper directory per the includes (imx8mm-pinfunc.h is in arch/arm64/boot/dts/freescale so that is where we put the file in our example), and compile from the correct directory such that the includes can be found … … 312 312 }}} 313 313 314 3. repurpose the I2C3 and SPI2 pins on a GW730x to GPIO's (like above) but bind 4 of them to the gpio-keys driver to use as up/down/right/left buttons and bind 2 of them to the gpio-led driver to use as leds via /sys/class/led314 3. Repurpose the I2C3 and SPI2 pins on a GW730x to GPIO's (like above) but bind 4 of them to the gpio-keys driver to use as up/down/right/left buttons and bind 2 of them to the gpio-led driver to use as leds via /sys/class/led 315 315 - the dts framgment here has C style includes required for the pinmux definitions and the gpio definitions so we use cpp to pre-process it before compiling 316 316 - we use gpio-keys1 and led-controller1 node names so as not to collide with gpio-keys and led-controller nodes already defined in the gw73xx-0x device-tree … … 455 455 * A list of optional files specified by {{{fdt_overlays}}} will be loaded and applied as overlays and if defined {{{fixfdt}}} will be run as well. 456 456 457 457 ==== Venice GW7300 GPIO Example 458 459 An example of how to repurpose pins to get more GPIO pins on a Venice SBC, in this example the GW73xx. See the example in this section: [#DeviceTreeOverlaysakaFragments] 458 460 ==== Venice GW7100 Example 459 461
