From 144f170314f5fd3c8011b5bb6b32f8d3b1b01b59 Mon Sep 17 00:00:00 2001 From: Wu Fengguang Date: Mon, 9 Jan 2012 11:53:50 -0600 Subject: [PATCH] --- yaml --- r: 287460 b: refs/heads/master c: 3310225dfc71a35a2cc9340c15c0e08b14b3c754 h: refs/heads/master v: v3 --- [refs] | 2 +- trunk/include/linux/proportions.h | 4 ++++ 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/[refs] b/[refs] index 435fbd2601e7..4e0406fe4870 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: 15eb77a07c714ac80201abd0a9568888bcee6276 +refs/heads/master: 3310225dfc71a35a2cc9340c15c0e08b14b3c754 diff --git a/trunk/include/linux/proportions.h b/trunk/include/linux/proportions.h index ef35bb73f69b..26a8a4ed9b07 100644 --- a/trunk/include/linux/proportions.h +++ b/trunk/include/linux/proportions.h @@ -81,7 +81,11 @@ void prop_inc_percpu(struct prop_descriptor *pd, struct prop_local_percpu *pl) * Limit the time part in order to ensure there are some bits left for the * cycle counter and fraction multiply. */ +#if BITS_PER_LONG == 32 #define PROP_MAX_SHIFT (3*BITS_PER_LONG/4) +#else +#define PROP_MAX_SHIFT (BITS_PER_LONG/2) +#endif #define PROP_FRAC_SHIFT (BITS_PER_LONG - PROP_MAX_SHIFT - 1) #define PROP_FRAC_BASE (1UL << PROP_FRAC_SHIFT)