Skip to content
Snippets Groups Projects
Forked from Reform / reform-boundary-uboot
Source project has a limited visibility.
  • Peng Fan's avatar
    c36ecf3a
    i2c:mxc fix array size of i2c_data · c36ecf3a
    Peng Fan authored
    
    We should not hardcode array size of i2c_data to 3. To CONFIG_FSL_LSCH3,
    there are 4 i2c interface, but not 3. So the size of i2c_data array should
    be calculated using "ARRAY_SIZE(i2c_bases)".
    
    To avoid compile error, move i2c_bases before sram_data structure which
    contains i2c_data array.
    
    Signed-off-by: default avatarPeng Fan <Peng.Fan@freescale.com>
    c36ecf3a
    History
    i2c:mxc fix array size of i2c_data
    Peng Fan authored
    
    We should not hardcode array size of i2c_data to 3. To CONFIG_FSL_LSCH3,
    there are 4 i2c interface, but not 3. So the size of i2c_data array should
    be calculated using "ARRAY_SIZE(i2c_bases)".
    
    To avoid compile error, move i2c_bases before sram_data structure which
    contains i2c_data array.
    
    Signed-off-by: default avatarPeng Fan <Peng.Fan@freescale.com>