Skip to content
Snippets Groups Projects
Select Git revision
  • master default protected
  • early-display
  • variant-emmc-nvme-boot
  • 2023-01-25
  • v3
  • variant-emmc-nvme-boot
  • 2020-06-01
7 results

cmd_eeprom.c

Blame
  • Forked from Reform / reform-boundary-uboot
    29189 commits behind the upstream repository.
    • Kuo-Jung Su's avatar
      6ca6d080
      cmd_eeprom: bug fix for i2c read/write · 6ca6d080
      Kuo-Jung Su authored
      
      The local pointer of address (i.e., addr) only gets
      referenced under SPI mode, and it won't be appropriate
      to pass only 1-byte addr[1] to i2c_read/i2c_write while
      CONFIG_SYS_I2C_EEPROM_ADDR_LEN > 1.
      
      1. In U-boot's I2C model, the address would be re-assembled
         to a byte string in MSB order inside I2C controller drivers.
      
      2. The 'CONFIG_SYS_I2C_EEPROM_ADDR_OVERFLOW' option which could
         be found at soft_i2c.c is always turned on in cmd_eeprom.c,
         the addr[0] always contains the device address with overflowed
         MSB address bits.
      
      Signed-off-by: default avatarKuo-Jung Su <dantesu@faraday-tech.com>
      Cc: Alexey Brodkin <abrodkin@synopsys.com>
      Cc: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
      cc: Peter Tyser <ptyser@xes-inc.com>
      Cc: Heiko Schocher <hs@denx.de>
      Cc: Wolfgang Denk <wd@denx.de>
      Cc: Stefan Roese <sr@denx.de>
      Cc: Mischa Jonker <mjonker@synopsys.com>
      6ca6d080
      History
      cmd_eeprom: bug fix for i2c read/write
      Kuo-Jung Su authored
      
      The local pointer of address (i.e., addr) only gets
      referenced under SPI mode, and it won't be appropriate
      to pass only 1-byte addr[1] to i2c_read/i2c_write while
      CONFIG_SYS_I2C_EEPROM_ADDR_LEN > 1.
      
      1. In U-boot's I2C model, the address would be re-assembled
         to a byte string in MSB order inside I2C controller drivers.
      
      2. The 'CONFIG_SYS_I2C_EEPROM_ADDR_OVERFLOW' option which could
         be found at soft_i2c.c is always turned on in cmd_eeprom.c,
         the addr[0] always contains the device address with overflowed
         MSB address bits.
      
      Signed-off-by: default avatarKuo-Jung Su <dantesu@faraday-tech.com>
      Cc: Alexey Brodkin <abrodkin@synopsys.com>
      Cc: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
      cc: Peter Tyser <ptyser@xes-inc.com>
      Cc: Heiko Schocher <hs@denx.de>
      Cc: Wolfgang Denk <wd@denx.de>
      Cc: Stefan Roese <sr@denx.de>
      Cc: Mischa Jonker <mjonker@synopsys.com>