net/smc: Fix error path in smc_init
authorYueHaibing <yuehaibing@huawei.com>
Wed, 26 Jun 2019 15:47:50 +0000 (17:47 +0200)
committerDavid S. Miller <davem@davemloft.net>
Wed, 26 Jun 2019 17:10:16 +0000 (10:10 -0700)
commit8c33bf1b0a9663d1742cb19ee71da46a1d8670dd
tree6b49ef1319ea4efc0838a85d71b746c3c1ba8e13
parent4480879251fb89b1c5585112b1ccc8c3333b41af
net/smc: Fix error path in smc_init

If register_pernet_subsys success in smc_init,
we should cleanup it in case any other error.

Fixes: 64e28b52c7a6 (net/smc: add pnet table namespace support")
Signed-off-by: YueHaibing <yuehaibing@huawei.com>
Signed-off-by: Ursula Braun <ubraun@linux.ibm.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/smc/af_smc.c