diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2011-06-29 14:07:02 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2011-06-29 14:07:02 -0400 |
commit | c7735471837b35a6205f6052a34ded3bdc1db505 (patch) | |
tree | c6f7a367d893f8194f624f321530fa010604d5c5 /drivers | |
parent | 78a3cc38f72cb0e6938ed8e796041d6d1beb8a28 (diff) | |
parent | cd823db8b1161ef0d756514d280715a576d65cc3 (diff) |
Merge branch 'i2c-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jdelvare/staging
* 'i2c-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jdelvare/staging:
i2c/pca954x: Initialize the mux to disconnected state
i2c-taos-evm: Fix log messages
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/i2c/busses/i2c-taos-evm.c | 8 | ||||
-rw-r--r-- | drivers/i2c/muxes/pca954x.c | 7 |
2 files changed, 8 insertions, 7 deletions
diff --git a/drivers/i2c/busses/i2c-taos-evm.c b/drivers/i2c/busses/i2c-taos-evm.c index dd39c1eb03ed..26c352a09298 100644 --- a/drivers/i2c/busses/i2c-taos-evm.c +++ b/drivers/i2c/busses/i2c-taos-evm.c | |||
@@ -234,7 +234,7 @@ static int taos_connect(struct serio *serio, struct serio_driver *drv) | |||
234 | 234 | ||
235 | if (taos->state != TAOS_STATE_IDLE) { | 235 | if (taos->state != TAOS_STATE_IDLE) { |
236 | err = -ENODEV; | 236 | err = -ENODEV; |
237 | dev_dbg(&serio->dev, "TAOS EVM reset failed (state=%d, " | 237 | dev_err(&serio->dev, "TAOS EVM reset failed (state=%d, " |
238 | "pos=%d)\n", taos->state, taos->pos); | 238 | "pos=%d)\n", taos->state, taos->pos); |
239 | goto exit_close; | 239 | goto exit_close; |
240 | } | 240 | } |
@@ -255,7 +255,7 @@ static int taos_connect(struct serio *serio, struct serio_driver *drv) | |||
255 | msecs_to_jiffies(250)); | 255 | msecs_to_jiffies(250)); |
256 | if (taos->state != TAOS_STATE_IDLE) { | 256 | if (taos->state != TAOS_STATE_IDLE) { |
257 | err = -ENODEV; | 257 | err = -ENODEV; |
258 | dev_err(&adapter->dev, "Echo off failed " | 258 | dev_err(&serio->dev, "TAOS EVM echo off failed " |
259 | "(state=%d)\n", taos->state); | 259 | "(state=%d)\n", taos->state); |
260 | goto exit_close; | 260 | goto exit_close; |
261 | } | 261 | } |
@@ -263,7 +263,7 @@ static int taos_connect(struct serio *serio, struct serio_driver *drv) | |||
263 | err = i2c_add_adapter(adapter); | 263 | err = i2c_add_adapter(adapter); |
264 | if (err) | 264 | if (err) |
265 | goto exit_close; | 265 | goto exit_close; |
266 | dev_dbg(&serio->dev, "Connected to TAOS EVM\n"); | 266 | dev_info(&serio->dev, "Connected to TAOS EVM\n"); |
267 | 267 | ||
268 | taos->client = taos_instantiate_device(adapter); | 268 | taos->client = taos_instantiate_device(adapter); |
269 | return 0; | 269 | return 0; |
@@ -288,7 +288,7 @@ static void taos_disconnect(struct serio *serio) | |||
288 | serio_set_drvdata(serio, NULL); | 288 | serio_set_drvdata(serio, NULL); |
289 | kfree(taos); | 289 | kfree(taos); |
290 | 290 | ||
291 | dev_dbg(&serio->dev, "Disconnected from TAOS EVM\n"); | 291 | dev_info(&serio->dev, "Disconnected from TAOS EVM\n"); |
292 | } | 292 | } |
293 | 293 | ||
294 | static struct serio_device_id taos_serio_ids[] = { | 294 | static struct serio_device_id taos_serio_ids[] = { |
diff --git a/drivers/i2c/muxes/pca954x.c b/drivers/i2c/muxes/pca954x.c index 54e1ce73534b..6f8953664636 100644 --- a/drivers/i2c/muxes/pca954x.c +++ b/drivers/i2c/muxes/pca954x.c | |||
@@ -201,10 +201,11 @@ static int pca954x_probe(struct i2c_client *client, | |||
201 | 201 | ||
202 | i2c_set_clientdata(client, data); | 202 | i2c_set_clientdata(client, data); |
203 | 203 | ||
204 | /* Read the mux register at addr to verify | 204 | /* Write the mux register at addr to verify |
205 | * that the mux is in fact present. | 205 | * that the mux is in fact present. This also |
206 | * initializes the mux to disconnected state. | ||
206 | */ | 207 | */ |
207 | if (i2c_smbus_read_byte(client) < 0) { | 208 | if (i2c_smbus_write_byte(client, 0) < 0) { |
208 | dev_warn(&client->dev, "probe failed\n"); | 209 | dev_warn(&client->dev, "probe failed\n"); |
209 | goto exit_free; | 210 | goto exit_free; |
210 | } | 211 | } |