diff options
author | Uwe Kleine-König <u.kleine-koenig@pengutronix.de> | 2010-08-12 11:43:55 -0400 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@suse.de> | 2010-10-22 13:21:26 -0400 |
commit | c9bfff9c98671ad50e4abbfe1ab606a9957f7539 (patch) | |
tree | 68ca78391c78bde1a82000e34eec70866f5c956e /drivers/usb/gadget/webcam.c | |
parent | 07a18bd716ed5dea336429404b132568cfaaef95 (diff) |
usb gadget: don't save bind callback in struct usb_configuration
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 configuration structure.
This fixes many section mismatches reported by modpost.
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
[m.nazarewicz@samsung.com: updated for -next]
Signed-off-by: Michał Nazarewicz <m.nazarewicz@samsung.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/usb/gadget/webcam.c')
-rw-r--r-- | drivers/usb/gadget/webcam.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/usb/gadget/webcam.c b/drivers/usb/gadget/webcam.c index de65b8078e05..a5a0fdb808c7 100644 --- a/drivers/usb/gadget/webcam.c +++ b/drivers/usb/gadget/webcam.c | |||
@@ -317,7 +317,6 @@ webcam_config_bind(struct usb_configuration *c) | |||
317 | 317 | ||
318 | static struct usb_configuration webcam_config_driver = { | 318 | static struct usb_configuration webcam_config_driver = { |
319 | .label = webcam_config_label, | 319 | .label = webcam_config_label, |
320 | .bind = webcam_config_bind, | ||
321 | .bConfigurationValue = 1, | 320 | .bConfigurationValue = 1, |
322 | .iConfiguration = 0, /* dynamic */ | 321 | .iConfiguration = 0, /* dynamic */ |
323 | .bmAttributes = USB_CONFIG_ATT_SELFPOWER, | 322 | .bmAttributes = USB_CONFIG_ATT_SELFPOWER, |
@@ -354,7 +353,8 @@ webcam_bind(struct usb_composite_dev *cdev) | |||
354 | webcam_config_driver.iConfiguration = ret; | 353 | webcam_config_driver.iConfiguration = ret; |
355 | 354 | ||
356 | /* Register our configuration. */ | 355 | /* Register our configuration. */ |
357 | if ((ret = usb_add_config(cdev, &webcam_config_driver)) < 0) | 356 | if ((ret = usb_add_config(cdev, &webcam_config_driver, |
357 | webcam_config_bind)) < 0) | ||
358 | goto error; | 358 | goto error; |
359 | 359 | ||
360 | INFO(cdev, "Webcam Video Gadget\n"); | 360 | INFO(cdev, "Webcam Video Gadget\n"); |