[U-Boot] Help with ppc460sx i2c_transfer
tx co
txcotrader at gmail.com
Thu Mar 28 23:13:40 CET 2013
I'm having a difficult time figuring out why I'm failing to get an ACK
response generated when running the /drivers/i2c/ppc4xx_i2c.c ->
i2c_transfer function. I'm using the same values as a reference boot loader
from a while back (2007).
Here is my I2C configurations:
231 /* SPD i2c spd addresses */
232 #define SPD_EEPROM_ADDRESS {0x50, 0x52}
302 #define CONFIG_SYS_I2C_SPEED 400000 /* I2C
speed */
303
304 /*#define CONFIG_SYS_I2C_MULTI_EEPROMS*/
305 #define CONFIG_SYS_I2C_EEPROM_ADDR (0xa8>>1)
306 #define CONFIG_SYS_I2C_EEPROM_ADDR_LEN 1
307 #define CONFIG_SYS_EEPROM_PAGE_WRITE_BITS 5
308 #define CONFIG_SYS_EEPROM_PAGE_WRITE_DELAY_MS 10
309
310 /* I2C bootstrap EEPROM */
311 #define IIC0_BOOTPROM_ADDR 0x54
312 #define IIC0_PLX_FPGA_ADDR 0x69
313 #define IIC0_PLX_PPC_ADDR 0x6A
314
315 /* I2C bootstrap EEPROM */
316 #define CONFIG_4xx_CONFIG_I2C_EEPROM_ADDR 0x52
317 #define CONFIG_4xx_CONFIG_I2C_EEPROM_OFFSET 0
318 #define CONFIG_4xx_CONFIG_BLOCKSIZE 16
319
320 /* RTC configuration */
321 #define CONFIG_RTC_DS1337 1
322 #define CONFIG_SYS_I2C_RTC_ADDR 0x68
The OLD, working configuration yields an ACK response. And I've noticed in
the i2c_transfer function the value for "status" returns:
i2c_trasfer -> status = 1
i2c_trasfer -> status = 28
i2c_trasfer -> status = 21
i2c_trasfer -> status = 8
i2c_trasfer -> status = 9
and my current port returns:
i2c_trasfer -> status = 1
i2c_trasfer -> status = 4
i2c_trasfer -> status = 2
Looking at the differences between the old and new code is not revealing
anything. I've got a hunch that my current port is not really accessing my
i2c (0x50). If anyone is willing to provide me with any pointers I would
greatly appreciate it.
Thank you
More information about the U-Boot
mailing list