mirror of
https://git.codelinaro.org/clo/qsdk/oss/boot/u-boot-2016.git
synced 2025-12-10 07:44:53 +01:00
Merge "ipq6018: reset: Do pmic reset if "atf" env variable is set"
This commit is contained in:
commit
3c7fc02e90
1 changed files with 18 additions and 1 deletions
|
|
@ -1150,10 +1150,27 @@ void qti_scm_pshold(void)
|
|||
writel(0, GCNT_PSHOLD);
|
||||
}
|
||||
|
||||
static void atf_reset(void)
|
||||
{
|
||||
if(*tz_wonce == 0 ) { /*COLD REBOOT*/
|
||||
if(do_pmic_reset())
|
||||
printf("PMIC Reset failed, please do power cycle\n");
|
||||
}
|
||||
else { /*WARM REBOOT*/
|
||||
psci_sys_reset();
|
||||
}
|
||||
while(1);
|
||||
}
|
||||
|
||||
void reset_cpu(unsigned long a)
|
||||
{
|
||||
reset_crashdump();
|
||||
psci_sys_reset();
|
||||
|
||||
if(getenv("atf"))
|
||||
atf_reset();
|
||||
else
|
||||
psci_sys_reset();
|
||||
|
||||
while(1);
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue