On 11.06.22 22:01, Felix Fietkau wrote:
The airtime weight calculation overflows with a default weight value of 256
whenever more than 8ms worth of airtime is reported.
Bigger weight values impose even smaller limits on maximum airtime values.
This can mess up airtime based calculations for drivers that don't report
per-PPDU airtime values, but batch up values instead.
Fix this by reordering multiplications/shifts and by reducing unnecessary
intermediate precision (which was lost in a later stage anyway).
The new shift value limits the maximum weight to 4096, which should be more
than enough. Any values bigger than that will be rejected
Signed-off-by: Felix Fietkau <nbd@xxxxxxxx>
Please don't merge this series yet. I'm still investigating reports of
regressions caused by it.
- Felix