mirror of
https://github.com/Fishwaldo/u-boot.git
synced 2025-07-01 03:12:14 +00:00
[PATCH] fix gpio setting when using CFG_440_GPIO_TABLE
Set the correct value in GPIOx_TCR when configuring the gpio with CFG_440_GPIO_TABLE. Signed-off-by: Benoit Monin <bmonin@adeneo.eu> Signed-off-by: Stefan Roese <sr@denx.de>
This commit is contained in:
parent
725671ccd2
commit
fba3fb0449
1 changed files with 2 additions and 2 deletions
|
@ -157,12 +157,12 @@ void gpio_set_chip_configuration(void)
|
||||||
switch (gpio_tab[gpio_core][i].alt_nb) {
|
switch (gpio_tab[gpio_core][i].alt_nb) {
|
||||||
case GPIO_SEL:
|
case GPIO_SEL:
|
||||||
if (gpio_core == GPIO0) {
|
if (gpio_core == GPIO0) {
|
||||||
reg = in32(GPIO0_TCR) | (0x80000000 >> (j));
|
reg = in32(GPIO0_TCR) | (0x80000000 >> (i));
|
||||||
out32(GPIO0_TCR, reg);
|
out32(GPIO0_TCR, reg);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (gpio_core == GPIO1) {
|
if (gpio_core == GPIO1) {
|
||||||
reg = in32(GPIO1_TCR) | (0x80000000 >> (j));
|
reg = in32(GPIO1_TCR) | (0x80000000 >> (i));
|
||||||
out32(GPIO1_TCR, reg);
|
out32(GPIO1_TCR, reg);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue