From: Marek Behun <marek.behun@nic.cz>
To: Vivien Didelot <vivien.didelot@gmail.com>
Cc: netdev@vger.kernel.org, davem@davemloft.net,
f.fainelli@gmail.com, andrew@lunn.ch
Subject: Re: [PATCH net-next] net: dsa: mv88e6xxx: fix freeing unused SERDES IRQ
Date: Thu, 29 Aug 2019 06:51:24 +0200 [thread overview]
Message-ID: <20190829065124.1e234e7a@nic.cz> (raw)
In-Reply-To: <20190828185511.21956-1-vivien.didelot@gmail.com>
On Wed, 28 Aug 2019 14:55:11 -0400
Vivien Didelot <vivien.didelot@gmail.com> wrote:
> Now mv88e6xxx does not enable its ports at setup itself and let
> the DSA core handle this, unused ports are disabled without being
> powered on first. While that is expected, the SERDES powering code
> was assuming that a port was already set up before powering it down,
> resulting in freeing an unused IRQ. The patch fixes this assumption.
>
> Fixes: b759f528ca3d ("net: dsa: mv88e6xxx: enable SERDES after setup")
> Signed-off-by: Vivien Didelot <vivien.didelot@gmail.com>
> ---
> drivers/net/dsa/mv88e6xxx/chip.c | 3 ++-
> 1 file changed, 2 insertions(+), 1 deletion(-)
>
> diff --git a/drivers/net/dsa/mv88e6xxx/chip.c b/drivers/net/dsa/mv88e6xxx/chip.c
> index 6525075f6bd3..c648f9fbfa59 100644
> --- a/drivers/net/dsa/mv88e6xxx/chip.c
> +++ b/drivers/net/dsa/mv88e6xxx/chip.c
> @@ -2070,7 +2070,8 @@ static int mv88e6xxx_serdes_power(struct mv88e6xxx_chip *chip, int port,
> if (chip->info->ops->serdes_irq_setup)
> err = chip->info->ops->serdes_irq_setup(chip, port);
> } else {
> - if (chip->info->ops->serdes_irq_free)
> + if (chip->info->ops->serdes_irq_free &&
> + chip->ports[port].serdes_irq)
> chip->info->ops->serdes_irq_free(chip, port);
>
> err = chip->info->ops->serdes_power(chip, port, false);
Reviewed-by: Marek Behún <marek.behun@nic.cz>
next prev parent reply other threads:[~2019-08-29 4:51 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-08-28 18:55 [PATCH net-next] net: dsa: mv88e6xxx: fix freeing unused SERDES IRQ Vivien Didelot
2019-08-29 4:51 ` Marek Behun [this message]
2019-08-29 17:08 ` Andrew Lunn
2019-08-30 0:24 ` David Miller
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=20190829065124.1e234e7a@nic.cz \
--to=marek.behun@nic.cz \
--cc=andrew@lunn.ch \
--cc=davem@davemloft.net \
--cc=f.fainelli@gmail.com \
--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 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.