Bug 698256

Summary: CONFIG_TUNE_CELL should be disabled on PPC/PPC64
Product: [Fedora] Fedora Reporter: Karsten Hopp <karsten>
Component: kernelAssignee: Kyle McMartin <kmcmartin>
Status: CLOSED RAWHIDE QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 15CC: davej, gansalmon, hbabu, itamar, jonathan, kernel-maint, madhu.chinakonda, peterm
Target Milestone: ---   
Target Release: ---   
Hardware: powerpc   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2011-06-23 12:29:35 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:

Description Karsten Hopp 2011-04-20 14:21:06 UTC
Description of problem:
CONFIG_TUNE_CELL causes problems on non-Power7 machinesand needs to be disabled.
Kernels build with this option won't boot on older PPC machines:
'Illegal Instruction'
The offending instruction is ldbrx which is an ISA 2.06 instruction found on power7 in 64-bit mode only.
Josh Boyer mentioned on IRC that he's 'pretty sure CONFIG_TUNE_CELL=y is set in the configs.  that might be allowing gcc/binutils to generate that instruction'

I've done a scratch build of a kernel with TUNE_CELL disabled and it boots where the kernel with TUNE_CELL enabled doesn't boot.
Due to the huge initrd we most likely won't be able to install on PS3 with Cell anyway so disabling this should be ok.

Comment 1 Chuck Ebbert 2011-04-25 01:46:46 UTC
config TUNE_CELL
        bool "Optimize for Cell Broadband Engine"
        depends on PPC64 && PPC_BOOK3S
        help
          Cause the compiler to optimize for the PPE of the Cell Broadband
          Engine. This will make the code run considerably faster on Cell
===>      but somewhat slower on other machines. This option only changes
===>      the scheduling of instructions, not the selection of instructions
===>      itself, so the resulting kernel will keep running on all other
===>      machines. When building a kernel that is supposed to run only
          on Cell, you should also select the POWER4_ONLY option.

So, maybe this is a binutils bug?

Comment 2 Kyle McMartin 2011-04-25 02:19:55 UTC
Probably -- it's similar to the pentium-versus-586-versus-686 catastrophe on i386. Safest just to turn off the -mtune and not worry about it in the future.

Comment 3 Chuck Ebbert 2011-06-23 12:29:35 UTC
This change was made in f15 and rawhide on Jun 24.