diff options
author | Andrew Morton <akpm@osdl.org> | 2004-05-24 18:44:52 -0700 |
---|---|---|
committer | Linus Torvalds <torvalds@ppc970.osdl.org> | 2004-05-24 18:44:52 -0700 |
commit | 625ba457febfff0907828a69a3175365d96523ad (patch) | |
tree | a1d4a94aad4db2cb31a8714e9faab0ca7c1c2afd /mm | |
parent | b1f5c118382ccf205a78f060310f5327fe3bd234 (diff) | |
download | history-625ba457febfff0907828a69a3175365d96523ad.tar.gz |
[PATCH] rmap build fix
From: William Lee Irwin III <wli@holomorphy.com>
PMD_SIZE is not a compile-time constant on sparc. Use min() in there so
that the cluster size will be evaluated at runtime if the architecture
insists on doing that.
Diffstat (limited to 'mm')
-rw-r--r-- | mm/rmap.c | 6 |
1 files changed, 1 insertions, 5 deletions
diff --git a/mm/rmap.c b/mm/rmap.c index e7c4189cc90762..871e76b9c25e20 100644 --- a/mm/rmap.c +++ b/mm/rmap.c @@ -537,11 +537,7 @@ out: * there there won't be many ptes located within the scan cluster. In this case * maybe we could scan further - to the end of the pte page, perhaps. */ -#define CLUSTER_SIZE (32 * PAGE_SIZE) -#if CLUSTER_SIZE > PMD_SIZE -#undef CLUSTER_SIZE -#define CLUSTER_SIZE PMD_SIZE -#endif +#define CLUSTER_SIZE min(32*PAGE_SIZE, PMD_SIZE) #define CLUSTER_MASK (~(CLUSTER_SIZE - 1)) static int try_to_unmap_cluster(unsigned long cursor, |