Re: [dpdk-dev] [PATCH] sched: fix overflow errors in WRR weighting code

2017-11-14 Thread Luca Boccassi
On Tue, 2017-11-14 at 16:04 +, alangordonde...@gmail.com wrote: > From: Alan Dewar > > The WRR code calculates the lowest common denominator between the > four > WRR weights as a uint32_t value and divides the LCD by each of the > WRR > weights and casts the results as a uint8_t.  This castin

[dpdk-dev] [PATCH] sched: fix overflow errors in WRR weighting code

2017-11-14 Thread alangordondewar
From: Alan Dewar The WRR code calculates the lowest common denominator between the four WRR weights as a uint32_t value and divides the LCD by each of the WRR weights and casts the results as a uint8_t. This casting can cause the ratios of the computed wrr costs to be wrong. For example with WR