Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 3132be9a authored by Linus Torvalds's avatar Linus Torvalds
Browse files
Pull USB fixes from Greg KH:
 "Here are some tiny USB fixes for 3.11-rc4

  Nothing major, some gadget fixes, some new device ids, a new tiny
  driver for the ANT+ USB device, and a number of fixes for the mos7840
  driver that were much needed"

* tag 'usb-3.11-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb:
  USB: serial: ftdi_sio: add more RT Systems ftdi devices
  usb: chipidea: fix the build error with randconfig
  usb: chipidea: cast PORTSC_PTS and DEVLC_PTS macros
  usb: gadget: udc-core: fix the typo of udc state attribute
  usb: gadget: f_phonet: remove unused preprocessor conditional
  usb: gadget: multi: fix error return code in cdc_do_config()
  USB: mos7840: fix pointer casts
  USB: mos7840: fix race in led handling
  USB: mos7840: fix device-type detection
  USB: mos7840: fix race in register handling
  USB: serial: add driver for Suunto ANT+ USB device
  usb: gadget: free opts struct on error recovery
  usb: gadget: ether: put_usb_function on unbind
  usb: musb: fix resource passed from glue layer to musb
parents a93f66dc fed1f1ed
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -12,7 +12,7 @@ if USB_CHIPIDEA

config USB_CHIPIDEA_UDC
	bool "ChipIdea device controller"
	depends on USB_GADGET=y || USB_CHIPIDEA=m
	depends on USB_GADGET=y || (USB_CHIPIDEA=m && USB_GADGET=m)
	help
	  Say Y here to enable device controller functionality of the
	  ChipIdea driver.
@@ -20,7 +20,7 @@ config USB_CHIPIDEA_UDC
config USB_CHIPIDEA_HOST
	bool "ChipIdea host controller"
	depends on USB=y
	depends on USB_EHCI_HCD=y || USB_CHIPIDEA=m
	depends on USB_EHCI_HCD=y || (USB_CHIPIDEA=m && USB_EHCI_HCD=m)
	select USB_EHCI_ROOT_HUB_TT
	help
	  Say Y here to enable host controller functionality of the
+2 −2
Original line number Diff line number Diff line
@@ -50,7 +50,7 @@
#define PORTSC_PTC            (0x0FUL << 16)
/* PTS and PTW for non lpm version only */
#define PORTSC_PTS(d)						\
	((((d) & 0x3) << 30) | (((d) & 0x4) ? BIT(25) : 0))
	(u32)((((d) & 0x3) << 30) | (((d) & 0x4) ? BIT(25) : 0))
#define PORTSC_PTW            BIT(28)
#define PORTSC_STS            BIT(29)

@@ -59,7 +59,7 @@
#define DEVLC_PSPD_HS         (0x02UL << 25)
#define DEVLC_PTW             BIT(27)
#define DEVLC_STS             BIT(28)
#define DEVLC_PTS(d)          (((d) & 0x7) << 29)
#define DEVLC_PTS(d)          (u32)(((d) & 0x7) << 29)

/* Encoding for DEVLC_PTS and PORTSC_PTS */
#define PTS_UTMI              0
+10 −4
Original line number Diff line number Diff line
@@ -449,14 +449,20 @@ static int __init eth_bind(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);
	if (use_eem)
	}
	if (use_eem) {
		usb_put_function(f_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);
	else
	} else {
		usb_put_function(f_geth);
		usb_put_function_instance(fi_geth);
	}
	return 0;
}

+0 −2
Original line number Diff line number Diff line
@@ -488,7 +488,6 @@ static int pn_bind(struct usb_configuration *c, struct usb_function *f)
	struct usb_ep *ep;
	int status, i;

#ifndef USBF_PHONET_INCLUDED
	struct f_phonet_opts *phonet_opts;

	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;
		phonet_opts->bound = true;
	}
#endif

	/* Reserve interface IDs */
	status = usb_interface_id(c, f);
+3 −7
Original line number Diff line number Diff line
@@ -160,10 +160,8 @@ static __init int rndis_do_config(struct usb_configuration *c)
		return ret;

	f_acm_rndis = usb_get_function(fi_acm);
	if (IS_ERR(f_acm_rndis)) {
		ret = PTR_ERR(f_acm_rndis);
		goto err_func_acm;
	}
	if (IS_ERR(f_acm_rndis))
		return PTR_ERR(f_acm_rndis);

	ret = usb_add_function(c, f_acm_rndis);
	if (ret)
@@ -178,7 +176,6 @@ static __init int rndis_do_config(struct usb_configuration *c)
	usb_remove_function(c, f_acm_rndis);
err_conf:
	usb_put_function(f_acm_rndis);
err_func_acm:
	return ret;
}

@@ -226,7 +223,7 @@ static __init int cdc_do_config(struct usb_configuration *c)
	/* implicit port_num is zero */
	f_acm_multi = usb_get_function(fi_acm);
	if (IS_ERR(f_acm_multi))
		goto err_func_acm;
		return PTR_ERR(f_acm_multi);

	ret = usb_add_function(c, f_acm_multi);
	if (ret)
@@ -241,7 +238,6 @@ static __init int cdc_do_config(struct usb_configuration *c)
	usb_remove_function(c, f_acm_multi);
err_conf:
	usb_put_function(f_acm_multi);
err_func_acm:
	return ret;
}

Loading