[PATCH] mips: Use the common RW_DATA macro in vmlinux.lds.S

From: Youling Tang
Date: Wed Nov 04 2020 - 06:10:49 EST


Use the common RW_DATA rule for the linker script in an effort to
regularize the linker script.

Signed-off-by: Youling Tang <tangyouling@xxxxxxxxxxx>
---
arch/mips/kernel/vmlinux.lds.S | 15 +++------------
1 file changed, 3 insertions(+), 12 deletions(-)

diff --git a/arch/mips/kernel/vmlinux.lds.S b/arch/mips/kernel/vmlinux.lds.S
index 5e97e9d..e2fa07e 100644
--- a/arch/mips/kernel/vmlinux.lds.S
+++ b/arch/mips/kernel/vmlinux.lds.S
@@ -84,18 +84,9 @@ SECTIONS
_sdata = .; /* Start of data section */
RO_DATA(4096)

- /* writeable */
- .data : { /* Data */
- . = . + DATAOFFSET; /* for CONFIG_MAPPED_KERNEL */
-
- INIT_TASK_DATA(THREAD_SIZE)
- NOSAVE_DATA
- CACHELINE_ALIGNED_DATA(1 << CONFIG_MIPS_L1_CACHE_SHIFT)
- READ_MOSTLY_DATA(1 << CONFIG_MIPS_L1_CACHE_SHIFT)
- DATA_DATA
- CONSTRUCTORS
- }
- BUG_TABLE
+ . = . + DATAOFFSET; /* for CONFIG_MAPPED_KERNEL */
+ RW_DATA(1 << CONFIG_MIPS_L1_CACHE_SHIFT, PAGE_SIZE, THREAD_SIZE)
+
_gp = . + 0x8000;
.lit8 : {
*(.lit8)
--
2.1.0