]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
ring-buffer: Fix return value check in test_ringbuffer()
authorWei Yongjun <yongjun_wei@trendmicro.com.cn>
Fri, 17 Jun 2016 17:33:59 +0000 (17:33 +0000)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 12 Apr 2017 10:42:06 +0000 (12:42 +0200)
commitab23a82a01763c4857a005ad2482125a61cc22e4
tree9f47f17062d1687795343dc730e665ab5d2b6c21
parent24d108e4dfecdba74470889b54d4ceab6ee24577
ring-buffer: Fix return value check in test_ringbuffer()

commit 62277de758b155dc04b78f195a1cb5208c37b2df upstream.

In case of error, the function kthread_run() returns ERR_PTR()
and never returns NULL. The NULL test in the return value check
should be replaced with IS_ERR().

Link: http://lkml.kernel.org/r/1466184839-14927-1-git-send-email-weiyj_lk@163.com
Fixes: 6c43e554a ("ring-buffer: Add ring buffer startup selftest")
Signed-off-by: Wei Yongjun <yongjun_wei@trendmicro.com.cn>
Signed-off-by: Steven Rostedt (VMware) <rostedt@goodmis.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
kernel/trace/ring_buffer.c