[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <f35a2bff-cd99-812c-8940-1046bc75d130@gmx.de>
Date: Wed, 15 Feb 2017 22:02:00 +0100
From: Lino Sanfilippo <LinoSanfilippo@....de>
To: Pavel Belous <Pavel.Belous@...antia.com>,
"David S . Miller" <davem@...emloft.net>
Cc: netdev@...r.kernel.org,
Simon Edelhaus <Simon.Edelhaus@...antia.com>,
Alexey Andriyanov <Alexey.Andriyanov@...antia.com>
Subject: Re: [PATCH net-next 06/13] net: ethernet: aquantia: Fixed missing
rtnl_unlock.
On 15.02.2017 21:01, Pavel Belous wrote:
> 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;
> }
>
Reviewed-by: Lino Sanfilippo <LinoSanfilippo@....de>
Regards,
Lino
Powered by blists - more mailing lists