openwrt/target/linux/mpc85xx/patches-5.15/106-powerpc-85xx-ws-ap3710i-support.patch
David Bauer 3001d3c5d4 mpc85xx: fix WS-AP3710i boot
On master, the bootwrapper link-address for all simpleImage targets was
relocated to 0x15000000 due to growing kernel size.

This was not done on OpenWrt 23.05, as the decompressed kernel still
fits. However, with the wrapper for the WS-AP3710i, the bootloader
attempts execute in-place with the uImage load-address of 0x1000000. As
the image is compiled without the uImage header in mind, this naturally
fails.

In order to fix this, link the WS-AP3715i simpleImage at 0x15000000 as
done in master. This will force the bootloader to relocate the code to
the proper address and skip XIP.

Signed-off-by: David Bauer <mail@david-bauer.net>
2024-06-10 03:37:03 +02:00

63 lines
2.2 KiB
Diff

--- a/arch/powerpc/platforms/85xx/Kconfig
+++ b/arch/powerpc/platforms/85xx/Kconfig
@@ -71,6 +71,17 @@ config PANDA
This board is a Concurrent Dual-Band wireless access point with a
Freescale P1020 SoC.
+config WS_AP3710I
+ bool "Enterasys WS-AP3710i"
+ select DEFAULT_UIMAGE
+ select ARCH_REQUIRE_GPIOLIB
+ select GPIO_MPC8XXX
+ help
+ This option enables support for the Enterasys WS-AP3710i board.
+
+ This board is a Concurrent Dual-Band wireless access point with a
+ Freescale P1020 SoC.
+
config MPC8540_ADS
bool "Freescale MPC8540 ADS"
select DEFAULT_UIMAGE
--- a/arch/powerpc/platforms/85xx/Makefile
+++ b/arch/powerpc/platforms/85xx/Makefile
@@ -26,6 +26,7 @@ obj-$(CONFIG_P1022_RDK) += p1022_rdk.o
obj-$(CONFIG_P1023_RDB) += p1023_rdb.o
obj-$(CONFIG_PANDA) += panda.o
obj-$(CONFIG_TWR_P102x) += twr_p102x.o
+obj-$(CONFIG_WS_AP3710I) += ws-ap3710i.o
obj-$(CONFIG_CORENET_GENERIC) += corenet_generic.o
obj-$(CONFIG_FB_FSL_DIU) += t1042rdb_diu.o
obj-$(CONFIG_RED_15W_REV1) += red15w_rev1.o
--- a/arch/powerpc/boot/Makefile
+++ b/arch/powerpc/boot/Makefile
@@ -164,6 +164,7 @@ src-plat-$(CONFIG_PPC_POWERNV) += pserie
src-plat-$(CONFIG_PPC_IBM_CELL_BLADE) += pseries-head.S
src-plat-$(CONFIG_MVME7100) += motload-head.S mvme7100.c
src-plat-$(CONFIG_TL_WDR4900_V1) += simpleboot.c fixed-head.S
+src-plat-$(CONFIG_WS_AP3710I) += simpleboot.c fixed-head.S
src-plat-$(CONFIG_PPC_MICROWATT) += fixed-head.S microwatt.c
@@ -345,6 +346,7 @@ image-$(CONFIG_TQM8555) += cuImage.tqm
image-$(CONFIG_TQM8560) += cuImage.tqm8560
image-$(CONFIG_KSI8560) += cuImage.ksi8560
image-$(CONFIG_TL_WDR4900_V1) += simpleImage.tl-wdr4900-v1
+image-$(CONFIG_WS_AP3710I) += simpleImage.ws-ap3710i
# Board ports in arch/powerpc/platform/86xx/Kconfig
image-$(CONFIG_MVME7100) += dtbImage.mvme7100
--- a/arch/powerpc/boot/wrapper
+++ b/arch/powerpc/boot/wrapper
@@ -331,6 +331,11 @@ simpleboot-tl-wdr4900-v1)
link_address='0x1000000'
binary=y
;;
+simpleboot-ws-ap3710i)
+ platformo="$object/fixed-head.o $object/simpleboot.o"
+ link_address='0x1500000'
+ binary=y
+ ;;
simpleboot-*)
platformo="$object/fixed-head.o $object/simpleboot.o"
binary=y