projects
/
openwrt
/
staging
/
blogic.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
b5893a0
)
bnx2x: Fix possible memory leak on iov error flow
author
Yuval Mintz
<
[email protected]
>
Thu, 27 Mar 2014 11:46:37 +0000
(13:46 +0200)
committer
David S. Miller
<
[email protected]
>
Fri, 28 Mar 2014 20:18:02 +0000
(16:18 -0400)
Commit
2dc33bbc4
"bnx2x: Remove the sriov VFOP mechanism" introduced a possible
memory leak on the error flow during multicast filters configuration.
Reported-by: Dan Carpenter <
[email protected]
>
Signed-off-by: Yuval Mintz <
[email protected]
>
Signed-off-by: Ariel Elior <
[email protected]
>
Signed-off-by: David S. Miller <
[email protected]
>
drivers/net/ethernet/broadcom/bnx2x/bnx2x_sriov.c
patch
|
blob
|
history
diff --git
a/drivers/net/ethernet/broadcom/bnx2x/bnx2x_sriov.c
b/drivers/net/ethernet/broadcom/bnx2x/bnx2x_sriov.c
index df1507288b3c739e1fc7ab77e2dc9204aca49174..5c523b32db70126720dbf0b2914dcbb1a3391a2b 100644
(file)
--- a/
drivers/net/ethernet/broadcom/bnx2x/bnx2x_sriov.c
+++ b/
drivers/net/ethernet/broadcom/bnx2x/bnx2x_sriov.c
@@
-595,6
+595,8
@@
int bnx2x_vf_mcast(struct bnx2x *bp, struct bnx2x_virtf *vf,
rc = bnx2x_config_mcast(bp, &mcast, BNX2X_MCAST_CMD_DEL);
if (rc) {
BNX2X_ERR("Failed to remove multicasts\n");
+ if (mc)
+ kfree(mc);
return rc;
}