lkml.org 
[lkml]   [2004]   [Apr]   [14]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
SubjectRe: [PATCH] I2C update for 2.6.5
Date
From
ChangeSet 1.1643.36.21, 2004/04/09 12:06:02-07:00, greg@kroah.com

[PATCH] I2C: minor bugfixes for the pcf8591.c driver and formatting cleanups.


drivers/i2c/chips/pcf8591.c | 10 ++++------
1 files changed, 4 insertions(+), 6 deletions(-)


diff -Nru a/drivers/i2c/chips/pcf8591.c b/drivers/i2c/chips/pcf8591.c
--- a/drivers/i2c/chips/pcf8591.c Wed Apr 14 15:13:11 2004
+++ b/drivers/i2c/chips/pcf8591.c Wed Apr 14 15:13:11 2004
@@ -125,8 +125,7 @@
unsigned int value;
struct i2c_client *client = to_i2c_client(dev);
struct pcf8591_data *data = i2c_get_clientdata(client);
- if ((value = (simple_strtoul(buf, NULL, 10) + 5) / 10) <= 255);
- {
+ if ((value = (simple_strtoul(buf, NULL, 10) + 5) / 10) <= 255) {
data->aout = value;
i2c_smbus_write_byte_data(client, data->control, data->aout);
}
@@ -235,9 +234,9 @@
/* OK, this is not exactly good programming practice, usually. But it is
very code-efficient in this case. */

- exit_kfree:
+exit_kfree:
kfree(new_client);
- exit:
+exit:
return err;
}

@@ -277,8 +276,7 @@

down(&data->update_lock);

- if ((data->control & PCF8591_CONTROL_AICH_MASK) != channel)
- {
+ if ((data->control & PCF8591_CONTROL_AICH_MASK) != channel) {
data->control = (data->control & ~PCF8591_CONTROL_AICH_MASK)
| channel;
i2c_smbus_write_byte(client, data->control);
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 14:02    [W:0.060 / U:0.096 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site