Thread (28 messages) flat view 28 messages, 6 authors, 2012-09-05
STALE5104d

[PATCH 1/6] ARM: move ARCH config definitions into mach dirs

From: Rob Herring <hidden>
Date: 2012-09-01 00:48:42

On 08/30/2012 02:28 PM, Russell King - ARM Linux wrote:
On Thu, Aug 30, 2012 at 02:07:18PM -0500, Rob Herring wrote:
quoted
On 08/30/2012 11:45 AM, Russell King - ARM Linux wrote:
quoted
That also means we can start to think about moving the mach/debug-macros.S
header elsewhere, remembering that this facility is shared between the
decompressor for debugging and the kernel.
I was thinking we could convert the phys and virt addresses to config
values and then the DEBUG_LL choices could just be "Use PL01x uart" and
"Use 8250 uart". This would cut down the number of debug-macro.S files
and choices.

Using a fixed virtual address for all platforms might also help simplify
DEBUG_LL.
No it won't, that comment says you totally don't understand the feature
you're playing with to me.
Or you don't understand what I meant.
It's not only about virtual addresses, it's about physical addresses too,
and we can't dictate that all hardware exposes a UART at any particular
physical address.
We have 3 things to track for each platform: the type of uart, the
uart's phys address, and the virtual address we map it to. Obviously, we
can't get rid of the first 2, but we can align the virtual address to
the same 1MB section for DEBUG_LL on all platforms. Then we only have 2
differences to deal with. If we make the physical address a config
value, then we could unify all the addruart implementations (except
perhaps for the crazy stuff omap does). So something like this:

		.macro	addruart,rp,rv,tmp
		mov	\rv, #0xfe000000
		orr	\rv, \rv, #0x00d00000
		ldr	\rp, =CONFIG_DEBUG_LL_UART_ADDR
		lsl	\tmp, \rp, #12
		lsr	\tmp, \tmp, #12
		orr	\rv, \rv, \tmp
		.endm

Of course we'd have to shift around static mappings to free up whatever
address we use. I don't know if 0xfed00000 would be the best choice, but
that is just below were I put the PCI i/o mapping.

Rob
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help