[media] bttv: disable g/s_tuner and g/s_freq when no tuner present, fix return codes
authorHans Verkuil <hans.verkuil@cisco.com>
Wed, 6 Feb 2013 14:43:07 +0000 (11:43 -0300)
committerMauro Carvalho Chehab <mchehab@redhat.com>
Tue, 5 Mar 2013 17:01:59 +0000 (14:01 -0300)
commitd9b6707673b6590bb6b984af6c435c807335a459
tree086339647bc1764d69daffe2a9c53fb45759d75e
parentf74f89cb1cf2cccdc111bcab7de4fb8c41bb2a07
[media] bttv: disable g/s_tuner and g/s_freq when no tuner present, fix return codes

If no tuner is present, then disable the tuner and frequency ioctls.
We can remove a number of checks from those ioctls testing for the presence
of a tuner.
Also remove some tuner type checks (now done by the core) and fix an
error return when the prio check fails.
Finally some 'unlikely' statements are removed since those only make sense
in tightly often executed loops, otherwise they just clutter up the code.

Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
drivers/media/pci/bt8xx/bttv-driver.c