usb: host: ehci-generic: initialize PHY only when found
authorPatrice Chotard <patrice.chotard@st.com>
Mon, 24 Jul 2017 15:07:04 +0000 (17:07 +0200)
committerMarek Vasut <marex@denx.de>
Fri, 28 Jul 2017 21:34:43 +0000 (23:34 +0200)
commit4b3928a08f24d21c2d34487b9d89fee35814bd0d
treeb2fce47816b22c714b01427d9899d837460a9303
parent623b7aca1f82bf1dee089c77f9a1020e80abaccc
usb: host: ehci-generic: initialize PHY only when found

Call generic_phy_init() only when a PHY was found.
This will avoid a crash if no "phys" property is found in DT.

Signed-off-by: Patrice Chotard <patrice.chotard@st.com>
Reported-by: Patrick Delaunay <patrick.delaunay@st.com>
drivers/usb/host/ehci-generic.c