Skip to content

Commit a19db02

Browse files
sophecRobertCNelson
authored andcommitted
cpsw: fix undefined function with PM disabled
When CONFIG_PM is not enabled, the function davinci_mdio_update_dt_from_phymask is not defined. This patch fixes this so that the build does not fail with CONFIG_PM disabled. Signed-off-by: Will Eccles <[email protected]>
1 parent 7599682 commit a19db02

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

drivers/net/ethernet/ti/davinci_mdio.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -484,6 +484,8 @@ static int davinci_mdio_runtime_resume(struct device *dev)
484484
davinci_mdio_enable(data);
485485
return 0;
486486
}
487+
#endif
488+
487489
static void davinci_mdio_update_dt_from_phymask(u32 phy_mask)
488490
{
489491
int i, len, skip;
@@ -571,7 +573,6 @@ static void davinci_mdio_update_dt_from_phymask(u32 phy_mask)
571573
kfree(phy_id_property);
572574
}
573575
}
574-
#endif
575576

576577
#ifdef CONFIG_PM_SLEEP
577578
static int davinci_mdio_suspend(struct device *dev)

0 commit comments

Comments
 (0)