Loading drivers/soc/qcom/jtagv8.c +11 −9 Original line number Diff line number Diff line // SPDX-License-Identifier: GPL-2.0-only /* * Copyright (c) 2014-2019, The Linux Foundation. All rights reserved. * Copyright (c) 2014-2020, The Linux Foundation. All rights reserved. * */ Loading Loading @@ -865,7 +865,7 @@ static void dbg_init_arch_data(void) * * In all cases we will run on the same cpu for the entire duration. */ void msm_jtag_save_state(void) void msm_jtag_save_state(bool is_hotcpu_cb) { int cpu; Loading @@ -875,13 +875,14 @@ void msm_jtag_save_state(void) /* ensure counter is updated before moving forward */ mb(); if (!is_hotcpu_cb) msm_jtag_etm_save_state(); if (dbg.save_restore_enabled) dbg_save_state(cpu); } EXPORT_SYMBOL(msm_jtag_save_state); void msm_jtag_restore_state(void) void msm_jtag_restore_state(bool is_hotcpu_cb) { int cpu; Loading @@ -907,6 +908,7 @@ void msm_jtag_restore_state(void) if (dbg.save_restore_enabled) dbg_restore_state(cpu); if (!is_hotcpu_cb) msm_jtag_etm_restore_state(); } EXPORT_SYMBOL(msm_jtag_restore_state); Loading @@ -925,13 +927,13 @@ static inline bool dbg_arch_supported(uint8_t arch) static int jtag_hotcpu_save_callback(unsigned int cpu) { msm_jtag_save_state(); msm_jtag_save_state(true); return 0; } static int jtag_hotcpu_restore_callback(unsigned int cpu) { msm_jtag_restore_state(); msm_jtag_restore_state(true); return 0; } Loading @@ -940,11 +942,11 @@ static int jtag_cpu_pm_callback(struct notifier_block *nfb, { switch (action) { case CPU_PM_ENTER: msm_jtag_save_state(); msm_jtag_save_state(false); break; case CPU_PM_ENTER_FAILED: case CPU_PM_EXIT: msm_jtag_restore_state(); msm_jtag_restore_state(false); break; } return NOTIFY_OK; Loading include/soc/qcom/jtag.h +2 −2 Original line number Diff line number Diff line Loading @@ -12,8 +12,8 @@ struct notifier_block; #if defined(CONFIG_MSM_JTAG) || defined(CONFIG_MSM_JTAG_MM) || \ defined(CONFIG_MSM_JTAGV8) extern void msm_jtag_save_state(void); extern void msm_jtag_restore_state(void); extern void msm_jtag_save_state(bool is_hotcpu_cb); extern void msm_jtag_restore_state(bool is_hotcpu_cb); extern void msm_jtag_etm_save_state(void); extern void msm_jtag_etm_restore_state(void); extern bool msm_jtag_fuse_apps_access_disabled(void); Loading Loading
drivers/soc/qcom/jtagv8.c +11 −9 Original line number Diff line number Diff line // SPDX-License-Identifier: GPL-2.0-only /* * Copyright (c) 2014-2019, The Linux Foundation. All rights reserved. * Copyright (c) 2014-2020, The Linux Foundation. All rights reserved. * */ Loading Loading @@ -865,7 +865,7 @@ static void dbg_init_arch_data(void) * * In all cases we will run on the same cpu for the entire duration. */ void msm_jtag_save_state(void) void msm_jtag_save_state(bool is_hotcpu_cb) { int cpu; Loading @@ -875,13 +875,14 @@ void msm_jtag_save_state(void) /* ensure counter is updated before moving forward */ mb(); if (!is_hotcpu_cb) msm_jtag_etm_save_state(); if (dbg.save_restore_enabled) dbg_save_state(cpu); } EXPORT_SYMBOL(msm_jtag_save_state); void msm_jtag_restore_state(void) void msm_jtag_restore_state(bool is_hotcpu_cb) { int cpu; Loading @@ -907,6 +908,7 @@ void msm_jtag_restore_state(void) if (dbg.save_restore_enabled) dbg_restore_state(cpu); if (!is_hotcpu_cb) msm_jtag_etm_restore_state(); } EXPORT_SYMBOL(msm_jtag_restore_state); Loading @@ -925,13 +927,13 @@ static inline bool dbg_arch_supported(uint8_t arch) static int jtag_hotcpu_save_callback(unsigned int cpu) { msm_jtag_save_state(); msm_jtag_save_state(true); return 0; } static int jtag_hotcpu_restore_callback(unsigned int cpu) { msm_jtag_restore_state(); msm_jtag_restore_state(true); return 0; } Loading @@ -940,11 +942,11 @@ static int jtag_cpu_pm_callback(struct notifier_block *nfb, { switch (action) { case CPU_PM_ENTER: msm_jtag_save_state(); msm_jtag_save_state(false); break; case CPU_PM_ENTER_FAILED: case CPU_PM_EXIT: msm_jtag_restore_state(); msm_jtag_restore_state(false); break; } return NOTIFY_OK; Loading
include/soc/qcom/jtag.h +2 −2 Original line number Diff line number Diff line Loading @@ -12,8 +12,8 @@ struct notifier_block; #if defined(CONFIG_MSM_JTAG) || defined(CONFIG_MSM_JTAG_MM) || \ defined(CONFIG_MSM_JTAGV8) extern void msm_jtag_save_state(void); extern void msm_jtag_restore_state(void); extern void msm_jtag_save_state(bool is_hotcpu_cb); extern void msm_jtag_restore_state(bool is_hotcpu_cb); extern void msm_jtag_etm_save_state(void); extern void msm_jtag_etm_restore_state(void); extern bool msm_jtag_fuse_apps_access_disabled(void); Loading