linuxppc-dev.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
From: Benjamin Herrenschmidt <benh@kernel.crashing.org>
To: Grant Erickson <gerickson@nuovations.com>
Cc: linuxppc-dev@ozlabs.org, sr@denx.de, jgarzik@pobox.com
Subject: Re: [PATCH v2] ibm_newemac: Add MII mode support to the EMAC RGMII bridge.
Date: Wed, 09 Jul 2008 13:23:22 +1000	[thread overview]
Message-ID: <1215573802.8970.302.camel@pasglop> (raw)
In-Reply-To: <1215529386-12749-1-git-send-email-gerickson@nuovations.com>

On Tue, 2008-07-08 at 08:03 -0700, Grant Erickson wrote:
> This patch adds support to the RGMII handler in the EMAC driver for
> the MII PHY mode such that device tree entries of the form `phy-mode = "mii";'
> are recognized and handled appropriately.
> 
> While logically, in software, "gmii" and "mii" modes are the same,
> they are wired differently, so it makes sense to allow DTS authors to
> specify each explicitly.
> 
> Signed-off-by: Grant Erickson <gerickson@nuovations.com>

Acked-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
---

Jeff, I'd like to apply that (and other EMAC patches for 2.6.27, do you
have anything else pending ?) via my tree provided you give me your ack.
The reason is that the multicast fix one is going that way as it touches
other arch files, and subsequent ones are now likely to conflict.

Let me know if that's ok with you in which case I'll stick your ack in
there.

Cheers,
Ben.

> ---
>  drivers/net/ibm_newemac/rgmii.c |    6 ++++++
>  1 files changed, 6 insertions(+), 0 deletions(-)
> 
> diff --git a/drivers/net/ibm_newemac/rgmii.c b/drivers/net/ibm_newemac/rgmii.c
> index e32da3d..5acb006 100644
> --- a/drivers/net/ibm_newemac/rgmii.c
> +++ b/drivers/net/ibm_newemac/rgmii.c
> @@ -39,6 +39,7 @@
>  #define RGMII_FER_RGMII(idx)	(0x5 << ((idx) * 4))
>  #define RGMII_FER_TBI(idx)	(0x6 << ((idx) * 4))
>  #define RGMII_FER_GMII(idx)	(0x7 << ((idx) * 4))
> +#define RGMII_FER_MII(idx)	RGMII_FER_GMII(idx)
>  
>  /* RGMIIx_SSR */
>  #define RGMII_SSR_MASK(idx)	(0x7 << ((idx) * 8))
> @@ -49,6 +50,7 @@
>  static inline int rgmii_valid_mode(int phy_mode)
>  {
>  	return  phy_mode == PHY_MODE_GMII ||
> +		phy_mode == PHY_MODE_MII ||
>  		phy_mode == PHY_MODE_RGMII ||
>  		phy_mode == PHY_MODE_TBI ||
>  		phy_mode == PHY_MODE_RTBI;
> @@ -63,6 +65,8 @@ static inline const char *rgmii_mode_name(int mode)
>  		return "TBI";
>  	case PHY_MODE_GMII:
>  		return "GMII";
> +	case PHY_MODE_MII:
> +		return "MII";
>  	case PHY_MODE_RTBI:
>  		return "RTBI";
>  	default:
> @@ -79,6 +83,8 @@ static inline u32 rgmii_mode_mask(int mode, int input)
>  		return RGMII_FER_TBI(input);
>  	case PHY_MODE_GMII:
>  		return RGMII_FER_GMII(input);
> +	case PHY_MODE_MII:
> +		return RGMII_FER_MII(input);
>  	case PHY_MODE_RTBI:
>  		return RGMII_FER_RTBI(input);
>  	default:
> --
> 1.5.4.3

  parent reply	other threads:[~2008-07-09  3:23 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-07-07 23:31 [PATCH] ibm_newemac: Add MII mode support to the EMAC RGMII bridge Grant Erickson
2008-07-07 23:40 ` Benjamin Herrenschmidt
2008-07-07 23:47   ` Grant Erickson
2008-07-08  0:46     ` Benjamin Herrenschmidt
2008-07-08 15:03     ` [PATCH v2] " Grant Erickson
2008-07-08 15:35       ` Stefan Roese
2008-07-09  3:23       ` Benjamin Herrenschmidt [this message]
2008-07-11  5:19         ` Jeff Garzik

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=1215573802.8970.302.camel@pasglop \
    --to=benh@kernel.crashing.org \
    --cc=gerickson@nuovations.com \
    --cc=jgarzik@pobox.com \
    --cc=linuxppc-dev@ozlabs.org \
    --cc=sr@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;
as well as URLs for NNTP newsgroup(s).