From 48039c333f057a8f95420e1ddf33c77ac974a113 Mon Sep 17 00:00:00 2001 From: Ovidiu Panait Date: Tue, 30 Nov 2021 18:33:52 +0200 Subject: microblaze: start.S: use stack space as scratch memory for endian offset To simpify the code, use stack space as scratch memory for endian offset calculation, rather than saving/restoring the first unused MB vector. Signed-off-by: Ovidiu Panait Link: https://lore.kernel.org/r/20211130163358.2531677-5-ovidiu.panait@windriver.com Signed-off-by: Michal Simek --- arch/microblaze/cpu/start.S | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/arch/microblaze/cpu/start.S b/arch/microblaze/cpu/start.S index 463e0feba47..a1c06108d72 100644 --- a/arch/microblaze/cpu/start.S +++ b/arch/microblaze/cpu/start.S @@ -125,10 +125,8 @@ __setup_exceptions: * 4b) BIG endian - r10 contains 0x0 because 0x2 offset is on addr 0x3 */ addik r6, r0, 0x2 /* BIG/LITTLE endian offset */ - lwi r7, r0, 0x28 - swi r6, r0, 0x28 /* used first unused MB vector */ - lbui r10, r0, 0x28 /* used first unused MB vector */ - swi r7, r0, 0x28 + sw r6, r1, r0 + lbu r10, r1, r0 /* add opcode instruction for 32bit jump - 2 instruction imm & brai */ addi r2, r0, 0xb0000000 /* hex b000 opcode imm */ -- cgit v1.2.3