Bug 1091641

Summary: x86_64 kernel should be built with CONFIG_X86_X32=y
Product: [Fedora] Fedora Reporter: Maciej Żenczykowski <zenczykowski>
Component: kernelAssignee: Kernel Maintainer List <kernel-maint>
Status: CLOSED DUPLICATE QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: medium Docs Contact:
Priority: unspecified    
Version: 20CC: gansalmon, itamar, jonathan, kernel-maint, madhu.chinakonda, mchehab
Target Milestone: ---   
Target Release: ---   
Hardware: x86_64   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2014-04-27 00:20:38 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Maciej Żenczykowski 2014-04-26 21:02:52 UTC
$ egrep X32 /boot/config-3.13.10-200.fc20.x86_64
# CONFIG_X86_X32 is not set

Could we toggle the above to on?

ie.
diff -Naur config-x86_64-generic_ config-x86_64-generic
--- config-x86_64-generic_	2014-04-26 00:11:33.532338990 -0700
+++ config-x86_64-generic	2014-04-26 00:17:41.300308003 -0700
@@ -1,6 +1,6 @@
 CONFIG_64BIT=y

-# CONFIG_X86_X32 is not set
+CONFIG_X86_X32=y
 # CONFIG_MK8 is not set
 # CONFIG_MPSC is not set
 CONFIG_GENERIC_CPU=y


Luckily f20 binutils already includes the required x32 support.

$ rpm -q --whatprovides `which objdump`
binutils-2.23.88.0.1-13.fc20.x86_64

$ objdump --help | egrep -i elf32-x86-64
objdump: supported targets: elf64-x86-64 elf32-i386 elf32-x86-64 a.out-i386-linux pei-i386 pei-x86-64 elf64-l1om elf64-k1om elf64-little elf64-big elf32-little elf32-big plugin srec symbolsrec verilog tekhex binary ihex

I've verified that the above patch is sufficient to get a kernel built/installed/booted,
and indeed the binutils is sufficient for the kernel to be built with (present in the command line visible in .o.cmd files) -DCONFIG_X86_X32_ABI

ie. this is all that is needed to run statically compiled x32 binaries on f20.

Comment 1 Josh Boyer 2014-04-27 00:20:38 UTC

*** This bug has been marked as a duplicate of bug 854317 ***