From: Linus Walleij Date: Fri, 19 Nov 2010 09:16:05 +0000 (+0100) Subject: ARM: 6488/1: nomadik: prevent sched_clock() wraparound X-Git-Tag: v2.6.37-rc4~31^2~7 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=8fbb97a2bc9b8c91b5a4588ba80709e48dad3f16;p=pandora-kernel.git ARM: 6488/1: nomadik: prevent sched_clock() wraparound The current implementation of sched_clock() for the Nomadik family is based on the clock source that will wrap around without any compensation. Currently on the Ux500 after 1030 seconds. Utilize cnt32_to_63 to expand the sched_clock() counter to 63 bits and introduce a keepwarm() timer to assure that sched clock and this cnt32_to_63 is called atleast once every half period. When I print out the actual wrap-around time, and using a year (3600*24*365 seconds) as minumum wrap limit I get an actual wrap-around of: sched_clock: using 55 bits @ 8333125 Hz wrap in 416 days Signed-off-by: Linus Walleij Signed-off-by: Russell King --- Reading git-diff-tree failed