mirror of
https://mirrors.bfsu.edu.cn/git/linux.git
synced 2024-12-15 15:04:27 +08:00
drivers/net/ethernet/broadcom/bnx2x/bnx2x_sriov.c: remove null test before kfree
Fix checkpatch warning: WARNING: kfree(NULL) is safe this check is probably not required Cc: Ariel Elior <ariele@broadcom.com> Cc: netdev@vger.kernel.org Signed-off-by: Fabian Frederick <fabf@skynet.be> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
parent
44f71cef92
commit
88729dd189
@ -597,8 +597,7 @@ 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);
|
||||
kfree(mc);
|
||||
return rc;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user