drivers: net: usb: pegasus: fix control urb submission
authorPetko Manolov <petkan@nucleusys.com>
Thu, 25 Apr 2013 22:41:50 +0000 (22:41 +0000)
committerDavid S. Miller <davem@davemloft.net>
Mon, 29 Apr 2013 17:57:50 +0000 (13:57 -0400)
commit323b34963d113efb566635f43858f40cce01d5f9
treecce217081da276ac54ad37b3ffa78c2da9e54ae8
parent2bd647018fe1b20c5c11dd1c508baea5771cd074
drivers: net: usb: pegasus: fix control urb submission

Pegasus driver used single callback for sync and async control URBs.
Special flags were employed to distinguish between both, but due to flawed
logic it didn't always work.  As a result of this change
[get|set]_registers() are now much simpler.  Async write is also leaner
and does not use single, statically allocated memory for usb_ctrlrequest,
which is another potential race when asynchronously submitting URBs.

Signed-off-by: Petko Manolov <petkan@nucleusys.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/usb/pegasus.c
drivers/net/usb/pegasus.h