From abec4c64ebf9eb654e9c5ddd46c834d47ab86522 Mon Sep 17 00:00:00 2001 From: Jean Delvare Date: Fri, 27 Jun 2003 16:15:24 +0000 Subject: [PATCH] Fixed a compiler warning, plus some code clean-ups. git-svn-id: http://lm-sensors.org/svn/lm-sensors/trunk@1818 7894878c-1315-0410-8ee3-d5d059ff63e0 --- kernel/busses/i2c-nforce2.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/kernel/busses/i2c-nforce2.c b/kernel/busses/i2c-nforce2.c index 30cf3bc4..c895ee67 100644 --- a/kernel/busses/i2c-nforce2.c +++ b/kernel/busses/i2c-nforce2.c @@ -145,7 +145,8 @@ s32 nforce2_access(struct i2c_adapter * adap, u16 addr, unsigned short flags, union i2c_smbus_data * data) { struct nforce2_smbus *smbus = adap->algo_data; - unsigned char protocol, len, pec, temp; + unsigned char protocol, pec, temp; + unsigned char len = 0; /* to keep the compiler quiet */ int timeout = 0; int i; @@ -276,12 +277,12 @@ s32 nforce2_access(struct i2c_adapter * adap, u16 addr, unsigned short flags, break; case I2C_SMBUS_WORD_DATA: - case I2C_SMBUS_PROC_CALL: + /* case I2C_SMBUS_PROC_CALL: not supported */ data->word = inb_p(NVIDIA_SMB_DATA) | (inb_p(NVIDIA_SMB_DATA+1) << 8); break; case I2C_SMBUS_BLOCK_DATA: - case I2C_SMBUS_BLOCK_PROC_CALL: + /* case I2C_SMBUS_BLOCK_PROC_CALL: not supported */ len = inb_p(NVIDIA_SMB_BCNT); len = min_t(u8, len, 32); case I2C_SMBUS_I2C_BLOCK_DATA: