[U-Boot-Users] Please pull from 'mpc83xx' branch
Kumar Gala
galak at kernel.crashing.org
Thu Dec 14 23:44:12 CET 2006
On Dec 14, 2006, at 4:18 PM, Timur Tabi wrote:
> Kumar Gala wrote:
>> Please pull from 'mpc83xx' branch of
>> git://git.kernel.org/pub/scm/boot/u-boot/galak/u-boot.git
>
> Unfortunately, I'm going to have to NACK one of these patches, "Fix
> config of Arbiter, System Priority, and Clock Mode on MPC83xx".
>
> I just noticed the problem with this patch. It will work for the
> 8349ITX, but it will break the 8349EMDS and TQM834x.
>
>> #ifdef CFG_SCCR_TSEC1CM
>> /* TSEC1 clock mode */
>> - im->clk.sccr = (im->clk.sccr & ~SCCR_TSEC1CM) | (1 <<
>> SCCR_TSEC1CM_SHIFT);
>> + im->clk.sccr = (im->clk.sccr & ~SCCR_TSEC1CM) |
>> (CFG_SCCR_TSEC1CM << SCCR_TSEC1CM_SHIFT);
>> #endif
>
> This works as long as CFG_SCCR_TSEC1CM is between 0 and 4. But
> look what the MPC8349EMDS.h has:
>
> #define CFG_SCCR_INIT (SCCR_DEFAULT & (~SCCR_CLK_MASK))
> #define CFG_SCCR_TSEC1CM SCCR_TSEC1CM_1 /* TSEC1 clock setting */
> #define CFG_SCCR_TSEC2CM SCCR_TSEC2CM_1 /* TSEC2 clock setting */
> #define CFG_SCCR_ENCCM SCCR_ENCCM_3 /* ENC clock setting */
> #define CFG_SCCR_USBCM SCCR_USBCM_3 /* USB clock setting */
> #define CFG_SCCR_VAL ( CFG_SCCR_INIT \
> | CFG_SCCR_TSEC1CM \
> | CFG_SCCR_TSEC2CM \
> | CFG_SCCR_ENCCM \
> | CFG_SCCR_USBCM )
>
> SCCR_TSEC1CM_1 is defined in mpc83xx.h:
>
> #define SCCR_TSEC1CM_1 0x40000000
Ok so we need to fixup the defines of CFG_SCCR_TSEC1M/
CFG_SCCR_TSEC2CM to be set to 1 for the boards
> So the patch for mpc83xx/cpu_init.c needs to include changes to
> MPC8349EMDS.h and TQM834x.h.
>
> But that's not the only problem. cpu_init_f() does not have any
> code that uses these two defines in MPC8349EMDS.h and TQM834x.h:
>
> #define CFG_SCCR_ENCCM SCCR_ENCCM_3 /* ENC clock setting */
> #define CFG_SCCR_USBCM SCCR_USBCM_3 /* USB clock setting */
>
> Which means that currently, these bitfields aren't being set at
> all! If you try to load the Linux USB driver on an 8349EMDS, the
> driver will hang at boot time.
>
> I'm working on follow-up patches to fix this.
Ok, I'll fix up the usage of CFG_SCCR_TSEC1M in my tree and leave the
other SCCR settings to you.
- kumar
More information about the U-Boot
mailing list