dynamic_tx_rpt_timing_counter is not per mac_id, but used across all
mac_ids.
---
drivers/net/wireless/realtek/rtl8xxxu/8188e.c | 8 ++++----
drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.h | 2 +-
2 files changed, 5 insertions(+), 5 deletions(-)
diff --git a/drivers/net/wireless/realtek/rtl8xxxu/8188e.c b/drivers/net/wireless/realtek/rtl8xxxu/8188e.c
index 766a7a7c7d28..de2837a91bbe 100644
--- a/drivers/net/wireless/realtek/rtl8xxxu/8188e.c
+++ b/drivers/net/wireless/realtek/rtl8xxxu/8188e.c
@@ -1550,14 +1550,14 @@ static void rtl8188e_rate_decision(struct rtl8xxxu_ra_info *ra)
}
if (ra->decision_rate == ra->pre_rate)
- ra->dynamic_tx_rpt_timing_counter++;
+ priv->dynamic_tx_rpt_timing_counter++;
else
- ra->dynamic_tx_rpt_timing_counter = 0;
+ priv->dynamic_tx_rpt_timing_counter = 0;
- if (ra->dynamic_tx_rpt_timing_counter >= 4) {
+ if (priv->dynamic_tx_rpt_timing_counter >= 4) {
/* Rate didn't change 4 times, extend RPT timing */
rtl8188e_set_tx_rpt_timing(ra, INCREASE_TIMING);
- ra->dynamic_tx_rpt_timing_counter = 0;
+ priv->dynamic_tx_rpt_timing_counter = 0;
}
ra->pre_rate = ra->decision_rate;
diff --git a/drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.h b/drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.h
index 9fb2583ffffc..4a744b5c1aec 100644
--- a/drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.h
+++ b/drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.h
@@ -1756,7 +1756,6 @@ struct rtl8xxxu_ra_info {
u16 drop;
u16 rpt_time;
u16 pre_min_rpt_time;
- u8 dynamic_tx_rpt_timing_counter;
u8 ra_waiting_counter;
u8 ra_pending_counter;
u8 ra_drop_after_down;
@@ -1917,6 +1916,7 @@ struct rtl8xxxu_priv {
struct rtl8xxxu_ra_report ra_report;
struct rtl8xxxu_cfo_tracking cfo_tracking;
struct rtl8xxxu_ra_info ra_info;
+ u8 dynamic_tx_rpt_timing_counter; // 8188e specific
bool led_registered;
char led_name[32];
--
2.53.0
Georg Müller <georgmueller@gmx.net> wrote: > dynamic_tx_rpt_timing_counter is not per mac_id, but used across all > mac_ids. I don't know the purpose of dynamic_tx_rpt_timing_counter. Could you share your study? Ping-Ke
Am 16.03.26 um 07:17 schrieb Ping-Ke Shih: > > Georg Müller <georgmueller@gmx.net> wrote: >> dynamic_tx_rpt_timing_counter is not per mac_id, but used across all >> mac_ids. > > I don't know the purpose of dynamic_tx_rpt_timing_counter. Could you > share your study? > It is used globally (not per mac) like this in the vendor driver as well [1][2]. Bitterblue Smith gave the hint that this should not be per macid [3], so it should move out of struct ra_info. [1] https://github.com/lwfinger/rtl8188eu/blob/master/hal/Hal8188ERateAdaptive.c#L248 [2] https://github.com/lwfinger/rtl8188eu/blob/v5.2.2.4/hal8188erateadaptive.c#L285 [3] https://lore.kernel.org/linux-wireless/938ae608-a865-4056-06de-c230d74e1847@gmail.com/
Georg Müller <georgmueller@gmx.net> wrote: > Am 16.03.26 um 07:17 schrieb Ping-Ke Shih: > > > > Georg Müller <georgmueller@gmx.net> wrote: > >> dynamic_tx_rpt_timing_counter is not per mac_id, but used across all > >> mac_ids. > > > > I don't know the purpose of dynamic_tx_rpt_timing_counter. Could you > > share your study? > > > It is used globally (not per mac) like this in the vendor driver as well [1][2]. > Bitterblue Smith gave the hint that this should not be per macid [3], so it should > move > out of struct ra_info. > > [1] > https://github.com/lwfinger/rtl8188eu/blob/master/hal/Hal8188ERateAdaptive.c > #L248 > [2] > https://github.com/lwfinger/rtl8188eu/blob/v5.2.2.4/hal8188erateadaptive.c#L > 285 > [3] > https://lore.kernel.org/linux-wireless/938ae608-a865-4056-06de-c230d74e1847@ > gmail.com/ > Thanks for the info. I can't find the log internally, so let's keep it as github does. Ping-Ke
© 2016 - 2026 Red Hat, Inc.