Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 285163
b: refs/heads/master
c: c27e305
h: refs/heads/master
i:
  285161: 950a4f1
  285159: 1a026d7
v: v3
  • Loading branch information
Laurent Pinchart authored and Mauro Carvalho Chehab committed Nov 7, 2011
1 parent e9c7c7b commit e2c4106
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 7 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: cfb128ed0768320c2d0e43cf781c8eaa622876b6
refs/heads/master: c27e3050378ec0d96d964cbf18746a30ad00ab9f
5 changes: 2 additions & 3 deletions trunk/drivers/media/video/mt9p031.c
Original file line number Diff line number Diff line change
Expand Up @@ -132,13 +132,12 @@ static struct mt9p031 *to_mt9p031(struct v4l2_subdev *sd)

static int mt9p031_read(struct i2c_client *client, u8 reg)
{
s32 data = i2c_smbus_read_word_data(client, reg);
return data < 0 ? data : be16_to_cpu(data);
return i2c_smbus_read_word_swapped(client, reg);
}

static int mt9p031_write(struct i2c_client *client, u8 reg, u16 data)
{
return i2c_smbus_write_word_data(client, reg, cpu_to_be16(data));
return i2c_smbus_write_word_swapped(client, reg, data);
}

static int mt9p031_set_output_control(struct mt9p031 *mt9p031, u16 clear,
Expand Down
5 changes: 2 additions & 3 deletions trunk/drivers/media/video/mt9t001.c
Original file line number Diff line number Diff line change
Expand Up @@ -133,13 +133,12 @@ static inline struct mt9t001 *to_mt9t001(struct v4l2_subdev *sd)

static int mt9t001_read(struct i2c_client *client, u8 reg)
{
s32 data = i2c_smbus_read_word_data(client, reg);
return data < 0 ? data : be16_to_cpu(data);
return i2c_smbus_read_word_swapped(client, reg);
}

static int mt9t001_write(struct i2c_client *client, u8 reg, u16 data)
{
return i2c_smbus_write_word_data(client, reg, cpu_to_be16(data));
return i2c_smbus_write_word_swapped(client, reg, data);
}

static int mt9t001_set_output_control(struct mt9t001 *mt9t001, u16 clear,
Expand Down

0 comments on commit e2c4106

Please sign in to comment.