public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
From: Ben Warren <biggerbadderben@gmail.com>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH] net: altera_tse: add write_hwaddr support
Date: Tue, 27 Apr 2010 00:27:04 -0700	[thread overview]
Message-ID: <4BD691C8.9050702@gmail.com> (raw)
In-Reply-To: <1272348719-1810-1-git-send-email-thomas@wytron.com.tw>

Hi Thomas,

On 4/26/2010 11:11 PM, Thomas Chou wrote:
> Signed-off-by: Thomas Chou<thomas@wytron.com.tw>
> ---
>   drivers/net/altera_tse.c |   63 ++++++++++++++++++++++++++-------------------
>   1 files changed, 36 insertions(+), 27 deletions(-)
>
>    
<snip>
>   static int tse_eth_init(struct eth_device *dev, bd_t * bd)
>   {
>   	int dat;
> @@ -830,33 +864,7 @@ static int tse_eth_init(struct eth_device *dev, bd_t * bd)
>   	mac_dev->command_config.image = dat;
>
>   	/* Set the MAC address */
> -	debug("Setting MAC address to 0x%x%x%x%x%x%x\n",
> -	      dev->enetaddr[5], dev->enetaddr[4],
> -	      dev->enetaddr[3], dev->enetaddr[2],
> -	      dev->enetaddr[1], dev->enetaddr[0]);
> -	mac_dev->mac_addr_0 = ((dev->enetaddr[3])<<  24 |
> -			       (dev->enetaddr[2])<<  16 |
> -			       (dev->enetaddr[1])<<  8 | (dev->enetaddr[0]));
> -
> -	mac_dev->mac_addr_1 = ((dev->enetaddr[5]<<  8 |
> -				(dev->enetaddr[4]))&  0xFFFF);
> -
> -	/* Set the MAC address */
> -	mac_dev->supp_mac_addr_0_0 = mac_dev->mac_addr_0;
> -	mac_dev->supp_mac_addr_0_1 = mac_dev->mac_addr_1;
> -
> -	/* Set the MAC address */
> -	mac_dev->supp_mac_addr_1_0 = mac_dev->mac_addr_0;
> -	mac_dev->supp_mac_addr_1_1 = mac_dev->mac_addr_1;
> -
> -	/* Set the MAC address */
> -	mac_dev->supp_mac_addr_2_0 = mac_dev->mac_addr_0;
> -	mac_dev->supp_mac_addr_2_1 = mac_dev->mac_addr_1;
> -
> -	/* Set the MAC address */
> -	mac_dev->supp_mac_addr_3_0 = mac_dev->mac_addr_0;
> -	mac_dev->supp_mac_addr_3_1 = mac_dev->mac_addr_1;
> -
> +	tse_set_mac_address(dev);
>    
Why is this needed?  Do you see a situation where the user would 'setenv 
ethmacskip' and then actually use the interface?

regards,
Ben

  reply	other threads:[~2010-04-27  7:27 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-04-27  6:11 [U-Boot] [PATCH] net: altera_tse: add write_hwaddr support Thomas Chou
2010-04-27  7:27 ` Ben Warren [this message]
2010-04-27 12:15 ` [U-Boot] [PATCH v2] " Thomas Chou
2010-04-27 17:09   ` Ben Warren

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4BD691C8.9050702@gmail.com \
    --to=biggerbadderben@gmail.com \
    --cc=u-boot@lists.denx.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox