]> git.karo-electronics.de Git - karo-tx-linux.git/commit
p54usb: rewriting rx/tx routines to make use of usb_anchor's facilities
authorChristian Lamparter <chunkeey@web.de>
Sat, 24 Jan 2009 09:44:53 +0000 (10:44 +0100)
committerGreg Kroah-Hartman <gregkh@suse.de>
Fri, 6 Feb 2009 21:47:22 +0000 (13:47 -0800)
commitd661ee77bd5eedd3782155b6c6f4426dda3abdd3
treec9d2da534e627c04b492424fcfe57a655fd814d4
parent621c147ff8fc7fca0d127e0e4c7c9c017560900a
p54usb: rewriting rx/tx routines to make use of usb_anchor's facilities

commit dd397dc9dddfa2149a1bbc9e52ac7d5630737cec upstream

Alan Stern found several flaws in p54usb's implementation and annotated:
"usb_kill_urb() and similar routines do not expect an URB's completion
routine to deallocate it.  This is almost obvious -- if the URB is deallocated
before the completion routine returns then there's no way for usb_kill_urb
to detect when the URB actually is complete."

This patch addresses all known limitations in the old implementation and fixes
khub's "use-after-freed" hang, when SLUB debug's poisoning option is enabled.

Signed-off-by: Christian Lamparter <chunkeey@web.de>
Tested-by: Larry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
drivers/net/wireless/p54/p54usb.c
drivers/net/wireless/p54/p54usb.h