public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
From: Mike Frysinger <vapier@gentoo.org>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH] Add support Asix's AX88783 ethernet chip v1.00
Date: Tue, 15 Feb 2011 03:15:27 -0500	[thread overview]
Message-ID: <201102150315.28242.vapier@gentoo.org> (raw)
In-Reply-To: <1296849402-8662-1-git-send-email-lgxue@hotmail.com>

On Friday, February 04, 2011 14:56:42 Joe Xue wrote:
> +static int ax88783_init(struct eth_device *dev, bd_t * bd)
> +{
> +	...
> +	/* set mac address*/
> +	mactmp[0] = dev->enetaddr[5];
> +	mactmp[1] = dev->enetaddr[4];
> +	mactmp[2] = dev->enetaddr[3];
> +	mactmp[3] = dev->enetaddr[2];
> +	writel(*mac, &reg->p0mac0);
> +
> +	mactmp[0] = dev->enetaddr[1];
> +	mactmp[1] = dev->enetaddr[0];
> +	writel(*mac, &reg->p0mac1);
> +
> +	/* write mac to forward entry */
> +	mactmp[0] = dev->enetaddr[3];
> +	mactmp[1] = dev->enetaddr[2];
> +	mactmp[2] = dev->enetaddr[1];
> +	mactmp[3] = dev->enetaddr[0];
> +	writel(*mac, &reg->ftdata);
> +
> +	tmp = dev->enetaddr[4] | (dev->enetaddr[5]<<8) | \
> +	      FTCMD_FT_PORT(0x2) | FTCMD_FT_STATIC | \
> +	      FTCMD_WRITE_FT;
> +	writel(tmp, &reg->ftcmd);

implement eth_device->write_hwaddr rather than inlining the code in the init
-mike
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 836 bytes
Desc: This is a digitally signed message part.
Url : http://lists.denx.de/pipermail/u-boot/attachments/20110215/5a523bd7/attachment.pgp 

      reply	other threads:[~2011-02-15  8:15 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <Joe Xue>
2011-01-29  2:03 ` [U-Boot] [PATCH] Add support for AX88183 ethernet chip Joe Xue
2011-01-30 18:42   ` stefano babic
2011-01-31 17:35 ` [U-Boot] [PATCH] Add support for ASIX's AX88783 " Joe Xue
2011-01-31 17:42 ` Joe Xue
2011-02-02 18:02   ` Stefano Babic
2011-02-04 14:47     ` Joe XUE
2011-02-04 15:23       ` Stefano Babic
2011-02-04 15:59       ` Wolfgang Denk
2011-02-04 19:56 ` [U-Boot] [PATCH] Add support Asix's AX88783 ethernet chip v1.00 Joe Xue
2011-02-15  8:15   ` Mike Frysinger [this message]

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=201102150315.28242.vapier@gentoo.org \
    --to=vapier@gentoo.org \
    --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