Skip to content
Commit 6cd18453 authored by Wei Yongjun's avatar Wei Yongjun Committed by Borislav Petkov
Browse files

EDAC/sifive: Fix return value check in ecc_register()



In case of error, the function edac_device_alloc_ctl_info() returns a
NULL pointer, not ERR_PTR(). Replace the IS_ERR() test in the return
value check with a NULL test.

Fixes: 91abaeaa ("EDAC/sifive: Add EDAC platform driver for SiFive SoCs")
Signed-off-by: default avatarWei Yongjun <weiyongjun1@huawei.com>
Signed-off-by: default avatarBorislav Petkov <bp@suse.de>
Link: https://lkml.kernel.org/r/20200115150303.112627-1-weiyongjun1@huawei.com
parent a651c6c6
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