Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

devicetree: bindings: gpio-davinic: fix documentation

This patch adds missing #gpio-cells and also adds a
usage example for leds.

Reported-by: Alexander Holler <holler@ahsoftware.de>
Signed-off-by: Lad, Prabhakar <prabhakar.csengg@gmail.com>
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>

authored by

Lad, Prabhakar and committed by
Linus Walleij
49e1f91c 758afe42

+21
+21
Documentation/devicetree/bindings/gpio/gpio-davinci.txt
··· 8 8 9 9 - gpio-controller : Marks the device node as a gpio controller. 10 10 11 + - #gpio-cells : Should be two. 12 + - first cell is the pin number 13 + - second cell is used to specify optional parameters (unused) 14 + 11 15 - interrupt-parent: phandle of the parent interrupt controller. 12 16 13 17 - interrupts: Array of GPIO interrupt number. Only banked or unbanked IRQs are ··· 31 27 gpio: gpio@1e26000 { 32 28 compatible = "ti,dm6441-gpio"; 33 29 gpio-controller; 30 + #gpio-cells = <2>; 34 31 reg = <0x226000 0x1000>; 35 32 interrupt-parent = <&intc>; 36 33 interrupts = <42 IRQ_TYPE_EDGE_BOTH 43 IRQ_TYPE_EDGE_BOTH ··· 43 38 ti,davinci-gpio-unbanked = <0>; 44 39 interrupt-controller; 45 40 #interrupt-cells = <2>; 41 + }; 42 + 43 + leds { 44 + compatible = "gpio-leds"; 45 + 46 + led1 { 47 + label = "davinci:green:usr1"; 48 + gpios = <&gpio 10 GPIO_ACTIVE_HIGH>; 49 + ... 50 + }; 51 + 52 + led2 { 53 + label = "davinci:red:debug1"; 54 + gpios = <&gpio 11 GPIO_ACTIVE_HIGH>; 55 + ... 56 + }; 46 57 };