1*c66ec88fSEmmanuel VadotAbilis Systems TB10x pin controller 2*c66ec88fSEmmanuel Vadot=================================== 3*c66ec88fSEmmanuel Vadot 4*c66ec88fSEmmanuel VadotRequired properties 5*c66ec88fSEmmanuel Vadot------------------- 6*c66ec88fSEmmanuel Vadot 7*c66ec88fSEmmanuel Vadot- compatible: should be "abilis,tb10x-iomux"; 8*c66ec88fSEmmanuel Vadot- reg: should contain the physical address and size of the pin controller's 9*c66ec88fSEmmanuel Vadot register range. 10*c66ec88fSEmmanuel Vadot 11*c66ec88fSEmmanuel Vadot 12*c66ec88fSEmmanuel VadotFunction definitions 13*c66ec88fSEmmanuel Vadot-------------------- 14*c66ec88fSEmmanuel Vadot 15*c66ec88fSEmmanuel VadotFunctions are defined (and referenced) by sub-nodes of the pin controller. 16*c66ec88fSEmmanuel VadotEvery sub-node defines exactly one function (implying a set of pins). 17*c66ec88fSEmmanuel VadotEvery function is associated to one named pin group inside the pin controller 18*c66ec88fSEmmanuel Vadotdriver and these names are used to associate pin group predefinitions to pin 19*c66ec88fSEmmanuel Vadotcontroller sub-nodes. 20*c66ec88fSEmmanuel Vadot 21*c66ec88fSEmmanuel VadotRequired function definition subnode properties: 22*c66ec88fSEmmanuel Vadot - abilis,function: should be set to the name of the function's pin group. 23*c66ec88fSEmmanuel Vadot 24*c66ec88fSEmmanuel VadotThe following pin groups are available: 25*c66ec88fSEmmanuel Vadot - GPIO ports: gpioa, gpiob, gpioc, gpiod, gpioe, gpiof, gpiog, 26*c66ec88fSEmmanuel Vadot gpioh, gpioi, gpioj, gpiok, gpiol, gpiom, gpion 27*c66ec88fSEmmanuel Vadot - Serial TS input ports: mis0, mis1, mis2, mis3, mis4, mis5, mis6, mis7 28*c66ec88fSEmmanuel Vadot - Parallel TS input ports: mip1, mip3, mip5, mip7 29*c66ec88fSEmmanuel Vadot - Serial TS output ports: mos0, mos1, mos2, mos3 30*c66ec88fSEmmanuel Vadot - Parallel TS output port: mop 31*c66ec88fSEmmanuel Vadot - CI+ port: ciplus 32*c66ec88fSEmmanuel Vadot - CableCard (Mcard) port: mcard 33*c66ec88fSEmmanuel Vadot - Smart card ports: stc0, stc1 34*c66ec88fSEmmanuel Vadot - UART ports: uart0, uart1 35*c66ec88fSEmmanuel Vadot - SPI ports: spi1, spi3 36*c66ec88fSEmmanuel Vadot - JTAG: jtag 37*c66ec88fSEmmanuel Vadot 38*c66ec88fSEmmanuel VadotAll other ports of the chip are not multiplexed and thus not managed by this 39*c66ec88fSEmmanuel Vadotdriver. 40*c66ec88fSEmmanuel Vadot 41*c66ec88fSEmmanuel Vadot 42*c66ec88fSEmmanuel VadotGPIO ranges definition 43*c66ec88fSEmmanuel Vadot---------------------- 44*c66ec88fSEmmanuel Vadot 45*c66ec88fSEmmanuel VadotThe named pin groups of GPIO ports can be used to define GPIO ranges as 46*c66ec88fSEmmanuel Vadotexplained in Documentation/devicetree/bindings/gpio/gpio.txt. 47*c66ec88fSEmmanuel Vadot 48*c66ec88fSEmmanuel Vadot 49*c66ec88fSEmmanuel VadotExample 50*c66ec88fSEmmanuel Vadot------- 51*c66ec88fSEmmanuel Vadot 52*c66ec88fSEmmanuel Vadotiomux: iomux@ff10601c { 53*c66ec88fSEmmanuel Vadot compatible = "abilis,tb10x-iomux"; 54*c66ec88fSEmmanuel Vadot reg = <0xFF10601c 0x4>; 55*c66ec88fSEmmanuel Vadot pctl_gpio_a: pctl-gpio-a { 56*c66ec88fSEmmanuel Vadot abilis,function = "gpioa"; 57*c66ec88fSEmmanuel Vadot }; 58*c66ec88fSEmmanuel Vadot pctl_uart0: pctl-uart0 { 59*c66ec88fSEmmanuel Vadot abilis,function = "uart0"; 60*c66ec88fSEmmanuel Vadot }; 61*c66ec88fSEmmanuel Vadot}; 62*c66ec88fSEmmanuel Vadotuart@ff100000 { 63*c66ec88fSEmmanuel Vadot compatible = "snps,dw-apb-uart"; 64*c66ec88fSEmmanuel Vadot reg = <0xFF100000 0x100>; 65*c66ec88fSEmmanuel Vadot clock-frequency = <166666666>; 66*c66ec88fSEmmanuel Vadot interrupts = <25 1>; 67*c66ec88fSEmmanuel Vadot reg-shift = <2>; 68*c66ec88fSEmmanuel Vadot reg-io-width = <4>; 69*c66ec88fSEmmanuel Vadot pinctrl-names = "default"; 70*c66ec88fSEmmanuel Vadot pinctrl-0 = <&pctl_uart0>; 71*c66ec88fSEmmanuel Vadot}; 72*c66ec88fSEmmanuel Vadotgpioa: gpio@ff140000 { 73*c66ec88fSEmmanuel Vadot compatible = "abilis,tb10x-gpio"; 74*c66ec88fSEmmanuel Vadot reg = <0xFF140000 0x1000>; 75*c66ec88fSEmmanuel Vadot gpio-controller; 76*c66ec88fSEmmanuel Vadot #gpio-cells = <2>; 77*c66ec88fSEmmanuel Vadot ngpio = <3>; 78*c66ec88fSEmmanuel Vadot gpio-ranges = <&iomux 0 0>; 79*c66ec88fSEmmanuel Vadot gpio-ranges-group-names = "gpioa"; 80*c66ec88fSEmmanuel Vadot}; 81