From 408f181e0d4210ef7c77e825289d31fac530291c Mon Sep 17 00:00:00 2001 From: Barry Song Date: Fri, 14 Dec 2012 15:24:01 +0800 Subject: pinctrl: sirf: add missing DT-binding document While sending email to Linus for reviewing: "pinctrl: sirf: add DT-binding pinmux mapping support" https://patchwork.kernel.org/patch/1364361/ i have included the devicetree/bindings/pinctrl/pinctrl-sirf.txt But while sending pull request with commit 056876f6c73406c, i missed the document. this patch takes the document back. Signed-off-by: Barry Song Signed-off-by: Linus Walleij --- .../devicetree/bindings/pinctrl/pinctrl-sirf.txt | 44 ++++++++++++++++++++++ 1 file changed, 44 insertions(+) create mode 100644 Documentation/devicetree/bindings/pinctrl/pinctrl-sirf.txt (limited to 'Documentation') diff --git a/Documentation/devicetree/bindings/pinctrl/pinctrl-sirf.txt b/Documentation/devicetree/bindings/pinctrl/pinctrl-sirf.txt new file mode 100644 index 000000000000..a2896df702ad --- /dev/null +++ b/Documentation/devicetree/bindings/pinctrl/pinctrl-sirf.txt @@ -0,0 +1,44 @@ +CSR SiRFprimaII pinmux controller + +Required properties: +- compatible : "sirf,prima2-pinctrl" +- reg : Address range of the pinctrl registers +- interrupts : Interrupts used by every GPIO group +- gpio-controller : Indicates this device is a GPIO controller +- interrupt-controller : Marks the device node as an interrupt controller + +Please refer to pinctrl-bindings.txt in this directory for details of the common +pinctrl bindings used by client devices. + +SiRFprimaII's pinmux nodes act as a container for an abitrary number of subnodes. +Each of these subnodes represents some desired configuration for a group of pins. + +Required subnode-properties: +- sirf,pins : An array of strings. Each string contains the name of a group. +- sirf,function: A string containing the name of the function to mux to the + group. + + Valid values for group and function names can be found from looking at the + group and function arrays in driver files: + drivers/pinctrl/pinctrl-sirf.c + +For example, pinctrl might have subnodes like the following: + uart2_pins_a: uart2@0 { + uart { + sirf,pins = "uart2grp"; + sirf,function = "uart2"; + }; + }; + uart2_noflow_pins_a: uart2@1 { + uart { + sirf,pins = "uart2_nostreamctrlgrp"; + sirf,function = "uart2_nostreamctrl"; + }; + }; + +For a specific board, if it wants to use uart2 without hardware flow control, +it can add the following to its board-specific .dts file. +uart2: uart@0xb0070000 { + pinctrl-names = "default"; + pinctrl-0 = <&uart2_noflow_pins_a>; +} -- cgit v1.2.3 From fc2b04e7fbd119f4bf41b6821d2f8ce4bf9ae417 Mon Sep 17 00:00:00 2001 From: Barry Song Date: Fri, 14 Dec 2012 17:15:59 +0800 Subject: pinctrl: sirf: enable GPIO pullup/down configuration from dts commit 7bec207427c2efb794 remove sirfsoc_gpio_set_pull function, this patches takes the feature back by adding sirf,pullups and sirf,pulldowns prop in dts, and the driver will set the GPIO pull according to the dts. Cc: Arnd Bergmann Signed-off-by: Barry Song Signed-off-by: Linus Walleij --- Documentation/devicetree/bindings/pinctrl/pinctrl-sirf.txt | 3 +++ 1 file changed, 3 insertions(+) (limited to 'Documentation') diff --git a/Documentation/devicetree/bindings/pinctrl/pinctrl-sirf.txt b/Documentation/devicetree/bindings/pinctrl/pinctrl-sirf.txt index a2896df702ad..c596a6ad3285 100644 --- a/Documentation/devicetree/bindings/pinctrl/pinctrl-sirf.txt +++ b/Documentation/devicetree/bindings/pinctrl/pinctrl-sirf.txt @@ -6,6 +6,9 @@ Required properties: - interrupts : Interrupts used by every GPIO group - gpio-controller : Indicates this device is a GPIO controller - interrupt-controller : Marks the device node as an interrupt controller +Optional properties: +- sirf,pullups : if n-th bit of m-th bank is set, set a pullup on GPIO-n of bank m +- sirf,pulldowns : if n-th bit of m-th bank is set, set a pulldown on GPIO-n of bank m Please refer to pinctrl-bindings.txt in this directory for details of the common pinctrl bindings used by client devices. -- cgit v1.2.3