Skip to content

Commit

Permalink
MIPS: BCM63xx: Initialize gpio_out_low & out_high to current value at…
Browse files Browse the repository at this point in the history
… boot.

To avoid a glitch during GPIO initialisation read GPIO output register
values left by the firmware.

Signed-off-by: Maxime Bizon <mbizon@freebox.fr>
To: linux-mips@linux-mips.org
Patchwork: http://patchwork.linux-mips.org/patch/903/
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
  • Loading branch information
mbizonfreebox authored and ralfbaechle committed Apr 12, 2010
1 parent e23a90e commit 9538ca6
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions arch/mips/bcm63xx/gpio.c
Original file line number Diff line number Diff line change
Expand Up @@ -125,6 +125,8 @@ static struct gpio_chip bcm63xx_gpio_chip = {

int __init bcm63xx_gpio_init(void)
{
gpio_out_low = bcm_gpio_readl(GPIO_DATA_LO_REG);
gpio_out_high = bcm_gpio_readl(GPIO_DATA_HI_REG);
bcm63xx_gpio_chip.ngpio = bcm63xx_gpio_count();
pr_info("registering %d GPIOs\n", bcm63xx_gpio_chip.ngpio);

Expand Down

0 comments on commit 9538ca6

Please sign in to comment.