Root/target/linux/brcm63xx/patches-2.6.32/210-init_gpio_out_low_high_current_value_at_boot.patch

1To avoid glitch during gpio initialisation, fetch gpio output
2registers values left by bootloader.
3
4Signed-off-by: Maxime Bizon <mbizon@freebox.fr>
5---
6 arch/mips/bcm63xx/gpio.c | 2 ++
7 1 files changed, 2 insertions(+), 0 deletions(-)
8
9--- a/arch/mips/bcm63xx/gpio.c
10+++ b/arch/mips/bcm63xx/gpio.c
11@@ -125,6 +125,8 @@ static struct gpio_chip bcm63xx_gpio_chi
12 
13 int __init bcm63xx_gpio_init(void)
14 {
15+ gpio_out_low = bcm_gpio_readl(GPIO_DATA_LO_REG);
16+ gpio_out_high = bcm_gpio_readl(GPIO_DATA_HI_REG);
17     bcm63xx_gpio_chip.ngpio = bcm63xx_gpio_count();
18     pr_info("registering %d GPIOs\n", bcm63xx_gpio_chip.ngpio);
19 
20

Archive Download this file



interactive