diff options
author | Takashi Iwai <tiwai@suse.de> | 2015-01-20 10:42:42 +0300 |
---|---|---|
committer | Takashi Iwai <tiwai@suse.de> | 2015-01-28 09:19:37 +0300 |
commit | 8a3b7c086a509d90c312ebab6d8e5a9bf48c6cf5 (patch) | |
tree | 89c8dd81edfc0148e3c5a5a54aa93892739e58db /sound/usb/line6/toneport.c | |
parent | 2a324fcdb568f4d7b0b65b271039beb987f6e1cd (diff) | |
download | linux-8a3b7c086a509d90c312ebab6d8e5a9bf48c6cf5.tar.xz |
ALSA: line6: Remove superfluous NULL checks in each driver
The interface and driver objects are always set when callbacks are
called. Drop such superfluous NULL checks in init and disconnect
calls of each driver.
Tested-by: Chris Rorvick <chris@rorvick.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Diffstat (limited to 'sound/usb/line6/toneport.c')
-rw-r--r-- | sound/usb/line6/toneport.c | 6 |
1 files changed, 0 insertions, 6 deletions
diff --git a/sound/usb/line6/toneport.c b/sound/usb/line6/toneport.c index c1f61cde52ab..e5669bd3233a 100644 --- a/sound/usb/line6/toneport.c +++ b/sound/usb/line6/toneport.c @@ -370,9 +370,6 @@ static void line6_toneport_disconnect(struct usb_interface *interface) struct usb_line6_toneport *toneport; u16 idProduct; - if (interface == NULL) - return; - toneport = usb_get_intfdata(interface); del_timer_sync(&toneport->timer); idProduct = le16_to_cpu(toneport->line6.usbdev->descriptor.idProduct); @@ -393,9 +390,6 @@ static int toneport_init(struct usb_interface *interface, int err; struct usb_line6_toneport *toneport = (struct usb_line6_toneport *) line6; - if ((interface == NULL) || (toneport == NULL)) - return -ENODEV; - line6->disconnect = line6_toneport_disconnect; /* initialize PCM subsystem: */ |