summaryrefslogtreecommitdiffstats
path: root/arch/arc/include/asm/pgtable.h
diff options
context:
space:
mode:
authorAlexey Brodkin <abrodkin@synopsys.com>2015-09-02 20:43:30 +0300
committerVineet Gupta <vgupta@synopsys.com>2015-10-28 19:31:05 +0530
commitd40846457fc23cd841a60fdc2786e08a8bedb35b (patch)
treef606674e78d842c26d7cdf385a64dcb2c998b8b8 /arch/arc/include/asm/pgtable.h
parent8840e14cd82d398d348b2947fad3a630e93260ba (diff)
downloadlinux-d40846457fc23cd841a60fdc2786e08a8bedb35b.tar.bz2
ARC: mm: use generic macros _BITUL()/_AC()
Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com> Signed-off-by: Vineet Gupta <vgupta@synopsys.com>
Diffstat (limited to 'arch/arc/include/asm/pgtable.h')
-rw-r--r--arch/arc/include/asm/pgtable.h11
1 files changed, 4 insertions, 7 deletions
diff --git a/arch/arc/include/asm/pgtable.h b/arch/arc/include/asm/pgtable.h
index 336267f2e9d9..f7c7273cd537 100644
--- a/arch/arc/include/asm/pgtable.h
+++ b/arch/arc/include/asm/pgtable.h
@@ -38,6 +38,7 @@
#include <asm/page.h>
#include <asm/mmu.h>
#include <asm-generic/pgtable-nopmd.h>
+#include <linux/const.h>
/**************************************************************************
* Page Table Flags
@@ -207,13 +208,9 @@
#define PGDIR_SIZE (1UL << PGDIR_SHIFT) /* vaddr span, not PDG sz */
#define PGDIR_MASK (~(PGDIR_SIZE-1))
-#ifdef __ASSEMBLY__
-#define PTRS_PER_PTE (1 << BITS_FOR_PTE)
-#define PTRS_PER_PGD (1 << BITS_FOR_PGD)
-#else
-#define PTRS_PER_PTE (1UL << BITS_FOR_PTE)
-#define PTRS_PER_PGD (1UL << BITS_FOR_PGD)
-#endif
+#define PTRS_PER_PTE _BITUL(BITS_FOR_PTE)
+#define PTRS_PER_PGD _BITUL(BITS_FOR_PGD)
+
/*
* Number of entries a user land program use.
* TASK_SIZE is the maximum vaddr that can be used by a userland program.