linux/drivers/staging/vt6656
Julia Lawall 17fb76165f drivers/staging/vt6656/main_usb.c: Delete unnecessary call to usb_kill_urb
Since in each case nothing has been done with the recently allocated urb,
it is not necessary to kill it before freeing it.

The semantic patch that fixes this problem is as follows:
(http://coccinelle.lip6.fr/)

// <smpl>
@r exists@
expression urb;
statement S;
position p1,p2;
@@

urb = usb_alloc_urb@p1(...);
... when != urb
if (urb == NULL) S
... when != urb
usb_kill_urb@p2(urb);

@other exists@
position r.p1,r.p2;
@@

... when != usb_alloc_urb@p1(...)
usb_kill_urb@p2(...);

@depends on !other exists@
expression urb;
position r.p1,r.p2;
@@

urb = usb_alloc_urb@p1(...);
...
(
-usb_kill_urb@p2(urb);
+usb_free_urb(urb);
... when != urb
|
-usb_kill_urb@p2(urb);
)
// </smpl>

Signed-off-by: Julia Lawall <julia@diku.dk>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2011-05-17 11:37:57 -07:00
..
80211hdr.h
80211mgr.c
80211mgr.h
Kconfig Staging: vt665?: prevent modules from being built into the kernel. 2011-04-04 21:33:26 -07:00
Makefile
TODO
aes_ccmp.c
aes_ccmp.h
baseband.c
baseband.h
bssdb.c staging: Remove unnecessary semicolons when if (foo) {...}; 2011-04-25 16:58:34 -07:00
bssdb.h
card.c
card.h
channel.c
channel.h
control.c
control.h
country.h
datarate.c
datarate.h
desc.h
device.h
device_cfg.h
dpc.c staging: Remove unnecessary semicolons when if (foo) {...}; 2011-04-25 16:58:34 -07:00
dpc.h
firmware.c staging: vt6656: Remove NULL check before kfree 2011-03-14 11:57:37 -07:00
firmware.h
hostap.c staging: vt6656: Remove NULL check before kfree 2011-03-14 11:57:37 -07:00
hostap.h
int.c
int.h
iocmd.h
ioctl.c staging: Remove unnecessary semicolons when for (foo) {...}; 2011-04-25 16:58:35 -07:00
ioctl.h
iowpa.h
iwctl.c
iwctl.h
key.c
key.h
mac.c
mac.h
main_usb.c drivers/staging/vt6656/main_usb.c: Delete unnecessary call to usb_kill_urb 2011-05-17 11:37:57 -07:00
mib.c
mib.h
michael.c
michael.h
power.c Staging: vt6656: Clean up switching to power saving mode. 2011-03-02 15:52:30 -05:00
power.h
rc4.c
rc4.h
rf.c
rf.h
rndis.h
rxtx.c staging: Remove unnecessary semicolons when if (foo) {...}; 2011-04-25 16:58:34 -07:00
rxtx.h
srom.h
tcrc.c
tcrc.h
tether.c
tether.h
tkip.c
tkip.h
tmacro.h
ttype.h
upc.h
usbpipe.c
usbpipe.h
vntconfiguration.dat
wcmd.c staging: Remove unnecessary semicolons when if (foo) {...}; 2011-04-25 16:58:34 -07:00
wcmd.h
wctl.c
wctl.h
wmgr.c staging: Remove unnecessary semicolons when for (foo) {...}; 2011-04-25 16:58:35 -07:00
wmgr.h Fix common misspellings 2011-03-31 11:26:23 -03:00
wpa.c
wpa.h
wpa2.c
wpa2.h
wpactl.c staging: Remove unnecessary semicolons when switch (foo) {...}; 2011-04-25 16:58:35 -07:00
wpactl.h