mirror of
https://github.com/torvalds/linux.git
synced 2026-06-09 23:23:53 +02:00
Mtp: fix mtp sync operation no response,hold in error stat.
fix bug: while read buffer length > MTP_BULK_BUFFER_SIZE, return -1 errno=EINVAL(22)
This commit is contained in:
parent
ba73f493d0
commit
bb2322bfa9
|
|
@ -470,7 +470,7 @@ static ssize_t mtp_read(struct file *fp, char __user *buf,
|
|||
DBG(cdev, "mtp_read(%d)\n", count);
|
||||
|
||||
if (count > MTP_BULK_BUFFER_SIZE)
|
||||
return -EINVAL;
|
||||
count = MTP_BULK_BUFFER_SIZE;
|
||||
|
||||
/* we will block until we're online */
|
||||
DBG(cdev, "mtp_read: waiting for online state\n");
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user