[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <894f21bfee34a1e15c462efb56ccf323cbd1c504.1487618263.git.pavel.belous@aquantia.com>
Date: Mon, 20 Feb 2017 22:36:44 +0300
From: Pavel Belous <Pavel.Belous@...antia.com>
To: "David S . Miller" <davem@...emloft.net>
Cc: netdev@...r.kernel.org,
Simon Edelhaus <Simon.Edelhaus@...antia.com>,
Alexey Andriyanov <Alexey.Andriyanov@...antia.com>,
Lino Sanfilippo <LinoSanfilippo@....de>,
Pavel Belous <pavel.belous@...antia.com>
Subject: [PATCH net-next v4 06/12] net: ethernet: aquantia: Fixed missing rtnl_unlock.
From: Pavel Belous <pavel.belous@...antia.com>
rtnl_unlock should be called if error occurred.
Signed-off-by: Pavel Belous <pavel.belous@...antia.com>
Reviewed-by: Lino Sanfilippo <LinoSanfilippo@....de>
---
drivers/net/ethernet/aquantia/atlantic/aq_nic.c | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/drivers/net/ethernet/aquantia/atlantic/aq_nic.c b/drivers/net/ethernet/aquantia/atlantic/aq_nic.c
index 4b8d074..646314c 100644
--- a/drivers/net/ethernet/aquantia/atlantic/aq_nic.c
+++ b/drivers/net/ethernet/aquantia/atlantic/aq_nic.c
@@ -932,7 +932,7 @@ int aq_nic_change_pm_state(struct aq_nic_s *self, pm_message_t *pm_msg)
if (!netif_running(self->ndev)) {
err = 0;
- goto err_exit;
+ goto out;
}
rtnl_lock();
if (pm_msg->event & PM_EVENT_SLEEP || pm_msg->event & PM_EVENT_FREEZE) {
@@ -957,8 +957,9 @@ int aq_nic_change_pm_state(struct aq_nic_s *self, pm_message_t *pm_msg)
netif_device_attach(self->ndev);
netif_tx_start_all_queues(self->ndev);
}
- rtnl_unlock();
err_exit:
+ rtnl_unlock();
+out:
return err;
}
--
2.7.4
Powered by blists - more mailing lists