diff options
author | Federico Manzan <f.manzan@gmail.com> | 2013-05-24 12:18:48 -0400 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2013-05-29 04:06:36 -0400 |
commit | e2e2f0ea1c935edcf53feb4c4c8fdb4f86d57dd9 (patch) | |
tree | da19bad92c18109768fe2f97b1a48f9902a9baec /drivers/usb/core | |
parent | 5cbfa3acdcbf19e1d29cf3479ad8200d2e644e44 (diff) |
usbfs: Increase arbitrary limit for USB 3 isopkt length
Increase the current arbitrary limit for isocronous packet size to a
value large enough to account for USB 3.0 super bandwidth streams,
bMaxBurst (0~15 allowed, 1~16 packets)
bmAttributes (bit 1:0, mult 0~2, 1~3 packets)
so the size max for one USB 3 isocronous transfer is
1024 byte * 16 * 3 = 49152 byte
Acked-by: Alan Stern <stern@rowland.harvard.edu>
Signed-off-by: Federico Manzan <f.manzan@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/usb/core')
-rw-r--r-- | drivers/usb/core/devio.c | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/drivers/usb/core/devio.c b/drivers/usb/core/devio.c index caefc800f298..c88c4fb9459d 100644 --- a/drivers/usb/core/devio.c +++ b/drivers/usb/core/devio.c | |||
@@ -1287,9 +1287,13 @@ static int proc_do_submiturb(struct dev_state *ps, struct usbdevfs_urb *uurb, | |||
1287 | goto error; | 1287 | goto error; |
1288 | } | 1288 | } |
1289 | for (totlen = u = 0; u < uurb->number_of_packets; u++) { | 1289 | for (totlen = u = 0; u < uurb->number_of_packets; u++) { |
1290 | /* arbitrary limit, | 1290 | /* |
1291 | * sufficient for USB 2.0 high-bandwidth iso */ | 1291 | * arbitrary limit need for USB 3.0 |
1292 | if (isopkt[u].length > 8192) { | 1292 | * bMaxBurst (0~15 allowed, 1~16 packets) |
1293 | * bmAttributes (bit 1:0, mult 0~2, 1~3 packets) | ||
1294 | * sizemax: 1024 * 16 * 3 = 49152 | ||
1295 | */ | ||
1296 | if (isopkt[u].length > 49152) { | ||
1293 | ret = -EINVAL; | 1297 | ret = -EINVAL; |
1294 | goto error; | 1298 | goto error; |
1295 | } | 1299 | } |