summaryrefslogtreecommitdiff
path: root/gcip-kernel-driver/include/gcip/gcip-firmware.h
diff options
context:
space:
mode:
Diffstat (limited to 'gcip-kernel-driver/include/gcip/gcip-firmware.h')
-rw-r--r--gcip-kernel-driver/include/gcip/gcip-firmware.h16
1 files changed, 11 insertions, 5 deletions
diff --git a/gcip-kernel-driver/include/gcip/gcip-firmware.h b/gcip-kernel-driver/include/gcip/gcip-firmware.h
index 8cf4353..52f5d11 100644
--- a/gcip-kernel-driver/include/gcip/gcip-firmware.h
+++ b/gcip-kernel-driver/include/gcip/gcip-firmware.h
@@ -1,4 +1,4 @@
-/* SPDX-License-Identifier: GPL-2.0 */
+/* SPDX-License-Identifier: GPL-2.0-only */
/*
* GCIP firmware interface.
*
@@ -44,9 +44,10 @@ enum gcip_fw_flavor {
GCIP_FW_FLAVOR_CUSTOM = 4,
};
-/* Type of firmware crash which will be sent by GCIP_RKCI_FIRMWARE_CRASH RKCI command. */
+/* Type of firmware crash. */
enum gcip_fw_crash_type {
- /* Assert happened. */
+ /* Type which will be sent by GCIP_RKCI_FIRMWARE_CRASH reverse KCI. */
+ /*Assert happened. */
GCIP_FW_CRASH_ASSERT_FAIL = 0,
/* Data abort exception. */
GCIP_FW_CRASH_DATA_ABORT = 1,
@@ -58,6 +59,9 @@ enum gcip_fw_crash_type {
GCIP_FW_CRASH_UNRECOVERABLE_FAULT = 4,
/* Used in debug dump. */
GCIP_FW_CRASH_DUMMY_CRASH_TYPE = 0xFF,
+
+ /* HW watchdog timeout. */
+ GCIP_FW_CRASH_HW_WDG_TIMEOUT = 0x100,
};
/* Firmware info filled out via KCI FIRMWARE_INFO command. */
@@ -80,7 +84,9 @@ struct gcip_fw_tracing {
* Lock to protect the struct members listed below.
*
* Note that since the request of tracing level adjusting might happen during power state
- * transitions, this lock must be acquired after holding the pm lock to avoid deadlock.
+ * transitions (i.e., another thread calling gcip_firmware_tracing_restore_on_powering()
+ * with pm lock held), one must either use the non-blocking gcip_pm_get_if_powered() or make
+ * sure there won't be any new power transition after holding this lock to prevent deadlock.
*/
struct mutex lock;
/* Actual firmware tracing level. */
@@ -123,6 +129,6 @@ void gcip_firmware_tracing_destroy(struct gcip_fw_tracing *fw_tracing);
* This function is designed to restore the firmware tracing level during power management calls and
* thus it assumes the caller holds the pm lock.
*/
-int gcip_firmware_tracing_restore(struct gcip_fw_tracing *fw_tracing);
+int gcip_firmware_tracing_restore_on_powering(struct gcip_fw_tracing *fw_tracing);
#endif /* __GCIP_FIRMWARE_H__ */