diff options
-rw-r--r-- | drivers/usb/phy/phy-mxs-usb.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/usb/phy/phy-mxs-usb.c b/drivers/usb/phy/phy-mxs-usb.c index da031c45395a..fbec863350f6 100644 --- a/drivers/usb/phy/phy-mxs-usb.c +++ b/drivers/usb/phy/phy-mxs-usb.c | |||
@@ -602,6 +602,9 @@ static enum usb_charger_type mxs_phy_charger_detect(struct usb_phy *phy) | |||
602 | void __iomem *base = phy->io_priv; | 602 | void __iomem *base = phy->io_priv; |
603 | enum usb_charger_type chgr_type = UNKNOWN_TYPE; | 603 | enum usb_charger_type chgr_type = UNKNOWN_TYPE; |
604 | 604 | ||
605 | if (!regmap) | ||
606 | return UNKNOWN_TYPE; | ||
607 | |||
605 | if (mxs_charger_data_contact_detect(mxs_phy)) | 608 | if (mxs_charger_data_contact_detect(mxs_phy)) |
606 | return chgr_type; | 609 | return chgr_type; |
607 | 610 | ||