On 2022-09-26 17:03:48 [+0200], Vlastimil Babka wrote: > > Doing the "p = kmalloc(sizeof(*p), GFP_ATOMIC);" from an atomic context > > is also a problem nowadays. Such code should be fixed across the kernel > > because of PREEMPT_RT support. You should make sure that the context in question is atomic on PREEMPT_RT before fixing it. My guess here is that it is average the softirq (NAPI) callback which is fine. > But the "atomic context" here is different, no? Calling kmalloc() from IRQ > handlers AFAIK is ok as IRQ handlers are threaded on PREEMPT_RT. Calling it > inside an local_irq_disable() would be a problem on the other hand. But then > under e.g. spin_lock_irqsave() could be ok as those don't really disable > irqs on RT. correct. Sebastian