netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: David Miller <davem@davemloft.net>
To: marek.behun@nic.cz
Cc: netdev@vger.kernel.org, andrew@lunn.ch, vivien.didelot@gmail.com,
	hkallweit1@gmail.com
Subject: Re: [PATCH net-next v2] net: dsa: mv88e6xxx: check for mode change in port_setup_mac
Date: Fri, 16 Aug 2019 13:05:29 -0700 (PDT)	[thread overview]
Message-ID: <20190816.130529.1610341946658634132.davem@davemloft.net> (raw)
In-Reply-To: <20190814144024.27975-1-marek.behun@nic.cz>

From: Marek Behún <marek.behun@nic.cz>
Date: Wed, 14 Aug 2019 16:40:24 +0200

> The mv88e6xxx_port_setup_mac checks if the requested MAC settings are
> different from the current ones, and if not, does nothing (since chaning
> them requires putting the link down).
> 
> In this check it only looks if the triplet [link, speed, duplex] is
> being changed.
> 
> This patch adds support to also check if the mode parameter (of type
> phy_interface_t) is requested to be changed. The current mode is
> computed by the ->port_link_state() method, and if it is different from
> PHY_INTERFACE_MODE_NA, we check for equality with the requested mode.
> 
> In the implementations of the mv88e6250_port_link_state() method we set
> the current mode to PHY_INTERFACE_MODE_NA - so the code does not check
> for mode change on 6250.
> 
> In the mv88e6352_port_link_state() method, we use the cached cmode of
> the port to determine the mode as phy_interface_t (and if it is not
> enough, eg. for RGMII, we also look at the port control register for
> RX/TX timings).
> 
> Signed-off-by: Marek Behún <marek.behun@nic.cz>

Applied.

      parent reply	other threads:[~2019-08-16 20:05 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-08-14 14:40 [PATCH net-next v2] net: dsa: mv88e6xxx: check for mode change in port_setup_mac Marek Behún
2019-08-14 14:48 ` Andrew Lunn
2019-08-16 20:05 ` David Miller [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=20190816.130529.1610341946658634132.davem@davemloft.net \
    --to=davem@davemloft.net \
    --cc=andrew@lunn.ch \
    --cc=hkallweit1@gmail.com \
    --cc=marek.behun@nic.cz \
    --cc=netdev@vger.kernel.org \
    --cc=vivien.didelot@gmail.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 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).