mirror of
https://github.com/u-boot/u-boot.git
synced 2025-05-09 03:21:51 +00:00
i2c: sh_i2c.c: support I2C2, I2C3 and I2C4
sh_i2c.c support I2C0 and I2C1. This patch extends it to I2C4. Acked-by: Nobuhiro Iwamatsu <nobuhiro.iwamatsu.yj@renesas.com> Signed-off-by: Tetsuyuki Kobayashi <koba@kmckk.co.jp>
This commit is contained in:
parent
3ce2703d8f
commit
020ec727a6
2 changed files with 19 additions and 1 deletions
|
@ -184,6 +184,21 @@ int i2c_set_bus_num(unsigned int bus)
|
|||
case 1:
|
||||
base = (void *)CONFIG_SH_I2C_BASE1;
|
||||
break;
|
||||
#ifdef CONFIG_SH_I2C_BASE2
|
||||
case 2:
|
||||
base = (void *)CONFIG_SH_I2C_BASE2;
|
||||
break;
|
||||
#endif
|
||||
#ifdef CONFIG_SH_I2C_BASE3
|
||||
case 3:
|
||||
base = (void *)CONFIG_SH_I2C_BASE3;
|
||||
break;
|
||||
#endif
|
||||
#ifdef CONFIG_SH_I2C_BASE4
|
||||
case 4:
|
||||
base = (void *)CONFIG_SH_I2C_BASE4;
|
||||
break;
|
||||
#endif
|
||||
default:
|
||||
return -1;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue