diff options
Diffstat (limited to 'src/soc/qualcomm')
-rw-r--r-- | src/soc/qualcomm/common/include/soc/qclib_common.h | 1 | ||||
-rw-r--r-- | src/soc/qualcomm/common/qclib.c | 6 |
2 files changed, 7 insertions, 0 deletions
diff --git a/src/soc/qualcomm/common/include/soc/qclib_common.h b/src/soc/qualcomm/common/include/soc/qclib_common.h index f38ed77a0d..19966e27a3 100644 --- a/src/soc/qualcomm/common/include/soc/qclib_common.h +++ b/src/soc/qualcomm/common/include/soc/qclib_common.h @@ -44,6 +44,7 @@ struct qclib_cb_if_table_entry { /* GA_BMASK_VALUES (global_attributes bit mask values) */ #define QCLIB_GA_ENABLE_UART_LOGGING 0x00000001 +#define QCLIB_GA_FORCE_COLD_REBOOT BIT(3) #define QCLIB_INTERFACE_VERSION 0x00000001 #define QCLIB_MAX_NUMBER_OF_ENTRIES 16 diff --git a/src/soc/qualcomm/common/qclib.c b/src/soc/qualcomm/common/qclib.c index 90bcc20a7d..0c7ace247d 100644 --- a/src/soc/qualcomm/common/qclib.c +++ b/src/soc/qualcomm/common/qclib.c @@ -16,6 +16,7 @@ #include <security/vboot/misc.h> #include <vb2_api.h> #include <commonlib/bsd/mem_chip_info.h> +#include <include/reset.h> #define QCLIB_VERSION 0 @@ -276,6 +277,11 @@ void qclib_load_and_run(void) mmu_restore_context(&pre_qclib_mmu_context); mmu_enable(); + if (qclib_cb_if_table.global_attributes & QCLIB_GA_FORCE_COLD_REBOOT) { + printk(BIOS_NOTICE, "QcLib requested cold reboot\n"); + board_reset(); + } + /* step through I/F table, handling return values */ for (i = 0; i < qclib_cb_if_table.num_entries; i++) if (qclib_cb_if_table.te[i].blob_attributes & |