Hi Kevin,
[...]
> Very nice... one minor nit below...
Thanks. However, I think the solution proposed in [1] is more elegant.
The way I see it, the root cause of the problem is that some of the
davinci_soc_info fields mapped virtual addresses. Since these virtual
addresses need to be filled in before davinci_common_init(), the current
v4 series implementation contorts the init flow in da8xx and tnetv107x.
By replacing davinci_soc_info virtual address fields with physical
addresses, we can get by with a single uniform flow that works cleanly
across all three families without said contortions.
Physical addresses in davinci_soc_info have other pleasant side effects
as well. First, doing so replaces a bunch of IO_ADDRESS() uses in the
mach-davinci code with ioremap(). Second, this also cleans up the early
uses of DA8XX_SYSCFG0_VIRT().
Any thoughts on this approach?
[...]
>> +void __init davinci_io_init(struct map_desc *desc, unsigned long desc_num)
>> +{
>> + if (!desc || !desc_num)
>> + return;
>> +
>> + /* silently refuse to init twice ...*/
>> + if (davinci_io_desc) {
>> + /* ... unless things change */
>> + BUG_ON(davinci_io_desc != desc ||
>> + davinci_io_desc_num != desc_num);
>
> Should be a WARN_ON() here. This is non fatal, and easy
> to recover from. (c.f. include/asm-generic/bug.h, below)
Thanks.
-- Cyril.
[1]
http://linux.davincidsp.com/pipermail/davinci-linux-open-source/2010-April/018681.html
_______________________________________________
Davinci-linux-open-source mailing list
[email protected]
http://linux.davincidsp.com/mailman/listinfo/davinci-linux-open-source