1*c66ec88fSEmmanuel VadotNVIDIA Tegra20 pinmux controller 2*c66ec88fSEmmanuel Vadot 3*c66ec88fSEmmanuel VadotRequired properties: 4*c66ec88fSEmmanuel Vadot- compatible: "nvidia,tegra20-pinmux" 5*c66ec88fSEmmanuel Vadot- reg: Should contain the register physical address and length for each of 6*c66ec88fSEmmanuel Vadot the tri-state, mux, pull-up/down, and pad control register sets. 7*c66ec88fSEmmanuel Vadot 8*c66ec88fSEmmanuel VadotPlease refer to pinctrl-bindings.txt in this directory for details of the 9*c66ec88fSEmmanuel Vadotcommon pinctrl bindings used by client devices, including the meaning of the 10*c66ec88fSEmmanuel Vadotphrase "pin configuration node". 11*c66ec88fSEmmanuel Vadot 12*c66ec88fSEmmanuel VadotTegra's pin configuration nodes act as a container for an arbitrary number of 13*c66ec88fSEmmanuel Vadotsubnodes. Each of these subnodes represents some desired configuration for a 14*c66ec88fSEmmanuel Vadotpin, a group, or a list of pins or groups. This configuration can include the 15*c66ec88fSEmmanuel Vadotmux function to select on those pin(s)/group(s), and various pin configuration 16*c66ec88fSEmmanuel Vadotparameters, such as pull-up, tristate, drive strength, etc. 17*c66ec88fSEmmanuel Vadot 18*c66ec88fSEmmanuel VadotThe name of each subnode is not important; all subnodes should be enumerated 19*c66ec88fSEmmanuel Vadotand processed purely based on their content. 20*c66ec88fSEmmanuel Vadot 21*c66ec88fSEmmanuel VadotEach subnode only affects those parameters that are explicitly listed. In 22*c66ec88fSEmmanuel Vadotother words, a subnode that lists a mux function but no pin configuration 23*c66ec88fSEmmanuel Vadotparameters implies no information about any pin configuration parameters. 24*c66ec88fSEmmanuel VadotSimilarly, a pin subnode that describes a pullup parameter implies no 25*c66ec88fSEmmanuel Vadotinformation about e.g. the mux function or tristate parameter. For this 26*c66ec88fSEmmanuel Vadotreason, even seemingly boolean values are actually tristates in this binding: 27*c66ec88fSEmmanuel Vadotunspecified, off, or on. Unspecified is represented as an absent property, 28*c66ec88fSEmmanuel Vadotand off/on are represented as integer values 0 and 1. 29*c66ec88fSEmmanuel Vadot 30*c66ec88fSEmmanuel VadotRequired subnode-properties: 31*c66ec88fSEmmanuel Vadot- nvidia,pins : An array of strings. Each string contains the name of a pin or 32*c66ec88fSEmmanuel Vadot group. Valid values for these names are listed below. 33*c66ec88fSEmmanuel Vadot 34*c66ec88fSEmmanuel VadotOptional subnode-properties: 35*c66ec88fSEmmanuel Vadot- nvidia,function: A string containing the name of the function to mux to the 36*c66ec88fSEmmanuel Vadot pin or group. Valid values for function names are listed below. See the Tegra 37*c66ec88fSEmmanuel Vadot TRM to determine which are valid for each pin or group. 38*c66ec88fSEmmanuel Vadot- nvidia,pull: Integer, representing the pull-down/up to apply to the pin. 39*c66ec88fSEmmanuel Vadot 0: none, 1: down, 2: up. 40*c66ec88fSEmmanuel Vadot- nvidia,tristate: Integer. 41*c66ec88fSEmmanuel Vadot 0: drive, 1: tristate. 42*c66ec88fSEmmanuel Vadot- nvidia,high-speed-mode: Integer. Enable high speed mode the pins. 43*c66ec88fSEmmanuel Vadot 0: no, 1: yes. 44*c66ec88fSEmmanuel Vadot- nvidia,schmitt: Integer. Enables Schmitt Trigger on the input. 45*c66ec88fSEmmanuel Vadot 0: no, 1: yes. 46*c66ec88fSEmmanuel Vadot- nvidia,low-power-mode: Integer. Valid values 0-3. 0 is least power, 3 is 47*c66ec88fSEmmanuel Vadot most power. Controls the drive power or current. See "Low Power Mode" 48*c66ec88fSEmmanuel Vadot or "LPMD1" and "LPMD0" in the Tegra TRM. 49*c66ec88fSEmmanuel Vadot- nvidia,pull-down-strength: Integer. Controls drive strength. 0 is weakest. 50*c66ec88fSEmmanuel Vadot The range of valid values depends on the pingroup. See "CAL_DRVDN" in the 51*c66ec88fSEmmanuel Vadot Tegra TRM. 52*c66ec88fSEmmanuel Vadot- nvidia,pull-up-strength: Integer. Controls drive strength. 0 is weakest. 53*c66ec88fSEmmanuel Vadot The range of valid values depends on the pingroup. See "CAL_DRVUP" in the 54*c66ec88fSEmmanuel Vadot Tegra TRM. 55*c66ec88fSEmmanuel Vadot- nvidia,slew-rate-rising: Integer. Controls rising signal slew rate. 0 is 56*c66ec88fSEmmanuel Vadot fastest. The range of valid values depends on the pingroup. See 57*c66ec88fSEmmanuel Vadot "DRVDN_SLWR" in the Tegra TRM. 58*c66ec88fSEmmanuel Vadot- nvidia,slew-rate-falling: Integer. Controls falling signal slew rate. 0 is 59*c66ec88fSEmmanuel Vadot fastest. The range of valid values depends on the pingroup. See 60*c66ec88fSEmmanuel Vadot "DRVUP_SLWF" in the Tegra TRM. 61*c66ec88fSEmmanuel Vadot 62*c66ec88fSEmmanuel VadotNote that many of these properties are only valid for certain specific pins 63*c66ec88fSEmmanuel Vadotor groups. See the Tegra TRM and various pinmux spreadsheets for complete 64*c66ec88fSEmmanuel Vadotdetails regarding which groups support which functionality. The Linux pinctrl 65*c66ec88fSEmmanuel Vadotdriver may also be a useful reference, since it consolidates, disambiguates, 66*c66ec88fSEmmanuel Vadotand corrects data from all those sources. 67*c66ec88fSEmmanuel Vadot 68*c66ec88fSEmmanuel VadotValid values for pin and group names are: 69*c66ec88fSEmmanuel Vadot 70*c66ec88fSEmmanuel Vadot mux groups: 71*c66ec88fSEmmanuel Vadot 72*c66ec88fSEmmanuel Vadot These all support nvidia,function, nvidia,tristate, and many support 73*c66ec88fSEmmanuel Vadot nvidia,pull. 74*c66ec88fSEmmanuel Vadot 75*c66ec88fSEmmanuel Vadot ata, atb, atc, atd, ate, cdev1, cdev2, crtp, csus, dap1, dap2, dap3, dap4, 76*c66ec88fSEmmanuel Vadot ddc, dta, dtb, dtc, dtd, dte, dtf, gma, gmb, gmc, gmd, gme, gpu, gpu7, 77*c66ec88fSEmmanuel Vadot gpv, hdint, i2cp, irrx, irtx, kbca, kbcb, kbcc, kbcd, kbce, kbcf, lcsn, 78*c66ec88fSEmmanuel Vadot ld0, ld1, ld2, ld3, ld4, ld5, ld6, ld7, ld8, ld9, ld10, ld11, ld12, ld13, 79*c66ec88fSEmmanuel Vadot ld14, ld15, ld16, ld17, ldc, ldi, lhp0, lhp1, lhp2, lhs, lm0, lm1, lpp, 80*c66ec88fSEmmanuel Vadot lpw0, lpw1, lpw2, lsc0, lsc1, lsck, lsda, lsdi, lspi, lvp0, lvp1, lvs, 81*c66ec88fSEmmanuel Vadot owc, pmc, pta, rm, sdb, sdc, sdd, sdio1, slxa, slxc, slxd, slxk, spdi, 82*c66ec88fSEmmanuel Vadot spdo, spia, spib, spic, spid, spie, spif, spig, spih, uaa, uab, uac, uad, 83*c66ec88fSEmmanuel Vadot uca, ucb, uda. 84*c66ec88fSEmmanuel Vadot 85*c66ec88fSEmmanuel Vadot tristate groups: 86*c66ec88fSEmmanuel Vadot 87*c66ec88fSEmmanuel Vadot These only support nvidia,pull. 88*c66ec88fSEmmanuel Vadot 89*c66ec88fSEmmanuel Vadot ck32, ddrc, pmca, pmcb, pmcc, pmcd, pmce, xm2c, xm2d, ls, lc, ld17_0, 90*c66ec88fSEmmanuel Vadot ld19_18, ld21_20, ld23_22. 91*c66ec88fSEmmanuel Vadot 92*c66ec88fSEmmanuel Vadot drive groups: 93*c66ec88fSEmmanuel Vadot 94*c66ec88fSEmmanuel Vadot With some exceptions, these support nvidia,high-speed-mode, 95*c66ec88fSEmmanuel Vadot nvidia,schmitt, nvidia,low-power-mode, nvidia,pull-down-strength, 96*c66ec88fSEmmanuel Vadot nvidia,pull-up-strength, nvidia,slew-rate-rising, nvidia,slew-rate-falling. 97*c66ec88fSEmmanuel Vadot 98*c66ec88fSEmmanuel Vadot drive_ao1, drive_ao2, drive_at1, drive_at2, drive_cdev1, drive_cdev2, 99*c66ec88fSEmmanuel Vadot drive_csus, drive_dap1, drive_dap2, drive_dap3, drive_dap4, drive_dbg, 100*c66ec88fSEmmanuel Vadot drive_lcd1, drive_lcd2, drive_sdmmc2, drive_sdmmc3, drive_spi, drive_uaa, 101*c66ec88fSEmmanuel Vadot drive_uab, drive_uart2, drive_uart3, drive_vi1, drive_vi2, drive_xm2a, 102*c66ec88fSEmmanuel Vadot drive_xm2c, drive_xm2d, drive_xm2clk, drive_sdio1, drive_crt, drive_ddc, 103*c66ec88fSEmmanuel Vadot drive_gma, drive_gmb, drive_gmc, drive_gmd, drive_gme, drive_owr, 104*c66ec88fSEmmanuel Vadot drive_uda. 105*c66ec88fSEmmanuel Vadot 106*c66ec88fSEmmanuel VadotValid values for nvidia,functions are: 107*c66ec88fSEmmanuel Vadot 108*c66ec88fSEmmanuel Vadot ahb_clk, apb_clk, audio_sync, crt, dap1, dap2, dap3, dap4, dap5, 109*c66ec88fSEmmanuel Vadot displaya, displayb, emc_test0_dll, emc_test1_dll, gmi, gmi_int, 110*c66ec88fSEmmanuel Vadot hdmi, i2cp, i2c1, i2c2, i2c3, ide, irda, kbc, mio, mipi_hs, nand, 111*c66ec88fSEmmanuel Vadot osc, owr, pcie, plla_out, pllc_out1, pllm_out1, pllp_out2, pllp_out3, 112*c66ec88fSEmmanuel Vadot pllp_out4, pwm, pwr_intr, pwr_on, rsvd1, rsvd2, rsvd3, rsvd4, rtck, 113*c66ec88fSEmmanuel Vadot sdio1, sdio2, sdio3, sdio4, sflash, spdif, spi1, spi2, spi2_alt, 114*c66ec88fSEmmanuel Vadot spi3, spi4, trace, twc, uarta, uartb, uartc, uartd, uarte, ulpi, 115*c66ec88fSEmmanuel Vadot vi, vi_sensor_clk, xio 116*c66ec88fSEmmanuel Vadot 117*c66ec88fSEmmanuel VadotExample: 118*c66ec88fSEmmanuel Vadot 119*c66ec88fSEmmanuel Vadot pinctrl@70000000 { 120*c66ec88fSEmmanuel Vadot compatible = "nvidia,tegra20-pinmux"; 121*c66ec88fSEmmanuel Vadot reg = < 0x70000014 0x10 /* Tri-state registers */ 122*c66ec88fSEmmanuel Vadot 0x70000080 0x20 /* Mux registers */ 123*c66ec88fSEmmanuel Vadot 0x700000a0 0x14 /* Pull-up/down registers */ 124*c66ec88fSEmmanuel Vadot 0x70000868 0xa8 >; /* Pad control registers */ 125*c66ec88fSEmmanuel Vadot }; 126*c66ec88fSEmmanuel Vadot 127*c66ec88fSEmmanuel VadotExample board file extract: 128*c66ec88fSEmmanuel Vadot 129*c66ec88fSEmmanuel Vadot pinctrl@70000000 { 130*c66ec88fSEmmanuel Vadot sdio4_default: sdio4_default { 131*c66ec88fSEmmanuel Vadot atb { 132*c66ec88fSEmmanuel Vadot nvidia,pins = "atb", "gma", "gme"; 133*c66ec88fSEmmanuel Vadot nvidia,function = "sdio4"; 134*c66ec88fSEmmanuel Vadot nvidia,pull = <0>; 135*c66ec88fSEmmanuel Vadot nvidia,tristate = <0>; 136*c66ec88fSEmmanuel Vadot }; 137*c66ec88fSEmmanuel Vadot }; 138*c66ec88fSEmmanuel Vadot }; 139*c66ec88fSEmmanuel Vadot 140*c66ec88fSEmmanuel Vadot sdhci@c8000600 { 141*c66ec88fSEmmanuel Vadot pinctrl-names = "default"; 142*c66ec88fSEmmanuel Vadot pinctrl-0 = <&sdio4_default>; 143*c66ec88fSEmmanuel Vadot }; 144