Re: "reset full-speed USB device number 6 using ehci-pci" with Dell Inspiron 15R 5537

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon, 22 Feb 2016, Daniel Fraga wrote:

> On Mon, 22 Feb 2016 14:30:32 -0500 (EST)
> Alan Stern <stern@xxxxxxxxxxxxxxxxxxx> wrote:
> 
> > Well, I'm still puzzled.  I tried running that patch on my system
> > (under 4.5-rc2) and it worked perfectly.
> > 
> > So let's try for a little more detail.  Please apply this patch instead
> > of the earlier one.  Also, add no_console_suspend to the boot command
> > line, do
> > 
> > 	echo 7 >/proc/sys/kernel/printk
> > 
> > and start the suspend from a VT console rather than a GUI.
> 
> 	Ok Alan, here's what I got (I took 6 pictures of the screen
> because there's no way to use the keyboard):
> 
> 1) http://imgur.com/7bpA2i4
> 
> 2) http://imgur.com/2kmLaJb
> 
> 3) http://imgur.com/6wYPZZK
> 
> 4) http://imgur.com/S42nV4Q
> 
> 5) http://imgur.com/VHNl6My
> 
> 6) http://imgur.com/dYCdqWn

Unfortunately I really need to see the stuff that shows up before the 
first couple of pictures.  Is there any way you can use a serial 
console or network console to capture the log data?

Failing that, the patch below does the same thing as the previous patch 
but it adds a 5-second delay after each line is sent to the log.  Maybe 
you'll be able to photograph something useful during those delays.

Alan Stern



Index: usb-4.4/drivers/hid/usbhid/hid-core.c
===================================================================
--- usb-4.4.orig/drivers/hid/usbhid/hid-core.c
+++ usb-4.4/drivers/hid/usbhid/hid-core.c
@@ -1427,6 +1427,7 @@ static int hid_post_reset(struct usb_int
 	struct usb_host_interface *interface = intf->cur_altsetting;
 	int status;
 	char *rdesc;
+	extern int alantest;
 
 	/* Fetch and examine the HID report descriptor. If this
 	 * has changed, then rebind. Since usbcore's check of the
@@ -1457,7 +1458,10 @@ static int hid_post_reset(struct usb_int
 	clear_bit(HID_RESET_PENDING, &usbhid->iofl);
 	spin_unlock_irq(&usbhid->lock);
 	hid_set_idle(dev, intf->cur_altsetting->desc.bInterfaceNumber, 0, 0);
+	alantest = 1;
 	status = hid_start_in(hid);
+	alantest = 0;
+	dev_info(&intf->dev, "post reset hid_start_in -> %d\n", status);
 	if (status < 0)
 		hid_io_error(hid);
 	usbhid_restart_queues(usbhid);
Index: usb-4.4/drivers/usb/core/urb.c
===================================================================
--- usb-4.4.orig/drivers/usb/core/urb.c
+++ usb-4.4/drivers/usb/core/urb.c
@@ -184,6 +184,9 @@ EXPORT_SYMBOL_GPL(usb_unanchor_urb);
 
 /*-------------------------------------------------------------------*/
 
+int alantest;
+EXPORT_SYMBOL(alantest);
+
 /**
  * usb_submit_urb - issue an asynchronous transfer request for an endpoint
  * @urb: pointer to the urb describing the request
@@ -332,8 +335,16 @@ int usb_submit_urb(struct urb *urb, gfp_
 	int				is_out;
 	unsigned int			allowed;
 
+	if (alantest) {
+		pr_info("alantest: urb %p\n", urb);
+		mdelay(5000);
+		pr_info("alantest: udev %p\n", urb->dev);
+		mdelay(5000);
+	}
+	if (alantest) { dev_info(&urb->dev->dev, "submit A\n"); mdelay(5000); }
 	if (!urb || !urb->complete)
 		return -EINVAL;
+	if (alantest) { dev_info(&urb->dev->dev, "submit B\n"); mdelay(5000); }
 	if (urb->hcpriv) {
 		WARN_ONCE(1, "URB %p submitted while active\n", urb);
 		return -EBUSY;
@@ -395,6 +406,7 @@ int usb_submit_urb(struct urb *urb, gfp_
 	 * but drivers only control those sizes for ISO.
 	 * while we're checking, initialize return status.
 	 */
+	if (alantest) { dev_info(&urb->dev->dev, "submit C\n"); mdelay(5000); }
 	if (xfertype == USB_ENDPOINT_XFER_ISOC) {
 		int	n, len;
 
@@ -433,6 +445,7 @@ int usb_submit_urb(struct urb *urb, gfp_
 			if (sg->length % max)
 				return -EINVAL;
 	}
+	if (alantest) { dev_info(&urb->dev->dev, "submit D\n"); mdelay(5000); }
 
 	/* the I/O buffer must be mapped/unmapped, except when length=0 */
 	if (urb->transfer_buffer_length > INT_MAX)
@@ -487,6 +500,7 @@ int usb_submit_urb(struct urb *urb, gfp_
 	case USB_ENDPOINT_XFER_ISOC:
 	case USB_ENDPOINT_XFER_INT:
 		/* too small? */
+	if (alantest) { dev_info(&urb->dev->dev, "submit E\n"); mdelay(5000); }
 		switch (dev->speed) {
 		case USB_SPEED_WIRELESS:
 			if ((urb->interval < 6)
@@ -497,6 +511,7 @@ int usb_submit_urb(struct urb *urb, gfp_
 				return -EINVAL;
 			break;
 		}
+	if (alantest) { dev_info(&urb->dev->dev, "submit F\n"); mdelay(5000); }
 		/* too big? */
 		switch (dev->speed) {
 		case USB_SPEED_SUPER:	/* units are 125us */
@@ -532,6 +547,7 @@ int usb_submit_urb(struct urb *urb, gfp_
 		default:
 			return -EINVAL;
 		}
+	if (alantest) { dev_info(&urb->dev->dev, "submit G\n"); mdelay(5000); }
 		if (dev->speed != USB_SPEED_WIRELESS) {
 			/* Round down to a power of 2, no more than max */
 			urb->interval = min(max, 1 << ilog2(urb->interval));

--
To unsubscribe from this list: send the line "unsubscribe linux-usb" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [Linux Media]     [Linux Input]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [Old Linux USB Devel Archive]

  Powered by Linux