media: tuners/it913x.c: fix missing error code
authorHans Verkuil <hverkuil-cisco@xs4all.nl>
Wed, 20 Jan 2021 08:39:20 +0000 (09:39 +0100)
committerMauro Carvalho Chehab <mchehab+huawei@kernel.org>
Wed, 27 Jan 2021 07:33:01 +0000 (08:33 +0100)
Fixes this smatch warning:

drivers/media/tuners/it913x.c:65 it913x_init() warn: missing error code 'ret'

Set ret to -EINVAL if the clock identifier was invalid.

Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
drivers/media/tuners/it913x.c

index e8e6639..7696a28 100644 (file)
@@ -62,6 +62,7 @@ static int it913x_init(struct dvb_frontend *fe)
                break;
        default:
                dev_err(&pdev->dev, "unknown clock identifier %d\n", utmp);
+               ret = -EINVAL;
                goto err;
        }