]> git.karo-electronics.de Git - karo-tx-linux.git/commitdiff
net: sched: integer overflow fix
authorStefan Hasko <hasko.stevo@gmail.com>
Fri, 21 Dec 2012 15:04:59 +0000 (15:04 +0000)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 11 Jan 2013 17:18:52 +0000 (09:18 -0800)
[ Upstream commit d2fe85da52e89b8012ffad010ef352a964725d5f ]

Fixed integer overflow in function htb_dequeue

Signed-off-by: Stefan Hasko <hasko.stevo@gmail.com>
Acked-by: Eric Dumazet <edumazet@google.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
net/sched/sch_htb.c

index 9d75b7761313c5789ca51fb47d5f0fe49fec6966..e9ea2f33b89b08e36008daac3622b9069bf08e2c 100644 (file)
@@ -874,7 +874,7 @@ ok:
        q->now = psched_get_time();
        start_at = jiffies;
 
-       next_event = q->now + 5 * PSCHED_TICKS_PER_SEC;
+       next_event = q->now + 5LLU * PSCHED_TICKS_PER_SEC;
 
        for (level = 0; level < TC_HTB_MAXDEPTH; level++) {
                /* common case optimization - skip event handler quickly */