ethoc_disable_rx_and_tx(priv);
}
+static int ethoc_ofdata_to_platdata(struct udevice *dev)
+{
+ struct ethoc_eth_pdata *pdata = dev_get_platdata(dev);
+
+ pdata->eth_pdata.iobase = dev_get_addr(dev);
+ return 0;
+}
+
static int ethoc_probe(struct udevice *dev)
{
struct ethoc_eth_pdata *pdata = dev_get_platdata(dev);
.write_hwaddr = ethoc_write_hwaddr,
};
+static const struct udevice_id ethoc_ids[] = {
+ { .compatible = "opencores,ethoc" },
+ { }
+};
+
U_BOOT_DRIVER(ethoc) = {
.name = "ethoc",
.id = UCLASS_ETH,
+ .of_match = ethoc_ids,
+ .ofdata_to_platdata = ethoc_ofdata_to_platdata,
.probe = ethoc_probe,
.remove = ethoc_remove,
.ops = ðoc_ops,