add device tree based initialization to wl12xx
[openwrt/openwrt.git] / target / linux / omap / patches-3.12 / 908-Documentation-dt-bindings-TI-WiLink-modules.patch
1 From patchwork Tue Jul 30 20:21:08 2013
2 Content-Type: text/plain; charset="utf-8"
3 MIME-Version: 1.0
4 Content-Transfer-Encoding: 7bit
5 Subject: [v3] Documentation: dt: bindings: TI WiLink modules
6 From: Luciano Coelho <coelho@ti.com>
7 X-Patchwork-Id: 2835914
8 Message-Id: <1375215668-29171-1-git-send-email-coelho@ti.com>
9 To: <devicetree@vger.kernel.org>, <linux-doc@vger.kernel.org>
10 Cc: <mturquette@linaro.org>, <mark.rutland@arm.com>, <balbi@ti.com>,
11 <grant.likely@linaro.org>, <rob.herring@calxeda.com>,
12 <linux-kernel@vger.kernel.org>, <linux-omap@vger.kernel.org>,
13 <linux-wireless@vger.kernel.org>,
14 <linux-arm-kernel@lists.infradead.org>, <tony@atomide.com>,
15 <nm@ti.com>, <laurent.pinchart@ideasonboard.com>
16 Date: Tue, 30 Jul 2013 23:21:08 +0300
17
18 Add device tree bindings documentation for the TI WiLink modules.
19 Currently only the WLAN part of the WiLink6, WiLink7 and WiLink8
20 modules is supported.
21
22 Signed-off-by: Luciano Coelho <coelho@ti.com>
23 Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
24
25 ---
26 In v3, use IRQ_TYPE_LEVEL_HIGH in the example, as suggested by Laurent.
27
28 .../devicetree/bindings/net/wireless/ti-wilink.txt | 68 ++++++++++++++++++++++
29 1 file changed, 68 insertions(+)
30 create mode 100644 Documentation/devicetree/bindings/net/wireless/ti-wilink.txt
31
32 --- /dev/null
33 +++ b/Documentation/devicetree/bindings/net/wireless/ti-wilink.txt
34 @@ -0,0 +1,68 @@
35 +TI WiLink Wireless Modules Device Tree Bindings
36 +===============================================
37 +
38 +The WiLink modules provide wireless connectivity, such as WLAN,
39 +Bluetooth, FM and NFC.
40 +
41 +There are several different modules available, which can be grouped by
42 +their generation: WiLink6, WiLink7 and WiLink8. WiLink4 is not
43 +currently supported with device tree.
44 +
45 +Currently, only the WLAN portion of the modules is supported with
46 +device tree.
47 +
48 +Required properties:
49 +--------------------
50 +
51 +- compatible: should be "ti,wilink6", "ti,wilink7" or "ti,wilink8"
52 +- interrupt-parent: the interrupt controller
53 +- interrupts: out-of-band WLAN interrupt
54 + See the interrupt controller's bindings documentation for
55 + detailed definition.
56 +
57 +Optional properties:
58 +--------------------
59 +
60 +- clocks: list of clocks needed by the chip as follows:
61 +
62 + refclock: the internal WLAN reference clock frequency (required for
63 + WiLink6 and WiLink7; not used for WiLink8).
64 +
65 + tcxoclock: the internal WLAN TCXO clock frequency (required for
66 + WiLink7 not used for WiLink6 and WiLink8).
67 +
68 + The clocks must be defined and named accordingly. For example:
69 +
70 + clocks = <&refclock>
71 + clock-names = "refclock";
72 +
73 + refclock: refclock {
74 + compatible = "ti,wilink-clock";
75 + #clock-cells = <0>;
76 + clock-frequency = <38400000>;
77 + };
78 +
79 + Some modules that contain the WiLink chip provide clocks in the
80 + module itself. In this case, we define a "ti,wilink-clock" as shown
81 + above. But any other clock could in theory be used, so the proper
82 + clock definition should be used.
83 +
84 +
85 +Example:
86 +--------
87 +
88 +Example definition that can be used in OMAP4 Panda:
89 +
90 +wlan {
91 + compatible = "ti,wilink6";
92 + interrupt-parent = <&gpio2>;
93 + interrupts = <21 IRQ_TYPE_LEVEL_HIGH>; /* gpio line 53 */
94 + clocks = <&refclock>;
95 + clock-names = "refclock";
96 +
97 + refclock: refclock {
98 + compatible = "ti,wilink-clock";
99 + #clock-cells = <0>;
100 + clock-frequency = <38400000>;
101 + };
102 +};