提交 ed9953d6 编写于 作者: W Wolfgang Denk

Merge branch 'master' of git://git.denx.de/u-boot-i2c

...@@ -51,14 +51,12 @@ ...@@ -51,14 +51,12 @@
DECLARE_GLOBAL_DATA_PTR; DECLARE_GLOBAL_DATA_PTR;
#endif #endif
/*----------------------------------------------------------------------- /*-----------------------------------------------------------------------
* Definitions * Definitions
*/ */
#define RETRIES 0 #define RETRIES 0
#define I2C_ACK 0 /* PD_SDA level to ack a byte */ #define I2C_ACK 0 /* PD_SDA level to ack a byte */
#define I2C_NOACK 1 /* PD_SDA level to noack a byte */ #define I2C_NOACK 1 /* PD_SDA level to noack a byte */
...@@ -154,7 +152,6 @@ static void send_stop(void) ...@@ -154,7 +152,6 @@ static void send_stop(void)
I2C_TRISTATE; I2C_TRISTATE;
} }
/*----------------------------------------------------------------------- /*-----------------------------------------------------------------------
* ack should be I2C_ACK or I2C_NOACK * ack should be I2C_ACK or I2C_NOACK
*/ */
...@@ -174,7 +171,6 @@ static void send_ack(int ack) ...@@ -174,7 +171,6 @@ static void send_ack(int ack)
I2C_DELAY; I2C_DELAY;
} }
/*----------------------------------------------------------------------- /*-----------------------------------------------------------------------
* Send 8 bits and look for an acknowledgement. * Send 8 bits and look for an acknowledgement.
*/ */
...@@ -246,6 +242,7 @@ int i2c_set_bus_num(unsigned int bus) ...@@ -246,6 +242,7 @@ int i2c_set_bus_num(unsigned int bus)
#endif #endif
return 0; return 0;
} }
#endif
/* TODO: add 100/400k switching */ /* TODO: add 100/400k switching */
unsigned int i2c_get_bus_speed(void) unsigned int i2c_get_bus_speed(void)
...@@ -260,7 +257,6 @@ int i2c_set_bus_speed(unsigned int speed) ...@@ -260,7 +257,6 @@ int i2c_set_bus_speed(unsigned int speed)
return 0; return 0;
} }
#endif
/*----------------------------------------------------------------------- /*-----------------------------------------------------------------------
* if ack == I2C_ACK, ACK the byte so can continue reading, else * if ack == I2C_ACK, ACK the byte so can continue reading, else
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册