#include <linux/bug.h>
#include <linux/compat.h>
#include <linux/delay.h>
+#include <asm/global_data.h>
#include "ldpaa_eth.h"
#ifdef CONFIG_PHYLIB
#ifdef CONFIG_DM_ETH
static int ldpaa_eth_open(struct udevice *dev)
{
- struct eth_pdata *plat = dev_get_platdata(dev);
+ struct eth_pdata *plat = dev_get_plat(dev);
struct ldpaa_eth_priv *priv = dev_get_priv(dev);
#else
static int ldpaa_eth_open(struct eth_device *net_dev, struct bd_info *bd)
return 0;
}
-static int ldpaa_eth_ofdata_to_platdata(struct udevice *dev)
+static int ldpaa_eth_of_to_plat(struct udevice *dev)
{
struct ldpaa_eth_priv *priv = dev_get_priv(dev);
const char *phy_mode_str;
.name = "ldpaa_eth",
.id = UCLASS_ETH,
.of_match = ldpaa_eth_of_ids,
- .ofdata_to_platdata = ldpaa_eth_ofdata_to_platdata,
+ .of_to_plat = ldpaa_eth_of_to_plat,
.bind = ldpaa_eth_bind,
.probe = ldpaa_eth_probe,
.ops = &ldpaa_eth_ops,
- .priv_auto_alloc_size = sizeof(struct ldpaa_eth_priv),
- .platdata_auto_alloc_size = sizeof(struct eth_pdata),
+ .priv_auto = sizeof(struct ldpaa_eth_priv),
+ .plat_auto = sizeof(struct eth_pdata),
};
#else