diff options
author | Douglas Schilling Landgraf <dougsland@linuxtv.org> | 2008-10-20 01:00:03 -0200 |
---|---|---|
committer | Douglas Schilling Landgraf <dougsland@linuxtv.org> | 2008-10-20 01:00:03 -0200 |
commit | fa2c7f7072fa52468acd23336dacef719c5ca706 (patch) | |
tree | b034e56ffaf69f45e4daba000810aa6da43bad6e /linux/drivers | |
parent | 7681262f35ef9d10b8389c719207aa55a357b4c0 (diff) | |
download | mediapointer-dvb-s2-fa2c7f7072fa52468acd23336dacef719c5ca706.tar.gz mediapointer-dvb-s2-fa2c7f7072fa52468acd23336dacef719c5ca706.tar.bz2 |
dsbr100: Add frequency check
From: Alexey Klimov <klimov.linux@gmail.com>
Add checking for frequency and printk if -1 returned.
Priority: normal
Signed-off-by: Alexey Klimov <klimov.linux@gmail.com>
Signed-off-by: Douglas Schilling Landgraf <dougsland@linuxtv.org>
Diffstat (limited to 'linux/drivers')
-rw-r--r-- | linux/drivers/media/radio/dsbr100.c | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/linux/drivers/media/radio/dsbr100.c b/linux/drivers/media/radio/dsbr100.c index 9f0bd34bc..71836beea 100644 --- a/linux/drivers/media/radio/dsbr100.c +++ b/linux/drivers/media/radio/dsbr100.c @@ -410,6 +410,7 @@ static int vidioc_s_audio(struct file *file, void *priv, static int usb_dsbr100_open(struct inode *inode, struct file *file) { struct dsbr100_device *radio = video_drvdata(file); + int retval; lock_kernel(); radio->users = 1; @@ -421,7 +422,12 @@ static int usb_dsbr100_open(struct inode *inode, struct file *file) unlock_kernel(); return -EIO; } - dsbr100_setfreq(radio, radio->curfreq); + + retval = dsbr100_setfreq(radio, radio->curfreq); + + if (retval == -1) + printk(KERN_WARNING KBUILD_MODNAME ": Set frequency failed\n"); + unlock_kernel(); return 0; } |