From aa9e7a39c5a5a77ff02670ef915f4c6712bc7658 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Amaury=20Decr=C3=AAme?= Date: Mon, 28 Jan 2013 22:21:06 +0100 Subject: [PATCH] i2c: sis630: clear sticky bits MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit The sticky bits must be cleared at the end of the transaction by writing a 1 to all fields. Datasheet: SMBus Status (SMB_STS) The following registers are all sticky bits and only can be cleared by writing a one to their corresponding fields. Signed-off-by: Amaury Decrême Reviewed-by: Jean Delvare Signed-off-by: Wolfram Sang --- drivers/i2c/busses/i2c-sis630.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/drivers/i2c/busses/i2c-sis630.c b/drivers/i2c/busses/i2c-sis630.c index df8e20ab3a09..3124d807c05a 100644 --- a/drivers/i2c/busses/i2c-sis630.c +++ b/drivers/i2c/busses/i2c-sis630.c @@ -213,10 +213,8 @@ static int sis630_transaction_wait(struct i2c_adapter *adap, int size) static void sis630_transaction_end(struct i2c_adapter *adap, u8 oldclock) { - int temp = 0; - /* clear all status "sticky" bits */ - sis630_write(SMB_STS, temp); + sis630_write(SMB_STS, 0xFF); dev_dbg(&adap->dev, "SMB_CNT before clock restore 0x%02x\n", sis630_read(SMB_CNT)); -- 2.39.5