diff options
author | Andrew Morton <akpm@linux-foundation.org> | 2008-01-07 09:24:51 +0100 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@infradead.org> | 2008-01-25 22:04:41 +0100 |
commit | 98512f7b36ec412ea0461e9aab8f16c882df055d (patch) | |
tree | a4b734f0ff9e5a8e28e222b333ccca79f7518454 /drivers/media/radio | |
parent | V4L/DVB (6975): Add missing entry for Beholder BeholdTV 407 (diff) | |
download | linux-98512f7b36ec412ea0461e9aab8f16c882df055d.tar.xz linux-98512f7b36ec412ea0461e9aab8f16c882df055d.zip |
V4L/DVB (6976): drivers/media/radio/radio-sf16fmr2.c: fix error handling
video_register_device() returns -EFOO on errr, not -1.
Addresses http://bugzilla.kernel.org/show_bug.cgi?id=9699
Reported-By: <devzero@web.de>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
Diffstat (limited to 'drivers/media/radio')
-rw-r--r-- | drivers/media/radio/radio-sf16fmr2.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/media/radio/radio-sf16fmr2.c b/drivers/media/radio/radio-sf16fmr2.c index c432c44bd634..f7c8b000404f 100644 --- a/drivers/media/radio/radio-sf16fmr2.c +++ b/drivers/media/radio/radio-sf16fmr2.c @@ -476,8 +476,7 @@ static int __init fmr2_init(void) return -EBUSY; } - if(video_register_device(&fmr2_radio, VFL_TYPE_RADIO, radio_nr)==-1) - { + if (video_register_device(&fmr2_radio, VFL_TYPE_RADIO, radio_nr) < 0) { release_region(io, 2); return -EINVAL; } |