diff options
author | Hans Verkuil <hans.verkuil@cisco.com> | 2012-05-04 14:42:29 +0200 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@redhat.com> | 2012-05-14 18:45:44 +0200 |
commit | 6fd522a6d12d0ebac528f2d4553c4bf51c0c3275 (patch) | |
tree | d4fffc048e45264f848903dfb8bec83ff0d3598e /drivers/media/radio/si470x/radio-si470x-common.c | |
parent | [media] radio-si470x-common.c: remove unnecessary kernel log spam (diff) | |
download | linux-6fd522a6d12d0ebac528f2d4553c4bf51c0c3275.tar.xz linux-6fd522a6d12d0ebac528f2d4553c4bf51c0c3275.zip |
[media] radio-si470x-usb: remove autosuspend, implement suspend/resume
The radio-si470x-usb driver supported both autosuspend and it stopped the
radio the moment the last user of the radio device closed it. However, that
was very confusing since if you play the audio from the device (e.g. through
arecord -D ... | aplay) then no sound would play unless you had the radio
device open at the same time, even though there is no need to do anything
with that node.
On the other hand, the actual suspend/resume functions didn't do anything,
which would fail if you *did* have the radio node open at that time.
So:
- remove autosuspend (bad idea in general for USB radio devices)
- move the start/stop out of the open/release functions into the resume/suspend
functions.
Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Acked-by: Tobias Lorenz <tobias.lorenz@gmx.net>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'drivers/media/radio/si470x/radio-si470x-common.c')
-rw-r--r-- | drivers/media/radio/si470x/radio-si470x-common.c | 1 |
1 files changed, 0 insertions, 1 deletions
diff --git a/drivers/media/radio/si470x/radio-si470x-common.c b/drivers/media/radio/si470x/radio-si470x-common.c index b9a44d4a032f..969cf494d85b 100644 --- a/drivers/media/radio/si470x/radio-si470x-common.c +++ b/drivers/media/radio/si470x/radio-si470x-common.c @@ -570,7 +570,6 @@ static int si470x_s_ctrl(struct v4l2_ctrl *ctrl) else radio->registers[POWERCFG] |= POWERCFG_DMUTE; return si470x_set_register(radio, POWERCFG); - break; default: return -EINVAL; } |