OSDN Git Service

ANDROID: uid_cputime: fix cputime overflow
authorJin Qian <jinqian@google.com>
Tue, 14 Jul 2015 01:16:55 +0000 (18:16 -0700)
committerAmit Pundir <amit.pundir@linaro.org>
Tue, 14 Aug 2018 12:17:11 +0000 (17:47 +0530)
commitf65e939715afa15cf55354002b771d2c06723e05
treefb39a85e7e92232558fc5c18424fa52145c6a640
parent634f5ea3ea8e948b179a70918b9414a1fca7cbe1
ANDROID: uid_cputime: fix cputime overflow

Converting cputime_t to usec caused overflow when the value is greater
than 1 hour. Use msec and convert to unsigned long long to support bigger
range.

Bug: 22461683

Change-Id: I853fe3e8e7dbf0d3e2cc5c6f9688a5a6e1f1fb3e
Signed-off-by: Jin Qian <jinqian@google.com>
[AmitP: Refactored the original changes because cputime_to_jiffies()
        is obsolete and removed in upstream commit
        f22d6df0b23e ("sched/cputime: Remove jiffies based cputime")]
Signed-off-by: Amit Pundir <amit.pundir@linaro.org>
drivers/misc/uid_cputime.c