Search Linux Wireless

[PATCH v3 19/41] net: ieee802154: ca8210: Call the complete helper when a transmission is over

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



ieee802154_xmit_complete() is the right helper to call when a
transmission is over. The fact that it completed or not is not really a
question, but drivers must tell the core that the completion is over,
even if it was canceled. Do not call ieee802154_wake_queue() manually,
in order to let full control of this task to the core.

Here the two paths are equivalent of calling *_xmit_complete() with its
ifs_handling parameter set to true or false, so let's use it instead of
open coding it.

Signed-off-by: Miquel Raynal <miquel.raynal@xxxxxxxxxxx>
---
 drivers/net/ieee802154/ca8210.c | 7 +++----
 1 file changed, 3 insertions(+), 4 deletions(-)

diff --git a/drivers/net/ieee802154/ca8210.c b/drivers/net/ieee802154/ca8210.c
index d3a9e4fe05f4..374827f51dff 100644
--- a/drivers/net/ieee802154/ca8210.c
+++ b/drivers/net/ieee802154/ca8210.c
@@ -1750,6 +1750,7 @@ static int ca8210_async_xmit_complete(
 	u8                     status)
 {
 	struct ca8210_priv *priv = hw->priv;
+	bool ifs_handling = true;
 
 	if (priv->nextmsduhandle != msduhandle) {
 		dev_err(
@@ -1770,10 +1771,8 @@ static int ca8210_async_xmit_complete(
 			"Link transmission unsuccessful, status = %d\n",
 			status
 		);
-		if (status != MAC_TRANSACTION_OVERFLOW) {
-			ieee802154_wake_queue(priv->hw);
-			return 0;
-		}
+		if (status != MAC_TRANSACTION_OVERFLOW)
+			ifs_handling = false;
 	}
 	ieee802154_xmit_complete(priv->hw, priv->tx_skb, true);
 
-- 
2.27.0




[Index of Archives]     [Linux Host AP]     [ATH6KL]     [Linux Wireless Personal Area Network]     [Linux Bluetooth]     [Wireless Regulations]     [Linux Netdev]     [Kernel Newbies]     [Linux Kernel]     [IDE]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite Hiking]     [MIPS Linux]     [ARM Linux]     [Linux RAID]

  Powered by Linux