On Tue, 21 Jul 2015, Peter Chen wrote:

> The ehci_init_driver is used to initialize hcd APIs for each
> ehci controller driver, it is designed to be called only one time
> and before driver register is called. The current design will
> cause ehci_init_driver is called multiple times at probe process,
> it will cause hc_driver's initialization affect current running hcd.
> 
> We run out NULL pointer dereference problem when one hcd is started
> by module_init, and the other is started by otg thread at SMP platform.
> The reason for this problem is ehci_init_driver will do memory copy
> for current uniform hc_driver, and this memory copy will do memset (as 0)
> first, so when the first hcd is running usb_add_hcd, and the second
> hcd may clear the uniform hc_driver's space (at ehci_init_driver),
> then the first hcd will meet NULL pointer at the same time.

> Cc: Jun Li <jun...@freescale.com>
> Cc: <sta...@vger.kernel.org>
> Cc: Alan Stern <st...@rowland.harvard.edu>
> Signed-off-by: Peter Chen <peter.c...@freescale.com>

Acked-by: Alan Stern <st...@rowland.harvard.edu>

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

Reply via email to