twx-linux/include
Jiri Slaby 1b011e2f13 ratelimit: fix WARN_ON_RATELIMIT return value
The macro is to be used similarly as WARN_ON as:

  if (WARN_ON_RATELIMIT(condition, state))
	do_something();

One would expect only 'condition' to affect the 'if', but
WARN_ON_RATELIMIT does internally only:

  WARN_ON((condition) && __ratelimit(state))

So the 'if' is affected by the ratelimiting state too.  Fix this by
returning 'condition' in any case.

Note that nobody uses WARN_ON_RATELIMIT yet, so there is nothing to
worry about.  But I was about to use it and was a bit surprised.

Link: http://lkml.kernel.org/r/20161215093224.23126-1-jslaby@suse.cz
Signed-off-by: Jiri Slaby <jslaby@suse.cz>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2016-12-20 09:48:47 -08:00
..
acpi IOMMU Updates for Linux v4.10 2016-12-15 12:24:14 -08:00
asm-generic Merge branch 'kbuild' of git://git.kernel.org/pub/scm/linux/kernel/git/mmarek/kbuild 2016-12-17 16:24:13 -08:00
clocksource
crypto This pull contains one set of changes: a conversion of the crypto DocBook 2016-12-17 16:00:34 -08:00
drm This pull request brings in VEC (TV-out) support for vc4, along with a 2016-12-13 12:05:12 +10:00
dt-bindings ARM: SoC driver updates for v4.10 2016-12-15 16:03:25 -08:00
keys
kvm
linux ratelimit: fix WARN_ON_RATELIMIT return value 2016-12-20 09:48:47 -08:00
math-emu
media
memory
misc
net Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net 2016-12-17 20:17:04 -08:00
pcmcia
ras
rdma Merge branches 'misc', 'qedr', 'reject-helpers', 'rxe' and 'srp' into merge-test 2016-12-14 14:44:47 -05:00
rxrpc
scsi linux: drop __bitwise__ everywhere 2016-12-16 00:13:41 +02:00
soc powerpc updates for 4.10 2016-12-16 09:26:42 -08:00
sound sound updates for 4.10-rc1 2016-12-14 11:14:28 -08:00
target linux: drop __bitwise__ everywhere 2016-12-16 00:13:41 +02:00
trace Merge branch 'for-linus-4.10' of git://git.kernel.org/pub/scm/linux/kernel/git/mason/linux-btrfs 2016-12-16 10:53:01 -08:00
uapi media updates for v4.10-rc1 2016-12-16 09:39:16 -08:00
video
xen xen: features and fixes for 4.10 rc0 2016-12-13 16:07:55 -08:00
Kbuild