summaryrefslogtreecommitdiff
path: root/drivers/usb/musb-new/musb_dsps.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/usb/musb-new/musb_dsps.c')
-rw-r--r--drivers/usb/musb-new/musb_dsps.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/drivers/usb/musb-new/musb_dsps.c b/drivers/usb/musb-new/musb_dsps.c
index 9b814f4cd4..0c794b310a 100644
--- a/drivers/usb/musb-new/musb_dsps.c
+++ b/drivers/usb/musb-new/musb_dsps.c
@@ -450,7 +450,7 @@ static int dsps_musb_init(struct musb *musb)
dsps_writel(reg_base, wrp->control, (1 << wrp->reset));
/* Start the on-chip PHY and its PLL. */
- if (data->set_phy_power)
+ if (data && data->set_phy_power)
data->set_phy_power(data->dev, 1);
musb->isr = dsps_interrupt;
@@ -491,7 +491,7 @@ static int dsps_musb_exit(struct musb *musb)
#endif
/* Shutdown the on-chip PHY and its PLL. */
- if (data->set_phy_power)
+ if (data && data->set_phy_power)
data->set_phy_power(data->dev, 0);
#ifndef __UBOOT__
@@ -691,7 +691,7 @@ static int dsps_suspend(struct device *dev)
struct omap_musb_board_data *data = plat->board_data;
/* Shutdown the on-chip PHY and its PLL. */
- if (data->set_phy_power)
+ if (data && data->set_phy_power)
data->set_phy_power(data->dev, 0);
return 0;
@@ -703,7 +703,7 @@ static int dsps_resume(struct device *dev)
struct omap_musb_board_data *data = plat->board_data;
/* Start the on-chip PHY and its PLL. */
- if (data->set_phy_power)
+ if (data && data->set_phy_power)
data->set_phy_power(data->dev, 1);
return 0;