Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

powerpc/booke: Revert SPE/AltiVec common defines for interrupt numbers

Book3E specification defines shared interrupt numbers for SPE and AltiVec
units. Still SPE is present in e200/e500v2 cores while AltiVec is present in
e6500 core. So we can currently decide at compile-time which unit to support
exclusively. As Alexander Graf suggested, this will improve code readability
especially in KVM.

Use distinct defines to identify SPE/AltiVec interrupt numbers, reverting
c58ce397 and 6b310fc5 patches that added common defines.

Signed-off-by: Mihai Caraman <mihai.caraman@freescale.com>
Acked-by: Scott Wood <scottwood@freescale.com>
Signed-off-by: Alexander Graf <agraf@suse.de>

authored by

Mihai Caraman and committed by
Alexander Graf
2b2695a8 3477e71d

+6 -6
+2 -2
arch/powerpc/kernel/exceptions-64e.S
··· 635 635 636 636 /* Altivec Unavailable Interrupt */ 637 637 START_EXCEPTION(altivec_unavailable); 638 - NORMAL_EXCEPTION_PROLOG(0x200, BOOKE_INTERRUPT_SPE_ALTIVEC_UNAVAIL, 638 + NORMAL_EXCEPTION_PROLOG(0x200, BOOKE_INTERRUPT_ALTIVEC_UNAVAIL, 639 639 PROLOG_ADDITION_NONE) 640 640 /* we can probably do a shorter exception entry for that one... */ 641 641 EXCEPTION_COMMON(0x200) ··· 658 658 /* AltiVec Assist */ 659 659 START_EXCEPTION(altivec_assist); 660 660 NORMAL_EXCEPTION_PROLOG(0x220, 661 - BOOKE_INTERRUPT_SPE_FP_DATA_ALTIVEC_ASSIST, 661 + BOOKE_INTERRUPT_ALTIVEC_ASSIST, 662 662 PROLOG_ADDITION_NONE) 663 663 EXCEPTION_COMMON(0x220) 664 664 INTS_DISABLE
+4 -4
arch/powerpc/kernel/head_fsl_booke.S
··· 617 617 #ifdef CONFIG_SPE 618 618 /* SPE Unavailable */ 619 619 START_EXCEPTION(SPEUnavailable) 620 - NORMAL_EXCEPTION_PROLOG(SPE_ALTIVEC_UNAVAIL) 620 + NORMAL_EXCEPTION_PROLOG(SPE_UNAVAIL) 621 621 beq 1f 622 622 bl load_up_spe 623 623 b fast_exception_return 624 624 1: addi r3,r1,STACK_FRAME_OVERHEAD 625 625 EXC_XFER_EE_LITE(0x2010, KernelSPE) 626 626 #elif defined(CONFIG_SPE_POSSIBLE) 627 - EXCEPTION(0x2020, SPE_ALTIVEC_UNAVAIL, SPEUnavailable, \ 627 + EXCEPTION(0x2020, SPE_UNAVAIL, SPEUnavailable, \ 628 628 unknown_exception, EXC_XFER_EE) 629 629 #endif /* CONFIG_SPE_POSSIBLE */ 630 630 631 631 /* SPE Floating Point Data */ 632 632 #ifdef CONFIG_SPE 633 - EXCEPTION(0x2030, SPE_FP_DATA_ALTIVEC_ASSIST, SPEFloatingPointData, 633 + EXCEPTION(0x2030, SPE_FP_DATA, SPEFloatingPointData, 634 634 SPEFloatingPointException, EXC_XFER_EE) 635 635 636 636 /* SPE Floating Point Round */ 637 637 EXCEPTION(0x2050, SPE_FP_ROUND, SPEFloatingPointRound, \ 638 638 SPEFloatingPointRoundException, EXC_XFER_EE) 639 639 #elif defined(CONFIG_SPE_POSSIBLE) 640 - EXCEPTION(0x2040, SPE_FP_DATA_ALTIVEC_ASSIST, SPEFloatingPointData, 640 + EXCEPTION(0x2040, SPE_FP_DATA, SPEFloatingPointData, 641 641 unknown_exception, EXC_XFER_EE) 642 642 EXCEPTION(0x2050, SPE_FP_ROUND, SPEFloatingPointRound, \ 643 643 unknown_exception, EXC_XFER_EE)