Some more tracing fixes for 6.3:
- Reset direct->addr back to its original value on error in updating the direct trampoline code. - Make lastcmd_mutex static. -----BEGIN PGP SIGNATURE----- iIoEABYIADIWIQRRSw7ePDh/lE+zeZMp5XQQmuv6qgUCZDB1JhQccm9zdGVkdEBn b29kbWlzLm9yZwAKCRAp5XQQmuv6qqihAQC6vNG/QFthBVj6++2O5+h+AGe3mIIv +SVs3GpL+Gr1MAEA/Q+zK7niLHrWSMsyq3eYY63J10AhI/ZHuFm28MbjKQM= =khcF -----END PGP SIGNATURE----- Merge tag 'trace-v6.3-rc5-2' of git://git.kernel.org/pub/scm/linux/kernel/git/trace/linux-trace Pull tracing fixes from Steven Rostedt: "A couple more minor fixes: - Reset direct->addr back to its original value on error in updating the direct trampoline code - Make lastcmd_mutex static" * tag 'trace-v6.3-rc5-2' of git://git.kernel.org/pub/scm/linux/kernel/git/trace/linux-trace: tracing/synthetic: Make lastcmd_mutex static ftrace: Fix issue that 'direct->addr' not restored in modify_ftrace_direct()
This commit is contained in:
Коммит
1a8a804a4f
|
@ -5667,12 +5667,15 @@ int modify_ftrace_direct(unsigned long ip,
|
|||
ret = 0;
|
||||
}
|
||||
|
||||
if (unlikely(ret && new_direct)) {
|
||||
direct->count++;
|
||||
list_del_rcu(&new_direct->next);
|
||||
synchronize_rcu_tasks();
|
||||
kfree(new_direct);
|
||||
ftrace_direct_func_count--;
|
||||
if (ret) {
|
||||
direct->addr = old_addr;
|
||||
if (unlikely(new_direct)) {
|
||||
direct->count++;
|
||||
list_del_rcu(&new_direct->next);
|
||||
synchronize_rcu_tasks();
|
||||
kfree(new_direct);
|
||||
ftrace_direct_func_count--;
|
||||
}
|
||||
}
|
||||
|
||||
out_unlock:
|
||||
|
|
|
@ -44,7 +44,7 @@ enum { ERRORS };
|
|||
|
||||
static const char *err_text[] = { ERRORS };
|
||||
|
||||
DEFINE_MUTEX(lastcmd_mutex);
|
||||
static DEFINE_MUTEX(lastcmd_mutex);
|
||||
static char *last_cmd;
|
||||
|
||||
static int errpos(const char *str)
|
||||
|
|
Загрузка…
Ссылка в новой задаче