Commit 709ebe6d authored by Linus Torvalds's avatar Linus Torvalds
Browse files

Merge tag 'for-linus' of git://git.armlinux.org.uk/~rmk/linux-arm

Pull ARM updates from Russell King:

 - handle inexact watchpoint addresses (Douglas Anderson)

 - decompressor serial debug cleanups (Linus Walleij)

 - update L2 cache prefetch bits (Guillaume Tucker)

 - add text offset and malloc size to the decompressor kexec data

* tag 'for-linus' of git://git.armlinux.org.uk/~rmk/linux-arm:
  ARM: add malloc size to decompressor kexec size structure
  ARM: add TEXT_OFFSET to decompressor kexec image structure
  ARM: 9007/1: l2c: fix prefetch bits init in L2X0_AUX_CTRL using DT values
  ARM: 9010/1: uncompress: Print the location of appended DTB
  ARM: 9009/1: uncompress: Enable debug in head.S
  ARM: 9008/1: uncompress: Drop excess whitespace print
  ARM: 9006/1: uncompress: Wait for ready and busy in debug prints
  ARM: 9005/1: debug: Select flow control for all debug UARTs
  ARM: 9004/1: debug: Split waituart to CTS and TXRDY
  ARM: 9003/1: uncompress: Delete unused debug macros
  ARM: 8997/2: hw_breakpoint: Handle inexact watchpoint addresses
parents b32649b8 adc5f702
Loading
Loading
Loading
Loading
+11 −5
Original line number Diff line number Diff line
@@ -1546,6 +1546,17 @@ config DEBUG_SIRFSOC_UART
	bool
	depends on ARCH_SIRF

config DEBUG_UART_FLOW_CONTROL
	bool "Enable flow control (CTS) for the debug UART"
	depends on DEBUG_LL
	default y if ARCH_EBSA110 || DEBUG_FOOTBRIDGE_COM1 || DEBUG_GEMINI || ARCH_RPC
	help
	  Some UART ports are connected to terminals that will use modem
	  control signals to indicate whether they are ready to receive text.
	  In practice this means that the terminal is asserting the special
	  control signal CTS (Clear To Send). If your debug UART supports
	  this and your debug terminal will require it, enable this option.

config DEBUG_LL_INCLUDE
	string
	default "debug/sa1100.S" if DEBUG_SA1100
@@ -1893,11 +1904,6 @@ config DEBUG_UART_8250_PALMCHIP
	  except for having a different register layout.  Say Y here if
	  the debug UART is of this type.

config DEBUG_UART_8250_FLOW_CONTROL
	bool "Enable flow control for 8250 UART"
	depends on DEBUG_LL_UART_8250 || DEBUG_UART_8250
	default y if ARCH_EBSA110 || DEBUG_FOOTBRIDGE_COM1 || DEBUG_GEMINI || ARCH_RPC

config DEBUG_UNCOMPRESS
	bool "Enable decompressor debugging via DEBUG_LL output"
	depends on ARCH_MULTIPLATFORM || PLAT_SAMSUNG || ARM_SINGLE_ARMV7M
+3 −0
Original line number Diff line number Diff line
@@ -143,6 +143,9 @@ head-y := arch/arm/kernel/head$(MMUEXT).o

# Text offset. This list is sorted numerically by address in order to
# provide a means to avoid/resolve conflicts in multi-arch kernels.
# Note: the 32kB below this value is reserved for use by the kernel
# during boot, and this offset is critical to the functioning of
# kexec-tools.
textofs-y	:= 0x00008000
# We don't want the htc bootloader to corrupt kernel during resume
textofs-$(CONFIG_PM_H1940)      := 0x00108000
+6 −1
Original line number Diff line number Diff line
@@ -7,11 +7,11 @@

OBJS		=

AFLAGS_head.o += -DTEXT_OFFSET=$(TEXT_OFFSET)
HEAD	= head.o
OBJS	+= misc.o decompress.o
ifeq ($(CONFIG_DEBUG_UNCOMPRESS),y)
OBJS	+= debug.o
AFLAGS_head.o += -DDEBUG
endif
FONTC	= $(srctree)/lib/fonts/font_acorn_8x8.c

@@ -68,7 +68,12 @@ ZTEXTADDR := 0
ZBSSADDR	:= ALIGN(8)
endif

MALLOC_SIZE	:= 65536

AFLAGS_head.o += -DTEXT_OFFSET=$(TEXT_OFFSET) -DMALLOC_SIZE=$(MALLOC_SIZE)
CPPFLAGS_vmlinux.lds := -DTEXT_START="$(ZTEXTADDR)" -DBSS_START="$(ZBSSADDR)"
CPPFLAGS_vmlinux.lds += -DTEXT_OFFSET="$(TEXT_OFFSET)"
CPPFLAGS_vmlinux.lds += -DMALLOC_SIZE="$(MALLOC_SIZE)"

compress-$(CONFIG_KERNEL_GZIP) = gzip
compress-$(CONFIG_KERNEL_LZO)  = lzo
+4 −1
Original line number Diff line number Diff line
@@ -8,7 +8,10 @@

ENTRY(putc)
	addruart r1, r2, r3
	waituart r3, r1
#ifdef CONFIG_DEBUG_UART_FLOW_CONTROL
	waituartcts r3, r1
#endif
	waituarttxrdy r3, r1
	senduart r0, r1
	busyuart r3, r1
	mov	 pc, lr
+35 −39
Original line number Diff line number Diff line
@@ -28,19 +28,19 @@
#if defined(CONFIG_CPU_V6) || defined(CONFIG_CPU_V6K) || defined(CONFIG_CPU_V7)
		.macro	loadsp, rb, tmp1, tmp2
		.endm
		.macro	writeb, ch, rb
		.macro	writeb, ch, rb, tmp
		mcr	p14, 0, \ch, c0, c5, 0
		.endm
#elif defined(CONFIG_CPU_XSCALE)
		.macro	loadsp, rb, tmp1, tmp2
		.endm
		.macro	writeb, ch, rb
		.macro	writeb, ch, rb, tmp
		mcr	p14, 0, \ch, c8, c0, 0
		.endm
#else
		.macro	loadsp, rb, tmp1, tmp2
		.endm
		.macro	writeb, ch, rb
		.macro	writeb, ch, rb, tmp
		mcr	p14, 0, \ch, c1, c0, 0
		.endm
#endif
@@ -49,8 +49,13 @@

#include CONFIG_DEBUG_LL_INCLUDE

		.macro	writeb,	ch, rb
		.macro	writeb,	ch, rb, tmp
#ifdef CONFIG_DEBUG_UART_FLOW_CONTROL
		waituartcts \tmp, \rb
#endif
		waituarttxrdy \tmp, \rb
		senduart \ch, \rb
		busyuart \tmp, \rb
		.endm

#if defined(CONFIG_ARCH_SA1100)
@@ -81,42 +86,11 @@
		bl	phex
		.endm

		.macro	debug_reloc_start
#ifdef DEBUG
		kputc	#'\n'
		kphex	r6, 8		/* processor id */
		kputc	#':'
		kphex	r7, 8		/* architecture id */
#ifdef CONFIG_CPU_CP15
		kputc	#':'
		mrc	p15, 0, r0, c1, c0
		kphex	r0, 8		/* control reg */
#endif
		kputc	#'\n'
		kphex	r5, 8		/* decompressed kernel start */
		kputc	#'-'
		kphex	r9, 8		/* decompressed kernel end  */
		kputc	#'>'
		kphex	r4, 8		/* kernel execution address */
		kputc	#'\n'
#endif
		.endm

		.macro	debug_reloc_end
#ifdef DEBUG
		kphex	r5, 8		/* end of kernel */
		kputc	#'\n'
		mov	r0, r4
		bl	memdump		/* dump 256 bytes at start of kernel */
#endif
		.endm

		/*
		 * Debug kernel copy by printing the memory addresses involved
		 */
		.macro dbgkc, begin, end, cbegin, cend
#ifdef DEBUG
		kputc   #'\n'
		kputc   #'C'
		kputc   #':'
		kputc   #'0'
@@ -136,7 +110,28 @@
		kputc	#'x'
		kphex	\cend, 8	/* End of kernel copy */
		kputc	#'\n'
		kputc	#'\r'
#endif
		.endm

		/*
		 * Debug print of the final appended DTB location
		 */
		.macro dbgadtb, begin, end
#ifdef DEBUG
		kputc   #'D'
		kputc   #'T'
		kputc   #'B'
		kputc   #':'
		kputc   #'0'
		kputc   #'x'
		kphex   \begin, 8	/* Start of appended DTB */
		kputc	#' '
		kputc	#'('
		kputc	#'0'
		kputc	#'x'
		kphex	\end, 8		/* End of appended DTB */
		kputc	#')'
		kputc	#'\n'
#endif
		.endm

@@ -303,7 +298,7 @@ restart: adr r0, LC1

#ifndef CONFIG_ZBOOT_ROM
		/* malloc space is above the relocated stack (64k max) */
		add	r10, sp, #0x10000
		add	r10, sp, #MALLOC_SIZE
#else
		/*
		 * With ZBOOT_ROM the bss/stack is non relocatable,
@@ -357,6 +352,7 @@ restart: adr r0, LC1
		mov	r5, r5, ror #8
		eor	r5, r5, r1, lsr #8
#endif
		dbgadtb	r6, r5
		/* 50% DTB growth should be good enough */
		add	r5, r5, r5, lsr #1
		/* preserve 64-bit alignment */
@@ -614,7 +610,7 @@ not_relocated: mov r0, #0
 */
		mov	r0, r4
		mov	r1, sp			@ malloc space above stack
		add	r2, sp, #0x10000	@ 64k max
		add	r2, sp, #MALLOC_SIZE	@ 64k max
		mov	r3, r7
		bl	decompress_kernel

@@ -1356,7 +1352,7 @@ puts: loadsp r3, r2, r1
1:		ldrb	r2, [r0], #1
		teq	r2, #0
		moveq	pc, lr
2:		writeb	r2, r3
2:		writeb	r2, r3, r1
		mov	r1, #0x00020000
3:		subs	r1, r1, #1
		bne	3b
Loading