162306a36Sopenharmony_ciCadence GPIO controller bindings 262306a36Sopenharmony_ci 362306a36Sopenharmony_ciRequired properties: 462306a36Sopenharmony_ci- compatible: should be "cdns,gpio-r1p02". 562306a36Sopenharmony_ci- reg: the register base address and size. 662306a36Sopenharmony_ci- #gpio-cells: should be 2. 762306a36Sopenharmony_ci * first cell is the GPIO number. 862306a36Sopenharmony_ci * second cell specifies the GPIO flags, as defined in 962306a36Sopenharmony_ci <dt-bindings/gpio/gpio.h>. Only the GPIO_ACTIVE_HIGH 1062306a36Sopenharmony_ci and GPIO_ACTIVE_LOW flags are supported. 1162306a36Sopenharmony_ci- gpio-controller: marks the device as a GPIO controller. 1262306a36Sopenharmony_ci- clocks: should contain one entry referencing the peripheral clock driving 1362306a36Sopenharmony_ci the GPIO controller. 1462306a36Sopenharmony_ci 1562306a36Sopenharmony_ciOptional properties: 1662306a36Sopenharmony_ci- ngpios: integer number of gpio lines supported by this controller, up to 32. 1762306a36Sopenharmony_ci- interrupts: interrupt specifier for the controllers interrupt. 1862306a36Sopenharmony_ci- interrupt-controller: marks the device as an interrupt controller. When 1962306a36Sopenharmony_ci defined, interrupts, interrupt-parent and #interrupt-cells 2062306a36Sopenharmony_ci are required. 2162306a36Sopenharmony_ci- interrupt-cells: should be 2. 2262306a36Sopenharmony_ci * first cell is the GPIO number you want to use as an IRQ source. 2362306a36Sopenharmony_ci * second cell specifies the IRQ type, as defined in 2462306a36Sopenharmony_ci <dt-bindings/interrupt-controller/irq.h>. 2562306a36Sopenharmony_ci Currently only level sensitive IRQs are supported. 2662306a36Sopenharmony_ci 2762306a36Sopenharmony_ci 2862306a36Sopenharmony_ciExample: 2962306a36Sopenharmony_ci gpio0: gpio-controller@fd060000 { 3062306a36Sopenharmony_ci compatible = "cdns,gpio-r1p02"; 3162306a36Sopenharmony_ci reg =<0xfd060000 0x1000>; 3262306a36Sopenharmony_ci 3362306a36Sopenharmony_ci clocks = <&gpio_clk>; 3462306a36Sopenharmony_ci 3562306a36Sopenharmony_ci interrupt-parent = <&gic>; 3662306a36Sopenharmony_ci interrupts = <0 5 IRQ_TYPE_LEVEL_HIGH>; 3762306a36Sopenharmony_ci 3862306a36Sopenharmony_ci gpio-controller; 3962306a36Sopenharmony_ci #gpio-cells = <2>; 4062306a36Sopenharmony_ci 4162306a36Sopenharmony_ci interrupt-controller; 4262306a36Sopenharmony_ci #interrupt-cells = <2>; 4362306a36Sopenharmony_ci }; 44