File tree Expand file tree Collapse file tree 2 files changed +7
-3
lines changed Expand file tree Collapse file tree 2 files changed +7
-3
lines changed Original file line number Diff line number Diff line change @@ -5592,7 +5592,7 @@ static const struct file_operations ftrace_notrace_fops = {
5592
5592
static DEFINE_MUTEX (graph_lock );
5593
5593
5594
5594
struct ftrace_hash __rcu * ftrace_graph_hash = EMPTY_HASH ;
5595
- struct ftrace_hash * ftrace_graph_notrace_hash = EMPTY_HASH ;
5595
+ struct ftrace_hash __rcu * ftrace_graph_notrace_hash = EMPTY_HASH ;
5596
5596
5597
5597
enum graph_filter_type {
5598
5598
GRAPH_FILTER_NOTRACE = 0 ,
Original file line number Diff line number Diff line change @@ -965,7 +965,7 @@ extern void __trace_graph_return(struct trace_array *tr,
965
965
966
966
#ifdef CONFIG_DYNAMIC_FTRACE
967
967
extern struct ftrace_hash __rcu * ftrace_graph_hash ;
968
- extern struct ftrace_hash * ftrace_graph_notrace_hash ;
968
+ extern struct ftrace_hash __rcu * ftrace_graph_notrace_hash ;
969
969
970
970
static inline int ftrace_graph_addr (struct ftrace_graph_ent * trace )
971
971
{
@@ -1018,10 +1018,14 @@ static inline void ftrace_graph_addr_finish(struct ftrace_graph_ret *trace)
1018
1018
static inline int ftrace_graph_notrace_addr (unsigned long addr )
1019
1019
{
1020
1020
int ret = 0 ;
1021
+ struct ftrace_hash * notrace_hash ;
1021
1022
1022
1023
preempt_disable_notrace ();
1023
1024
1024
- if (ftrace_lookup_ip (ftrace_graph_notrace_hash , addr ))
1025
+ notrace_hash = rcu_dereference_protected (ftrace_graph_notrace_hash ,
1026
+ !preemptible ());
1027
+
1028
+ if (ftrace_lookup_ip (notrace_hash , addr ))
1025
1029
ret = 1 ;
1026
1030
1027
1031
preempt_enable_notrace ();
You can’t perform that action at this time.
0 commit comments