13 Sep, 2011
1 commit
-
The logbuf_lock lock can be taken in atomic context and therefore
cannot be preempted on -rt - annotate it.In mainline this change documents the low level nature of
the lock - otherwise there's no functional difference. Lockdep
and Sparse checking will work as usual.Signed-off-by: Thomas Gleixner
[ merged and fixed it ]
Signed-off-by: Ingo Molnar
27 May, 2011
1 commit
-
As reported by Ingo Molnar, we still have configuration combinations
where use of the WARN_RATELIMIT interfaces break the build because
dependencies don't get met.Instead of going down the long road of trying to make it so that
ratelimit.h can get included by kernel.h or asm-generic/bug.h,
just move the interface into ratelimit.h and make users have
to include that.Reported-by: Ingo Molnar
Signed-off-by: David S. Miller
Acked-by: Randy Dunlap
27 Oct, 2010
1 commit
-
Adding declaration of printk_ratelimit_state in ratelimit.h removes
potential build breakage and following sparse warning:kernel/printk.c:1426:1: warning: symbol 'printk_ratelimit_state' was not declared. Should it be static?
[akpm@linux-foundation.org: remove unneeded ifdef]
Signed-off-by: Namhyung Kim
Cc: Ingo Molnar
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds
25 May, 2010
1 commit
-
For now, all users of ratelimit_state allocates it statically, so
DEFINE_RATELIMIT_STATE() is enough. But, I want to use ratelimit_state
for fs, i.e. per super_block to suppress too many error reports.So, this adds ratelimit_state_init() to initialize ratelimite_state
which is dynamically allocated, instead of opencoding.Signed-off-by: OGAWA Hirofumi
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds
23 Oct, 2009
1 commit
-
Today I got:
[39648.224782] Registered led device: iwl-phy0::TX
[40676.545099] __ratelimit: 246 callbacks suppressed
[40676.545103] abcdef[23675]: segfault at 0 ...as you can see the ratelimit message contains a function prefix.
Since this is always __ratelimit, this wont help much.This patch changes __ratelimit and printk_ratelimit to print the
function name that calls ratelimit.This will pinpoint the responsible function, as long as not several
different places call ratelimit with the same ratelimit state at
the same time. In that case we catch only one random function that
calls ratelimit after the wait period.Signed-off-by: Christian Borntraeger
Cc: Dave Young
Cc: Linus Torvalds
CC: Andrew Morton
LKML-Reference:
Signed-off-by: Ingo Molnar
22 Sep, 2009
1 commit
-
I'd like to use printk_ratelimit() in atomic context, but that's
not possible right now due to the spinlock usage this commit
introduced more than a year ago:717115e: printk ratelimiting rewrite
As a first step push the lock into the ratelimit state structure.
This allows us to deal with locking failures to be considered as an
event related to that state being too busy.Also clean up the code a bit (without changing functionality):
- tidy up the definitions
- clean up the code flow
This also shrinks the code a tiny bit:
text data bss dec hex filename
264 0 4 268 10c ratelimit.o.before
255 0 0 255 ff ratelimit.o.after( Whole-kernel data size got a bit larger, because we have
two ratelimit-state data structures right now. )Cc: Peter Zijlstra
Cc: Andrew Morton
Cc: Linus Torvalds
Cc: David S. Miller
LKML-Reference:
Signed-off-by: Ingo Molnar
13 Nov, 2008
1 commit
-
It mistakenly assumes that a static local in an inlined function is a
kernel-wide singleton. It also has no callers, so let's remove it.Cc: Dave Young
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds
26 Jul, 2008
1 commit
-
All ratelimit user use same jiffies and burst params, so some messages
(callbacks) will be lost.For example:
a call printk_ratelimit(5 * HZ, 1)
b call printk_ratelimit(5 * HZ, 1) before the 5*HZ timeout of a, then b will
will be supressed.- rewrite __ratelimit, and use a ratelimit_state as parameter. Thanks for
hints from andrew.- Add WARN_ON_RATELIMIT, update rcupreempt.h
- remove __printk_ratelimit
- use __ratelimit in net_ratelimit
Signed-off-by: Dave Young
Cc: "David S. Miller"
Cc: "Paul E. McKenney"
Cc: Dave Young
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds