summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorchristos <christos@NetBSD.org>2019-03-29 12:50:30 +0000
committerchristos <christos@NetBSD.org>2019-03-29 12:50:30 +0000
commit025ef44510ba35e2ced4ac36076bdbb7fa60db4d (patch)
tree3144b717bb8643418b976bf10158b0c75edd5841
parentf71a53bbcd4f20e50df8c8631b3d9c10553b7d30 (diff)
Change strategy: instead of always defining PAGE_SHIFT in vmparam.h, fail
back to using MAX_PAGE_SHIFT.
-rw-r--r--external/bsd/jemalloc/include/jemalloc/internal/jemalloc_internal_defs.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/external/bsd/jemalloc/include/jemalloc/internal/jemalloc_internal_defs.h b/external/bsd/jemalloc/include/jemalloc/internal/jemalloc_internal_defs.h
index bb8efca563f..6dc186720d6 100644
--- a/external/bsd/jemalloc/include/jemalloc/internal/jemalloc_internal_defs.h
+++ b/external/bsd/jemalloc/include/jemalloc/internal/jemalloc_internal_defs.h
@@ -200,7 +200,13 @@
/* One page is 2^LG_PAGE bytes. */
#include <machine/vmparam.h>
+#ifdef PAGE_SHIFT
#define LG_PAGE PAGE_SHIFT
+#elifdef MAX_PAGE_SHIFT
+#define LG_PAGE MAX_PAGE_SHIFT
+#else
+#error "PAGE_SHIFT is not defined"
+#endif
/*
* One huge page is 2^LG_HUGEPAGE bytes. Note that this is defined even if the