]> git.baikalelectronics.ru Git - kernel.git/commit
[PKT_SCHED]: Fix regression in PSCHED_TADD{,2}.
authorGuillaume Chazarain <guichaz@yahoo.fr>
Mon, 24 Jul 2006 06:37:24 +0000 (23:37 -0700)
committerDavid S. Miller <davem@sunset.davemloft.net>
Mon, 24 Jul 2006 19:44:23 +0000 (12:44 -0700)
commit7322874e188d0a7cb294e55354ebed1a91d916cd
tree09666e27746a3aac8c00d6bfc3717939354888e1
parent146ca2649ade6af3f3f4d6b002573caf640b8a05
[PKT_SCHED]: Fix regression in PSCHED_TADD{,2}.

In PSCHED_TADD and PSCHED_TADD2, if delta is less than tv.tv_usec (so,
less than USEC_PER_SEC too) then tv_res will be smaller than tv. The
affectation "(tv_res).tv_usec = __delta;" is wrong.  The fix is to
revert to the original code before
7ec2c9b23391fd7f01504a210226aeeb0491eeb4 and change the 'if' in
'while'.

[Shuya MAEDA: "while (__delta >= USEC_PER_SEC){ ... }" instead of
"while (__delta > USEC_PER_SEC){ ... }"]

Signed-off-by: Guillaume Chazarain <guichaz@yahoo.fr>
Signed-off-by: David S. Miller <davem@davemloft.net>
include/net/pkt_sched.h