On 10/18/2019 05:35 AM, Johannes Berg wrote:
On Fri, 2019-10-18 at 12:15 +0200, Toke Høiland-Jørgensen wrote:
Kan Yan <kyan@xxxxxxxxxx> writes:
The "tx_time_est" field, shared by control and status, is not able to
survive until the skb returns to the mac80211 layer in some
architectures. The same space is defined as driver_data and some
wireless drivers use it for other purposes, as the cb in the sk_buff
is free to be used by any layer.
In the case of ath10k, the tx_time_est get clobbered by
struct ath10k_skb_cb {
dma_addr_t paddr;
u8 flags;
u8 eid;
u16 msdu_id;
u16 airtime_est;
struct ieee80211_vif *vif;
struct ieee80211_txq *txq;
} __packed;
Ah, bugger, of course the driver that actually needs this is using the
full driver_data space :P
Looks like you could shrink *this* fairly easily though.
E.g. most likely vif == txq->vif unless txq==NULL, so it's down to 22
bytes plus a bit/flag for knowing whether the pointer is a vif directly
(if no TXQ) or a TXQ.
And of course you get two bits in every pointer (0x3) and likely the
dma addr too. Plenty of space!
Thanks,
Ben
--
Ben Greear <greearb@xxxxxxxxxxxxxxx>
Candela Technologies Inc http://www.candelatech.com