summaryrefslogtreecommitdiff
path: root/drivers/net/tigon3.c
diff options
context:
space:
mode:
authorMike Frysinger <vapier@gentoo.org>2009-02-11 19:04:25 -0500
committerWolfgang Denk <wd@denx.de>2009-03-20 22:39:10 +0100
commitc4b8762f11d337e6a9d90c227b2871d65d372469 (patch)
tree5079ad627d9dba3d460276bba36a7f26de35bd06 /drivers/net/tigon3.c
parentd3f871482f06f6a4eaf4a3fafde84846bad87b4f (diff)
downloadu-boot-imx-c4b8762f11d337e6a9d90c227b2871d65d372469.zip
u-boot-imx-c4b8762f11d337e6a9d90c227b2871d65d372469.tar.gz
u-boot-imx-c4b8762f11d337e6a9d90c227b2871d65d372469.tar.bz2
bcm570x: get mac address from environment
The environment is the canonical storage location of the mac address, so we're killing off the global data location and moving everything to querying the env directly. Since the address is in the PLM_DEVICE_BLOCK structure already, there is no need to pass the NodeAddress as a second parameter. So drop the second argument to the LM_SetMacAddress() function (and update the tigon3 driver accordingly). Signed-off-by: Mike Frysinger <vapier@gentoo.org> CC: Ben Warren <biggerbadderben@gmail.com>
Diffstat (limited to 'drivers/net/tigon3.c')
-rw-r--r--drivers/net/tigon3.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/drivers/net/tigon3.c b/drivers/net/tigon3.c
index e4e004e..33cb447 100644
--- a/drivers/net/tigon3.c
+++ b/drivers/net/tigon3.c
@@ -2463,7 +2463,7 @@ LM_STATUS LM_ResetAdapter (PLM_DEVICE_BLOCK pDevice)
#endif /* T3_JUMBO_RCV_ENTRY_COUNT */
/* Configure the MAC address. */
- LM_SetMacAddress (pDevice, pDevice->NodeAddress);
+ LM_SetMacAddress (pDevice);
/* Initialize the transmit random backoff seed. */
Value32 = (pDevice->NodeAddress[0] + pDevice->NodeAddress[1] +
@@ -3428,7 +3428,7 @@ LM_STATUS LM_Halt (PLM_DEVICE_BLOCK pDevice)
(pDevice->SubsystemId << 16) | pDevice->SubsystemVendorId);
/* Reprogram the MAC address. */
- LM_SetMacAddress (pDevice, pDevice->NodeAddress);
+ LM_SetMacAddress (pDevice);
return LM_STATUS_SUCCESS;
} /* LM_Halt */
@@ -3833,9 +3833,10 @@ LM_STATUS LM_MulticastClear (PLM_DEVICE_BLOCK pDevice)
/* */
/* Return: */
/******************************************************************************/
-LM_STATUS LM_SetMacAddress (PLM_DEVICE_BLOCK pDevice, PLM_UINT8 pMacAddress)
+LM_STATUS LM_SetMacAddress (PLM_DEVICE_BLOCK pDevice)
{
LM_UINT32 j;
+ PLM_UINT8 pMacAddress = pDevice->NodeAddress;
for (j = 0; j < 4; j++) {
REG_WR (pDevice, MacCtrl.MacAddr[j].High,