On 10.06.21 10:54, Philippe Gerum wrote:
> 
> Jan Kiszka <[email protected]> writes:
> 
>> On 10.06.21 09:29, Philippe Gerum via Xenomai wrote:
>>> From: Philippe Gerum <[email protected]>
>>>
>>> Signed-off-by: Philippe Gerum <[email protected]>
>>> ---
>>>  kernel/trace/trace_preemptirq.c | 8 ++++++++
>>>  1 file changed, 8 insertions(+)
>>>
>>> diff --git a/kernel/trace/trace_preemptirq.c 
>>> b/kernel/trace/trace_preemptirq.c
>>> index 261ea4101d018ac..2b4110cf6ea2824 100644
>>> --- a/kernel/trace/trace_preemptirq.c
>>> +++ b/kernel/trace/trace_preemptirq.c
>>> @@ -124,6 +124,8 @@ void trace_hardirqs_off_pipelined(void)
>>>     if (running_inband())
>>>             trace_hardirqs_off();
>>>  }
>>> +EXPORT_SYMBOL(trace_hardirqs_off_pipelined);
>>> +NOKPROBE_SYMBOL(trace_hardirqs_off_pipelined);
>>>  
>>>  void trace_hardirqs_on_pipelined(void)
>>>  {
>>> @@ -142,6 +144,8 @@ void trace_hardirqs_on_pipelined(void)
>>>             unstall_inband_nocheck();
>>>     }
>>>  }
>>> +EXPORT_SYMBOL(trace_hardirqs_on_pipelined);
>>> +NOKPROBE_SYMBOL(trace_hardirqs_on_pipelined);
>>>  
>>>  #else
>>>  
>>> @@ -149,11 +153,15 @@ void trace_hardirqs_off_pipelined(void)
>>>  {
>>>     trace_hardirqs_off();
>>>  }
>>> +EXPORT_SYMBOL(trace_hardirqs_off_pipelined);
>>> +NOKPROBE_SYMBOL(trace_hardirqs_off_pipelined);
>>>  
>>>  void trace_hardirqs_on_pipelined(void)
>>>  {
>>>     trace_hardirqs_on();
>>>  }
>>> +EXPORT_SYMBOL(trace_hardirqs_on_pipelined);
>>> +NOKPROBE_SYMBOL(trace_hardirqs_on_pipelined);
>>>  
>>>  #endif
>>>  
>>>
>>
>> How about
>>
>> "blacklist pipeline tracepoints for kprobe"
>>
>> as subject? The symbols were already exported, but not in the right way.
>> The kernel says
>>
>> "Probing (trapping) such functions can cause a recursive trap (e.g.
>> double fault) or the nested probe handler may never be called.
>> Kprobes manages such functions as a blacklist."
>>
> 
> This is actually the export line which was missing for me. The kbprobe
> bits are a careless by-product.
> 

Oops, indeed - I somehow read

-EXPORT_SYMBOL(trace_hardirqs_on_pipelined);
+NOKPROBE_SYMBOL(trace_hardirqs_on_pipelined);

no idea why.

Jan

-- 
Siemens AG, T RDA IOT
Corporate Competence Center Embedded Linux

Reply via email to