OSDN Git Service

USB: gadget: f_mtp: Make sure request is dequeued if transfer is canceled
authorMike Lockwood <lockwood@android.com>
Thu, 13 Jan 2011 21:19:57 +0000 (16:19 -0500)
committerBrian Swetland <swetland@google.com>
Tue, 29 Mar 2011 20:58:02 +0000 (13:58 -0700)
commit943935c67d762c65e786e066ceae8733e74dd4d6
treed1aa082ea10192c9985c5a1e02e1fc9f3117c68c
parenta21d6a9da5a78337f4734bbe3a75492b000615c0
USB: gadget: f_mtp: Make sure request is dequeued if transfer is canceled

If the host cancels a file transfer while we have a read request pending,
call usb_ep_dequeue to cancel the read.
Also return -ECANCELED from mtp_ioctl if we are canceled in MTP_RECEIVE_FILE

Signed-off-by: Mike Lockwood <lockwood@android.com>
drivers/usb/gadget/f_mtp.c