Skip to contentSkip to conversation

efi: Build EFI stub with EFI-appropriate options

PATCH Applied Matthew Garrett 5 participants 7 messages Jul 26, 2012 – Oct 24, 2012

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 efi: Build EFI stub with EFI-appropriate options

We can't assume the presence of the red zone while we're still in a boot services environment, so we should build with -fno-red-zone to avoid problems. Change the size of wchar at the same time to make string handling simpler.

---
 arch/x86/boot/compressed/Makefile |    3 +++
 1 file changed, 3 insertions(+)
arch/x86/boot/compressed/Makefile +3 -0
index e398bb5..8a84501 100644
@@ -28,6 +28,9 @@ VMLINUX_OBJS = $(obj)/vmlinux.lds $(obj)/head_$(BITS).o $(obj)/misc.o \
 	$(obj)/string.o $(obj)/cmdline.o $(obj)/early_serial_console.o \
 	$(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
 endif
Signature · 1 line
1.7.10.4
Acked-by on v1 1/1
#1 lore raw
Quoted 9 lines · Matthew Garrett

We can't assume the presence of the red zone while we're still in a boot services environment, so we should build with -fno-red-zone to avoid problems. Change the size of wchar at the same time to make string handling simpler.

---
 arch/x86/boot/compressed/Makefile |    3 +++
 1 file changed, 3 insertions(+)
#2 lore raw
In reply to Matthew Garrett
Quoted 15 lines · Matthew Garrett

We can't assume the presence of the red zone while we're still in a boot services environment, so we should build with -fno-red-zone to avoid problems. Change the size of wchar at the same time to make string handling simpler.

---
 arch/x86/boot/compressed/Makefile |    3 +++
 1 file changed, 3 insertions(+)
arch/x86/boot/compressed/Makefile +0 -0
index e398bb5..8a84501 100644

arch/x86/boot/compressed/Makefile VMLINUX_OBJS = $(obj)/vmlinux.lds $(obj)/head_$(BITS).o $(obj)/misc.o \ · line 36

Quoted 9 lines
arch/x86/boot/compressed/Makefile +3 -0
@@ -28,6 +28,9 @@ VMLINUX_OBJS = $(obj)/vmlinux.lds $(obj)/head_$(BITS).o $(obj)/misc.o \
        $(obj)/string.o $(obj)/cmdline.o $(obj)/early_serial_console.o \
        $(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
 endif

s/CLFAGS/CFLAGS/

should go to stable too?

--nX
--
To unsubscribe from this list: send the line "unsubscribe linux-efi" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html

#3 lore raw
Quoted 3 lines · Daniel Vacek

s/CLFAGS/CFLAGS/

should go to stable too?

Crap. Yes. Feel free to send that.

Signature · 5 lines
Matthew Garrett | [email protected]
--
To unsubscribe from this list: send the line "unsubscribe linux-efi" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
#4 lore raw
Quoted 7 lines · Matthew Garrett
Quoted 3 lines · Daniel Vacek

s/CLFAGS/CFLAGS/

should go to stable too?

Crap. Yes. Feel free to send that.

--nX

From 53864fe932aa87be62f1c70944c386cff9bb9130 Mon Sep 17 00:00:00 2001
From: Daniel Vacek <[email protected]>
Date: Thu, 18 Oct 2012 22:06:26 +0200
Subject: [PATCH] efi: fix typo in Makefile

---
 arch/x86/boot/compressed/Makefile |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
arch/x86/boot/compressed/Makefile +1 -1
index 8a84501..059a17f 100644
@@ -29,7 +29,7 @@ VMLINUX_OBJS = $(obj)/vmlinux.lds $(obj)/head_$(BITS).o $(obj)/misc.o \
 	$(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
+$(obj)/efi_stub_$(BITS).o: KBUILD_CFLAGS += -fshort-wchar -mno-red-zone
 
 ifeq ($(CONFIG_EFI_STUB), y)
 	VMLINUX_OBJS += $(obj)/eboot.o $(obj)/efi_stub_$(BITS).o
Signature · 1 line
1.7.10.4
Applied
#5 lore raw
Quoted 8 lines · Daniel Vacek
Quoted 7 lines · Matthew Garrett
Quoted 3 lines · Daniel Vacek

s/CLFAGS/CFLAGS/

should go to stable too?

Crap. Yes. Feel free to send that.

Applied, thanks.

greg k-h

#6 lore raw
Quoted 11 lines · Greg KH
Quoted 8 lines · Daniel Vacek
Quoted 7 lines · Matthew Garrett
Quoted 3 lines · Daniel Vacek

s/CLFAGS/CFLAGS/

should go to stable too?

Crap. Yes. Feel free to send that.

Applied, thanks.

Something went wrong. I responded to the other two emails.

--nX