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/f_sourcesink.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/f_sourcesink.c')
-rw-r--r-- | drivers/usb/gadget/f_sourcesink.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/usb/gadget/f_sourcesink.c b/drivers/usb/gadget/f_sourcesink.c index 6d3cc443d91..e403a534dd5 100644 --- a/drivers/usb/gadget/f_sourcesink.c +++ b/drivers/usb/gadget/f_sourcesink.c | |||
@@ -498,7 +498,6 @@ unknown: | |||
498 | static struct usb_configuration sourcesink_driver = { | 498 | static struct usb_configuration sourcesink_driver = { |
499 | .label = "source/sink", | 499 | .label = "source/sink", |
500 | .strings = sourcesink_strings, | 500 | .strings = sourcesink_strings, |
501 | .bind = sourcesink_bind_config, | ||
502 | .setup = sourcesink_setup, | 501 | .setup = sourcesink_setup, |
503 | .bConfigurationValue = 3, | 502 | .bConfigurationValue = 3, |
504 | .bmAttributes = USB_CONFIG_ATT_SELFPOWER, | 503 | .bmAttributes = USB_CONFIG_ATT_SELFPOWER, |
@@ -532,5 +531,5 @@ int __init sourcesink_add(struct usb_composite_dev *cdev, bool autoresume) | |||
532 | sourcesink_driver.bmAttributes |= USB_CONFIG_ATT_WAKEUP; | 531 | sourcesink_driver.bmAttributes |= USB_CONFIG_ATT_WAKEUP; |
533 | } | 532 | } |
534 | 533 | ||
535 | return usb_add_config(cdev, &sourcesink_driver); | 534 | return usb_add_config(cdev, &sourcesink_driver, sourcesink_bind_config); |
536 | } | 535 | } |