Re: [PATCH] batman-adv: Use wifi rx/tx as fallback throughput

Marek Lindner
2019-06-09T11:40:24Z

[-- Attachment #1: Type: text/plain, Size: 795 bytes --]

On Sunday, 9 June 2019 18:37:54 HKT Sven Eckelmann wrote:
> No, we are not interested in rx rate for tx throughput estimations.

Before ruling rx out, can you explain your thinking behind this magic formula
(if smaller compute sum and divide by 6):

+ if (sinfo.filled & BIT(NL80211_STA_INFO_TX_BITRATE)) {
+ tx = cfg80211_calculate_bitrate(&sinfo.txrate);
+ if (sinfo.filled & BIT(NL80211_STA_INFO_RX_BITRATE)) {
+ rx =
cfg80211_calculate_bitrate(&sinfo.rxrate);
+ if (rx < tx) {
+ return (rx + tx) / 6;
+ }
+ }
+ return tx / 3;
+ }

Thanks,
Marek

[-- Attachment #2: This is a digitally signed message part. --]
[-- Type: application/pgp-signature, Size: 488 bytes --]