All rollback failures should result in freeing of the sk_buff
by calling brcmf_txfinalize().
Reviewed-by: Hante Meuleman <meuleman@broadcom.com>
Reviewed-by: Pieter-Paul Giesberts <pieterpg@broadcom.com>
Signed-off-by: Arend van Spriel <arend@broadcom.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
/* free the hanger slot */
brcmf_fws_hanger_poppkt(&fws->hanger, hslot,
&pktout, true);
- brcmf_txfinalize(fws->drvr, skb, false);
rc = -EINVAL;
goto fail;
}
fail:
- if (rc)
+ if (rc) {
+ brcmf_txfinalize(fws->drvr, skb, false);
fws->stats.rollback_failed++;
- else
+ } else
fws->stats.rollback_success++;
return rc;
}