Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

ARM: zx: add low level debug support for zx296702

Use the UART0 peripheral for low level debug. Only the UART port 0 is
currently supported.

Signed-off-by: Jun Nie <jun.nie@linaro.org>
Signed-off-by: Arnd Bergmann <arnd@arndb.de>

authored by

Jun Nie and committed by
Arnd Bergmann
58d03985 acede515

+21
+14
arch/arm/Kconfig.debug
··· 1166 1166 For more details about semihosting, please see 1167 1167 chapter 8 of DUI0203I_rvct_developer_guide.pdf from ARM Ltd. 1168 1168 1169 + config DEBUG_ZTE_ZX 1170 + bool "Use ZTE ZX UART" 1171 + select DEBUG_UART_PL01X 1172 + depends on ARCH_ZX 1173 + help 1174 + Say Y here if you are enabling ZTE ZX296702 SOC and need 1175 + debug uart support. 1176 + 1177 + This option is preferred over the platform specific 1178 + options; the platform specific options are deprecated 1179 + and will be soon removed. 1180 + 1169 1181 config DEBUG_LL_UART_8250 1170 1182 bool "Kernel low-level debugging via 8250 UART" 1171 1183 help ··· 1358 1346 default 0x02531000 if DEBUG_KEYSTONE_UART1 1359 1347 default 0x03010fe0 if ARCH_RPC 1360 1348 default 0x07000000 if DEBUG_SUN9I_UART0 1349 + default 0x09405000 if DEBUG_ZTE_ZX 1361 1350 default 0x10009000 if DEBUG_REALVIEW_STD_PORT || \ 1362 1351 DEBUG_VEXPRESS_UART0_CA9 1363 1352 default 0x1010c000 if DEBUG_REALVIEW_PB1176_PORT ··· 1490 1477 default 0xfb009000 if DEBUG_REALVIEW_STD_PORT 1491 1478 default 0xfb10c000 if DEBUG_REALVIEW_PB1176_PORT 1492 1479 default 0xfc40ab00 if DEBUG_BRCMSTB_UART 1480 + default 0xfc705000 if DEBUG_ZTE_ZX 1493 1481 default 0xfcfe8600 if DEBUG_UART_BCM63XX 1494 1482 default 0xfd000000 if ARCH_SPEAR3XX || ARCH_SPEAR6XX 1495 1483 default 0xfd000000 if ARCH_SPEAR13XX
+7
arch/arm/include/debug/pl01x.S
··· 12 12 */ 13 13 #include <linux/amba/serial.h> 14 14 15 + #ifdef CONFIG_DEBUG_ZTE_ZX 16 + #undef UART01x_DR 17 + #undef UART01x_FR 18 + #define UART01x_DR 0x04 19 + #define UART01x_FR 0x14 20 + #endif 21 + 15 22 #ifdef CONFIG_DEBUG_UART_PHYS 16 23 .macro addruart, rp, rv, tmp 17 24 ldr \rp, =CONFIG_DEBUG_UART_PHYS