Commit 235ac9a4 authored by Sakari Ailus's avatar Sakari Ailus Committed by Mauro Carvalho Chehab

media: smiapp: Remove quirk function for writing a single 8-bit register

This function is no longer needed as the smiapp_write() function can be
used to write 8-bit registers with plain register addresses.
Signed-off-by: default avatarSakari Ailus <sakari.ailus@linux.intel.com>
Signed-off-by: default avatarMauro Carvalho Chehab <mchehab+huawei@kernel.org>
parent 42aab58f
......@@ -14,11 +14,6 @@
#include "smiapp.h"
static int smiapp_write_8(struct smiapp_sensor *sensor, u16 reg, u8 val)
{
return smiapp_write(sensor, reg, val);
}
static int smiapp_write_8s(struct smiapp_sensor *sensor,
const struct smiapp_reg_8 *regs, int len)
{
......@@ -26,7 +21,7 @@ static int smiapp_write_8s(struct smiapp_sensor *sensor,
int rval;
for (; len > 0; len--, regs++) {
rval = smiapp_write_8(sensor, regs->reg, regs->val);
rval = smiapp_write(sensor, regs->reg, regs->val);
if (rval < 0) {
dev_err(&client->dev,
"error %d writing reg 0x%4.4x, val 0x%2.2x",
......@@ -170,7 +165,7 @@ static int jt8ev1_post_poweron(struct smiapp_sensor *sensor)
static int jt8ev1_pre_streamon(struct smiapp_sensor *sensor)
{
return smiapp_write_8(sensor, 0x3328, 0x00);
return smiapp_write(sensor, 0x3328, 0x00);
}
static int jt8ev1_post_streamoff(struct smiapp_sensor *sensor)
......@@ -178,7 +173,7 @@ static int jt8ev1_post_streamoff(struct smiapp_sensor *sensor)
int rval;
/* Workaround: allows fast standby to work properly */
rval = smiapp_write_8(sensor, 0x3205, 0x04);
rval = smiapp_write(sensor, 0x3205, 0x04);
if (rval < 0)
return rval;
......@@ -186,11 +181,11 @@ static int jt8ev1_post_streamoff(struct smiapp_sensor *sensor)
usleep_range(2000, 2050);
/* Restore it */
rval = smiapp_write_8(sensor, 0x3205, 0x00);
rval = smiapp_write(sensor, 0x3205, 0x00);
if (rval < 0)
return rval;
return smiapp_write_8(sensor, 0x3328, 0x80);
return smiapp_write(sensor, 0x3328, 0x80);
}
static int jt8ev1_init(struct smiapp_sensor *sensor)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment