xhci controller problem on MBPr2013

Hans Petter Selasky hps at selasky.org
Sun Apr 27 11:37:20 UTC 2014


On 04/27/14 10:57, Huang Wen Hui wrote:
> Hi,
> The system hang  at random place after  pass xhci message. Before hangs, no
> usb device
> can attach in most time.
>

Hi,

If you change IMOD_DEFAULT like shown below, does it make any difference?

> === ./xhcireg.h
> ==================================================================
> --- ./xhcireg.h	(revision 264804)
> +++ ./xhcireg.h	(local)
> @@ -166,7 +166,7 @@
>  #define	XHCI_IMOD_IVAL_SET(x)	(((x) & 0xFFFF) << 0)	/* 250ns unit */
>  #define	XHCI_IMOD_ICNT_GET(x)	(((x) >> 16) & 0xFFFF)	/* 250ns unit */
>  #define	XHCI_IMOD_ICNT_SET(x)	(((x) & 0xFFFF) << 16)	/* 250ns unit */
> -#define	XHCI_IMOD_DEFAULT	0x000001F4U	/* 8000 IRQ/second */
> +#define	XHCI_IMOD_DEFAULT	0x01F401F4U	/* 8000 IRQ/second */
>  #define	XHCI_ERSTSZ(n)		(0x0028 + (0x20 * (n)))	/* XHCI event ring segment table size */
>  #define	XHCI_ERSTS_GET(x)	((x) & 0xFFFF)
>  #define	XHCI_ERSTS_SET(x)	((x) & 0xFFFF)


Second, if you comment out in xhci.c:

	/* catch any lost interrupts */
	xhci_do_poll(&sc->sc_bus);

Does that change anything?

Try one change at a time.

Thank you!

--HPS


More information about the freebsd-usb mailing list