[U-Boot-Users] i2c_set_bus_num

Dongying_Xu at us.alphanetworks.com Dongying_Xu at us.alphanetworks.com
Thu Mar 29 20:07:37 CEST 2007


Kim,

Thanks. When I defined CFG_SPD_BUS_NUM 1 in my header file, things are 
much better.  Though I don't understand why this definition will help.  I 
read the  "Initial Stack, Global Data" part in Readme, It looks that 
Initialized global data is read-only, if this is the case, then It should 
fail when I try to set I2c bus num to 0, but it worked.  Could you please 
explain a little bit?   Thanks 

dongy





Kim Phillips <kim.phillips at freescale.com>
03/27/2007 06:00 PM
 
        To:     Dongying_Xu at us.alphanetworks.com
        cc:     u-boot-users at lists.sourceforge.net
        Subject:        Re: [U-Boot-Users] i2c_set_bus_num


On Tue, 27 Mar 2007 16:48:29 -0700
Dongying_Xu at us.alphanetworks.com wrote:

> Hi, 
> 
> Does anyone experienced following problem? In u-boot/drivers/fsl_i2c.c, 
> there are functions to set and get i2c bus number,
> When I set the default i2c_bus_num to 0, I can not use i2c_set_bus_num() 

> set bus 1 properly.  For example, I called
> 
> >>i2c_set_bus_num(1);
> >>printf(The bus number is %d\n", i2c_get_bus_num());
> 
> >>>>The bus number is 0.
> 
> I am using MPC8343.  Thanks. Any suggestion is appreciated.
> 
See "Initial Stack, Global Data" in the u-boot README.

If your memory controller, or whatever you want to access while unable to 
write global vars, is hanging off of the 2nd bus, do something equivalent 
to what the 8349ITX does (look for CFG_SPD_BUS_NUM).

Kim


-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.denx.de/pipermail/u-boot/attachments/20070329/54ee7789/attachment.htm 


More information about the U-Boot mailing list