#include <linux/davinci_emac.h>
#include <linux/of.h>
#include <linux/of_device.h>
+#include <linux/pinctrl/consumer.h>
/*
* This timeout definition is a worst-case ultra defensive measure against
data->bus->parent = dev;
data->bus->priv = data;
+ /* Select default pin state */
+ pinctrl_pm_select_default_state(&pdev->dev);
+
pm_runtime_enable(&pdev->dev);
pm_runtime_get_sync(&pdev->dev);
data->clk = clk_get(&pdev->dev, "fck");
data->suspended = true;
spin_unlock(&data->lock);
+ /* Select sleep pin state */
+ pinctrl_pm_select_sleep_state(dev);
+
return 0;
}
struct davinci_mdio_data *data = dev_get_drvdata(dev);
u32 ctrl;
+ /* Select default pin state */
+ pinctrl_pm_select_default_state(dev);
+
spin_lock(&data->lock);
pm_runtime_get_sync(data->dev);