Re: [RFC] Printk deadlock in bpf trace called from scheduler context

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon, Jul 29, 2024 at 01:46:09PM +0200, Radoslaw Zielonek wrote:
> I am currently working on a syzbot-reported bug where bpf
> is called from trace_sched_switch. In this scenario, we are still within
> the scheduler context, and calling printk can create a deadlock.
> 
> I am uncertain about the best approach to fix this issue.

It's been like this forever, it doesn't need fixing, because tracepoints
shouldn't be doing printk() in the first place.

> Should we simply forbid such calls, or perhaps we should replace printk
> with printk_deferred in the bpf where we are still in scheduler context?

Not doing printk() is best.




[Index of Archives]     [Linux Samsung SoC]     [Linux Rockchip SoC]     [Linux Actions SoC]     [Linux for Synopsys ARC Processors]     [Linux NFS]     [Linux NILFS]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]


  Powered by Linux