On Thu, Sep 02, 2010 at 07:33:08AM +0200, Michal Nazarewicz wrote: > The bind function is most of the time only called at init time so there > is no need to save a pointer to it in the composite driver structure. > > This fixes many section mismatches reported by modpost. > > Signed-off-by: Michał Nazarewicz <m.nazarewicz@xxxxxxxxxxx> > Acked-by: Uwe Kleine-König <u.kleine-koenig@xxxxxxxxxxxxxx> > Signed-off-by: Greg Kroah-Hartman <gregkh@xxxxxxx> > --- > drivers/usb/gadget/audio.c | 3 +-- > drivers/usb/gadget/cdc2.c | 3 +-- > drivers/usb/gadget/composite.c | 15 +++++++++++---- > drivers/usb/gadget/ether.c | 3 +-- > drivers/usb/gadget/g_ffs.c | 3 +-- > drivers/usb/gadget/hid.c | 3 +-- > drivers/usb/gadget/mass_storage.c | 3 +-- > drivers/usb/gadget/multi.c | 3 +-- > drivers/usb/gadget/nokia.c | 3 +-- > drivers/usb/gadget/serial.c | 3 +-- > drivers/usb/gadget/webcam.c | 3 +-- > drivers/usb/gadget/zero.c | 3 +-- > include/linux/usb/composite.h | 19 +++++-------------- > 13 files changed, 27 insertions(+), 40 deletions(-) > > On Thu, 02 Sep 2010 05:54:50 +0200, Stephen Rothwell wrote: > > After merging the usb tree, today's linux-next build (x86_64 > > allmodconfig) failed like this: > > > > drivers/usb/gadget/nokia.c:244: error: unknown field 'bind' specified in initializer > > drivers/usb/gadget/nokia.c:244: warning: initialization makes integer from pointer without a cast > > drivers/usb/gadget/nokia.c:244: error: initializer element is not computable at load time > > drivers/usb/gadget/nokia.c:244: error: (near initialization for 'nokia_driver.needs_serial') > > drivers/usb/gadget/nokia.c: In function 'nokia_init': > > drivers/usb/gadget/nokia.c:250: error: implicit declaration of function 'usb_composite_register' > > > > Caused by commit cc604fa9db859b7d6899de807d6bd8df80fc0a1a ("usb gadget: > > don't save bind callback in struct usb_configuration"). The 'bind' and > > 'usb_composite_register' references above were added before 2.6.34-rc1 > > but missed in this patch. > > Sorry about that. Nokia composite gadget requires Phonet and that's > why I failed to catch this error. (Truly, grep would probably work > better). > > Attached is an updated patch that takes nokia.c into consideration as > well. Greg, please replace the non-working version of the patch in > your tree with this one. Now replaced, thanks. greg k-h -- To unsubscribe from this list: send the line "unsubscribe linux-next" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html