diff options
author | Michael Ellerman <michael@ellerman.id.au> | 2013-06-25 03:47:54 -0400 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2013-07-25 17:07:21 -0400 |
commit | 497f0957430403bc4e3a0c776da3907fe769b64f (patch) | |
tree | d9536d86d0942fda1b5d2d25932a02892f2c2be0 /arch | |
parent | 81bcd526fea6383be0361b1827fcac656d276d57 (diff) |
powerpc: Remove unreachable relocation on exception handlers
commit 1d567cb4bd42d560a7621cac6f6aebe87343689e upstream.
We have relocation on exception handlers defined for h_data_storage and
h_instr_storage. However we will never take relocation on exceptions for
these because they can only come from a guest, and we never take
relocation on exceptions when we transition from guest to host.
We also have a handler for hmi_exception (Hypervisor Maintenance) which
is defined in the architecture to never be delivered with relocation on,
see see v2.07 Book III-S section 6.5.
So remove the handlers, leaving a branch to self just to be double extra
paranoid.
Signed-off-by: Michael Ellerman <michael@ellerman.id.au>
Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'arch')
-rw-r--r-- | arch/powerpc/kernel/exceptions-64s.S | 18 |
1 files changed, 3 insertions, 15 deletions
diff --git a/arch/powerpc/kernel/exceptions-64s.S b/arch/powerpc/kernel/exceptions-64s.S index 40e4a17c8ba0..0a9fdea2fc0f 100644 --- a/arch/powerpc/kernel/exceptions-64s.S +++ b/arch/powerpc/kernel/exceptions-64s.S | |||
@@ -793,14 +793,10 @@ system_call_relon_pSeries: | |||
793 | STD_RELON_EXCEPTION_PSERIES(0x4d00, 0xd00, single_step) | 793 | STD_RELON_EXCEPTION_PSERIES(0x4d00, 0xd00, single_step) |
794 | 794 | ||
795 | . = 0x4e00 | 795 | . = 0x4e00 |
796 | SET_SCRATCH0(r13) | 796 | b . /* Can't happen, see v2.07 Book III-S section 6.5 */ |
797 | EXCEPTION_PROLOG_0(PACA_EXGEN) | ||
798 | b h_data_storage_relon_hv | ||
799 | 797 | ||
800 | . = 0x4e20 | 798 | . = 0x4e20 |
801 | SET_SCRATCH0(r13) | 799 | b . /* Can't happen, see v2.07 Book III-S section 6.5 */ |
802 | EXCEPTION_PROLOG_0(PACA_EXGEN) | ||
803 | b h_instr_storage_relon_hv | ||
804 | 800 | ||
805 | . = 0x4e40 | 801 | . = 0x4e40 |
806 | SET_SCRATCH0(r13) | 802 | SET_SCRATCH0(r13) |
@@ -808,9 +804,7 @@ system_call_relon_pSeries: | |||
808 | b emulation_assist_relon_hv | 804 | b emulation_assist_relon_hv |
809 | 805 | ||
810 | . = 0x4e60 | 806 | . = 0x4e60 |
811 | SET_SCRATCH0(r13) | 807 | b . /* Can't happen, see v2.07 Book III-S section 6.5 */ |
812 | EXCEPTION_PROLOG_0(PACA_EXGEN) | ||
813 | b hmi_exception_relon_hv | ||
814 | 808 | ||
815 | . = 0x4e80 | 809 | . = 0x4e80 |
816 | SET_SCRATCH0(r13) | 810 | SET_SCRATCH0(r13) |
@@ -1180,14 +1174,8 @@ tm_unavailable_common: | |||
1180 | __end_handlers: | 1174 | __end_handlers: |
1181 | 1175 | ||
1182 | /* Equivalents to the above handlers for relocation-on interrupt vectors */ | 1176 | /* Equivalents to the above handlers for relocation-on interrupt vectors */ |
1183 | STD_RELON_EXCEPTION_HV_OOL(0xe00, h_data_storage) | ||
1184 | KVM_HANDLER(PACA_EXGEN, EXC_HV, 0xe00) | ||
1185 | STD_RELON_EXCEPTION_HV_OOL(0xe20, h_instr_storage) | ||
1186 | KVM_HANDLER(PACA_EXGEN, EXC_HV, 0xe20) | ||
1187 | STD_RELON_EXCEPTION_HV_OOL(0xe40, emulation_assist) | 1177 | STD_RELON_EXCEPTION_HV_OOL(0xe40, emulation_assist) |
1188 | KVM_HANDLER(PACA_EXGEN, EXC_HV, 0xe40) | 1178 | KVM_HANDLER(PACA_EXGEN, EXC_HV, 0xe40) |
1189 | STD_RELON_EXCEPTION_HV_OOL(0xe60, hmi_exception) | ||
1190 | KVM_HANDLER(PACA_EXGEN, EXC_HV, 0xe60) | ||
1191 | MASKABLE_RELON_EXCEPTION_HV_OOL(0xe80, h_doorbell) | 1179 | MASKABLE_RELON_EXCEPTION_HV_OOL(0xe80, h_doorbell) |
1192 | KVM_HANDLER(PACA_EXGEN, EXC_HV, 0xe80) | 1180 | KVM_HANDLER(PACA_EXGEN, EXC_HV, 0xe80) |
1193 | 1181 | ||