diff options
Diffstat (limited to 'include')
-rw-r--r-- | include/asm-ppc/i2c.h | 10 | ||||
-rw-r--r-- | include/configs/MPC8349ITX.h | 2 | ||||
-rw-r--r-- | include/configs/TQM834x.h | 2 | ||||
-rw-r--r-- | include/i2c.h | 8 |
4 files changed, 8 insertions, 14 deletions
diff --git a/include/asm-ppc/i2c.h b/include/asm-ppc/i2c.h index baf9d9a..8afdda2 100644 --- a/include/asm-ppc/i2c.h +++ b/include/asm-ppc/i2c.h @@ -79,12 +79,6 @@ typedef struct i2c #endif #define I2C_TIMEOUT (CFG_HZ/4) -enum I2C_BUS_NUM -{ - I2C_BUS_1 = 0, - I2C_BUS_2, -}; - #ifndef CFG_IMMRBAR #error CFG_IMMRBAR is not defined in /include/configs/${BOARD}.h #endif @@ -96,9 +90,9 @@ enum I2C_BUS_NUM #define I2C_1 ((i2c_t*)(CFG_IMMRBAR + CFG_I2C_OFFSET)) /* Optional support for second I2C bus */ -#ifdef CFG_I2C2_OFFSET +#ifdef CFG_I2C2_OFFSET #define I2C_2 ((i2c_t*)(CFG_IMMRBAR + CFG_I2C2_OFFSET)) -#endif /* CFG_I2C2_OFFSET */ +#endif /* CFG_I2C2_OFFSET */ #define I2C_READ 1 #define I2C_WRITE 0 diff --git a/include/configs/MPC8349ITX.h b/include/configs/MPC8349ITX.h index 20f3c6d..2fbc736 100644 --- a/include/configs/MPC8349ITX.h +++ b/include/configs/MPC8349ITX.h @@ -81,7 +81,7 @@ #define CONFIG_I2C_CMD_TREE #define CFG_I2C_OFFSET 0x3000 #define CFG_I2C2_OFFSET 0x3100 -#define CFG_SPD_BUS_NUM I2C_2 +#define CFG_SPD_BUS_NUM 2 #define CFG_I2C_8574_ADDR1 0x20 /* I2C2, PCF8574 */ #define CFG_I2C_8574_ADDR2 0x21 /* I2C2, PCF8574 */ diff --git a/include/configs/TQM834x.h b/include/configs/TQM834x.h index f0e4900..727094b 100644 --- a/include/configs/TQM834x.h +++ b/include/configs/TQM834x.h @@ -36,8 +36,8 @@ */ #define CONFIG_E300 1 /* E300 Family */ #define CONFIG_MPC83XX 1 /* MPC83XX family */ -#define CONFIG_MPC8349 1 /* MPC8349 specific */ #define CONFIG_MPC834X 1 /* MPC834X specific */ +#define CONFIG_MPC8349 1 /* MPC8349 specific */ #define CONFIG_TQM834X 1 /* TQM834X board specific */ /* IMMR Base Addres Register, use Freescale default: 0xff400000 */ diff --git a/include/i2c.h b/include/i2c.h index 97e0061..a8f729a 100644 --- a/include/i2c.h +++ b/include/i2c.h @@ -97,7 +97,7 @@ void i2c_reg_write(uchar chip, uchar reg, uchar val); * Returns: 0 on success, not 0 on failure * */ -int i2c_set_bus_num(uchar bus); +int i2c_set_bus_num(unsigned int bus); /* * i2c_get_bus_num: @@ -105,7 +105,7 @@ int i2c_set_bus_num(uchar bus); * Returns index of currently active I2C bus. Zero-based. */ -uchar i2c_get_bus_num(void); +unsigned int i2c_get_bus_num(void); /* * i2c_set_bus_speed: @@ -117,7 +117,7 @@ uchar i2c_get_bus_num(void); * Returns: 0 on success, not 0 on failure * */ -int i2c_set_bus_speed(int); +int i2c_set_bus_speed(unsigned int); /* * i2c_get_bus_speed: @@ -125,6 +125,6 @@ int i2c_set_bus_speed(int); * Returns speed of currently active I2C bus in Hz */ -int i2c_get_bus_speed(void); +unsigned int i2c_get_bus_speed(void); #endif /* _I2C_H_ */ |