Skip to content

Commit

Permalink
i2c: sis630: clear sticky bits
Browse files Browse the repository at this point in the history
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 <amaury.decreme@gmail.com>
Reviewed-by: Jean Delvare <khali@linux-fr.org>
Signed-off-by: Wolfram Sang <wolfram@the-dreams.de>
  • Loading branch information
Amaury Decrême authored and Wolfram Sang committed Feb 11, 2013
1 parent 974d6a3 commit aa9e7a3
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions drivers/i2c/busses/i2c-sis630.c
Original file line number Diff line number Diff line change
Expand Up @@ -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));

Expand Down

0 comments on commit aa9e7a3

Please sign in to comment.