Skip to content

Commit 10c77db

Browse files
bwhacksmpe
authored andcommitted
powerpc/boot: Fix build failure in 32-bit boot wrapper
OPAL is not callable from 32-bit mode and the assembly code for it may not even build (depending on how binutils was configured). References: https://buildd.debian.org/status/fetch.php?pkg=linux&arch=powerpcspe&ver=4.8.7-1&stamp=1479203712 Fixes: 656ad58 ("powerpc/boot: Add OPAL console to epapr wrappers") Cc: stable@vger.kernel.org # v4.8+ Signed-off-by: Ben Hutchings <ben@decadent.org.uk> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
1 parent 984d7a1 commit 10c77db

2 files changed

Lines changed: 3 additions & 2 deletions

File tree

arch/powerpc/boot/Makefile

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -100,7 +100,8 @@ src-wlib-y := string.S crt0.S crtsavres.S stdio.c decompress.c main.c \
100100
ns16550.c serial.c simple_alloc.c div64.S util.S \
101101
elf_util.c $(zlib-y) devtree.c stdlib.c \
102102
oflib.c ofconsole.c cuboot.c mpsc.c cpm-serial.c \
103-
uartlite.c mpc52xx-psc.c opal.c opal-calls.S
103+
uartlite.c mpc52xx-psc.c opal.c
104+
src-wlib-$(CONFIG_PPC64_BOOT_WRAPPER) += opal-calls.S
104105
src-wlib-$(CONFIG_40x) += 4xx.c planetcore.c
105106
src-wlib-$(CONFIG_44x) += 4xx.c ebony.c bamboo.c
106107
src-wlib-$(CONFIG_8xx) += mpc8xx.c planetcore.c fsl-soc.c

arch/powerpc/boot/opal.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
#include <libfdt.h>
1414
#include "../include/asm/opal-api.h"
1515

16-
#ifdef __powerpc64__
16+
#ifdef CONFIG_PPC64_BOOT_WRAPPER
1717

1818
/* Global OPAL struct used by opal-call.S */
1919
struct opal {

0 commit comments

Comments
 (0)