diff options
author | Dmitry Torokhov <dmitry.torokhov@gmail.com> | 2014-03-01 19:31:53 +0100 |
---|---|---|
committer | Dmitry Torokhov <dmitry.torokhov@gmail.com> | 2014-03-01 19:31:53 +0100 |
commit | 04421fe2671c1790ab6529fad87ce8c73af0e1eb (patch) | |
tree | d2f803b4eef6108648f1beee6bf97a342cd9bc73 /drivers/usb/gadget/epautoconf.c | |
parent | Input: imx_keypad - Propagate the real error code on platform_get_irq() failure (diff) | |
parent | Linux 3.14-rc4 (diff) | |
download | linux-04421fe2671c1790ab6529fad87ce8c73af0e1eb.tar.xz linux-04421fe2671c1790ab6529fad87ce8c73af0e1eb.zip |
Merge tag 'v3.14-rc4' into next
Merge with Linux 3.14-rc4 to bring devm_request_any_context_irq().
Diffstat (limited to 'drivers/usb/gadget/epautoconf.c')
-rw-r--r-- | drivers/usb/gadget/epautoconf.c | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/drivers/usb/gadget/epautoconf.c b/drivers/usb/gadget/epautoconf.c index a777f7bd11b4..0567cca1465e 100644 --- a/drivers/usb/gadget/epautoconf.c +++ b/drivers/usb/gadget/epautoconf.c @@ -11,7 +11,6 @@ #include <linux/kernel.h> #include <linux/module.h> -#include <linux/init.h> #include <linux/types.h> #include <linux/device.h> @@ -58,7 +57,7 @@ ep_matches ( return 0; /* only support ep0 for portable CONTROL traffic */ - type = desc->bmAttributes & USB_ENDPOINT_XFERTYPE_MASK; + type = usb_endpoint_type(desc); if (USB_ENDPOINT_XFER_CONTROL == type) return 0; @@ -129,7 +128,7 @@ ep_matches ( * and wants to know the maximum possible, provide the info. */ if (desc->wMaxPacketSize == 0) - desc->wMaxPacketSize = cpu_to_le16(ep->maxpacket); + desc->wMaxPacketSize = cpu_to_le16(ep->maxpacket_limit); /* endpoint maxpacket size is an input parameter, except for bulk * where it's an output parameter representing the full speed limit. @@ -145,7 +144,7 @@ ep_matches ( case USB_ENDPOINT_XFER_ISOC: /* ISO: limit 1023 bytes full speed, 1024 high/super speed */ - if (ep->maxpacket < max) + if (ep->maxpacket_limit < max) return 0; if (!gadget_is_dualspeed(gadget) && max > 1023) return 0; @@ -178,7 +177,7 @@ ep_matches ( /* report (variable) full speed bulk maxpacket */ if ((USB_ENDPOINT_XFER_BULK == type) && !ep_comp) { - int size = ep->maxpacket; + int size = ep->maxpacket_limit; /* min() doesn't work on bitfields with gcc-3.5 */ if (size > 64) |