linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Andrew Lunn <andrew@lunn.ch>
To: Roger Quadros <rogerq@ti.com>
Cc: f.fainelli@gmail.com, davem@davemloft.net, kyle.roeschley@ni.com,
	netdev@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [RFC PATCH] net: phy: Don't miss phy_suspend() on PHY_HALTED for PHYs with interrupts
Date: Wed, 15 Mar 2017 15:08:11 +0100	[thread overview]
Message-ID: <20170315140811.GD21021@lunn.ch> (raw)
In-Reply-To: <1489585887-8683-1-git-send-email-rogerq@ti.com>

On Wed, Mar 15, 2017 at 03:51:27PM +0200, Roger Quadros wrote:
> Since commit 3c293f4e08b5 ("net: phy: Trigger state machine on state change and not polling.")
> phy_suspend() doesn't get called as part of phy_stop() for PHYs using
> interrupts because the phy state machine is never triggered after a phy_stop().
> 
> Explicitly trigger the PHY state machine so that it can
> see the new PHY state (HALTED) and suspend the PHY.
> 
> Signed-off-by: Roger Quadros <rogerq@ti.com>

Hi Roger

This seems sensible. It mirrors what phy_start() does.

Reviewed-by: Andrew Lunn <andrew@lunn.ch>

It does however lead to a follow up question. Are there other places
phydev->state is changed and it is missing a phy_trigger_machine()?

	      Andrew

  reply	other threads:[~2017-03-15 14:09 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-03-15 13:51 [RFC PATCH] net: phy: Don't miss phy_suspend() on PHY_HALTED for PHYs with interrupts Roger Quadros
2017-03-15 14:08 ` Andrew Lunn [this message]
2017-03-15 15:00   ` Roger Quadros
2017-03-15 15:49     ` Andrew Lunn
2017-03-16  7:46       ` Roger Quadros
2017-03-20 16:41         ` Florian Fainelli
2017-03-21 10:09           ` Roger Quadros
2017-03-21 16:00             ` Florian Fainelli
2017-03-20 16:42     ` Florian Fainelli

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=20170315140811.GD21021@lunn.ch \
    --to=andrew@lunn.ch \
    --cc=davem@davemloft.net \
    --cc=f.fainelli@gmail.com \
    --cc=kyle.roeschley@ni.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=netdev@vger.kernel.org \
    --cc=rogerq@ti.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).