Bug 121404

Summary: CONFIG_DEBUG_SLAB causes PPC32 SIGFPE
Product: [Fedora] Fedora Reporter: David Woodhouse <dwmw2>
Component: kernelAssignee: Arjan van de Ven <arjanv>
Status: CLOSED RAWHIDE QA Contact: Brian Brock <bbrock>
Severity: medium Docs Contact:
Priority: medium    
Version: 2   
Target Milestone: ---   
Target Release: ---   
Hardware: powerpc   
OS: Linux   
Whiteboard:
Fixed In Version: 2.6.5-1.344 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2004-04-30 16:14:55 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On:    
Bug Blocks: 121179    
Attachments:
Description Flags
Patch to initialise tsk->thread.fpexc_mode
none
Patch to set ARCH_MIN_TASKALIGN none

Description David Woodhouse 2004-04-21 06:28:55 UTC
CONFIG_DEBUG_SLAB causes random SIGFPE to occur in FP-using processes.

Comment 1 David Woodhouse 2004-04-21 21:34:06 UTC
Some debugging (in ProgramCheckException()) gives:

SIGFPE fpscr ea0a420b code 30006 ip eac37f0 msr 10d032
SIGFPE fpscr ea0a420b code 30006 ip f351718 msr 10d032
SIGFPE fpscr ee0a460f code 30006 ip e79e2bc msr 210d032
SIGFPE fpscr ea0a420b code 30006 ip f47b578 msr 210d032
SIGFPE fpscr ee0a460f code 30006 ip f51fc50 msr 210d032
SIGFPE fpscr ea0a420b code 30006 ip eed2474 msr 10d032

In each case, we take a SIGFPE with code FPE_FLTRES, because the
FPSCR_XX bit is set and unmasked. Looks like fpscr isn't being
initialised correctly?

Comment 2 David Woodhouse 2004-04-21 22:10:33 UTC
Created attachment 99614 [details]
Patch to initialise tsk->thread.fpexc_mode

This fixes it but is probably the wrong thing to do since we won't now inherit
from our parent. Instead, we should set it correctly for the init task at boot
time.

Comment 3 David Woodhouse 2004-04-21 22:39:34 UTC
That patch seems to just work around the problem by disabling
exceptions. There's still other strangeness.

Comment 4 David Woodhouse 2004-04-22 02:11:06 UTC
Created attachment 99623 [details]
Patch to set ARCH_MIN_TASKALIGN

This is the real fix -- ensure the task_struct remains aligned to 16 bytes even
when redzoning is enabled.