diff mbox

RDMA/ocrdma: remove a unused-label warning

Message ID 1411973983-7125-1-git-send-email-roy.qing.li@gmail.com (mailing list archive)
State Accepted, archived
Headers show

Commit Message

roy.qing.li@gmail.com Sept. 29, 2014, 6:59 a.m. UTC
From: Li RongQing <roy.qing.li@gmail.com> 

If disable IPV6, and the warning will happen:
    drivers/infiniband/hw/ocrdma/ocrdma_main.c:650:1: warning: label ‘err_notifier6’ defined but not used [-Wunused-label]

Signed-off-by: Li RongQing <roy.qing.li@gmail.com>
---
 drivers/infiniband/hw/ocrdma/ocrdma_main.c |    2 ++
 1 file changed, 2 insertions(+)
diff mbox

Patch

diff --git a/drivers/infiniband/hw/ocrdma/ocrdma_main.c b/drivers/infiniband/hw/ocrdma/ocrdma_main.c
index 256a06b..c108623 100644
--- a/drivers/infiniband/hw/ocrdma/ocrdma_main.c
+++ b/drivers/infiniband/hw/ocrdma/ocrdma_main.c
@@ -646,8 +646,10 @@  static int __init ocrdma_init_module(void)
 	return 0;
 
 err_be_reg:
+#if IS_ENABLED(CONFIG_IPV6)
 	ocrdma_unregister_inet6addr_notifier();
 err_notifier6:
+#endif
 	ocrdma_unregister_inetaddr_notifier();
 	return status;
 }