Re: [PATCH] NVMe: Fix error handling of class_create("nvme")

From: Keith Busch
Date: Mon Mar 16 2015 - 13:23:42 EST


On Fri, 6 Mar 2015, Alexey Khoroshilov wrote:
class_create() returns ERR_PTR on failure,
so IS_ERR() should be used instead of check for NULL.

Found by Linux Driver Verification project (linuxtesting.org).

Signed-off-by: Alexey Khoroshilov <khoroshilov@xxxxxxxxx>

Thanks for the fix.

Acked-by: Keith Busch <keith.busch@xxxxxxxxx>
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/