Here are some fixes for v3.11-rc3. Mostly related to
 the recent conversion to configfs done on the gadget
 drivers, but we also have a fix for MUSB resources
 on platforms which need 3 resources instead of 2, and
 a fix for the sysfs_notify() call on udc-core.c which
 was notifying an unexistent file.
 -----BEGIN PGP SIGNATURE-----
 Version: GnuPG v1.4.12 (GNU/Linux)
 
 iQIcBAABAgAGBQJR9lyoAAoJEIaOsuA1yqREcBwQAKUZmCxjyiCfuCHpTi5/CxzQ
 CBxawqgB1fA2v+8y7j/c2MwRBwgpJgGbVkyrIiiC6dpdUUw9z+2drFFyvMk4005j
 ER7/qF4/0RPVH/C1PPJ3pFjAwYw1iSx7hFCxo6oJMhlxWNvzhR3REz3Z48fg8rK/
 nDIxMlAcApZTVMsHrNRJLUX3kfSSn4p0bip+bh4sXHRaR2+RXE7cSHL3mXE7QkMl
 osCtaAXsOXUC+Og/wXhY8ZNM1y3gM/Dzc4oYB/kauu38xzLdIsoRJ3I/vn4a9lF0
 XppQkwW1+9lqoE68gtF640Z4kPtBLbpxksS+pCvyA99u4YFFejbhfqF09dA/8/it
 uZETtN3IkMCA/AgADle15dmNZld7y+WHmtxhVMEabYwTH29ua0I3ZFouSwyWhUl6
 8ffWD4b4vTxUAWzuULTJFW8m5Z7YkMaurtNgmtuF03wZnRs6JJFtRnnz+ax+YqoR
 MqqueC+pmRAPR3AMUM/R71gIThDYaEGPm/InHh9uDp3BI9TYhQzEmKe+mQN4wXhf
 Wy+ubbrP6d+GKzVDS1jurlnXPDJu0r+EHbvPJEhV8oLbDqoq+MGnqCljr0GDSWJy
 D1/za0nHqENwGv/wJ5/pVPz1i0CMd5CrQioDBtjFco65RWxAA/y954gpFM5WowMo
 BlrBKOJIqXcsOhqfK2J2
 =WNXc
 -----END PGP SIGNATURE-----

Merge tag 'fixes-for-v3.11-rc3' of git://git.kernel.org/pub/scm/linux/kernel/git/balbi/usb into usb-linus

Felipe writes:

usb: fixes for v3.11-rc3

Here are some fixes for v3.11-rc3. Mostly related to
the recent conversion to configfs done on the gadget
drivers, but we also have a fix for MUSB resources
on platforms which need 3 resources instead of 2, and
a fix for the sysfs_notify() call on udc-core.c which
was notifying an unexistent file.
This commit is contained in:
Greg Kroah-Hartman 2013-07-29 07:44:52 -07:00
Родитель 683a0e4d79 1894870eb4
Коммит 235d57eda8
6 изменённых файлов: 26 добавлений и 16 удалений

Просмотреть файл

@ -449,14 +449,20 @@ fail:
static int __exit eth_unbind(struct usb_composite_dev *cdev) static int __exit eth_unbind(struct usb_composite_dev *cdev)
{ {
if (has_rndis()) if (has_rndis()) {
usb_put_function(f_rndis);
usb_put_function_instance(fi_rndis); usb_put_function_instance(fi_rndis);
if (use_eem) }
if (use_eem) {
usb_put_function(f_eem);
usb_put_function_instance(fi_eem); usb_put_function_instance(fi_eem);
else if (can_support_ecm(cdev->gadget)) } else if (can_support_ecm(cdev->gadget)) {
usb_put_function(f_ecm);
usb_put_function_instance(fi_ecm); usb_put_function_instance(fi_ecm);
else } else {
usb_put_function(f_geth);
usb_put_function_instance(fi_geth); usb_put_function_instance(fi_geth);
}
return 0; return 0;
} }

Просмотреть файл

@ -488,7 +488,6 @@ static int pn_bind(struct usb_configuration *c, struct usb_function *f)
struct usb_ep *ep; struct usb_ep *ep;
int status, i; int status, i;
#ifndef USBF_PHONET_INCLUDED
struct f_phonet_opts *phonet_opts; struct f_phonet_opts *phonet_opts;
phonet_opts = container_of(f->fi, struct f_phonet_opts, func_inst); phonet_opts = container_of(f->fi, struct f_phonet_opts, func_inst);
@ -507,7 +506,6 @@ static int pn_bind(struct usb_configuration *c, struct usb_function *f)
return status; return status;
phonet_opts->bound = true; phonet_opts->bound = true;
} }
#endif
/* Reserve interface IDs */ /* Reserve interface IDs */
status = usb_interface_id(c, f); status = usb_interface_id(c, f);

Просмотреть файл

@ -160,10 +160,8 @@ static __init int rndis_do_config(struct usb_configuration *c)
return ret; return ret;
f_acm_rndis = usb_get_function(fi_acm); f_acm_rndis = usb_get_function(fi_acm);
if (IS_ERR(f_acm_rndis)) { if (IS_ERR(f_acm_rndis))
ret = PTR_ERR(f_acm_rndis); return PTR_ERR(f_acm_rndis);
goto err_func_acm;
}
ret = usb_add_function(c, f_acm_rndis); ret = usb_add_function(c, f_acm_rndis);
if (ret) if (ret)
@ -178,7 +176,6 @@ err_fsg:
usb_remove_function(c, f_acm_rndis); usb_remove_function(c, f_acm_rndis);
err_conf: err_conf:
usb_put_function(f_acm_rndis); usb_put_function(f_acm_rndis);
err_func_acm:
return ret; return ret;
} }
@ -226,7 +223,7 @@ static __init int cdc_do_config(struct usb_configuration *c)
/* implicit port_num is zero */ /* implicit port_num is zero */
f_acm_multi = usb_get_function(fi_acm); f_acm_multi = usb_get_function(fi_acm);
if (IS_ERR(f_acm_multi)) if (IS_ERR(f_acm_multi))
goto err_func_acm; return PTR_ERR(f_acm_multi);
ret = usb_add_function(c, f_acm_multi); ret = usb_add_function(c, f_acm_multi);
if (ret) if (ret)
@ -241,7 +238,6 @@ err_fsg:
usb_remove_function(c, f_acm_multi); usb_remove_function(c, f_acm_multi);
err_conf: err_conf:
usb_put_function(f_acm_multi); usb_put_function(f_acm_multi);
err_func_acm:
return ret; return ret;
} }

Просмотреть файл

@ -109,7 +109,7 @@ void usb_gadget_set_state(struct usb_gadget *gadget,
enum usb_device_state state) enum usb_device_state state)
{ {
gadget->state = state; gadget->state = state;
sysfs_notify(&gadget->dev.kobj, NULL, "status"); sysfs_notify(&gadget->dev.kobj, NULL, "state");
} }
EXPORT_SYMBOL_GPL(usb_gadget_set_state); EXPORT_SYMBOL_GPL(usb_gadget_set_state);

Просмотреть файл

@ -481,7 +481,7 @@ static u64 omap2430_dmamask = DMA_BIT_MASK(32);
static int omap2430_probe(struct platform_device *pdev) static int omap2430_probe(struct platform_device *pdev)
{ {
struct resource musb_resources[2]; struct resource musb_resources[3];
struct musb_hdrc_platform_data *pdata = pdev->dev.platform_data; struct musb_hdrc_platform_data *pdata = pdev->dev.platform_data;
struct omap_musb_board_data *data; struct omap_musb_board_data *data;
struct platform_device *musb; struct platform_device *musb;
@ -581,6 +581,11 @@ static int omap2430_probe(struct platform_device *pdev)
musb_resources[1].end = pdev->resource[1].end; musb_resources[1].end = pdev->resource[1].end;
musb_resources[1].flags = pdev->resource[1].flags; musb_resources[1].flags = pdev->resource[1].flags;
musb_resources[2].name = pdev->resource[2].name;
musb_resources[2].start = pdev->resource[2].start;
musb_resources[2].end = pdev->resource[2].end;
musb_resources[2].flags = pdev->resource[2].flags;
ret = platform_device_add_resources(musb, musb_resources, ret = platform_device_add_resources(musb, musb_resources,
ARRAY_SIZE(musb_resources)); ARRAY_SIZE(musb_resources));
if (ret) { if (ret) {

Просмотреть файл

@ -1156,7 +1156,7 @@ static u64 tusb_dmamask = DMA_BIT_MASK(32);
static int tusb_probe(struct platform_device *pdev) static int tusb_probe(struct platform_device *pdev)
{ {
struct resource musb_resources[2]; struct resource musb_resources[3];
struct musb_hdrc_platform_data *pdata = pdev->dev.platform_data; struct musb_hdrc_platform_data *pdata = pdev->dev.platform_data;
struct platform_device *musb; struct platform_device *musb;
struct tusb6010_glue *glue; struct tusb6010_glue *glue;
@ -1199,6 +1199,11 @@ static int tusb_probe(struct platform_device *pdev)
musb_resources[1].end = pdev->resource[1].end; musb_resources[1].end = pdev->resource[1].end;
musb_resources[1].flags = pdev->resource[1].flags; musb_resources[1].flags = pdev->resource[1].flags;
musb_resources[2].name = pdev->resource[2].name;
musb_resources[2].start = pdev->resource[2].start;
musb_resources[2].end = pdev->resource[2].end;
musb_resources[2].flags = pdev->resource[2].flags;
ret = platform_device_add_resources(musb, musb_resources, ret = platform_device_add_resources(musb, musb_resources,
ARRAY_SIZE(musb_resources)); ARRAY_SIZE(musb_resources));
if (ret) { if (ret) {