On Sun, Mar 31, 2019 at 12:15 PM Lorenzo Bianconi <lorenzo.bianc...@redhat.com> wrote: > > > > > On Sun, Mar 31, 2019 at 6:45 AM Lorenzo Bianconi > > <lorenzo.bianc...@redhat.com> wrote: > > > > > > > > > > > bump. > > > > > > Hi Joe, > > > > > > sorry for the delay > > > > > > > > > > > On Mon, Mar 18, 2019 at 10:59 PM Joe Ayers <j...@ayerscasa.com> wrote: > > > >> > > > >> Lorenzo, I have tested dynack on a (real distance apart) ~60km link > > > >> with some success. This is the code change made: > > > >> > > > >> --- a/drivers/net/wireless/ath/ath9k/dynack.c > > > >> +++ b/drivers/net/wireless/ath/ath9k/dynack.c > > > >> @@ -20,8 +20,9 @@ > > > >> > > > >> #define COMPUTE_TO (5 * HZ) > > > >> #define LATEACK_DELAY (10 * HZ) > > > >> -#define LATEACK_TO 256 > > > >> -#define MAX_DELAY 300 > > > >> +#define LATEACK_TO 1054 > > > >> +/* AREDN max distance set to 150km */ > > > >> +#define MAX_DELAY 1054 > > > >> #define EWMA_LEVEL 96 > > > >> #define EWMA_DIV 128 > > > >> > > > >> @@ -293,7 +294,8 @@ > > > >> void ath_dynack_node_init(struct ath_hw *ah, struct ath_node *an) > > > >> { > > > >> /* ackto = slottime + sifs + air delay */ > > > >> - u32 ackto = 9 + 16 + 64; > > > >> + /* AREDN starting point is 20km */ > > > >> + u32 ackto = 9 + 16 + 171; > > > >> struct ath_dynack *da = &ah->dynack; > > > >> > > > >> an->ackto = ackto; > > > >> @@ -328,7 +330,8 @@ > > > >> void ath_dynack_reset(struct ath_hw *ah) > > > >> { > > > >> /* ackto = slottime + sifs + air delay */ > > > >> - u32 ackto = 9 + 16 + 64; > > > >> + /* AREDN starting point is 20km */ > > > >> + u32 ackto = 9 + 16 + 171; > > > >> struct ath_dynack *da = &ah->dynack; > > > >> > > > >> da->lto = jiffies; > > > >> > > > >> Notes: > > > >> > > > >> 1) The stations are showing ack_to between 525 up to 575 A. When > > > >> static set at 60k distance, the timeout is set to 460 S. > > > >> 2) significant performance improvement between these settings with > > > >> iperf3 and back to back runs with reboot in the middle: > > > >> > > > > > > could you please try to attached patch? The max distance the hw can > > > support depends of channel width: > > > e.g @20MHz (HT20, 5GHz) > > > > > > max distance is ~ 61Km > > > > > > > Could these max distance specs be what the manufacture tested, not > > necessarily a hardware limitation -- just not known? > > > > https://github.com/torvalds/linux/blob/master/drivers/net/wireless/ath/ath9k/hw.c#L1006 > > max timeout you can set is AR_TIME_OUT_ACK (0x3fff) / clock_rate > > > I suspect in the calculation for max_to, if the channel is 10MHz, the > > max distance can be doubled for the hardware--do the specs only give > > 20MHz values? This would be consistent with, for example, the symbol > > lengths are doubled when cutting the bandwidth in half, hence half the > > rates and still 64 bins or 64 point fft squeezed in the channel. SNR > > is also 3dB higher given same energy in half the bandwidth. We don't > > see 20MHz channels working at these long distances, rather use 10MHz > > for it to work. Intuitively, as I understand it, more time is needed > > with increased distance for reflection signals to not be received past > > the symbol time and increased inter-symbol interference. > > yes, but it is already done in ath9k_hw_set_clockrate() > https://github.com/torvalds/linux/blob/master/drivers/net/wireless/ath/ath9k/hw.c#L61 > > > > > > @Koen: do you have any chance to test the attached patch in your > > > environment? Thx > > > > > > >> run 1 @ static 60km: > > > >> [ 5] 0.00-10.00 sec 7.31 MBytes 6.13 Mbits/sec 0 > > > >> sender > > > >> [ 5] 0.00-10.08 sec 7.16 MBytes 5.95 Mbits/sec > > > >> receiver > > > >> > > > >> run 2 @ static 60km: > > > >> [ 5] 0.00-10.00 sec 5.88 MBytes 4.93 Mbits/sec 0 > > > >> sender > > > >> [ 5] 0.00-10.04 sec 5.77 MBytes 4.81 Mbits/sec > > > >> receiver > > > >> > > > >> run 1 and 2 @ auto distance -- goes up to ~575us with data flow, > > > >> floats back to ~525 otherwise: > > > >> [ 5] 0.00-10.00 sec 20.0 MBytes 16.8 Mbits/sec 0 > > > >> sender > > > >> [ 5] 0.00-10.07 sec 19.8 MBytes 16.5 Mbits/sec > > > >> receiver > > > >> > > > >> [ 5] 0.00-10.00 sec 21.4 MBytes 18.0 Mbits/sec 0 > > > >> sender > > > >> [ 5] 0.00-10.04 sec 21.2 MBytes 17.7 Mbits/sec > > > >> receiver > > > >> > > > >> 3) running wpa_supplicant and psk2 > > > >> 4) running ibss on ch 176 with AREDN channels on top of 18.06.2 > > > >> 5) on one reboot, one of the stations stayed down at initial 196, then > > > >> bumped up to ~250 range and stayed there, link not functional. Not > > > >> sure how to explain this value... > > > >> > > > >> Question, can this condition be true periodically while the link is > > > >> live or only at initial 802.11 adhoc link setup?: > > > >> > > > >> if (ieee80211_is_assoc_req(hdr->frame_control) || > > > >> ieee80211_is_assoc_resp(hdr->frame_control) || > > > >> ieee80211_is_auth(hdr->frame_control)) { > > > >> > > > > > > I do not think so since AFAIK auth frames are sent just during ibss join > > > > > > >> 6) Auto distance stayed at initial 196 when turning off encryption. > > > >> > > > >> Any ideas of alternative options of packets to key off in late ack > > > >> situation? running wpad-mini is ~500k file size and RAM consumer. > > > >> It would be beneficial to take wpa_supplicant out of the equation if > > > >> at all possible. > > > >> > > > > > > What is mandatory are unicast frames during joining phase, maybe you can > > > develop an userspace daemon for this purpose > > > > > > > I see where you're going with this. I'd have to learn a lot to do > > this. Possibly a simpler approach, if it doesn't add too much > > penalty. What if the initial ack_to is at max, it quickly settles > > down to measured, then after some criteria, time or # acks received, > > say ~15 seconds has elapsed a cycle is triggered back to max ack_to. > > This should catch new stations joining at farther distances when wpad > > is not used. > > > > I am a little bit concerned about short/medium distance links with high LER. > Is the attached patch working? > > Regards, > Lorenzo >
I did not have success on the patch on 60km link @ 10MHz channel with encryption. I need to double-check, tomorrow, to have confidence something wasn't overlooked. After I turned on debug, here's what the log looked like, ack_to stayed too short (from memory) "89 A". [ 29.956353] br-lan: port 1(eth0) entered blocking state [ 29.961669] br-lan: port 1(eth0) entered forwarding state [ 29.968128] ttyS ttyS0: 1 input overrun(s) [ 40.115424] wlan0: Trigger new scan to find an IBSS to join [ 197.402125] ath: phy0: rx sample 160615364 [h 12-t 15] [ 198.828057] ath: phy0: rx sample 162041305 [h 12-t 16] [ 199.355304] ath: phy0: {44:d9:e7:c0:15:4d} tx sample 162568408 [dur 80][h 17-t 18] [ 199.355358] ath: phy0: ack_ts 159069666 st_ts 162568408 st_dur 80 [12-17] [ 199.355373] ath: phy0: ack_ts 159070847 st_ts 162568408 st_dur 80 [13-17] [ 199.355388] ath: phy0: ack_ts 160615364 st_ts 162568408 st_dur 80 [14-17] [ 199.355403] ath: phy0: ack_ts 162041305 st_ts 162568408 st_dur 80 [15-17] [ 199.392299] ath: phy0: rx sample 162605530 [h 16-t 17] [ 199.392342] ath: phy0: ack_ts 162605530 st_ts 162568408 st_dur 80 [16-17] [ 199.674044] ath: phy0: rx sample 162887287 [h 16-t 18] [ 200.234878] ath: phy0: rx sample 163448139 [h 16-t 19] [ 200.633696] ath: phy0: rx sample 163846942 [h 16-t 20] [ 201.206719] ath: phy0: rx sample 164419968 [h 16-t 21] [ 201.890843] ath: phy0: rx sample 165104085 [h 16-t 22] [ 206.104859] ath: phy0: {44:d9:e7:c0:15:4d} tx sample 169318008 [dur 80][h 18-t 19] [ 206.104884] ath: phy0: ack_ts 162605530 st_ts 169318008 st_dur 80 [16-18] [ 206.104900] ath: phy0: ack_ts 162887287 st_ts 169318008 st_dur 80 [17-18] [ 206.104915] ath: phy0: ack_ts 163448139 st_ts 169318008 st_dur 80 [18-18] [ 206.104930] ath: phy0: ack_ts 163846942 st_ts 169318008 st_dur 80 [19-18] [ 206.104945] ath: phy0: ack_ts 164419968 st_ts 169318008 st_dur 80 [20-18] [ 206.104959] ath: phy0: ack_ts 165104085 st_ts 169318008 st_dur 80 [21-18] [ 207.735339] ath: phy0: rx sample 170948588 [h 22-t 23] [ 207.735363] ath: phy0: ack_ts 170948588 st_ts 169318008 st_dur 80 [22-18] [ 212.135832] ath: phy0: rx sample 175349078 [h 22-t 24] [ 212.646658] ath: phy0: {44:d9:e7:c0:15:4d} tx sample 175858835 [dur 3180][h 19-t 20] [ 212.646682] ath: phy0: ack_ts 170948588 st_ts 175858835 st_dur 3180 [22-19] [ 212.646715] ath: phy0: ack_ts 175349078 st_ts 175858835 st_dur 3180 [23-19] [ 212.655967] ath: phy0: rx sample 175869229 [h 24-t 25] [ 212.655991] ath: phy0: ack_ts 175869229 st_ts 175858835 st_dur 3180 [24-19] [ 213.463873] ath: phy0: rx sample 176677247 [h 24-t 26] [ 214.011744] ath: phy0: rx sample 177225005 [h 24-t 27] [ 214.695804] ath: phy0: rx sample 177909064 [h 24-t 28] [ 215.302377] ath: phy0: {44:d9:e7:c0:15:4d} tx sample 178515072 [dur 2804][h 20-t 21] [ 215.302402] ath: phy0: ack_ts 175869229 st_ts 178515072 st_dur 2804 [24-20] [ 215.302417] ath: phy0: ack_ts 176677247 st_ts 178515072 st_dur 2804 [25-20] [ 215.302432] ath: phy0: ack_ts 177225005 st_ts 178515072 st_dur 2804 [26-20] [ 215.302447] ath: phy0: ack_ts 177909064 st_ts 178515072 st_dur 2804 [27-20] [ 215.441735] ath: phy0: rx sample 178654966 [h 28-t 29] [ 215.441760] ath: phy0: ack_ts 178654966 st_ts 178515072 st_dur 2804 [28-20] [ 215.915237] ath: phy0: rx sample 179128515 [h 28-t 30] [ 215.964754] ath: phy0: rx sample 179178017 [h 28-t 31] [ 215.966648] ath: phy0: rx sample 179179951 [h 28-t 32] [ 216.593609] ath: phy0: rx sample 179806871 [h 28-t 33] [ 216.692988] ath: phy0: rx sample 179906248 [h 28-t 34] [ 216.696747] ath: phy0: rx sample 179910028 [h 28-t 35] [ 217.143315] ath: phy0: rx sample 180356569 [h 28-t 36] [ 217.243497] ath: phy0: rx sample 180456764 [h 28-t 37] [ 217.740801] ath: phy0: rx sample 180954068 [h 28-t 38] [ 217.742587] ath: phy0: rx sample 180955845 [h 28-t 39] [ 217.771823] ath: phy0: rx sample 180985091 [h 28-t 40] [ 217.774091] ath: phy0: rx sample 180987376 [h 28-t 41] [ 218.143797] ath: phy0: rx sample 181356153 [h 28-t 42] [ 218.145709] ath: phy0: rx sample 181358955 [h 28-t 43] [ 218.487477] ath: phy0: rx sample 181700756 [h 28-t 44] [ 218.823813] ath: phy0: rx sample 182037099 [h 28-t 45] [ 218.824925] ath: phy0: rx sample 182038231 [h 28-t 46] [ 219.248108] ath: phy0: rx sample 182461382 [h 28-t 47] [ 219.249844] ath: phy0: rx sample 182463153 [h 28-t 48] [ 219.526230] ath: phy0: rx sample 182739468 [h 28-t 49] [ 219.529144] ath: phy0: rx sample 182742408 [h 28-t 50] [ 219.837333] ath: phy0: rx sample 183050622 [h 28-t 51] [ 219.855530] ath: phy0: rx sample 183068800 [h 28-t 52] [ 219.957283] ath: phy0: rx sample 183170560 [h 28-t 53] [ 219.958754] ath: phy0: rx sample 183172062 [h 28-t 54] [ 220.536767] ath: phy0: {44:d9:e7:c0:15:4d} tx sample 183748234 [dur 168][h 21-t 22] [ 220.536791] ath: phy0: ack_ts 178654966 st_ts 183748234 st_dur 168 [28-21] [ 220.536807] ath: phy0: ack_ts 179128515 st_ts 183748234 st_dur 168 [29-21] [ 220.536822] ath: phy0: ack_ts 179178017 st_ts 183748234 st_dur 168 [30-21] [ 220.536837] ath: phy0: ack_ts 179179951 st_ts 183748234 st_dur 168 [31-21] [ 220.536852] ath: phy0: ack_ts 179806871 st_ts 183748234 st_dur 168 [32-21] [ 220.536867] ath: phy0: ack_ts 179906248 st_ts 183748234 st_dur 168 [33-21] [ 220.536882] ath: phy0: ack_ts 179910028 st_ts 183748234 st_dur 168 [34-21] [ 220.536897] ath: phy0: ack_ts 180356569 st_ts 183748234 st_dur 168 [35-21] [ 220.536912] ath: phy0: ack_ts 180456764 st_ts 183748234 st_dur 168 [36-21] [ 220.536927] ath: phy0: ack_ts 180954068 st_ts 183748234 st_dur 168 [37-21] [ 220.536942] ath: phy0: ack_ts 180955845 st_ts 183748234 st_dur 168 [38-21] [ 220.536957] ath: phy0: ack_ts 180985091 st_ts 183748234 st_dur 168 [39-21] [ 220.536972] ath: phy0: ack_ts 180987376 st_ts 183748234 st_dur 168 [40-21] [ 220.536987] ath: phy0: ack_ts 181356153 st_ts 183748234 st_dur 168 [41-21] [ 220.537002] ath: phy0: ack_ts 181358955 st_ts 183748234 st_dur 168 [42-21] [ 220.537017] ath: phy0: ack_ts 181700756 st_ts 183748234 st_dur 168 [43-21] [ 220.537032] ath: phy0: ack_ts 182037099 st_ts 183748234 st_dur 168 [44-21] [ 220.537047] ath: phy0: ack_ts 182038231 st_ts 183748234 st_dur 168 [45-21] [ 220.537062] ath: phy0: ack_ts 182461382 st_ts 183748234 st_dur 168 [46-21] [ 220.537077] ath: phy0: ack_ts 182463153 st_ts 183748234 st_dur 168 [47-21] [ 220.537092] ath: phy0: ack_ts 182739468 st_ts 183748234 st_dur 168 [48-21] [ 220.537107] ath: phy0: ack_ts 182742408 st_ts 183748234 st_dur 168 [49-21] [ 220.537140] ath: phy0: ack_ts 183050622 st_ts 183748234 st_dur 168 [50-21] [ 220.537155] ath: phy0: ack_ts 183068800 st_ts 183748234 st_dur 168 [51-21] [ 220.537170] ath: phy0: ack_ts 183170560 st_ts 183748234 st_dur 168 [52-21] [ 220.537185] ath: phy0: ack_ts 183172062 st_ts 183748234 st_dur 168 [53-21] [ 221.407198] ath: phy0: rx sample 184620468 [h 54-t 55] [ 221.407223] ath: phy0: ack_ts 184620468 st_ts 183748234 st_dur 168 [54-21] [ 221.862947] ath: phy0: rx sample 185076217 [h 54-t 56] [ 221.866719] ath: phy0: rx sample 185080022 [h 54-t 57] [ 223.105324] ath: phy0: rx sample 186318570 [h 54-t 58] [ 223.903678] ath: phy0: rx sample 187116952 [h 54-t 59] [ 223.907580] ath: phy0: rx sample 187120841 [h 54-t 60] [ 224.255119] ath: phy0: rx sample 187468402 [h 54-t 61] [ 224.675136] ath: phy0: rx sample 187888416 [h 54-t 62] [ 225.827935] ath: phy0: rx sample 189041215 [h 54-t 63] [ 225.830059] ath: phy0: rx sample 189043360 [h 54-t 0] [ 226.122152] ath: phy0: rx sample 189335428 [h 54-t 1] [ 226.124548] ath: phy0: rx sample 189337865 [h 54-t 2] [ 226.556117] ath: phy0: rx sample 189769395 [h 54-t 3] [ 226.559177] ath: phy0: rx sample 189772475 [h 54-t 4] [ 226.676979] ath: phy0: {44:d9:e7:c0:15:4d} tx sample 189889636 [dur 288][h 22-t 23] [ 226.677004] ath: phy0: ack_ts 184620468 st_ts 189889636 st_dur 288 [54-22] [ 226.677019] ath: phy0: ack_ts 185076217 st_ts 189889636 st_dur 288 [55-22] [ 226.677034] ath: phy0: ack_ts 185080022 st_ts 189889636 st_dur 288 [56-22] [ 226.677049] ath: phy0: ack_ts 186318570 st_ts 189889636 st_dur 288 [57-22] [ 226.677064] ath: phy0: ack_ts 187116952 st_ts 189889636 st_dur 288 [58-22] [ 226.677079] ath: phy0: ack_ts 187120841 st_ts 189889636 st_dur 288 [59-22] [ 226.677094] ath: phy0: ack_ts 187468402 st_ts 189889636 st_dur 288 [60-22] [ 226.677109] ath: phy0: ack_ts 187888416 st_ts 189889636 st_dur 288 [61-22] [ 226.677148] ath: phy0: ack_ts 189041215 st_ts 189889636 st_dur 288 [62-22] [ 226.677163] ath: phy0: ack_ts 189043360 st_ts 189889636 st_dur 288 [63-22] [ 226.677178] ath: phy0: ack_ts 189335428 st_ts 189889636 st_dur 288 [0-22] [ 226.677193] ath: phy0: ack_ts 189337865 st_ts 189889636 st_dur 288 [1-22] [ 226.677208] ath: phy0: ack_ts 189769395 st_ts 189889636 st_dur 288 [2-22] [ 226.677223] ath: phy0: ack_ts 189772475 st_ts 189889636 st_dur 288 [3-22] [ 226.940734] ath: phy0: {44:d9:e7:c0:15:4d} tx sample 190149825 [dur 3552][h 22-t 24] [ 227.145354] ath: phy0: rx sample 190358638 [h 4-t 5] [ 227.145379] ath: phy0: ack_ts 190358638 st_ts 189889636 st_dur 288 [4-22] [ 227.145395] ath: phy0: ack_ts 190358638 st_ts 190149825 st_dur 3552 [4-23] [ 227.585946] ath: phy0: rx sample 190799199 [h 4-t 6] [ 227.721988] ath: phy0: {44:d9:e7:c0:15:4d} tx sample 190935148 [dur 80][h 24-t 25] [ 227.722012] ath: phy0: ack_ts 190358638 st_ts 190935148 st_dur 80 [4-24] [ 227.722028] ath: phy0: ack_ts 190799199 st_ts 190935148 st_dur 80 [5-24] [ 228.120727] ath: phy0: rx sample 191334011 [h 6-t 7] [ 228.120752] ath: phy0: ack_ts 191334011 st_ts 190935148 st_dur 80 [6-24] [ 228.124955] ath: phy0: rx sample 191338272 [h 6-t 8] [ 228.315928] ath: phy0: rx sample 191529228 [h 6-t 9] [ 228.317513] ath: phy0: rx sample 191530821 [h 6-t 10] [ 228.440364] ath: phy0: rx sample 191653645 [h 6-t 11] [ 228.577569] ath: phy0: rx sample 191790833 [h 6-t 12] [ 228.581457] ath: phy0: rx sample 191794722 [h 6-t 13] [ 228.658327] ath: phy0: rx sample 191871617 [h 6-t 14] [ 228.900168] ath: phy0: rx sample 192113449 [h 6-t 15] [ 228.904672] ath: phy0: rx sample 192117995 [h 6-t 16] [ 229.228065] ath: phy0: rx sample 192441368 [h 6-t 17] [ 229.516237] ath: phy0: rx sample 192729521 [h 6-t 18] [ 229.519803] ath: phy0: rx sample 192733097 [h 6-t 19] [ 229.659565] ath: phy0: rx sample 192872836 [h 6-t 20] [ 230.039245] ath: phy0: rx sample 193252548 [h 6-t 21] [ 230.653931] ath: phy0: rx sample 193867225 [h 6-t 22] [ 230.738556] ath: phy0: rx sample 193951843 [h 6-t 23] [ 230.740006] ath: phy0: rx sample 193953248 [h 6-t 24] [ 230.956872] ath: phy0: rx sample 194170164 [h 6-t 25] [ 230.959536] ath: phy0: rx sample 194172861 [h 6-t 26] [ 231.181837] ath: phy0: rx sample 194395127 [h 6-t 27] [ 231.184747] ath: phy0: rx sample 194398071 [h 6-t 28] [ 231.776087] ath: phy0: rx sample 194989330 [h 6-t 29] [ 231.778612] ath: phy0: rx sample 194991863 [h 6-t 30] [ 232.275938] ath: phy0: rx sample 195489244 [h 6-t 31] [ 232.278229] ath: phy0: rx sample 195491557 [h 6-t 32] [ 232.556163] ath: phy0: rx sample 195769445 [h 6-t 33] [ 232.558751] ath: phy0: rx sample 195772046 [h 6-t 34] [ 232.575733] ath: phy0: rx sample 195789026 [h 6-t 35] [ 232.696912] ath: phy0: rx sample 195910205 [h 6-t 36] [ 232.808461] ath: phy0: rx sample 196021764 [h 6-t 37] [ 233.302605] ath: phy0: rx sample 196515876 [h 6-t 38] [ 233.307306] ath: phy0: rx sample 196520597 [h 6-t 39] [ 233.364771] ath: phy0: rx sample 196578031 [h 6-t 40] [ 233.366169] ath: phy0: rx sample 196579440 [h 6-t 41] [ 233.386912] ath: phy0: rx sample 196600181 [h 6-t 42] [ 234.653791] ath: phy0: rx sample 197867078 [h 6-t 43] [ 234.655365] ath: phy0: rx sample 197868668 [h 6-t 44] [ 235.437288] ath: phy0: rx sample 198650587 [h 6-t 45] [ 235.440085] ath: phy0: rx sample 198653377 [h 6-t 46] [ 236.588956] ath: phy0: rx sample 199802250 [h 6-t 47] [ 236.591932] ath: phy0: rx sample 199805223 [h 6-t 48] [ 237.733586] ath: phy0: {44:d9:e7:c0:15:4d} tx sample 200946761 [dur 80][h 25-t 26] [ 237.733633] ath: phy0: ack_ts 191334011 st_ts 200946761 st_dur 80 [6-25] [ 237.733648] ath: phy0: ack_ts 191338272 st_ts 200946761 st_dur 80 [7-25] ... _______________________________________________ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/mailman/listinfo/openwrt-devel