[U-Boot] [PATCH] mpc83xx: Add UPMA configuration to SIMPC8313

Kim Phillips kim.phillips at freescale.com
Thu Apr 29 00:08:01 CEST 2010


On Wed, 28 Apr 2010 10:48:44 -0700
Ron Madrid <ron_madrid at sbcglobal.net> wrote:

> +	volatile immap_t *immap = (immap_t *) CONFIG_SYS_IMMR;
> +	volatile fsl_lbus_t *lbus = &immap->lbus;
> +	volatile u32 *mxmr = &lbus->mamr;	/* Pointer to mamr */

no volatiles...

> +	/* Set LUPWAIT to be active low and enabled */
> +	*mxmr = 0x08000000 | MxMR_GPL_x4DIS;

...because we should now be using i/o accessors.  Also, let's add a
MxMR_UWPL in fsl_lbc.h please (can be in same patch).

> +#define CONFIG_SYS_BR1_PRELIM		( 0xFF000000	/* FPGA Base Addr */ \
> +					| BR_PS_16 \
> +					| BR_MS_UPMA \
> +					| BR_V )
> +#define CONFIG_SYS_OR1_PRELIM		( 0xFFE00000	/* length 2MB */ \

OR_AM_2MB (and therefore drop the comment).

> +					| OR_UPM_BCTLD)
> +
> +#define CONFIG_SYS_LBLAWBAR1_PRELIM	0xFF000000	/* FPGA Base Addr */

if FPGA base address becomes a recurring reference, best to name it
something like CONFIG_SYS_FPGA_BASE.

> +#define CONFIG_SYS_LBLAWAR1_PRELIM	0x80000014	/* 2MB */

(LBLAWAR_EN | LBLAWAR_2MB)

Kim


More information about the U-Boot mailing list