From mboxrd@z Thu Jan 1 00:00:00 1970 From: Sergei Shtylyov Subject: Re: [PATCH v2 42/48] usb: gadget: epautoconf: use 'ep_match' gadget callback Date: Tue, 14 Jul 2015 14:04:32 +0300 Message-ID: <55A4ECC0.4030205@cogentembedded.com> References: <1436866776-5004-1-git-send-email-r.baldyga@samsung.com> <1436866776-5004-43-git-send-email-r.baldyga@samsung.com> Mime-Version: 1.0 Content-Type: text/plain; charset=windows-1252; format=flowed Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: <1436866776-5004-43-git-send-email-r.baldyga-Sze3O3UU22JBDgjK7y7TUQ@public.gmane.org> Sender: linux-usb-owner-u79uwXL29TY76Z2rM5mHXA@public.gmane.org To: Robert Baldyga , gregkh-hQyY1W1yCW8ekmWlsbkhG0B+6BGkLq7r@public.gmane.org, balbi-l0cyMroinI0@public.gmane.org Cc: Peter.Chen-KZfg59tc24xl57MIdRCFDg@public.gmane.org, johnyoun-HKixBCOQz3hWk0Htik3J/w@public.gmane.org, dahlmann.thomas-KvP5wT2u2U0@public.gmane.org, nicolas.ferre-AIFe0yeh4nAAvxtiuMwx3w@public.gmane.org, cernekee-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org, leoli-KZfg59tc24xl57MIdRCFDg@public.gmane.org, daniel-cYrQPVfZoowdnm+yROfE0A@public.gmane.org, haojian.zhuang-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org, robert.jarzmik-GANU6spQydw@public.gmane.org, michal.simek-gjFFaj9aHVfQT0dZR+AlfA@public.gmane.org, devel-gWbeCf7V1WCQmaza687I9mD2FQJk+8+b@public.gmane.org, linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org, linux-usb-u79uwXL29TY76Z2rM5mHXA@public.gmane.org, linux-omap-u79uwXL29TY76Z2rM5mHXA@public.gmane.org, linux-geode-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org, linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org, linuxppc-dev-uLR06cmDAlY/bJ5BZ2RsiQ@public.gmane.org, andrzej.p-Sze3O3UU22JBDgjK7y7TUQ@public.gmane.org, m.szyprowski-Sze3O3UU22JBDgjK7y7TUQ@public.gmane.org List-Id: linux-omap@vger.kernel.org Hello. On 7/14/2015 12:39 PM, Robert Baldyga wrote: > If gadget has set 'ep_match' callback we prefer to call it first to allow > UDC driver to find the best matching endpoint basing on chip-specific "best > usage" knowledge. > Signed-off-by: Robert Baldyga > --- > drivers/usb/gadget/epautoconf.c | 6 ++++++ > 1 file changed, 6 insertions(+) > diff --git a/drivers/usb/gadget/epautoconf.c b/drivers/usb/gadget/epautoconf.c > index ee0d4e6..92a1a4c 100644 > --- a/drivers/usb/gadget/epautoconf.c > +++ b/drivers/usb/gadget/epautoconf.c > @@ -165,6 +165,12 @@ struct usb_ep *usb_ep_autoconfig_ss( > > type = desc->bmAttributes & USB_ENDPOINT_XFERTYPE_MASK; > > + if (gadget->ops->match_ep) { > + ep = gadget->ops->match_ep(gadget, desc, ep_comp); > + if (ep) > + goto found_ep; > + } > + I think this patch should be merged with the previous one. [...] WBR, Sergei -- To unsubscribe from this list: send the line "unsubscribe linux-usb" in the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org More majordomo info at http://vger.kernel.org/majordomo-info.html From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-lb0-f182.google.com (mail-lb0-f182.google.com [209.85.217.182]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by lists.ozlabs.org (Postfix) with ESMTPS id A1D4A1A001E for ; Tue, 14 Jul 2015 21:04:39 +1000 (AEST) Received: by lblf12 with SMTP id f12so3905788lbl.2 for ; Tue, 14 Jul 2015 04:04:35 -0700 (PDT) Subject: Re: [PATCH v2 42/48] usb: gadget: epautoconf: use 'ep_match' gadget callback To: Robert Baldyga , gregkh@linuxfoundation.org, balbi@ti.com References: <1436866776-5004-1-git-send-email-r.baldyga@samsung.com> <1436866776-5004-43-git-send-email-r.baldyga@samsung.com> Cc: Peter.Chen@freescale.com, johnyoun@synopsys.com, dahlmann.thomas@arcor.de, nicolas.ferre@atmel.com, cernekee@gmail.com, leoli@freescale.com, daniel@zonque.org, haojian.zhuang@gmail.com, robert.jarzmik@free.fr, michal.simek@xilinx.com, devel@driverdev.osuosl.org, linux-kernel@vger.kernel.org, linux-usb@vger.kernel.org, linux-omap@vger.kernel.org, linux-geode@lists.infradead.org, linux-arm-kernel@lists.infradead.org, linuxppc-dev@lists.ozlabs.org, andrzej.p@samsung.com, m.szyprowski@samsung.com From: Sergei Shtylyov Message-ID: <55A4ECC0.4030205@cogentembedded.com> Date: Tue, 14 Jul 2015 14:04:32 +0300 MIME-Version: 1.0 In-Reply-To: <1436866776-5004-43-git-send-email-r.baldyga@samsung.com> Content-Type: text/plain; charset=windows-1252; format=flowed List-Id: Linux on PowerPC Developers Mail List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Hello. On 7/14/2015 12:39 PM, Robert Baldyga wrote: > If gadget has set 'ep_match' callback we prefer to call it first to allow > UDC driver to find the best matching endpoint basing on chip-specific "best > usage" knowledge. > Signed-off-by: Robert Baldyga > --- > drivers/usb/gadget/epautoconf.c | 6 ++++++ > 1 file changed, 6 insertions(+) > diff --git a/drivers/usb/gadget/epautoconf.c b/drivers/usb/gadget/epautoconf.c > index ee0d4e6..92a1a4c 100644 > --- a/drivers/usb/gadget/epautoconf.c > +++ b/drivers/usb/gadget/epautoconf.c > @@ -165,6 +165,12 @@ struct usb_ep *usb_ep_autoconfig_ss( > > type = desc->bmAttributes & USB_ENDPOINT_XFERTYPE_MASK; > > + if (gadget->ops->match_ep) { > + ep = gadget->ops->match_ep(gadget, desc, ep_comp); > + if (ep) > + goto found_ep; > + } > + I think this patch should be merged with the previous one. [...] WBR, Sergei From mboxrd@z Thu Jan 1 00:00:00 1970 From: sergei.shtylyov@cogentembedded.com (Sergei Shtylyov) Date: Tue, 14 Jul 2015 14:04:32 +0300 Subject: [PATCH v2 42/48] usb: gadget: epautoconf: use 'ep_match' gadget callback In-Reply-To: <1436866776-5004-43-git-send-email-r.baldyga@samsung.com> References: <1436866776-5004-1-git-send-email-r.baldyga@samsung.com> <1436866776-5004-43-git-send-email-r.baldyga@samsung.com> Message-ID: <55A4ECC0.4030205@cogentembedded.com> To: linux-arm-kernel@lists.infradead.org List-Id: linux-arm-kernel.lists.infradead.org Hello. On 7/14/2015 12:39 PM, Robert Baldyga wrote: > If gadget has set 'ep_match' callback we prefer to call it first to allow > UDC driver to find the best matching endpoint basing on chip-specific "best > usage" knowledge. > Signed-off-by: Robert Baldyga > --- > drivers/usb/gadget/epautoconf.c | 6 ++++++ > 1 file changed, 6 insertions(+) > diff --git a/drivers/usb/gadget/epautoconf.c b/drivers/usb/gadget/epautoconf.c > index ee0d4e6..92a1a4c 100644 > --- a/drivers/usb/gadget/epautoconf.c > +++ b/drivers/usb/gadget/epautoconf.c > @@ -165,6 +165,12 @@ struct usb_ep *usb_ep_autoconfig_ss( > > type = desc->bmAttributes & USB_ENDPOINT_XFERTYPE_MASK; > > + if (gadget->ops->match_ep) { > + ep = gadget->ops->match_ep(gadget, desc, ep_comp); > + if (ep) > + goto found_ep; > + } > + I think this patch should be merged with the previous one. [...] WBR, Sergei