mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: "H. Peter Anvin" <hpa@zytor.com>
To: Jan Beulich <JBeulich@suse.com>, mingo@elte.hu, tglx@linutronix.de
Cc: Matt Fleming <matt.fleming@intel.com>,
	mjg@redhat.com, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] x86: fix rebuild with EFI_STUB enabled
Date: Wed, 03 Apr 2013 07:48:30 -0700	[thread overview]
Message-ID: <5a3182e0-580a-42f4-a17f-925836cca7d2@email.android.com> (raw)
In-Reply-To: <515C5D2502000078000CA6AD@nat28.tlf.novell.com>

This looks awesome for 3.10, but getting a minimal fix for 3.9/stable would be good, too.

Jan Beulich <JBeulich@suse.com> wrote:

>eboot.o and efi_stub_$(BITS).o didn't get added to "targets", and hence
>their .cmd files don't get included by the build machinery, leading to
>the files always getting rebuilt.
>
>Rather than adding the two files individually, take the opportunity and
>add $(VMLINUX_OBJS) to "targets" instead, thus allowing the assignment
>at the top of the file to be shrunk quite a bit.
>
>At the same time, remove a pointless flags override line - the variable
>assigned to was misspelled anyway, and the options added are
>meaningless for assembly sources.
>
>Signed-off-by: Jan Beulich <jbeulich@suse.com>
>Cc: Matthew Garrett <mjg@redhat.com>
>Cc: Matt Fleming <matt.fleming@intel.com>
>---
> arch/x86/boot/compressed/Makefile |    5 ++---
> 1 file changed, 2 insertions(+), 3 deletions(-)
>
>--- 3.9-rc5/arch/x86/boot/compressed/Makefile
>+++ 3.9-rc5-x86-EFI-stub-rebuild/arch/x86/boot/compressed/Makefile
>@@ -4,7 +4,7 @@
> # create a compressed vmlinux image from the original vmlinux
> #
> 
>-targets := vmlinux.lds vmlinux vmlinux.bin vmlinux.bin.gz
>vmlinux.bin.bz2 vmlinux.bin.lzma vmlinux.bin.xz vmlinux.bin.lzo
>head_$(BITS).o misc.o string.o cmdline.o early_serial_console.o piggy.o
>+targets := vmlinux vmlinux.bin vmlinux.bin.gz vmlinux.bin.bz2
>vmlinux.bin.lzma vmlinux.bin.xz vmlinux.bin.lzo
> 
> KBUILD_CFLAGS := -m$(BITS) -D__KERNEL__ $(LINUX_INCLUDE) -O2
> KBUILD_CFLAGS += -fno-strict-aliasing -fPIC
>@@ -29,7 +29,6 @@ VMLINUX_OBJS = $(obj)/vmlinux.lds $(obj)
> 	$(obj)/piggy.o
> 
> $(obj)/eboot.o: KBUILD_CFLAGS += -fshort-wchar -mno-red-zone
>-$(obj)/efi_stub_$(BITS).o: KBUILD_CLFAGS += -fshort-wchar
>-mno-red-zone
> 
> ifeq ($(CONFIG_EFI_STUB), y)
> 	VMLINUX_OBJS += $(obj)/eboot.o $(obj)/efi_stub_$(BITS).o
>@@ -43,7 +42,7 @@ OBJCOPYFLAGS_vmlinux.bin :=  -R .comment
> $(obj)/vmlinux.bin: vmlinux FORCE
> 	$(call if_changed,objcopy)
> 
>-targets += vmlinux.bin.all vmlinux.relocs
>+targets += $(patsubst $(obj)/%,%,$(VMLINUX_OBJS)) vmlinux.bin.all
>vmlinux.relocs
> 
> CMD_RELOCS = arch/x86/tools/relocs
> quiet_cmd_relocs = RELOCS  $@

-- 
Sent from my mobile phone. Please excuse brevity and lack of formatting.

  reply	other threads:[~2013-04-03 14:49 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-04-03 14:47 Jan Beulich
2013-04-03 14:48 ` H. Peter Anvin [this message]
2013-04-03 14:58   ` Jan Beulich
2013-04-03 15:26     ` H. Peter Anvin
2013-04-05 22:29 ` [tip:x86/urgent] x86: Fix " tip-bot for Jan Beulich

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=5a3182e0-580a-42f4-a17f-925836cca7d2@email.android.com \
    --to=hpa@zytor.com \
    --cc=JBeulich@suse.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=matt.fleming@intel.com \
    --cc=mingo@elte.hu \
    --cc=mjg@redhat.com \
    --cc=tglx@linutronix.de \
    /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

all inboxes | Powered by JetHome®