[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <80a3455a5e65f5eb911d4863ffb3b7cd1d0b26bf.1487365317.git.pavel.belous@aquantia.com>
Date: Sat, 18 Feb 2017 00:07:28 +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 v2 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>
---
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 a153750..1bf5975 100644
--- a/drivers/net/ethernet/aquantia/atlantic/aq_nic.c
+++ b/drivers/net/ethernet/aquantia/atlantic/aq_nic.c
@@ -931,7 +931,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) {
@@ -956,8 +956,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