Commit 6070bf35 authored by Tetsuo Handa's avatar Tetsuo Handa Committed by James Morris

kernel: Constify temporary variable in roundup()

Fix build error with GCC 3.x caused by commit b28efd54
"kernel: roundup should only reference arguments once" by constifying
temporary variable used in that macro.
Signed-off-by: default avatarTetsuo Handa <penguin-kernel@I-love.SAKURA.ne.jp>
Suggested-by: default avatarAndrew Morton <akpm@linux-foundation.org>
Acked-by: default avatarEric Paris <eparis@redhat.com>
Signed-off-by: default avatarJames Morris <jmorris@namei.org>
parent a7bcf21e
......@@ -60,7 +60,7 @@ extern const char linux_proc_banner[];
#define DIV_ROUND_UP(n,d) (((n) + (d) - 1) / (d))
#define roundup(x, y) ( \
{ \
typeof(y) __y = y; \
const typeof(y) __y = y; \
(((x) + (__y - 1)) / __y) * __y; \
} \
)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment