spin_lock_irqsave(&bus->txqlock, flags);
if (!brcmf_c_prec_enq(bus->sdiodev->dev, &bus->txq, pkt, prec)) {
skb_pull(pkt, SDPCM_HDRLEN);
- brcmf_txcomplete(bus->sdiodev->dev, pkt, false);
brcmf_err("out of bus->txq !!!\n");
ret = -ENOSR;
} else {
int fifo = BRCMF_FWS_FIFO_BCMC;
bool multicast = is_multicast_ether_addr(eh->h_dest);
bool pae = eh->h_proto == htons(ETH_P_PAE);
+ int ret;
/* determine the priority */
if (!skb->priority)
brcmf_proto_hdrpush(drvr, ifp->ifidx, 0, skb);
/* Use bus module to send data frame */
- return brcmf_bus_txdata(drvr->bus_if, skb);
+ ret = brcmf_bus_txdata(drvr->bus_if, skb);
+ if (ret < 0)
+ brcmf_txfinalize(drvr, skb, false);
+ return ret;
}
/* set control buffer information */