diff options
author | Uwe Kleine-König <u.kleine-koenig@pengutronix.de> | 2018-12-04 09:31:30 +0100 |
---|---|---|
committer | Peter Chen <peter.chen@nxp.com> | 2018-12-11 09:13:10 +0800 |
commit | 1bf4743f641d85f32fe3f3a4d8aa01a387549e3e (patch) | |
tree | d1c818a57b8f0a96f8d5c716e582e96d99e358c3 /drivers | |
parent | a82bf696aa39b08c0dfce5569525e61368c6827f (diff) | |
download | talos-obmc-linux-1bf4743f641d85f32fe3f3a4d8aa01a387549e3e.tar.gz talos-obmc-linux-1bf4743f641d85f32fe3f3a4d8aa01a387549e3e.zip |
usb: chipidea: imx: Warn if oc polarity isn't specified
The polarity of the over current detection pin isn't configured on i.MX6/7
if it's unspecified in the device tree. So the actual configuration depends
on bootloader behavior which is bad.
So encourage users to fix their device tree by issuing a warning in this
case.
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Signed-off-by: Peter Chen <peter.chen@nxp.com>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/usb/chipidea/ci_hdrc_imx.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/usb/chipidea/ci_hdrc_imx.c b/drivers/usb/chipidea/ci_hdrc_imx.c index 1951b37aa39d..e81de9ca8729 100644 --- a/drivers/usb/chipidea/ci_hdrc_imx.c +++ b/drivers/usb/chipidea/ci_hdrc_imx.c @@ -148,6 +148,8 @@ static struct imx_usbmisc_data *usbmisc_get_init_data(struct device *dev) } else if (of_find_property(np, "over-current-active-low", NULL)) { data->oc_pol_active_low = 1; data->oc_pol_configured = 1; + } else { + dev_warn(dev, "No over current polarity defined\n"); } if (of_find_property(np, "external-vbus-divider", NULL)) |