From: Andrew Lunn <andrew@lunn.ch>
To: "SZ Lin (?????????)" <sz.lin@moxa.com>
Cc: Schuyler Patton <spatton@ti.com>,
Grygorii Strashko <grygorii.strashko@ti.com>,
"David S. Miller" <davem@davemloft.net>,
Ivan Khoronzhuk <ivan.khoronzhuk@linaro.org>,
Keerthy <j-keerthy@ti.com>, Sekhar Nori <nsekhar@ti.com>,
linux-omap@vger.kernel.org, netdev@vger.kernel.org,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH] net: ethernet: ti: cpsw: add check for in-band mode setting with RGMII PHY interface
Date: Thu, 15 Mar 2018 15:31:02 +0100 [thread overview]
Message-ID: <20180315143102.GA28577@lunn.ch> (raw)
In-Reply-To: <20180315064145.7022-1-sz.lin@moxa.com>
> @@ -1014,7 +1014,13 @@ static void _cpsw_adjust_link(struct cpsw_slave *slave,
> /* set speed_in input in case RMII mode is used in 100Mbps */
> if (phy->speed == 100)
> mac_control |= BIT(15);
> - else if (phy->speed == 10)
> +
> + /* in band mode only works in 10Mbps RGMII mode */
> + else if ((phy->speed == 10) &&
> + ((phy->interface == PHY_INTERFACE_MODE_RGMII) ||
> + (phy->interface == PHY_INTERFACE_MODE_RGMII_ID) ||
> + (phy->interface == PHY_INTERFACE_MODE_RGMII_RXID) ||
> + (phy->interface == PHY_INTERFACE_MODE_RGMII_TXID)))
Please use phy_interface_mode_is_rgmii()
Andrew
prev parent reply other threads:[~2018-03-15 14:31 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-03-15 6:41 [PATCH] net: ethernet: ti: cpsw: add check for in-band mode setting with RGMII PHY interface SZ Lin (林上智)
2018-03-15 6:41 ` SZ Lin (林上智)
2018-03-15 14:31 ` Andrew Lunn [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=20180315143102.GA28577@lunn.ch \
--to=andrew@lunn.ch \
--cc=davem@davemloft.net \
--cc=grygorii.strashko@ti.com \
--cc=ivan.khoronzhuk@linaro.org \
--cc=j-keerthy@ti.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-omap@vger.kernel.org \
--cc=netdev@vger.kernel.org \
--cc=nsekhar@ti.com \
--cc=spatton@ti.com \
--cc=sz.lin@moxa.com \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.