From: Pingfan Liu <kernelfans@gmail.com>
To: x86@kernel.org
Cc: Pingfan Liu <kernelfans@gmail.com>,
Thomas Gleixner <tglx@linutronix.de>,
Ingo Molnar <mingo@redhat.com>, Borislav Petkov <bp@alien8.de>,
"H. Peter Anvin" <hpa@zytor.com>,
Hans de Goede <hdegoede@redhat.com>,
Nick Desaulniers <ndesaulniers@google.com>,
Arvind Sankar <nivedita@alum.mit.edu>,
Steve Wahl <steve.wahl@hpe.com>,
linux-kernel@vger.kernel.org
Subject: [PATCH] x86/purgatory: strip debug info
Date: Thu, 30 Jul 2020 16:26:49 +0800 [thread overview]
Message-ID: <1596097609-14118-1-git-send-email-kernelfans@gmail.com> (raw)
It is useless to keep debug info in purgatory. And discarding them saves
about 200K space.
Original:
259080 kexec-purgatory.o
Stripped:
29152 kexec-purgatory.o
Signed-off-by: Pingfan Liu <kernelfans@gmail.com>
Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: Ingo Molnar <mingo@redhat.com>
Cc: Borislav Petkov <bp@alien8.de>
Cc: "H. Peter Anvin" <hpa@zytor.com>
Cc: Hans de Goede <hdegoede@redhat.com>
Cc: Nick Desaulniers <ndesaulniers@google.com>
Cc: Arvind Sankar <nivedita@alum.mit.edu>
Cc: Steve Wahl <steve.wahl@hpe.com>
Cc: linux-kernel@vger.kernel.org
To: x86@kernel.org
---
arch/x86/purgatory/Makefile | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/arch/x86/purgatory/Makefile b/arch/x86/purgatory/Makefile
index 088bd76..4340ae6 100644
--- a/arch/x86/purgatory/Makefile
+++ b/arch/x86/purgatory/Makefile
@@ -16,7 +16,7 @@ CFLAGS_sha256.o := -D__DISABLE_EXPORTS
# When linking purgatory.ro with -r unresolved symbols are not checked,
# also link a purgatory.chk binary without -r to check for unresolved symbols.
-PURGATORY_LDFLAGS := -e purgatory_start -nostdlib -z nodefaultlib
+PURGATORY_LDFLAGS := -e purgatory_start -nostdlib -z nodefaultlib -S
LDFLAGS_purgatory.ro := -r $(PURGATORY_LDFLAGS)
LDFLAGS_purgatory.chk := $(PURGATORY_LDFLAGS)
targets += purgatory.ro purgatory.chk
--
2.7.5
next reply other threads:[~2020-07-30 8:27 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-07-30 8:26 Pingfan Liu [this message]
2020-07-30 23:11 ` [PATCH] x86/purgatory: strip debug info Nick Desaulniers
2020-07-31 9:36 ` Pingfan Liu
2020-07-31 18:18 ` Nick Desaulniers
2020-08-03 4:13 ` Pingfan Liu
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=1596097609-14118-1-git-send-email-kernelfans@gmail.com \
--to=kernelfans@gmail.com \
--cc=bp@alien8.de \
--cc=hdegoede@redhat.com \
--cc=hpa@zytor.com \
--cc=linux-kernel@vger.kernel.org \
--cc=mingo@redhat.com \
--cc=ndesaulniers@google.com \
--cc=nivedita@alum.mit.edu \
--cc=steve.wahl@hpe.com \
--cc=tglx@linutronix.de \
--cc=x86@kernel.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