netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Sergei Shtylyov <sergei.shtylyov@cogentembedded.com>
To: Murali Karicheri <m-karicheri2@ti.com>
Cc: netdev@vger.kernel.org, davem@davemloft.net,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH] net: netcp: remove call to netif_carrier_(on/off) for MAC to Phy interface
Date: Fri, 24 Apr 2015 19:41:30 +0300	[thread overview]
Message-ID: <553A723A.8090700@cogentembedded.com> (raw)
In-Reply-To: <553A5EA8.4010908@ti.com>

On 04/24/2015 06:18 PM, Murali Karicheri wrote:

>>> Currently when interface type is MAC to Phy, netif_carrier_(on/off)
>>> is called which is not needed as Phy lib already updates the carrier
>>> status to net stack. This is needed only for other interface types

>>> Signed-off-by: Murali Karicheri <m-karicheri2@ti.com>
>>> ---
>>>   drivers/net/ethernet/ti/netcp_ethss.c |    8 ++++++--
>>>   1 file changed, 6 insertions(+), 2 deletions(-)

>>> diff --git a/drivers/net/ethernet/ti/netcp_ethss.c
>>> b/drivers/net/ethernet/ti/netcp_ethss.c
>>> index 2bef655..0a1ef2e 100644
>>> --- a/drivers/net/ethernet/ti/netcp_ethss.c
>>> +++ b/drivers/net/ethernet/ti/netcp_ethss.c
>>> @@ -1765,7 +1765,9 @@ static void netcp_ethss_link_state_action(struct
>>> gbe_priv *gbe_dev,
>>>                        ALE_PORT_STATE,
>>>                        ALE_PORT_STATE_FORWARD);
>>>
>>> -        if (ndev && slave->open)
>>> +        if (ndev && slave->open &&
>>> +            ((slave->link_interface != SGMII_LINK_MAC_PHY) &&
>>> +            (slave->link_interface != XGMII_LINK_MAC_PHY)))

>>    You don't need extra parens around &&.

> You are right! I will fix it up and re-send.

    In fact, you don't need parens around != either.

> Mruali

[...]

WBR, Sergei

      reply	other threads:[~2015-04-24 16:41 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-04-23 19:17 [PATCH] net: netcp: remove call to netif_carrier_(on/off) for MAC to Phy interface Murali Karicheri
2015-04-24  5:55 ` Mugunthan V N
2015-04-24 13:33 ` Sergei Shtylyov
2015-04-24 15:18   ` Murali Karicheri
2015-04-24 16:41     ` Sergei Shtylyov [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=553A723A.8090700@cogentembedded.com \
    --to=sergei.shtylyov@cogentembedded.com \
    --cc=davem@davemloft.net \
    --cc=linux-kernel@vger.kernel.org \
    --cc=m-karicheri2@ti.com \
    --cc=netdev@vger.kernel.org \
    /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).