USB: serial: fix DMA buffers on stack for io_edgeport.c
authorDan Carpenter <error27@gmail.com>
Thu, 31 Dec 2009 15:42:55 +0000 (17:42 +0200)
committerGreg Kroah-Hartman <gregkh@suse.de>
Tue, 2 Mar 2010 22:53:59 +0000 (14:53 -0800)
The original code was passing a stack variable as a dma buffer, so I
made it an allocated variable.  Instead of adding a bunch of kfree()
calls, I changed all the error return paths to gotos.

Also I noticed that the error checking wasn't correct because
usb_get_descriptor() can return negative values.

While I was at it, I made an unrelated white space change by moving
the unicode_to_ascii() on to one line.

Signed-off-by: Dan Carpenter <error27@gmail.com>
Cc: Johan Hovold <jhovold@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
drivers/usb/serial/io_edgeport.c

Simple merge