aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/media/radio/dsbr100.c
diff options
context:
space:
mode:
authorAlexey Klimov <klimov.linux@gmail.com>2008-12-27 20:33:54 -0500
committerMauro Carvalho Chehab <mchehab@redhat.com>2008-12-30 06:40:12 -0500
commitfc55bcb0a04a66465ab13c33f36a290f6e3a3f7d (patch)
treebb4fe5bb81738b1c016f9968166584422826e483 /drivers/media/radio/dsbr100.c
parent7e1ca8491d046d1f01de105add7f2f8f477869ec (diff)
V4L/DVB (10060): dsbr100: fix and add right comments
Fix and add right comments. Few empty lines removed. Signed-off-by: Alexey Klimov <klimov.linux@gmail.com> Signed-off-by: Douglas Schilling Landgraf <dougsland@redhat.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'drivers/media/radio/dsbr100.c')
-rw-r--r--drivers/media/radio/dsbr100.c21
1 files changed, 10 insertions, 11 deletions
diff --git a/drivers/media/radio/dsbr100.c b/drivers/media/radio/dsbr100.c
index 5de5def9c166..448e5a42b468 100644
--- a/drivers/media/radio/dsbr100.c
+++ b/drivers/media/radio/dsbr100.c
@@ -1,5 +1,5 @@
1/* A driver for the D-Link DSB-R100 USB radio. The R100 plugs 1/* A driver for the D-Link DSB-R100 USB radio and Gemtek USB Radio 21.
2 into both the USB and an analog audio input, so this thing 2 The device plugs into both the USB and an analog audio input, so this thing
3 only deals with initialisation and frequency setting, the 3 only deals with initialisation and frequency setting, the
4 audio data has to be handled by a sound driver. 4 audio data has to be handled by a sound driver.
5 5
@@ -172,7 +172,6 @@ struct dsbr100_device {
172 int muted; 172 int muted;
173}; 173};
174 174
175
176static struct usb_device_id usb_dsbr100_device_table [] = { 175static struct usb_device_id usb_dsbr100_device_table [] = {
177 { USB_DEVICE(DSB100_VENDOR, DSB100_PRODUCT) }, 176 { USB_DEVICE(DSB100_VENDOR, DSB100_PRODUCT) },
178 { } /* Terminating entry */ 177 { } /* Terminating entry */
@@ -237,7 +236,6 @@ usb_control_msg_failed:
237 236
238} 237}
239 238
240
241/* switch off radio */ 239/* switch off radio */
242static int dsbr100_stop(struct dsbr100_device *radio) 240static int dsbr100_stop(struct dsbr100_device *radio)
243{ 241{
@@ -363,13 +361,14 @@ static void dsbr100_getstat(struct dsbr100_device *radio)
363 mutex_unlock(&radio->lock); 361 mutex_unlock(&radio->lock);
364} 362}
365 363
366
367/* USB subsystem interface begins here */ 364/* USB subsystem interface begins here */
368 365
369/* handle unplugging of the device, release data structures 366/*
370if nothing keeps us from doing it. If something is still 367 * Handle unplugging of the device.
371keeping us busy, the release callback of v4l will take care 368 * We call video_unregister_device in any case.
372of releasing it. */ 369 * The last function called in this procedure is
370 * usb_dsbr100_video_device_release
371 */
373static void usb_dsbr100_disconnect(struct usb_interface *intf) 372static void usb_dsbr100_disconnect(struct usb_interface *intf)
374{ 373{
375 struct dsbr100_device *radio = usb_get_intfdata(intf); 374 struct dsbr100_device *radio = usb_get_intfdata(intf);
@@ -640,6 +639,7 @@ static int usb_dsbr100_resume(struct usb_interface *intf)
640 return 0; 639 return 0;
641} 640}
642 641
642/* free data structures */
643static void usb_dsbr100_video_device_release(struct video_device *videodev) 643static void usb_dsbr100_video_device_release(struct video_device *videodev)
644{ 644{
645 struct dsbr100_device *radio = videodev_to_radio(videodev); 645 struct dsbr100_device *radio = videodev_to_radio(videodev);
@@ -683,8 +683,7 @@ static struct video_device dsbr100_videodev_data = {
683 .release = usb_dsbr100_video_device_release, 683 .release = usb_dsbr100_video_device_release,
684}; 684};
685 685
686/* check if the device is present and register with v4l and 686/* check if the device is present and register with v4l and usb if it is */
687usb if it is */
688static int usb_dsbr100_probe(struct usb_interface *intf, 687static int usb_dsbr100_probe(struct usb_interface *intf,
689 const struct usb_device_id *id) 688 const struct usb_device_id *id)
690{ 689{