Skip to content

Commit

Permalink
V4L/DVB (12143): radio-si470x: cleanups
Browse files Browse the repository at this point in the history
- Remove user count log messages
- Comments adopted to general style

Signed-off-by: Tobias Lorenz <tobias.lorenz@gmx.net>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
  • Loading branch information
Tobias Lorenz authored and Mauro Carvalho Chehab committed Sep 12, 2009
1 parent 721f59e commit 9817dc3
Showing 1 changed file with 3 additions and 9 deletions.
12 changes: 3 additions & 9 deletions drivers/media/radio/radio-si470x.c
Original file line number Diff line number Diff line change
Expand Up @@ -1141,17 +1141,15 @@ static int si470x_fops_open(struct file *file)
goto done;
}

printk(KERN_INFO DRIVER_NAME
": Opened radio (users now: %i)\n", radio->users);

if (radio->users == 1) {
/* start radio */
retval = si470x_start(radio);
if (retval < 0) {
usb_autopm_put_interface(radio->intf);
goto done;
}
/* Initialize interrupt URB. */

/* initialize interrupt urb */
usb_fill_int_urb(radio->int_in_urb, radio->usbdev,
usb_rcvintpipe(radio->usbdev,
radio->int_in_endpoint->bEndpointAddress),
Expand All @@ -1171,7 +1169,6 @@ static int si470x_fops_open(struct file *file)
radio->int_in_running = 0;
usb_autopm_put_interface(radio->intf);
}

}

done:
Expand All @@ -1196,11 +1193,8 @@ static int si470x_fops_release(struct file *file)

mutex_lock(&radio->disconnect_lock);
radio->users--;
printk(KERN_INFO DRIVER_NAME
": Closed radio (remaining users:%i)\n", radio->users);
if (radio->users == 0) {

/* Shutdown Interrupt handler */
/* shutdown interrupt handler */
if (radio->int_in_running) {
radio->int_in_running = 0;
if (radio->int_in_urb)
Expand Down

0 comments on commit 9817dc3

Please sign in to comment.