wifi: rtw89: add function to wait for completion of TX skbs
authorPo-Hao Huang <phhuang@realtek.com>
Tue, 11 Apr 2023 12:48:29 +0000 (20:48 +0800)
committerKalle Valo <kvalo@kernel.org>
Fri, 14 Apr 2023 12:11:22 +0000 (15:11 +0300)
commit1ae5ca615285d5d4f72d1de464716d85dffef19f
tree4b163e23483f6698d3ac406479c8bfc468c4871f
parentd2b6da242454ee886729aad7020dfda7995bc26b
wifi: rtw89: add function to wait for completion of TX skbs

Allocate a per-skb completion to track those skbs we are interested in
and wait for them to complete transmission with TX status.

Normally, the completion object is freed by wait side, but it could be
timeout result that complete side should free the object instead. Add a
owner field with RCU to determine which side should free the object.

Signed-off-by: Po-Hao Huang <phhuang@realtek.com>
Signed-off-by: Zong-Zhe Yang <kevin_yang@realtek.com>
Signed-off-by: Ping-Ke Shih <pkshih@realtek.com>
Signed-off-by: Kalle Valo <kvalo@kernel.org>
Link: https://lore.kernel.org/r/20230411124832.14965-3-pkshih@realtek.com
drivers/net/wireless/realtek/rtw89/core.c
drivers/net/wireless/realtek/rtw89/core.h
drivers/net/wireless/realtek/rtw89/pci.c
drivers/net/wireless/realtek/rtw89/pci.h