Commit 9e5f1138 authored by Roel Kluin's avatar Roel Kluin Committed by Linus Torvalds

gru: allocation may fail in quicktest1()

The allocation may fail.
Signed-off-by: default avatarRoel Kluin <roel.kluin@gmail.com>
Acked-by: default avatarJack Steiner <steiner@sgi.com>
Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
parent f8679af8
...@@ -937,6 +937,8 @@ static int quicktest1(unsigned long arg) ...@@ -937,6 +937,8 @@ static int quicktest1(unsigned long arg)
/* Need 1K cacheline aligned that does not cross page boundary */ /* Need 1K cacheline aligned that does not cross page boundary */
p = kmalloc(4096, 0); p = kmalloc(4096, 0);
if (p == NULL)
return -ENOMEM;
mq = ALIGNUP(p, 1024); mq = ALIGNUP(p, 1024);
memset(mes, 0xee, sizeof(mes)); memset(mes, 0xee, sizeof(mes));
dw = mq; dw = mq;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment