diff options
author | Colin Ian King <colin.king@canonical.com> | 2016-09-03 14:04:17 -0300 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@s-opensource.com> | 2016-10-24 17:00:42 -0200 |
commit | c0b34ab141505087d7d66f447d77e6023f34501e (patch) | |
tree | 1adca98981a30cf9ba68b9b522cca16796b2d046 /drivers/media/dvb-frontends/cx24120.c | |
parent | 37e785682746b53017c7b6e533c3ac2c85bb4ac8 (diff) | |
download | lwn-c0b34ab141505087d7d66f447d77e6023f34501e.tar.gz lwn-c0b34ab141505087d7d66f447d77e6023f34501e.zip |
[media] cx24120: do not allow an invalid delivery system types
cx24120_set_frontend currently allows invalid delivery system types
other than SYS_DVBS2 and SYS_DVBS. Fix this by returning -EINVAL
for invalid values.
Signed-off-by: Colin Ian King <colin.king@canonical.com>
Acked-by: Jemma Denson <jdenson@gmail.com>
Diffstat (limited to 'drivers/media/dvb-frontends/cx24120.c')
-rw-r--r-- | drivers/media/dvb-frontends/cx24120.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/media/dvb-frontends/cx24120.c b/drivers/media/dvb-frontends/cx24120.c index 066ee387bf25..3112a3206d46 100644 --- a/drivers/media/dvb-frontends/cx24120.c +++ b/drivers/media/dvb-frontends/cx24120.c @@ -1154,8 +1154,7 @@ static int cx24120_set_frontend(struct dvb_frontend *fe) dev_dbg(&state->i2c->dev, "delivery system(%d) not supported\n", c->delivery_system); - ret = -EINVAL; - break; + return -EINVAL; } state->dnxt.delsys = c->delivery_system; |