diff options
author | Mauro Carvalho Chehab <mchehab@redhat.com> | 2009-06-29 11:12:05 -0300 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@redhat.com> | 2009-06-29 11:12:05 -0300 |
commit | a1f731e499ffb5e010c3b1d9b28cbfccc5db0028 (patch) | |
tree | bfff4e1fe4974277cdfbd3fb6fd5709bcb865d10 /linux/drivers/media/video | |
parent | b971cb7ebd14c02cdd2768cb81e96530eca6f5c6 (diff) | |
download | mediapointer-dvb-s2-a1f731e499ffb5e010c3b1d9b28cbfccc5db0028.tar.gz mediapointer-dvb-s2-a1f731e499ffb5e010c3b1d9b28cbfccc5db0028.tar.bz2 |
mt9v011: CodingStyle fixes
From: Mauro Carvalho Chehab <mchehab@redhat.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'linux/drivers/media/video')
-rw-r--r-- | linux/drivers/media/video/mt9v011.c | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/linux/drivers/media/video/mt9v011.c b/linux/drivers/media/video/mt9v011.c index ce64cd728..d3f2b4dc5 100644 --- a/linux/drivers/media/video/mt9v011.c +++ b/linux/drivers/media/video/mt9v011.c @@ -81,15 +81,17 @@ static int mt9v011_read(struct v4l2_subdev *sd, unsigned char addr) __be16 buffer; int rc, val; - if (1 != (rc = i2c_master_send(c, &addr, 1))) + rc = i2c_master_send(c, &addr, 1); + if (rc != 1) v4l2_dbg(0, debug, sd, "i2c i/o error: rc == %d (should be 1)\n", rc); msleep(10); - if (2 != (rc = i2c_master_recv(c, (char *)&buffer, 2))) + rc = i2c_master_recv(c, (char *)&buffer, 2); + if (rc != 2) v4l2_dbg(0, debug, sd, - "i2c i/o error: rc == %d (should be 1)\n", rc); + "i2c i/o error: rc == %d (should be 2)\n", rc); val = be16_to_cpu(buffer); @@ -111,7 +113,8 @@ static void mt9v011_write(struct v4l2_subdev *sd, unsigned char addr, v4l2_dbg(2, debug, sd, "mt9v011: writing 0x%02x 0x%04x\n", buffer[0], value); - if (3 != (rc = i2c_master_send(c, buffer, 3))) + rc = i2c_master_send(c, &buffer, 3); + if (rc != 3) v4l2_dbg(0, debug, sd, "i2c i/o error: rc == %d (should be 3)\n", rc); } |