X-Git-Url: https://gerrit.opnfv.org/gerrit/gitweb?a=blobdiff_plain;f=kernel%2Fdrivers%2Fusb%2Fphy%2Fphy-mxs-usb.c;h=3fcc0483a0811e8f7e2984aea1c4a11ce2da0951;hb=fdb8b20906f3546ba6c2f9f0686d8a5189516ba3;hp=8f7cb068d29bab1eb1f9641e41cbe4da30e22489;hpb=cc84a1f21026270463b580f2564f9d71912b20db;p=kvmfornfv.git diff --git a/kernel/drivers/usb/phy/phy-mxs-usb.c b/kernel/drivers/usb/phy/phy-mxs-usb.c index 8f7cb068d..3fcc0483a 100644 --- a/kernel/drivers/usb/phy/phy-mxs-usb.c +++ b/kernel/drivers/usb/phy/phy-mxs-usb.c @@ -217,6 +217,9 @@ static bool mxs_phy_get_vbus_status(struct mxs_phy *mxs_phy) { unsigned int vbus_value; + if (!mxs_phy->regmap_anatop) + return false; + if (mxs_phy->port_id == 0) regmap_read(mxs_phy->regmap_anatop, ANADIG_USB1_VBUS_DET_STAT,