Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit e9eb70c9 authored by Timur Tabi's avatar Timur Tabi Committed by Jeff Garzik
Browse files

ucc_geth: use of_get_mac_address()



Update ucc_geth_probe() to use function of_get_mac_address() to obtain the MAC
address.

Signed-off-by: default avatarTimur Tabi <timur@freescale.com>
Signed-off-by: default avatarJeff Garzik <jeff@garzik.org>
parent f19841f5
Loading
Loading
Loading
Loading
+1 −3
Original line number Diff line number Diff line
@@ -4199,9 +4199,7 @@ static int ucc_geth_probe(struct of_device* ofdev, const struct of_device_id *ma
	ugeth->ug_info = ug_info;
	ugeth->dev = dev;

	mac_addr = get_property(np, "mac-address", NULL);
	if (mac_addr == NULL)
		mac_addr = get_property(np, "local-mac-address", NULL);
	mac_addr = of_get_mac_address(np);
	if (mac_addr)
		memcpy(dev->dev_addr, mac_addr, 6);