Hi

I was having problems with my usb device, that failed with "hub.c: connect-debounce failed, port N disabled". This problem appears in all kernels from 2.4.19pre2 (including those 2.5.x I have tested, but there most probably with all 2.5.x as the impacted code seems to be same). Problems seems to be in clearing USB_PORT_STAT_CONNECTION flag after it is being read once. Don't ask me why, but thats what I find out. Following patch fixes this and IMHO should break anything else (it just leaves debounce look if device seems to be connected).

For those who noticed: yes this patch has already appeared here few weeks ago, but it was a bit hidden in thread and there was no reaction at all. Any comments?

Regards
Michal Cihar

--- linux-2.4.19-orig/drivers/usb/hub.c 2002-09-10 15:25:42.000000000 +0200
+++ linux/drivers/usb/hub.c 2002-09-11 11:12:04.000000000 +0200
@@ -655,6 +655,7 @@
}
else
delay_time += HUB_DEBOUNCE_STEP;
+ if (portstatus&USB_PORT_STAT_CONNECTION) return 0;
}
return ((portstatus&USB_PORT_STAT_CONNECTION)) ? 0 : 1;
}



-------------------------------------------------------
This sf.net email is sponsored by: See the NEW Palm Tungsten T handheld. Power & Color in a compact size!
http://ads.sourceforge.net/cgi-bin/redirect.pl?palm0001en
_______________________________________________
[EMAIL PROTECTED]
To unsubscribe, use the last form field at:
https://lists.sourceforge.net/lists/listinfo/linux-usb-devel

Reply via email to