net: ieee802154: ca8210: Call _xmit_error() when a transmission fails

ieee802154_xmit_error() is the right helper to call when a transmission
has failed. Let's use it instead of open-coding it.

Signed-off-by: Miquel Raynal <miquel.raynal@bootlin.com>
Acked-by: Alexander Aring <aahringo@redhat.com>
Link: https://lore.kernel.org/r/20220407100903.1695973-11-miquel.raynal@bootlin.com
Signed-off-by: Stefan Schmidt <stefan@datenfreihafen.org>
This commit is contained in:
Miquel Raynal 2022-04-07 12:09:03 +02:00 committed by Stefan Schmidt
parent ab191c1cff
commit 510ce58632

View File

@ -1729,8 +1729,7 @@ static int ca8210_async_xmit_complete(
status
);
if (status != IEEE802154_TRANSACTION_OVERFLOW) {
dev_kfree_skb_any(priv->tx_skb);
ieee802154_wake_queue(priv->hw);
ieee802154_xmit_error(priv->hw, priv->tx_skb, status);
return 0;
}
}