af9013: Don't accept invalid bandwidth
authorMauro Carvalho Chehab <mchehab@osg.samsung.com>
Tue, 28 Apr 2015 22:02:19 +0000 (19:02 -0300)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Mon, 3 Aug 2015 16:29:43 +0000 (09:29 -0700)
commit85c81d78fd02debcdc0f885a10075f9aff55ee81
tree7acc4cf03c665d217ed6cf4eee8d75302d5e461d
parentaa264839927926ea7e4de21ba9d086708bc0ec18
af9013: Don't accept invalid bandwidth

commit d7b76c91f471413de9ded837bddeca2164786571 upstream.

If userspace sends an invalid bandwidth, it should either return
EINVAL or switch to auto mode.

This driver will go past an array and program the hardware on a
wrong way if this happens.

Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/media/dvb-frontends/af9013.c