lists.openwall.net | lists / announce owl-users owl-dev john-users john-dev passwdqc-users yescrypt popa3d-users / oss-security kernel-hardening musl sabotage tlsify passwords / crypt-dev xvendor / Bugtraq Full-Disclosure linux-kernel linux-netdev linux-ext4 linux-hardening linux-cve-announce PHC | |
Open Source and information security mailing list archives
| ||
|
Message-Id: <1283602121-11443-1-git-send-email-jslaby@suse.cz> Date: Sat, 4 Sep 2010 14:08:41 +0200 From: Jiri Slaby <jslaby@...e.cz> To: davem@...emloft.net Cc: linux-kernel@...r.kernel.org, jirislaby@...il.com, netdev@...r.kernel.org, Debashis Dutt <ddutt@...cade.com>, Rasesh Mody <rmody@...cade.com> Subject: [PATCH 1/1] NET: bna, fix lock imbalance bnad_set_rx_mode omit to unlock bna_lock on one fail path. Fix that. Signed-off-by: Jiri Slaby <jslaby@...e.cz> Cc: Debashis Dutt <ddutt@...cade.com> Cc: Rasesh Mody <rmody@...cade.com> Cc: David S. Miller <davem@...emloft.net> --- drivers/net/bna/bnad.c | 3 ++- 1 files changed, 2 insertions(+), 1 deletions(-) diff --git a/drivers/net/bna/bnad.c b/drivers/net/bna/bnad.c index cbc1d56..a1a449a 100644 --- a/drivers/net/bna/bnad.c +++ b/drivers/net/bna/bnad.c @@ -2706,7 +2706,7 @@ bnad_set_rx_mode(struct net_device *netdev) kzalloc((mc_count + 1) * ETH_ALEN, GFP_ATOMIC); if (!mcaddr_list) - return; + goto unlock; memcpy(&mcaddr_list[0], &bnad_bcast_addr[0], ETH_ALEN); @@ -2719,6 +2719,7 @@ bnad_set_rx_mode(struct net_device *netdev) /* Should we enable BNAD_CF_ALLMULTI for err != 0 ? */ kfree(mcaddr_list); } +unlock: spin_unlock_irqrestore(&bnad->bna_lock, flags); } -- 1.7.2.2 -- To unsubscribe from this list: send the line "unsubscribe netdev" in the body of a message to majordomo@...r.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
Powered by blists - more mailing lists