From c80a4df97f0f49dc83960a912795147cae885229 Mon Sep 17 00:00:00 2001 From: kfx Date: Wed, 28 Mar 2012 11:03:35 +0800 Subject: [PATCH] rk30: i2c: update driver for 'rx only' mode --- drivers/i2c/busses/i2c-rk30-adapter.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/drivers/i2c/busses/i2c-rk30-adapter.c b/drivers/i2c/busses/i2c-rk30-adapter.c index 4272bcfdce6b..c11b544500e2 100755 --- a/drivers/i2c/busses/i2c-rk30-adapter.c +++ b/drivers/i2c/busses/i2c-rk30-adapter.c @@ -395,7 +395,9 @@ static int rk30_i2c_set_master(struct rk30_i2c *i2c, struct i2c_msg *msgs, int n addr |= 1; i2c->msg = &msgs[0]; i2c_writel(addr | I2C_MRXADDR_LOW, i2c->regs + I2C_MRXADDR); - i2c->mode = I2C_CON_MOD_RX; + i2c_writel(0, i2c->regs + I2C_MRXRADDR); + i2c->mode = I2C_CON_MOD_TRX; + //i2c->mode = I2C_CON_MOD_RX; } } else if(num == 2) { -- 2.34.1