lkml.org 
[lkml]   [2019]   [Mar]   [20]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
Date
SubjectRe: printk_ratelimited() && proc/sys/kernel/printk_ratelimit*
On Wed, Mar 20, 2019 at 10:03 AM Oleg Nesterov <oleg@redhat.com> wrote:
>
> At the same time, printk_ratelimited() uses a static ratelimit_state, so user-
> space can't override the default DEFAULT_RATELIMIT_.* numbers.
>
> Isn't it strange? Shouldn't printk_ratelimited() use printk_ratelimit_state ?

No it shouldn't.

Each printk_ratelimited() is independent, and that's very much on purpose.

One screaming printk shouldn't mean that every *other* printk would be shut up.

That said, it's likely true that nobody should really use
printk_ratelimited() anyway. But if two different users do, they
definitely shouldn't then affect each other.

Linus

\
 
 \ /
  Last update: 2019-03-20 18:32    [W:0.064 / U:0.608 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site