[PATCH 4.5/6] ARM: omap: pass phys, virt and lsr from uncompress.h to debug-macro.S

Nicolas Pitre nico at fluxnic.net
Tue Sep 6 14:45:04 EDT 2011


On Mon, 5 Sep 2011, Tony Lindgren wrote:

> Earlier code passed the serial port configuration number as the
> code originally used the scratchpad register in the serial port
> to pass it from uncompress.h to debug-macro.S. This is no longer
> the case as some omaps don't have a serial port. A memory address
> is used instead.
> 
> Change the code to pass phys, virt and lsr from uncompress.h
> to debug-macro.S. Note that the virt value is only used on zoom
> boards that have an external 8250 hardware.
> 
> This will make it possible to combine omap1 and omap2+ debug-macro.S.
> 
> Signed-off-by: Tony Lindgren <tony at atomide.com>
> 
[...]
> 
>  	u32 ram_start = (u32)&uart_shift & 0xf8000000;
>  	u32 *uart_info = (u32 *)(ram_start + OMAP_UART_INFO_OFS);
> -	*uart_info = port;
> +	*uart_info = (u32)uart_base;
> +	uart_info++;
> +	*uart_info = (u32)uart_virt;
> +	uart_info++;
> +	*uart_info = UART_LSR << uart_shift;

Whouldn't this be clearer as:

	uart_info[0] = (u32)uart_base;
	uart_info[1] = (u32)uart_virt;
	uart_info[2] = UART_LSR << uart_shift;

?


Nicolas



More information about the linux-arm-kernel mailing list