staging: most: fix error comparison
device_create() returns ERR_PTR on error, it does not return NULL. Signed-off-by: Sudip Mukherjee <sudip@vectorindia.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
parent
0833ac7db0
commit
17ac98ac73
|
@ -1869,7 +1869,7 @@ static int __init most_init(void)
|
|||
|
||||
class_glue_dir =
|
||||
device_create(most_class, NULL, 0, NULL, "mostcore");
|
||||
if (!class_glue_dir)
|
||||
if (IS_ERR(class_glue_dir))
|
||||
goto exit_driver;
|
||||
|
||||
most_aim_kset =
|
||||
|
|
Loading…
Reference in New Issue