Suggested-by: Dan Carpenter <dan.carpenter@xxxxxxxxxx> Signed-off-by: Eli Billauer <eli.billauer@xxxxxxxxx> --- drivers/staging/xillybus/xillybus_core.c | 10 ++-------- 1 files changed, 2 insertions(+), 8 deletions(-) diff --git a/drivers/staging/xillybus/xillybus_core.c b/drivers/staging/xillybus/xillybus_core.c index 3e14198..3050815 100644 --- a/drivers/staging/xillybus/xillybus_core.c +++ b/drivers/staging/xillybus/xillybus_core.c @@ -2115,17 +2115,11 @@ EXPORT_SYMBOL(xillybus_endpoint_remove); static int __init xillybus_init(void) { - int rc = 0; - mutex_init(&ep_list_lock); xillybus_class = class_create(THIS_MODULE, xillyname); - if (IS_ERR(xillybus_class)) { - rc = PTR_ERR(xillybus_class); - pr_warn("Failed to register class xillybus\n"); - - return rc; - } + if (IS_ERR(xillybus_class)) + return PTR_ERR(xillybus_class); xillybus_wq = alloc_workqueue(xillyname, 0, 0); if (!xillybus_wq) { -- 1.7.2.3 _______________________________________________ devel mailing list devel@xxxxxxxxxxxxxxxxxxxxxx http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel