aboutsummaryrefslogtreecommitdiffstats
path: root/target/linux/bcm63xx/image/lzma-loader/Makefile
diff options
context:
space:
mode:
authorÁlvaro Fernández Rojas <noltari@gmail.com>2020-05-20 09:14:02 +0200
committerÁlvaro Fernández Rojas <noltari@gmail.com>2020-05-20 11:15:29 +0200
commitc93cdf536a086deab0fa696989263a97b4d6c417 (patch)
tree962a57d8e1150af8504eaf3b57e5d51a768f64d2 /target/linux/bcm63xx/image/lzma-loader/Makefile
parent8e8920c92f1346ff1898b8674bc79d9a1a3ea59e (diff)
downloadupstream-c93cdf536a086deab0fa696989263a97b4d6c417.tar.gz
upstream-c93cdf536a086deab0fa696989263a97b4d6c417.tar.bz2
upstream-c93cdf536a086deab0fa696989263a97b4d6c417.zip
bcm63xx: lzma-loader: rely on CHIP_ID for UART address
lzma-loader uart output wasn't working on BCM3380/BCM6362 because these SoCs have the same processor ID. Let's use CHIP_ID for establishing the UART base address. Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
Diffstat (limited to 'target/linux/bcm63xx/image/lzma-loader/Makefile')
-rw-r--r--target/linux/bcm63xx/image/lzma-loader/Makefile22
1 files changed, 22 insertions, 0 deletions
diff --git a/target/linux/bcm63xx/image/lzma-loader/Makefile b/target/linux/bcm63xx/image/lzma-loader/Makefile
index 6100a8c2ea..2be41c875a 100644
--- a/target/linux/bcm63xx/image/lzma-loader/Makefile
+++ b/target/linux/bcm63xx/image/lzma-loader/Makefile
@@ -1,4 +1,6 @@
#
+# Copyright (C) 2020 Álvaro Fernández Rojas <noltari@gmail.com>
+# Copyright (C) 2014 Jonas Gorski <jogo@openwrt.org>
# Copyright (C) 2011 OpenWrt.org
# Copyright (C) 2011 Gabor Juhos <juhosg@openwrt.org>
#
@@ -14,6 +16,25 @@ LOADER_NAME := $(basename $(notdir $(LOADER)))
LOADER_DATA :=
TARGET_DIR :=
+UART_BASE_3329 := 0xb0000100
+UART_BASE_3368 := 0xfff8c100
+UART_BASE_3380 := 0xb4e00200
+UART_BASE_3383 := 0xb4e00500
+UART_BASE_3384 := 0xb4e00500
+UART_BASE_6318 := 0xb0000100
+UART_BASE_6328 := 0xb0000100
+UART_BASE_6338 := 0xfffe0300
+UART_BASE_6345 := 0xfffe0300
+UART_BASE_6348 := 0xfffe0300
+UART_BASE_6358 := 0xfffe0100
+UART_BASE_6362 := 0xb0000100
+UART_BASE_6368 := 0xb0000100
+UART_BASE_63268 := 0xb0000180
+UART_BASE_6816 := 0xb0000100
+UART_BASE_6818 := 0xb0000100
+UART_BASE_6828 := 0xb0000180
+UART_BASE := $(if $(UART_BASE_$(CHIP_ID)),$(UART_BASE_$(CHIP_ID)),0)
+
ifeq ($(TARGET_DIR),)
TARGET_DIR := $(KDIR)
endif
@@ -35,6 +56,7 @@ loader-compile: $(PKG_BUILD_DIR)/.prepared
$(MAKE) -C $(PKG_BUILD_DIR) CROSS_COMPILE="$(TARGET_CROSS)" \
LZMA_TEXT_START=$(LZMA_TEXT_START) \
LOADER_DATA=$(LOADER_DATA) \
+ UART_BASE=$(UART_BASE) \
clean all
loader.elf: $(PKG_BUILD_DIR)/loader.elf