Thanks for mention this, I forget to describe the problem in my new version. As the version 1-3 cover, “cbs_set_port_rate() and cbs_change() multiply link rates and slope values by BYTES_PER_KBIT, an unsigned long constant. On 32-bit architectures, the multiplications therefore take place in 32-bit unsigned arithmetic before the results are assigned to s64 fields.” This is the main problem this series aiming to solve.
During v1-v3 the Sashikomention other problem I missed with.”q->idleslope” and “q->sendslope” will be tearing by 32-bit machine, I change idleslope and sendslope to atomic64_t type to solve this.Here is the main change reason for my patch.
Jamal Hadi Salim mention cbs is still have a watchdog problem. I try to solve in v2 and v3 and it did not work well. Considering Mohamed is do a patch relevant to this patch, I believe separating this is a better way. For watchdog issue, I will send another patch to deal with.
Re: [PATCH net v4] net/sched: cbs: perform rate conversions in signed 64-bit arithmetic
- From
- 163w…@gmail.com (Jack Wang)
- Organization
- Usenet Network
- Message-ID
- <CC82…@gmail.com>
- Date
- Newsgroups
- linux.kernel.netdev