xref: /freebsd/sys/contrib/device-tree/Bindings/pinctrl/actions,s700-pinctrl.txt (revision c66ec88fed842fbaad62c30d510644ceb7bd2d71)
1*c66ec88fSEmmanuel VadotActions Semi S700 Pin Controller
2*c66ec88fSEmmanuel Vadot
3*c66ec88fSEmmanuel VadotThis binding describes the pin controller found in the S700 SoC.
4*c66ec88fSEmmanuel Vadot
5*c66ec88fSEmmanuel VadotRequired Properties:
6*c66ec88fSEmmanuel Vadot
7*c66ec88fSEmmanuel Vadot- compatible:   Should be "actions,s700-pinctrl"
8*c66ec88fSEmmanuel Vadot- reg:          Should contain the register base address and size of
9*c66ec88fSEmmanuel Vadot		the pin controller.
10*c66ec88fSEmmanuel Vadot- clocks:       phandle of the clock feeding the pin controller
11*c66ec88fSEmmanuel Vadot- gpio-controller: Marks the device node as a GPIO controller.
12*c66ec88fSEmmanuel Vadot- gpio-ranges: Specifies the mapping between gpio controller and
13*c66ec88fSEmmanuel Vadot               pin-controller pins.
14*c66ec88fSEmmanuel Vadot- #gpio-cells: Should be two. The first cell is the gpio pin number
15*c66ec88fSEmmanuel Vadot		and the second cell is used for optional parameters.
16*c66ec88fSEmmanuel Vadot- interrupt-controller: Marks the device node as an interrupt controller.
17*c66ec88fSEmmanuel Vadot- #interrupt-cells: Specifies the number of cells needed to encode an
18*c66ec88fSEmmanuel Vadot		interrupt.  Shall be set to 2.  The first cell
19*c66ec88fSEmmanuel Vadot		defines the interrupt number, the second encodes
20*c66ec88fSEmmanuel Vadot		the trigger flags described in
21*c66ec88fSEmmanuel Vadot		bindings/interrupt-controller/interrupts.txt
22*c66ec88fSEmmanuel Vadot- interrupts: The interrupt outputs from the controller. There is one GPIO
23*c66ec88fSEmmanuel Vadot              interrupt per GPIO bank. The number of interrupts listed depends
24*c66ec88fSEmmanuel Vadot              on the number of GPIO banks on the SoC. The interrupts must be
25*c66ec88fSEmmanuel Vadot              ordered by bank, starting with bank 0.
26*c66ec88fSEmmanuel Vadot
27*c66ec88fSEmmanuel VadotPlease refer to pinctrl-bindings.txt in this directory for details of the
28*c66ec88fSEmmanuel Vadotcommon pinctrl bindings used by client devices, including the meaning of the
29*c66ec88fSEmmanuel Vadotphrase "pin configuration node".
30*c66ec88fSEmmanuel Vadot
31*c66ec88fSEmmanuel VadotThe pin configuration nodes act as a container for an arbitrary number of
32*c66ec88fSEmmanuel Vadotsubnodes. Each of these subnodes represents some desired configuration for a
33*c66ec88fSEmmanuel Vadotpin, a group, or a list of pins or groups. This configuration can include the
34*c66ec88fSEmmanuel Vadotmux function to select on those group(s), and various pin configuration
35*c66ec88fSEmmanuel Vadotparameters, such as pull-up, drive strength, etc.
36*c66ec88fSEmmanuel Vadot
37*c66ec88fSEmmanuel VadotPIN CONFIGURATION NODES:
38*c66ec88fSEmmanuel Vadot
39*c66ec88fSEmmanuel VadotThe name of each subnode is not important; all subnodes should be enumerated
40*c66ec88fSEmmanuel Vadotand processed purely based on their content.
41*c66ec88fSEmmanuel Vadot
42*c66ec88fSEmmanuel VadotEach subnode only affects those parameters that are explicitly listed. In
43*c66ec88fSEmmanuel Vadotother words, a subnode that lists a mux function but no pin configuration
44*c66ec88fSEmmanuel Vadotparameters implies no information about any pin configuration parameters.
45*c66ec88fSEmmanuel VadotSimilarly, a pin subnode that describes a pullup parameter implies no
46*c66ec88fSEmmanuel Vadotinformation about e.g. the mux function.
47*c66ec88fSEmmanuel Vadot
48*c66ec88fSEmmanuel VadotPinmux functions are available only for the pin groups while pinconf
49*c66ec88fSEmmanuel Vadotparameters are available for both pin groups and individual pins.
50*c66ec88fSEmmanuel Vadot
51*c66ec88fSEmmanuel VadotThe following generic properties as defined in pinctrl-bindings.txt are valid
52*c66ec88fSEmmanuel Vadotto specify in a pin configuration subnode:
53*c66ec88fSEmmanuel Vadot
54*c66ec88fSEmmanuel VadotRequired Properties:
55*c66ec88fSEmmanuel Vadot
56*c66ec88fSEmmanuel Vadot- pins:		An array of strings, each string containing the name of a pin.
57*c66ec88fSEmmanuel Vadot		These pins are used for selecting the pull control and schmitt
58*c66ec88fSEmmanuel Vadot		trigger parameters. The following are the list of pins
59*c66ec88fSEmmanuel Vadot		available:
60*c66ec88fSEmmanuel Vadot
61*c66ec88fSEmmanuel Vadot		eth_txd0, eth_txd1, eth_txd2, eth_txd3, eth_txen, eth_rxer,
62*c66ec88fSEmmanuel Vadot		eth_crs_dv, eth_rxd1, eth_rxd0, eth_rxd2, eth_rxd3, eth_ref_clk,
63*c66ec88fSEmmanuel Vadot		eth_mdc, eth_mdio, sirq0, sirq1, sirq2, i2s_d0, i2s_bclk0,
64*c66ec88fSEmmanuel Vadot		i2s_lrclk0, i2s_mclk0, i2s_d1, i2s_bclk1, i2s_lrclk1, i2s_mclk1,
65*c66ec88fSEmmanuel Vadot		pcm1_in, pcm1_clk, pcm1_sync, pcm1_out, ks_in0, ks_in1, ks_in2,
66*c66ec88fSEmmanuel Vadot		ks_in3, ks_out0, ks_out1, ks_out2, lvds_oep, lvds_oen, lvds_odp,
67*c66ec88fSEmmanuel Vadot		lvds_odn, lvds_ocp, lvds_ocn, lvds_obp, lvds_obn, lvds_oap,
68*c66ec88fSEmmanuel Vadot		lvds_oan, lvds_eep, lvds_een, lvds_edp, lvds_edn, lvds_ecp,
69*c66ec88fSEmmanuel Vadot		lvds_ecn, lvds_ebp, lvds_ebn, lvds_eap, lvds_ean, lcd0_d18,
70*c66ec88fSEmmanuel Vadot		lcd0_d2, dsi_dp3, dsi_dn3, dsi_dp1, dsi_dn1, dsi_cp, dsi_cn,
71*c66ec88fSEmmanuel Vadot		dsi_dp0, dsi_dn0, dsi_dp2, dsi_dn2, sd0_d0, sd0_d1, sd0_d2,
72*c66ec88fSEmmanuel Vadot		sd0_d3, sd1_d0, sd1_d1, sd1_d2, sd1_d3, sd0_cmd, sd0_clk,
73*c66ec88fSEmmanuel Vadot		sd1_cmd, sd1_clk, spi0_ss, spi0_miso, uart0_rx, uart0_tx,
74*c66ec88fSEmmanuel Vadot		uart2_rx, uart2_tx, uart2_rtsb, uart2_ctsb, uart3_rx, uart3_tx,
75*c66ec88fSEmmanuel Vadot		uart3_rtsb, uart3_ctsb, i2c0_sclk, i2c0_sdata, i2c1_sclk,
76*c66ec88fSEmmanuel Vadot		i2c1_sdata, i2c2_sdata, csi_dn0, csi_dp0, csi_dn1, csi_dp1,
77*c66ec88fSEmmanuel Vadot		csi_cn, csi_cp, csi_dn2, csi_dp2, csi_dn3, csi_dp3,
78*c66ec88fSEmmanuel Vadot		sensor0_pclk, sensor0_ckout, dnand_d0, dnand_d1, dnand_d2,
79*c66ec88fSEmmanuel Vadot		dnand_d3, dnand_d4, dnand_d5, dnand_d6, dnand_d7, dnand_wrb,
80*c66ec88fSEmmanuel Vadot		dnand_rdb, dnand_rdbn, dnand_dqs, dnand_dqsn, dnand_rb0,
81*c66ec88fSEmmanuel Vadot		dnand_ale, dnand_cle, dnand_ceb0, dnand_ceb1, dnand_ceb2,
82*c66ec88fSEmmanuel Vadot		dnand_ceb3, porb, clko_25m, bsel, pkg0, pkg1, pkg2, pkg3
83*c66ec88fSEmmanuel Vadot
84*c66ec88fSEmmanuel Vadot- groups:       An array of strings, each string containing the name of a pin
85*c66ec88fSEmmanuel Vadot                group. These pin groups are used for selecting the pinmux
86*c66ec88fSEmmanuel Vadot                functions.
87*c66ec88fSEmmanuel Vadot		rgmii_txd23_mfp, rgmii_rxd2_mfp, rgmii_rxd3_mfp, lcd0_d18_mfp,
88*c66ec88fSEmmanuel Vadot		rgmii_txd01_mfp, rgmii_txd0_mfp, rgmii_txd1_mfp, rgmii_txen_mfp,
89*c66ec88fSEmmanuel Vadot		rgmii_rxen_mfp, rgmii_rxd1_mfp, rgmii_rxd0_mfp, rgmii_ref_clk_mfp,
90*c66ec88fSEmmanuel Vadot		i2s_d0_mfp, i2s_pcm1_mfp, i2s0_pcm0_mfp, i2s1_pcm0_mfp,
91*c66ec88fSEmmanuel Vadot		i2s_d1_mfp, ks_in2_mfp, ks_in1_mfp, ks_in0_mfp, ks_in3_mfp,
92*c66ec88fSEmmanuel Vadot		ks_out0_mfp, ks_out1_mfp, ks_out2_mfp, lvds_o_pn_mfp, dsi_dn0_mfp,
93*c66ec88fSEmmanuel Vadot		dsi_dp2_mfp, lcd0_d2_mfp, dsi_dp3_mfp, dsi_dn3_mfp, dsi_dp0_mfp,
94*c66ec88fSEmmanuel Vadot		lvds_ee_pn_mfp, uart2_rx_tx_mfp, spi0_i2c_pcm_mfp, dsi_dnp1_cp_d2_mfp,
95*c66ec88fSEmmanuel Vadot		dsi_dnp1_cp_d17_mfp, lvds_e_pn_mfp, dsi_dn2_mfp, uart2_rtsb_mfp,
96*c66ec88fSEmmanuel Vadot		uart2_ctsb_mfp, uart3_rtsb_mfp, uart3_ctsb_mfp, sd0_d0_mfp, sd0_d1_mfp,
97*c66ec88fSEmmanuel Vadot		sd0_d2_d3_mfp, sd1_d0_d3_mfp, sd0_cmd_mfp, sd0_clk_mfp, sd1_cmd_mfp,
98*c66ec88fSEmmanuel Vadot		uart0_rx_mfp, clko_25m_mfp, csi_cn_cp_mfp, sens0_ckout_mfp, uart0_tx_mfp,
99*c66ec88fSEmmanuel Vadot		i2c0_mfp, csi_dn_dp_mfp, sen0_pclk_mfp, pcm1_in_mfp, pcm1_clk_mfp,
100*c66ec88fSEmmanuel Vadot		pcm1_sync_mfp, pcm1_out_mfp, dnand_data_wr_mfp, dnand_acle_ce0_mfp,
101*c66ec88fSEmmanuel Vadot		nand_ceb2_mfp, nand_ceb3_mfp
102*c66ec88fSEmmanuel Vadot
103*c66ec88fSEmmanuel Vadot		These pin groups are used for selecting the drive strength
104*c66ec88fSEmmanuel Vadot		parameters.
105*c66ec88fSEmmanuel Vadot
106*c66ec88fSEmmanuel Vadot		sirq_drv, rgmii_txd23_drv, rgmii_rxd23_drv, rgmii_txd01_txen_drv,
107*c66ec88fSEmmanuel Vadot		rgmii_rxer_drv, rgmii_crs_drv, rgmii_rxd10_drv, rgmii_ref_clk_drv,
108*c66ec88fSEmmanuel Vadot		smi_mdc_mdio_drv, i2s_d0_drv, i2s_bclk0_drv, i2s3_drv, i2s13_drv,
109*c66ec88fSEmmanuel Vadot		pcm1_drv, ks_in_drv, ks_out_drv, lvds_all_drv, lcd_d18_d2_drv,
110*c66ec88fSEmmanuel Vadot		dsi_all_drv, sd0_d0_d3_drv, sd0_cmd_drv, sd0_clk_drv, spi0_all_drv,
111*c66ec88fSEmmanuel Vadot		uart0_rx_drv, uart0_tx_drv, uart2_all_drv, i2c0_all_drv, i2c12_all_drv,
112*c66ec88fSEmmanuel Vadot		sens0_pclk_drv, sens0_ckout_drv, uart3_all_drv
113*c66ec88fSEmmanuel Vadot
114*c66ec88fSEmmanuel Vadot- function:	An array of strings, each string containing the name of the
115*c66ec88fSEmmanuel Vadot		pinmux functions. These functions can only be selected by
116*c66ec88fSEmmanuel Vadot		the corresponding pin groups. The following are the list of
117*c66ec88fSEmmanuel Vadot		pinmux functions available:
118*c66ec88fSEmmanuel Vadot
119*c66ec88fSEmmanuel Vadot		nor, eth_rgmii, eth_sgmii, spi0, spi1, spi2, spi3, seNs0, sens1,
120*c66ec88fSEmmanuel Vadot		uart0, uart1, uart2, uart3, uart4, uart5, uart6, i2s0, i2s1,
121*c66ec88fSEmmanuel Vadot		pcm1, pcm0, ks, jtag, pwm0, pwm1, pwm2, pwm3, pwm4, pwm5, p0,
122*c66ec88fSEmmanuel Vadot		sd0, sd1, sd2, i2c0, i2c1, i2c2, i2c3, dsi, lvds, usb30,
123*c66ec88fSEmmanuel Vadot		clko_25m, mipi_csi, nand, spdif, sirq0, sirq1, sirq2, bt, lcd0
124*c66ec88fSEmmanuel Vadot
125*c66ec88fSEmmanuel VadotOptional Properties:
126*c66ec88fSEmmanuel Vadot
127*c66ec88fSEmmanuel Vadot- bias-pull-down: No arguments. The specified pins should be configured as
128*c66ec88fSEmmanuel Vadot		pull down.
129*c66ec88fSEmmanuel Vadot- bias-pull-up:   No arguments. The specified pins should be configured as
130*c66ec88fSEmmanuel Vadot		pull up.
131*c66ec88fSEmmanuel Vadot- input-schmitt-enable: No arguments: Enable schmitt trigger for the specified
132*c66ec88fSEmmanuel Vadot		pins
133*c66ec88fSEmmanuel Vadot- input-schmitt-disable: No arguments: Disable schmitt trigger for the specified
134*c66ec88fSEmmanuel Vadot		pins
135*c66ec88fSEmmanuel Vadot- drive-strength: Integer. Selects the drive strength for the specified
136*c66ec88fSEmmanuel Vadot		pins in mA.
137*c66ec88fSEmmanuel Vadot		Valid values are:
138*c66ec88fSEmmanuel Vadot		<2>
139*c66ec88fSEmmanuel Vadot		<4>
140*c66ec88fSEmmanuel Vadot		<8>
141*c66ec88fSEmmanuel Vadot		<12>
142*c66ec88fSEmmanuel Vadot
143*c66ec88fSEmmanuel VadotExample:
144*c66ec88fSEmmanuel Vadot
145*c66ec88fSEmmanuel Vadot	pinctrl: pinctrl@e01b0000 {
146*c66ec88fSEmmanuel Vadot		compatible = "actions,s700-pinctrl";
147*c66ec88fSEmmanuel Vadot		reg = <0x0 0xe01b0000 0x0 0x1000>;
148*c66ec88fSEmmanuel Vadot		clocks = <&cmu CLK_GPIO>;
149*c66ec88fSEmmanuel Vadot		gpio-controller;
150*c66ec88fSEmmanuel Vadot		gpio-ranges = <&pinctrl 0 0 136>;
151*c66ec88fSEmmanuel Vadot		#gpio-cells = <2>;
152*c66ec88fSEmmanuel Vadot		interrupt-controller;
153*c66ec88fSEmmanuel Vadot		#interrupt-cells = <2>;
154*c66ec88fSEmmanuel Vadot                interrupts = <GIC_SPI 36 IRQ_TYPE_LEVEL_HIGH>,
155*c66ec88fSEmmanuel Vadot                             <GIC_SPI 37 IRQ_TYPE_LEVEL_HIGH>,
156*c66ec88fSEmmanuel Vadot                             <GIC_SPI 38 IRQ_TYPE_LEVEL_HIGH>,
157*c66ec88fSEmmanuel Vadot                             <GIC_SPI 39 IRQ_TYPE_LEVEL_HIGH>,
158*c66ec88fSEmmanuel Vadot                             <GIC_SPI 40 IRQ_TYPE_LEVEL_HIGH>;
159*c66ec88fSEmmanuel Vadot
160*c66ec88fSEmmanuel Vadot		uart3-default: uart3-default {
161*c66ec88fSEmmanuel Vadot			pinmux {
162*c66ec88fSEmmanuel Vadot				groups = "uart3_rtsb_mfp", "uart3_ctsb_mfp";
163*c66ec88fSEmmanuel Vadot				function = "uart3";
164*c66ec88fSEmmanuel Vadot			};
165*c66ec88fSEmmanuel Vadot			pinconf {
166*c66ec88fSEmmanuel Vadot				groups = "uart3_all_drv";
167*c66ec88fSEmmanuel Vadot				drive-strength = <2>;
168*c66ec88fSEmmanuel Vadot			};
169*c66ec88fSEmmanuel Vadot		};
170*c66ec88fSEmmanuel Vadot	};
171