From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from metis.ext.pengutronix.de (metis.ext.pengutronix.de [92.198.50.35]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (Client did not present a certificate) by ozlabs.org (Postfix) with ESMTPS id 27E5AB70E2 for ; Mon, 2 Aug 2010 23:14:04 +1000 (EST) Date: Mon, 2 Aug 2010 15:12:48 +0200 From: Uwe =?iso-8859-1?Q?Kleine-K=F6nig?= To: Julia Lawall Subject: Re: [PATCH] usb gadget: don't save bind callback in struct usb_gadget_driver Message-ID: <20100802131248.GD13900@pengutronix.de> References: <1280752803-11441-1-git-send-email-u.kleine-koenig@pengutronix.de> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 In-Reply-To: Cc: Cliff Cai , Greg Kroah-Hartman , Dinh Nguyen , Takashi Iwai , Nicolas Ferre , linux-kernel@vger.kernel.org, linuxppc-dev@ozlabs.org, Laurent Pinchart , Philipp Zabel , Mark Brown , Felipe Balbi , Andrea Gelmini , Robert Jarzmik , Fabien Chouteau , Dan Carpenter , FUJITA Tomonori , David Brownell , Vladimir Zapolskiy , Sergei Shtylyov , Vincent Sanders , Marc Singer , David Brownell , Tony Lindgren , =?iso-8859-1?Q?Andr=E9?= Goddard Rosa , Alan Stern , Sean MacLennan , Russell King , Tobias Klauser , Anatolij Gustschin , Alexey Dobriyan , Eirik Aanonsen , Mike Frysinger , Thomas Dahlmann , linux-geode@lists.infradead.org, Ben Dooks , Magnus Damm , Thomas Gleixner , Anton Vorontsov , Andrew Victor , linux-arm-kernel@lists.infradead.org, Robert Lukassen , Eric Miao , =?iso-8859-1?Q?N=E9meth_M=E1rton?= , Jiri Kosina , Yoshihiro Shimoda , linux-usb@vger.kernel.org, =?utf-8?Q?Micha=C5=82?= Nazarewicz , Harro Haan , Kyle McMartin , H Hartley Sweeten , Paul Mundt , Tejun Heo , Andrew Morton , Cory Maccarrone List-Id: Linux on PowerPC Developers Mail List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , On Mon, Aug 02, 2010 at 02:51:36PM +0200, Julia Lawall wrote: > > diff --git a/drivers/usb/gadget/amd5536udc.c b/drivers/usb/gadget/amd5536udc.c > > index 731150d..c266c1e 100644 > > --- a/drivers/usb/gadget/amd5536udc.c > > +++ b/drivers/usb/gadget/amd5536udc.c > > @@ -1954,13 +1954,14 @@ static int setup_ep0(struct udc *dev) > > } > > > > /* Called by gadget driver to register itself */ > > -int usb_gadget_register_driver(struct usb_gadget_driver *driver) > > +int usb_gadget_probe_driver(struct usb_gadget_driver *driver, > > + int (*bind)(struct usb_gadget *)) > > { > > struct udc *dev = udc; > > int retval; > > u32 tmp; > > > > - if (!driver || !driver->bind || !driver->setup > > + if (!driver || bind || !driver->setup > > I have the impression that this should be !bind rather than bind. ah, now I see what you meant. Obviously you're right. I fixed it up locally here for now. Greg, just tell me when/if you need a fixed patch. > That would be like what is done in the patch for > drivers/usb/gadget/fsl_udc_core.c below Thanks Uwe -- Pengutronix e.K. | Uwe Kleine-König | Industrial Linux Solutions | http://www.pengutronix.de/ |