diff options
author | Peter Zijlstra <peterz@infradead.org> | 2008-07-28 11:53:11 +0200 |
---|---|---|
committer | Ingo Molnar <mingo@elte.hu> | 2008-07-28 12:01:58 +0200 |
commit | 157124c11f4217733691223ecf5ee47558ae9495 (patch) | |
tree | bb6a8c8374ddef78ae3b07c004e5a794796d5289 /kernel/sched_fair.c | |
parent | c9272c4f9fbe2087beb3392f526dc5b19efaa56b (diff) | |
download | kernel_samsung_smdk4412-157124c11f4217733691223ecf5ee47558ae9495.zip kernel_samsung_smdk4412-157124c11f4217733691223ecf5ee47558ae9495.tar.gz kernel_samsung_smdk4412-157124c11f4217733691223ecf5ee47558ae9495.tar.bz2 |
sched: fix warning in hrtick_start_fair()
Benjamin Herrenschmidt reported:
> I get that on ppc64 ...
>
> In file included from kernel/sched.c:1595:
> kernel/sched_fair.c: In function ‘hrtick_start_fair’:
> kernel/sched_fair.c:902: warning: comparison of distinct pointer types lacks a cast
>
> Probably harmless but annoying.
s64 delta = slice - ran;
--> delta = max(10000LL, delta);
Probably ppc64's s64 is long vs long long..
I think hpa was looking at sanitizing all these 64bit types across the
architectures.
Use max_t with an explicit type meanwhile.
Reported-by: Benjamin Herrenschmid <benh@kernel.crashing.org>
Signed-off-by: Peter Zijlstra <a.p.zijlstra@chello.nl>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'kernel/sched_fair.c')
-rw-r--r-- | kernel/sched_fair.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/kernel/sched_fair.c b/kernel/sched_fair.c index cf2cd6c..0fe94ea 100644 --- a/kernel/sched_fair.c +++ b/kernel/sched_fair.c @@ -899,7 +899,7 @@ static void hrtick_start_fair(struct rq *rq, struct task_struct *p) * doesn't make sense. Rely on vruntime for fairness. */ if (rq->curr != p) - delta = max(10000LL, delta); + delta = max_t(s64, 10000LL, delta); hrtick_start(rq, delta); } |