From be3b5ae235c088145c0d9437e2436b26936ebba7 Mon Sep 17 00:00:00 2001 From: Marco Elver Date: Fri, 22 Jan 2021 09:18:42 +0000 Subject: [PATCH] FROMGIT: kfence: fix typo in test Fix a typo/accidental copy-paste that resulted in the obviously incorrect 'GFP_KERNEL * 2' expression. Link: https://lkml.kernel.org/r/X9lHQExmHGvETxY4@elver.google.com Signed-off-by: Marco Elver Reported-by: kernel test robot Acked-by: Alexander Potapenko Signed-off-by: Andrew Morton Bug: 177201466 (cherry picked from commit 161c8770c371ca3992565d8f1db1ad4a88a562e9 https://github.com/hnaz/linux-mm v5.11-rc4-mmots-2021-01-21-20-10) Test: CONFIG_KFENCE_KUNIT_TEST=y passes on Cuttlefish Signed-off-by: Alexander Potapenko Change-Id: I4c26617c64fd2e6d410e6e793bb0eebf8fc87e55 --- mm/kfence/kfence_test.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mm/kfence/kfence_test.c b/mm/kfence/kfence_test.c index 1433a35a1644..f57c61c833e6 100644 --- a/mm/kfence/kfence_test.c +++ b/mm/kfence/kfence_test.c @@ -665,7 +665,7 @@ static void test_krealloc(struct kunit *test) for (; i < size * 3; i++) /* Fill to extra bytes. */ buf[i] = i + 1; - buf = krealloc(buf, size * 2, GFP_KERNEL * 2); /* Shrink. */ + buf = krealloc(buf, size * 2, GFP_KERNEL); /* Shrink. */ KUNIT_EXPECT_GE(test, ksize(buf), size * 2); for (i = 0; i < size * 2; i++) KUNIT_EXPECT_EQ(test, buf[i], (char)(i + 1));