X-Git-Url: https://git.rohieb.name/openwrt.git/blobdiff_plain/7c54f57e7eed040ec8e9dbdd92e43c932f566081..59b7de56237bddc694706c8c220ca0865be4c666:/target/linux/ramips/files/arch/mips/ralink/common/gpio.c diff --git a/target/linux/ramips/files/arch/mips/ralink/common/gpio.c b/target/linux/ramips/files/arch/mips/ralink/common/gpio.c index af4cac738..3a1b03863 100644 --- a/target/linux/ramips/files/arch/mips/ralink/common/gpio.c +++ b/target/linux/ramips/files/arch/mips/ralink/common/gpio.c @@ -52,6 +52,7 @@ enum ramips_pio_reg { RAMIPS_GPIO_REG_INT, /* Interrupt status */ RAMIPS_GPIO_REG_EDGE, RAMIPS_GPIO_REG_RENA, + RAMIPS_GPIO_REG_FENA, RAMIPS_GPIO_REG_DATA, RAMIPS_GPIO_REG_DIR, /* Direction, 0:in, 1: out */ RAMIPS_GPIO_REG_POL, /* Polarity, 0: normal, 1: invert */ @@ -147,6 +148,7 @@ static struct ramips_gpio_chip ramips_gpio_chip0 = { [RAMIPS_GPIO_REG_INT] = GPIO0_REG_INT, [RAMIPS_GPIO_REG_EDGE] = GPIO0_REG_EDGE, [RAMIPS_GPIO_REG_RENA] = GPIO0_REG_RENA, + [RAMIPS_GPIO_REG_FENA] = GPIO0_REG_FENA, [RAMIPS_GPIO_REG_DATA] = GPIO0_REG_DATA, [RAMIPS_GPIO_REG_DIR] = GPIO0_REG_DIR, [RAMIPS_GPIO_REG_POL] = GPIO0_REG_POL, @@ -170,6 +172,7 @@ static struct ramips_gpio_chip ramips_gpio_chip1 = { [RAMIPS_GPIO_REG_INT] = GPIO1_REG_INT, [RAMIPS_GPIO_REG_EDGE] = GPIO1_REG_EDGE, [RAMIPS_GPIO_REG_RENA] = GPIO1_REG_RENA, + [RAMIPS_GPIO_REG_FENA] = GPIO1_REG_FENA, [RAMIPS_GPIO_REG_DATA] = GPIO1_REG_DATA, [RAMIPS_GPIO_REG_DIR] = GPIO1_REG_DIR, [RAMIPS_GPIO_REG_POL] = GPIO1_REG_POL, @@ -193,6 +196,7 @@ static struct ramips_gpio_chip ramips_gpio_chip2 = { [RAMIPS_GPIO_REG_INT] = GPIO2_REG_INT, [RAMIPS_GPIO_REG_EDGE] = GPIO2_REG_EDGE, [RAMIPS_GPIO_REG_RENA] = GPIO2_REG_RENA, + [RAMIPS_GPIO_REG_FENA] = GPIO2_REG_FENA, [RAMIPS_GPIO_REG_DATA] = GPIO2_REG_DATA, [RAMIPS_GPIO_REG_DIR] = GPIO2_REG_DIR, [RAMIPS_GPIO_REG_POL] = GPIO2_REG_POL, @@ -204,7 +208,7 @@ static struct ramips_gpio_chip ramips_gpio_chip2 = { static __init void ramips_gpio_chip_add(struct ramips_gpio_chip *rg) { - /* set priority to low for all lines */ + /* set polarity to low for all lines */ ramips_gpio_wr(rg, RAMIPS_GPIO_REG_POL, 0); gpiochip_add(&rg->chip); @@ -220,5 +224,3 @@ __init int ramips_gpio_init(void) return 0; } - -arch_initcall(ramips_gpio_init);