Skip to content

Commit 79eab28

Browse files
committed
media: vpbe_venc: don't store return codes if they won't be used
Fix those two warnings drivers/media/platform/davinci/vpbe_venc.c: In function ‘venc_set_ntsc’: drivers/media/platform/davinci/vpbe_venc.c:230:6: warning: variable ‘val’ set but not used [-Wunused-but-set-variable] u32 val; ^~~ drivers/media/platform/davinci/vpbe_venc.c: In function ‘venc_sub_dev_init’: drivers/media/platform/davinci/vpbe_venc.c:611:6: warning: variable ‘err’ set but not used [-Wunused-but-set-variable] int err; ^~~ AR drivers/media/platform/davinci/built-in.a Signed-off-by: Mauro Carvalho Chehab <[email protected]>
1 parent 05c9090 commit 79eab28

File tree

1 file changed

+2
-4
lines changed

1 file changed

+2
-4
lines changed

drivers/media/platform/davinci/vpbe_venc.c

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -227,7 +227,6 @@ venc_enable_vpss_clock(int venc_type,
227227
*/
228228
static int venc_set_ntsc(struct v4l2_subdev *sd)
229229
{
230-
u32 val;
231230
struct venc_state *venc = to_state(sd);
232231
struct venc_platform_data *pdata = venc->pdata;
233232

@@ -244,7 +243,7 @@ static int venc_set_ntsc(struct v4l2_subdev *sd)
244243
if (venc->venc_type == VPBE_VERSION_3) {
245244
venc_write(sd, VENC_CLKCTL, 0x01);
246245
venc_write(sd, VENC_VIDCTL, 0);
247-
val = vdaccfg_write(sd, VDAC_CONFIG_SD_V3);
246+
vdaccfg_write(sd, VDAC_CONFIG_SD_V3);
248247
} else if (venc->venc_type == VPBE_VERSION_2) {
249248
venc_write(sd, VENC_CLKCTL, 0x01);
250249
venc_write(sd, VENC_VIDCTL, 0);
@@ -608,9 +607,8 @@ struct v4l2_subdev *venc_sub_dev_init(struct v4l2_device *v4l2_dev,
608607
const char *venc_name)
609608
{
610609
struct venc_state *venc;
611-
int err;
612610

613-
err = bus_for_each_dev(&platform_bus_type, NULL, &venc,
611+
bus_for_each_dev(&platform_bus_type, NULL, &venc,
614612
venc_device_get);
615613
if (venc == NULL)
616614
return NULL;

0 commit comments

Comments
 (0)