net/mlx4: fix small memory leak on error
"work" needs to be freed before returning on this error path. Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
parent
4bc41b84e9
commit
9caf83c32b
|
@ -1572,6 +1572,7 @@ int mlx4_master_immediate_activate_vlan_qos(struct mlx4_priv *priv,
|
|||
vp_admin->default_vlan,
|
||||
&admin_vlan_ix);
|
||||
if (err) {
|
||||
kfree(work);
|
||||
mlx4_warn((&priv->dev),
|
||||
"No vlan resources slave %d, port %d\n",
|
||||
slave, port);
|
||||
|
|
Loading…
Reference in New Issue