162306a36Sopenharmony_ciAbilis Systems TB10x pin controller 262306a36Sopenharmony_ci=================================== 362306a36Sopenharmony_ci 462306a36Sopenharmony_ciRequired properties 562306a36Sopenharmony_ci------------------- 662306a36Sopenharmony_ci 762306a36Sopenharmony_ci- compatible: should be "abilis,tb10x-iomux"; 862306a36Sopenharmony_ci- reg: should contain the physical address and size of the pin controller's 962306a36Sopenharmony_ci register range. 1062306a36Sopenharmony_ci 1162306a36Sopenharmony_ci 1262306a36Sopenharmony_ciFunction definitions 1362306a36Sopenharmony_ci-------------------- 1462306a36Sopenharmony_ci 1562306a36Sopenharmony_ciFunctions are defined (and referenced) by sub-nodes of the pin controller. 1662306a36Sopenharmony_ciEvery sub-node defines exactly one function (implying a set of pins). 1762306a36Sopenharmony_ciEvery function is associated to one named pin group inside the pin controller 1862306a36Sopenharmony_cidriver and these names are used to associate pin group predefinitions to pin 1962306a36Sopenharmony_cicontroller sub-nodes. 2062306a36Sopenharmony_ci 2162306a36Sopenharmony_ciRequired function definition subnode properties: 2262306a36Sopenharmony_ci - abilis,function: should be set to the name of the function's pin group. 2362306a36Sopenharmony_ci 2462306a36Sopenharmony_ciThe following pin groups are available: 2562306a36Sopenharmony_ci - GPIO ports: gpioa, gpiob, gpioc, gpiod, gpioe, gpiof, gpiog, 2662306a36Sopenharmony_ci gpioh, gpioi, gpioj, gpiok, gpiol, gpiom, gpion 2762306a36Sopenharmony_ci - Serial TS input ports: mis0, mis1, mis2, mis3, mis4, mis5, mis6, mis7 2862306a36Sopenharmony_ci - Parallel TS input ports: mip1, mip3, mip5, mip7 2962306a36Sopenharmony_ci - Serial TS output ports: mos0, mos1, mos2, mos3 3062306a36Sopenharmony_ci - Parallel TS output port: mop 3162306a36Sopenharmony_ci - CI+ port: ciplus 3262306a36Sopenharmony_ci - CableCard (Mcard) port: mcard 3362306a36Sopenharmony_ci - Smart card ports: stc0, stc1 3462306a36Sopenharmony_ci - UART ports: uart0, uart1 3562306a36Sopenharmony_ci - SPI ports: spi1, spi3 3662306a36Sopenharmony_ci - JTAG: jtag 3762306a36Sopenharmony_ci 3862306a36Sopenharmony_ciAll other ports of the chip are not multiplexed and thus not managed by this 3962306a36Sopenharmony_cidriver. 4062306a36Sopenharmony_ci 4162306a36Sopenharmony_ci 4262306a36Sopenharmony_ciGPIO ranges definition 4362306a36Sopenharmony_ci---------------------- 4462306a36Sopenharmony_ci 4562306a36Sopenharmony_ciThe named pin groups of GPIO ports can be used to define GPIO ranges as 4662306a36Sopenharmony_ciexplained in Documentation/devicetree/bindings/gpio/gpio.txt. 4762306a36Sopenharmony_ci 4862306a36Sopenharmony_ci 4962306a36Sopenharmony_ciExample 5062306a36Sopenharmony_ci------- 5162306a36Sopenharmony_ci 5262306a36Sopenharmony_ciiomux: iomux@ff10601c { 5362306a36Sopenharmony_ci compatible = "abilis,tb10x-iomux"; 5462306a36Sopenharmony_ci reg = <0xFF10601c 0x4>; 5562306a36Sopenharmony_ci pctl_gpio_a: pctl-gpio-a { 5662306a36Sopenharmony_ci abilis,function = "gpioa"; 5762306a36Sopenharmony_ci }; 5862306a36Sopenharmony_ci pctl_uart0: pctl-uart0 { 5962306a36Sopenharmony_ci abilis,function = "uart0"; 6062306a36Sopenharmony_ci }; 6162306a36Sopenharmony_ci}; 6262306a36Sopenharmony_ciuart@ff100000 { 6362306a36Sopenharmony_ci compatible = "snps,dw-apb-uart"; 6462306a36Sopenharmony_ci reg = <0xFF100000 0x100>; 6562306a36Sopenharmony_ci clock-frequency = <166666666>; 6662306a36Sopenharmony_ci interrupts = <25 1>; 6762306a36Sopenharmony_ci reg-shift = <2>; 6862306a36Sopenharmony_ci reg-io-width = <4>; 6962306a36Sopenharmony_ci pinctrl-names = "default"; 7062306a36Sopenharmony_ci pinctrl-0 = <&pctl_uart0>; 7162306a36Sopenharmony_ci}; 7262306a36Sopenharmony_cigpioa: gpio@ff140000 { 7362306a36Sopenharmony_ci compatible = "abilis,tb10x-gpio"; 7462306a36Sopenharmony_ci reg = <0xFF140000 0x1000>; 7562306a36Sopenharmony_ci gpio-controller; 7662306a36Sopenharmony_ci #gpio-cells = <2>; 7762306a36Sopenharmony_ci ngpio = <3>; 7862306a36Sopenharmony_ci gpio-ranges = <&iomux 0 0>; 7962306a36Sopenharmony_ci gpio-ranges-group-names = "gpioa"; 8062306a36Sopenharmony_ci}; 81