On Fri, Apr 23, 2010 at 23:27:02, Chemparathy, Cyril wrote:
> TNETV107X is a Texas Instruments SOC that shares a number of common features
> with the Davinci architecture.  Some of the key differences between
> traditional Davincis and this new SOC are as follow:
>
> 1. The SOCs clock architecture includes a new spread-spectrum PLL.  Some
> elements of the clock architecture are reused from Davinci (e.g. LPSC), but
> the PLL related code is overridden using existing interfaces in "struct clk".
>
> 2. The MMR layout on this SOC is substantially different from Davinci.
> Consequently, the fixed I/O map is a whole lot more convoluted (more so than
> DA8xx).  The net impact here is that IO_ADDRESS() will not work on this SoC,
> and therefore all mappings have to be through ioremap().
>
> Signed-off-by: Cyril Chemparathy <[email protected]>

[...]

> +
> +/* Base addresses for on-chip devices */
> +#define TNETV107X_TPCC_BASE                  0x01c00000
> +#define TNETV107X_TPTC0_BASE                 0x01c10000
> +#define TNETV107X_TPTC1_BASE                 0x01c10400
> +#define TNETV107X_ASYNC_EMIF_DATA_CE0_BASE   0x30000000
> +#define TNETV107X_WDOG_BASE                  0x08086700
> +#define TNETV107X_SDIO0_BASE                 0x08088700
> +#define TNETV107X_SDIO1_BASE                 0x08088800
> +#define TNETV107X_ASYNC_EMIF_CNTRL_BASE              0x08200000

It will be nice to see these in ascending order.

[...]

> diff --git a/arch/arm/mach-davinci/tnetv107x.c 
> b/arch/arm/mach-davinci/tnetv107x.c
> new file mode 100644
> index 0000000..2dfed3e
> --- /dev/null
> +++ b/arch/arm/mach-davinci/tnetv107x.c
> @@ -0,0 +1,841 @@
> +/*
> + * Texas Instruments TNETV107X SoC Support
> + *

[...]

> +static void __iomem *psc_regs[1];
> +
> +/* Host map for interrupt controller */
> +static u32 intc_host_map[] = { 0x01010000, 0x01010101, -1 };
> +
> +static unsigned long clk_sspll_recalc(struct clk *clk);
> +
> +

Extra line here.

[...]

> +
> +/*
> + * TNETV107X platforms do not use the static mappings from Davinci
> + * IO_PHYS/IO_VIRT. This SOC's interesting MMRs are at different addresses,
> + * and changing IO_PHYS would break away from existing Davinci SOCs.
> + *
> + * The primary impact of the current model is that IO_ADDRESS() is not to be
> + * used to map registers on TNETV107X. With the exception of early boot code
> + * in tnetv107x_init() (where fixed maps are necessary), all other pieces of
> + * code absolutely _must_ use ioremap().
> + *
> + * 1.        The first section in here is specifically for edma, even 
> through the
> + *   edma driver code properly ioremap()s its register space.  This is
> + *   because the edma MMRs on tnetv107x unfortunately fall within the
> + *   davinci IO_PHYS - (IO_PHYS + IO_SIZE) range, and therefore the edma
> + *   driver's ioremap() gets subverted by davinci_ioremap(). Yikes!

I had pointed this earlier, but don't remember a follow-up discussion.

Why not just redefine IO_PHYS for this SoC?

Thanks,
Sekhar

_______________________________________________
Davinci-linux-open-source mailing list
[email protected]
http://linux.davincidsp.com/mailman/listinfo/davinci-linux-open-source

Reply via email to