net: ti: cpsw-common: Isolate getting syscon address from assigning macid

ti_cm_get_macid() is used to get a syscon node from the dt, read the
efuse address and then assign the macid read from the address. Divide
these two steps into separate functions one of which can be called from
ofdata_to_platdata() while the other can be called from _probe(). This
ensures that platdata can be assigned statically in a board file when
OF_CONTROL is not enabled. Also add a macid_sel_compat in private data
to get information about the macid byte placement.

Signed-off-by: Faiz Abbas <faiz_abbas@ti.com>
diff --git a/drivers/net/ti/cpsw.c b/drivers/net/ti/cpsw.c
index 904d402..d9d25a6 100644
--- a/drivers/net/ti/cpsw.c
+++ b/drivers/net/ti/cpsw.c
@@ -1185,6 +1185,7 @@
 
 	priv->dev = dev;
 	priv->data = pdata->priv_pdata;
+	ti_cm_get_macid(dev, priv->data, pdata->enetaddr);
 	/* Select phy interface in control module */
 	cpsw_phy_sel(priv, priv->data->phy_sel_compat,
 		     pdata->phy_interface);
@@ -1336,7 +1337,7 @@
 		data->slave_data[1].sliver_reg_ofs = CPSW_SLIVER1_OFFSET;
 	}
 
-	ret = ti_cm_get_macid(dev, active_slave, pdata->enetaddr);
+	ret = ti_cm_get_macid_addr(dev, active_slave, data);
 	if (ret < 0) {
 		pr_err("cpsw read efuse mac failed\n");
 		return ret;