projects
/
GitHub
/
LineageOS
/
G12
/
android_kernel_amlogic_linux-4.9.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
033d899
)
[PKT_SCHED]: Fix range in PSCHED_TDIFF_SAFE to 0..bound
author
Patrick McHardy
<kaber@trash.net>
Tue, 3 May 2005 21:41:18 +0000
(14:41 -0700)
committer
David S. Miller
<davem@davemloft.net>
Tue, 3 May 2005 21:41:18 +0000
(14:41 -0700)
Signed-off-by: Patrick McHardy <kaber@trash.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
include/net/pkt_sched.h
patch
|
blob
|
blame
|
history
diff --git
a/include/net/pkt_sched.h
b/include/net/pkt_sched.h
index 7352e455053cc857e70f0cb1e008eb7adabbe011..fcb05a387dbee560d6a0f20b6e8c3c4f1b2d93f1 100644
(file)
--- a/
include/net/pkt_sched.h
+++ b/
include/net/pkt_sched.h
@@
-157,7
+157,8
@@
psched_tod_diff(int delta_sec, int bound)
case 1: \
__delta += 1000000; \
case 0: \
- __delta = abs(__delta); \
+ if (__delta > bound || __delta < 0) \
+ __delta = bound; \
} \
__delta; \
})