mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2024-10-06 08:46:46 +00:00
[media] adv7170: drop redundant ret local
Simplifies return value logic of adv7170_set_fmt(). Signed-off-by: Baruch Siach <baruch@tkos.co.il> Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
This commit is contained in:
parent
30e0e2ed7c
commit
5f98e5f555
1 changed files with 2 additions and 3 deletions
|
@ -298,7 +298,6 @@ static int adv7170_set_fmt(struct v4l2_subdev *sd,
|
||||||
{
|
{
|
||||||
struct v4l2_mbus_framefmt *mf = &format->format;
|
struct v4l2_mbus_framefmt *mf = &format->format;
|
||||||
u8 val = adv7170_read(sd, 0x7);
|
u8 val = adv7170_read(sd, 0x7);
|
||||||
int ret = 0;
|
|
||||||
|
|
||||||
if (format->pad)
|
if (format->pad)
|
||||||
return -EINVAL;
|
return -EINVAL;
|
||||||
|
@ -319,9 +318,9 @@ static int adv7170_set_fmt(struct v4l2_subdev *sd,
|
||||||
}
|
}
|
||||||
|
|
||||||
if (format->which == V4L2_SUBDEV_FORMAT_ACTIVE)
|
if (format->which == V4L2_SUBDEV_FORMAT_ACTIVE)
|
||||||
ret = adv7170_write(sd, 0x7, val);
|
return adv7170_write(sd, 0x7, val);
|
||||||
|
|
||||||
return ret;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* ----------------------------------------------------------------------- */
|
/* ----------------------------------------------------------------------- */
|
||||||
|
|
Loading…
Reference in a new issue