From: Michael Ellerman <mpe@ellerman.id.au>
To: linuxppc-dev@ozlabs.org
Cc: joel@jms.id.au, amodra@gmail.com
Subject: [PATCH 2/2] powerpc/vmlinux.lds: Discard .interp section
Date: Thu, 27 Feb 2020 15:59:33 +1100 [thread overview]
Message-ID: <20200227045933.22967-2-mpe@ellerman.id.au> (raw)
In-Reply-To: <20200227045933.22967-1-mpe@ellerman.id.au>
The .interp section specifies which "interpreter", ie. dynamic loader,
the kernel requests. But that doesn't make any sense, the kernel is
not a regular binary that is run with an interpreter.
The content seems to be some default value, this file doesn't even
exist on my system:
00000000 2f 75 73 72 2f 6c 69 62 2f 6c 64 2e 73 6f 2e 31 |/usr/lib/ld.so.1|
So the section serves no useful purpose and consumes a small amount of
space.
Also Alan Modra says we "likely could discard" it, so do so.
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
---
arch/powerpc/kernel/vmlinux.lds.S | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/arch/powerpc/kernel/vmlinux.lds.S b/arch/powerpc/kernel/vmlinux.lds.S
index 31a0f201fb6f..619ffbaf72ad 100644
--- a/arch/powerpc/kernel/vmlinux.lds.S
+++ b/arch/powerpc/kernel/vmlinux.lds.S
@@ -257,7 +257,6 @@ SECTIONS
}
.hash : AT(ADDR(.hash) - LOAD_OFFSET) { *(.hash) }
.gnu.hash : AT(ADDR(.gnu.hash) - LOAD_OFFSET) { *(.gnu.hash) }
- .interp : AT(ADDR(.interp) - LOAD_OFFSET) { *(.interp) }
.rela.dyn : AT(ADDR(.rela.dyn) - LOAD_OFFSET)
{
__rela_dyn_start = .;
@@ -370,5 +369,6 @@ SECTIONS
*(.gnu.version*)
*(.gnu.attributes)
*(.eh_frame)
+ *(.interp)
}
}
--
2.21.1
next prev parent reply other threads:[~2020-02-27 5:03 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-02-27 4:59 [PATCH 1/2] powerpc/vmlinux.lds: Explicitly retain .gnu.hash Michael Ellerman
2020-02-27 4:59 ` Michael Ellerman [this message]
2020-02-27 6:27 ` [PATCH 2/2] powerpc/vmlinux.lds: Discard .interp section Alan Modra
2020-03-27 9:27 ` Michael Ellerman
2020-02-27 6:21 ` [PATCH 1/2] powerpc/vmlinux.lds: Explicitly retain .gnu.hash Alan Modra
2020-03-27 9:29 ` Michael Ellerman
2020-04-01 12:53 ` Michael Ellerman
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20200227045933.22967-2-mpe@ellerman.id.au \
--to=mpe@ellerman.id.au \
--cc=amodra@gmail.com \
--cc=joel@jms.id.au \
--cc=linuxppc-dev@ozlabs.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).