Commit a0b54e25 authored by Nelson Elhage's avatar Nelson Elhage Committed by Ralf Baechle

MIPS: Use PAGE_SIZE in assembly instead of _PAGE_SIZE.

Now that PAGE_SIZE is available to assembly directly, there is no need
to separately expose it as _PAGE_SIZE through asm-offsets.

In addition, remove _PAGE_SHIFT from asm-offsets, since it was never
needed, and is not used anywhere.
Signed-off-by: default avatarNelson Elhage <nelhage@ksplice.com>
Signed-off-by: default avatarTim Abbott <tabbott@ksplice.com>
Signed-off-by: default avatarRalf Baechle <ralf@linux-mips.org>
parent 24ffce18
...@@ -183,9 +183,6 @@ void output_mm_defines(void) ...@@ -183,9 +183,6 @@ void output_mm_defines(void)
OFFSET(MM_PGD, mm_struct, pgd); OFFSET(MM_PGD, mm_struct, pgd);
OFFSET(MM_CONTEXT, mm_struct, context); OFFSET(MM_CONTEXT, mm_struct, context);
BLANK(); BLANK();
DEFINE(_PAGE_SIZE, PAGE_SIZE);
DEFINE(_PAGE_SHIFT, PAGE_SHIFT);
BLANK();
DEFINE(_PGD_T_SIZE, sizeof(pgd_t)); DEFINE(_PGD_T_SIZE, sizeof(pgd_t));
DEFINE(_PMD_T_SIZE, sizeof(pmd_t)); DEFINE(_PMD_T_SIZE, sizeof(pmd_t));
DEFINE(_PTE_T_SIZE, sizeof(pte_t)); DEFINE(_PTE_T_SIZE, sizeof(pte_t));
......
#include <asm/asm-offsets.h> #include <asm/asm-offsets.h>
#include <asm/page.h>
#include <asm-generic/vmlinux.lds.h> #include <asm-generic/vmlinux.lds.h>
#undef mips #undef mips
...@@ -76,7 +77,7 @@ SECTIONS ...@@ -76,7 +77,7 @@ SECTIONS
* of init_thread_union is greater than maximum * of init_thread_union is greater than maximum
* object file alignment. Using 32768 * object file alignment. Using 32768
*/ */
. = ALIGN(_PAGE_SIZE); . = ALIGN(PAGE_SIZE);
*(.data.init_task) *(.data.init_task)
DATA_DATA DATA_DATA
...@@ -96,12 +97,12 @@ SECTIONS ...@@ -96,12 +97,12 @@ SECTIONS
*(.sdata) *(.sdata)
} }
. = ALIGN(_PAGE_SIZE); . = ALIGN(PAGE_SIZE);
.data_nosave : { .data_nosave : {
__nosave_begin = .; __nosave_begin = .;
*(.data.nosave) *(.data.nosave)
} }
. = ALIGN(_PAGE_SIZE); . = ALIGN(PAGE_SIZE);
__nosave_end = .; __nosave_end = .;
. = ALIGN(1 << CONFIG_MIPS_L1_CACHE_SHIFT); . = ALIGN(1 << CONFIG_MIPS_L1_CACHE_SHIFT);
...@@ -111,7 +112,7 @@ SECTIONS ...@@ -111,7 +112,7 @@ SECTIONS
_edata = .; /* End of data section */ _edata = .; /* End of data section */
/* will be freed after init */ /* will be freed after init */
. = ALIGN(_PAGE_SIZE); /* Init code and data */ . = ALIGN(PAGE_SIZE); /* Init code and data */
__init_begin = .; __init_begin = .;
.init.text : { .init.text : {
_sinittext = .; _sinittext = .;
...@@ -151,15 +152,15 @@ SECTIONS ...@@ -151,15 +152,15 @@ SECTIONS
EXIT_DATA EXIT_DATA
} }
#if defined(CONFIG_BLK_DEV_INITRD) #if defined(CONFIG_BLK_DEV_INITRD)
. = ALIGN(_PAGE_SIZE); . = ALIGN(PAGE_SIZE);
.init.ramfs : { .init.ramfs : {
__initramfs_start = .; __initramfs_start = .;
*(.init.ramfs) *(.init.ramfs)
__initramfs_end = .; __initramfs_end = .;
} }
#endif #endif
PERCPU(_PAGE_SIZE) PERCPU(PAGE_SIZE)
. = ALIGN(_PAGE_SIZE); . = ALIGN(PAGE_SIZE);
__init_end = .; __init_end = .;
/* freed after init ends here */ /* freed after init ends here */
......
...@@ -8,6 +8,7 @@ ...@@ -8,6 +8,7 @@
* Wu Zhangjin <wuzj@lemote.com> * Wu Zhangjin <wuzj@lemote.com>
*/ */
#include <asm/asm-offsets.h> #include <asm/asm-offsets.h>
#include <asm/page.h>
#include <asm/regdef.h> #include <asm/regdef.h>
#include <asm/asm.h> #include <asm/asm.h>
...@@ -34,7 +35,7 @@ LEAF(swsusp_arch_resume) ...@@ -34,7 +35,7 @@ LEAF(swsusp_arch_resume)
0: 0:
PTR_L t1, PBE_ADDRESS(t0) /* source */ PTR_L t1, PBE_ADDRESS(t0) /* source */
PTR_L t2, PBE_ORIG_ADDRESS(t0) /* destination */ PTR_L t2, PBE_ORIG_ADDRESS(t0) /* destination */
PTR_ADDIU t3, t1, _PAGE_SIZE PTR_ADDIU t3, t1, PAGE_SIZE
1: 1:
REG_L t8, (t1) REG_L t8, (t1)
REG_S t8, (t2) REG_S t8, (t2)
......
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