On Wed, 2016-06-29 at 11:56 +0200, Borislav Petkov wrote: > From: Borislav Petkov <[email protected]> > > Extend the ratelimiting facility to print the amount of suppressed lines > when it is being released. > > Separated from a previous patch by Linus. [] > diff --git a/include/linux/ratelimit.h b/include/linux/ratelimit.h [] > @@ -15,6 +19,7 @@ struct ratelimit_state { > int printed; > int missed; > unsigned long begin; > + unsigned long flags; > };
There are a lot of ratelimit_state structs used in the kernel. Every printk like <foo>_ratelimited uses a static one. It'd likely be better to reduce the struct ratelimit_state size rather than expand it. burst and printed could probably become s16 or even s8. flags could be u8 until necessary to expand.

