summaryrefslogtreecommitdiff
path: root/drivers/usb/gadget/function/f_ncm.c
diff options
context:
space:
mode:
authorRobert Baldyga <r.baldyga@samsung.com>2015-07-28 07:20:02 +0200
committerFelipe Balbi <balbi@ti.com>2015-07-30 11:43:36 -0500
commit7a896d40525349e7d52307fb957882696e09466c (patch)
tree4f6fe25e55bc3d7785b22d9b7a5aa19b428ed8d5 /drivers/usb/gadget/function/f_ncm.c
parenta4cc42157f3f8c3dd5562b91c7430376912c6fb8 (diff)
downloadlinux-7a896d40525349e7d52307fb957882696e09466c.tar.gz
linux-7a896d40525349e7d52307fb957882696e09466c.tar.bz2
linux-7a896d40525349e7d52307fb957882696e09466c.zip
usb: gadget: f_ecm/f_ncm: check quirk instead of UDC name
Use generic mechanism to check if UDC controller supports zlp. Signed-off-by: Robert Baldyga <r.baldyga@samsung.com> Signed-off-by: Felipe Balbi <balbi@ti.com>
Diffstat (limited to 'drivers/usb/gadget/function/f_ncm.c')
-rw-r--r--drivers/usb/gadget/function/f_ncm.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/drivers/usb/gadget/function/f_ncm.c b/drivers/usb/gadget/function/f_ncm.c
index bdcda9f5148e..3f05c6bd57f0 100644
--- a/drivers/usb/gadget/function/f_ncm.c
+++ b/drivers/usb/gadget/function/f_ncm.c
@@ -853,9 +853,8 @@ static int ncm_set_alt(struct usb_function *f, unsigned intf, unsigned alt)
/* Enable zlps by default for NCM conformance;
* override for musb_hdrc (avoids txdma ovhead)
*/
- ncm->port.is_zlp_ok = !(
- gadget_is_musbhdrc(cdev->gadget)
- );
+ ncm->port.is_zlp_ok =
+ gadget_is_zlp_supported(cdev->gadget);
ncm->port.cdc_filter = DEFAULT_FILTER;
DBG(cdev, "activate ncm\n");
net = gether_connect(&ncm->port);