ipq806x: Reset S17C switch during soft reboot

In case of AP148 , the S17C switch has to be additionally reset using
GPIO 63. This is done for soft reboot cases.

This change is ported based on commit e1c6cd2c07

Change-Id: I31ce8a34797ae353035a7b3fa05ad2783f78aece
Signed-off-by: Kathiravan T <kathirav@codeaurora.org>
This commit is contained in:
Kathiravan T 2018-02-02 11:40:31 +05:30 committed by Gerrit - the friendly Code Review server
parent ea17792263
commit 6186c29910
2 changed files with 17 additions and 0 deletions

View file

@ -92,4 +92,15 @@
};
};
reset_s17_gpio {
gpio63 {
gpio = <63>;
func = <0>;
out = <GPIO_OUTPUT>;
pull = <GPIO_PULL_DOWN>;
drvstr = <GPIO_8MA>;
oe = <GPIO_OE_ENABLE>;
};
};
};

View file

@ -166,6 +166,12 @@ void reset_crashdump(void)
void reset_cpu(unsigned long a)
{
int reset_s17_gpio_node;
reset_s17_gpio_node = fdt_path_offset(gd->fdt_blob, "/reset_s17_gpio");
if (reset_s17_gpio_node)
qca_gpio_init(reset_s17_gpio_node);
reset_crashdump();
printf("\nResetting with watch dog!\n");