mirror of
https://github.com/torvalds/linux.git
synced 2026-06-08 14:42:37 +02:00
zd1201: do not use stack as URB transfer_buffer
commit 1206ff4ff9 upstream.
Patch fixes zd1201 not to use stack as URB transfer_buffer. URB buffers need
to be DMA-able, which stack is not.
Patch is only compile tested.
Signed-off-by: Jussi Kivilinna <jussi.kivilinna@iki.fi>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
parent
0cbf39727e
commit
b169395145
|
|
@ -98,10 +98,12 @@ static int zd1201_fw_upload(struct usb_device *dev, int apfw)
|
|||
goto exit;
|
||||
|
||||
err = usb_control_msg(dev, usb_rcvctrlpipe(dev, 0), 0x4,
|
||||
USB_DIR_IN | 0x40, 0,0, &ret, sizeof(ret), ZD1201_FW_TIMEOUT);
|
||||
USB_DIR_IN | 0x40, 0, 0, buf, sizeof(ret), ZD1201_FW_TIMEOUT);
|
||||
if (err < 0)
|
||||
goto exit;
|
||||
|
||||
memcpy(&ret, buf, sizeof(ret));
|
||||
|
||||
if (ret & 0x80) {
|
||||
err = -EIO;
|
||||
goto exit;
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user