Messages in this thread | | | Date | Wed, 4 Sep 2019 16:19:11 +0900 | From | Sergey Senozhatsky <> | Subject | Re: [PATCH] net/skbuff: silence warnings under memory pressure |
| |
On (09/04/19 08:54), Michal Hocko wrote: > I am sorry, I could have been more explicit when CCing you.
Oh, sorry! My bad!
> Sure the ratelimit is part of the problem. But I was more interested > in the potential livelock (infinite loop) mentioned by Qian Cai. It > is not important whether we generate one or more lines of output from > the softirq context as long as the printk generates more irq processing > which might end up doing the same. Is this really possible?
Hmm. I need to look at this more... wake_up_klogd() queues work only once on particular CPU: irq_work_queue(this_cpu_ptr(&wake_up_klogd_work));
bool irq_work_queue() { /* Only queue if not already pending */ if (!irq_work_claim(work)) return false;
__irq_work_queue_local(work); }
softirqs are processed in batches, right? The softirq batch can add XXXX lines to printk logbuf, but there will be only one PRINTK_PENDING_WAKEUP queued. Qian Cai mentioned that "net_rx_action softirqs again which are plenty due to connected via ssh etc." so the proportion still seems to be N:1 - we process N softirqs, add 1 printk irq_work.
But need to think more. Interesting question.
-ss
| |