summaryrefslogtreecommitdiff
path: root/lib/test_string.c
diff options
context:
space:
mode:
authorKees Cook <keescook@chromium.org>2019-07-16 16:27:24 -0700
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2019-08-06 19:06:51 +0200
commit8e087a2abaf8a1d11bba8770c7e4e73572b52eff (patch)
tree3e6be7fd6557a78ef7af9af6205c22fe9a6064b5 /lib/test_string.c
parent439c79ed7718ee509421ca201a1f1a009bc403d0 (diff)
lib/test_overflow.c: avoid tainting the kernel and fix wrap size
[ Upstream commit 8e060c21ae2c265a2b596e9e7f9f97ec274151a4 ] This adds __GFP_NOWARN to the kmalloc()-portions of the overflow test to avoid tainting the kernel. Additionally fixes up the math on wrap size to be architecture and page size agnostic. Link: http://lkml.kernel.org/r/201905282012.0A8767E24@keescook Fixes: ca90800a91ba ("test_overflow: Add memory allocation overflow tests") Signed-off-by: Kees Cook <keescook@chromium.org> Reported-by: Randy Dunlap <rdunlap@infradead.org> Suggested-by: Rasmus Villemoes <linux@rasmusvillemoes.dk> Cc: Joe Perches <joe@perches.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> Signed-off-by: Sasha Levin <sashal@kernel.org>
Diffstat (limited to 'lib/test_string.c')
0 files changed, 0 insertions, 0 deletions