* [PATCH net] sfc: remove duplicate up_write on VF filter_sem
@ 2017-06-20 12:08 Edward Cree
2017-06-20 19:40 ` David Miller
0 siblings, 1 reply; 2+ messages in thread
From: Edward Cree @ 2017-06-20 12:08 UTC (permalink / raw)
To: linux-net-drivers, davem; +Cc: netdev
Somehow two copies of the line 'up_write(&vf->efx->filter_sem);' got into
efx_ef10_sriov_set_vf_vlan(). This would put the mutex in a bad state and
cause all subsequent down attempts to hang.
Fixes: 671b53eec2ed ("sfc: Ensure down_write(&filter_sem) and up_write() are matched before calling efx_net_open()")
Signed-off-by: Edward Cree <ecree@solarflare.com>
---
This should probably go to stable kernels as well.
drivers/net/ethernet/sfc/ef10_sriov.c | 2 --
1 file changed, 2 deletions(-)
diff --git a/drivers/net/ethernet/sfc/ef10_sriov.c b/drivers/net/ethernet/sfc/ef10_sriov.c
index b7e4345..019cef1 100644
--- a/drivers/net/ethernet/sfc/ef10_sriov.c
+++ b/drivers/net/ethernet/sfc/ef10_sriov.c
@@ -661,8 +661,6 @@ int efx_ef10_sriov_set_vf_vlan(struct efx_nic *efx, int vf_i, u16 vlan,
up_write(&vf->efx->filter_sem);
mutex_unlock(&vf->efx->mac_lock);
- up_write(&vf->efx->filter_sem);
-
rc2 = efx_net_open(vf->efx->net_dev);
if (rc2)
goto reset_nic;
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH net] sfc: remove duplicate up_write on VF filter_sem
2017-06-20 12:08 [PATCH net] sfc: remove duplicate up_write on VF filter_sem Edward Cree
@ 2017-06-20 19:40 ` David Miller
0 siblings, 0 replies; 2+ messages in thread
From: David Miller @ 2017-06-20 19:40 UTC (permalink / raw)
To: ecree; +Cc: linux-net-drivers, netdev
From: Edward Cree <ecree@solarflare.com>
Date: Tue, 20 Jun 2017 13:08:51 +0100
> Somehow two copies of the line 'up_write(&vf->efx->filter_sem);' got into
> efx_ef10_sriov_set_vf_vlan(). This would put the mutex in a bad state and
> cause all subsequent down attempts to hang.
>
> Fixes: 671b53eec2ed ("sfc: Ensure down_write(&filter_sem) and up_write() are matched before calling efx_net_open()")
> Signed-off-by: Edward Cree <ecree@solarflare.com>
Applied and queued up for -stable.
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2017-06-20 19:40 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-06-20 12:08 [PATCH net] sfc: remove duplicate up_write on VF filter_sem Edward Cree
2017-06-20 19:40 ` David Miller
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).