* [PATCH] net: ethernet: ixgbe: don't propagate -ENODEV from ixgbe_mii_bus_init()
@ 2020-09-28 7:17 Bartosz Golaszewski
2020-10-12 12:20 ` Bartosz Golaszewski
0 siblings, 1 reply; 4+ messages in thread
From: Bartosz Golaszewski @ 2020-09-28 7:17 UTC (permalink / raw)
To: Jeff Kirsher, David S . Miller, Jakub Kicinski
Cc: intel-wired-lan, netdev, linux-kernel, Bartosz Golaszewski,
Yongxin Liu
From: Bartosz Golaszewski <bgolaszewski@baylibre.com>
It's a valid use-case for ixgbe_mii_bus_init() to return -ENODEV - we
still want to finalize the registration of the ixgbe device. Check the
error code and don't bail out if err == -ENODEV.
This fixes an issue on C3000 family of SoCs where four ixgbe devices
share a single MDIO bus and ixgbe_mii_bus_init() returns -ENODEV for
three of them but we still want to register them.
Fixes: 09ef193fef7e ("net: ethernet: ixgbe: check the return value of ixgbe_mii_bus_init()")
Reported-by: Yongxin Liu <yongxin.liu@windriver.com>
Signed-off-by: Bartosz Golaszewski <bgolaszewski@baylibre.com>
---
drivers/net/ethernet/intel/ixgbe/ixgbe_main.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/net/ethernet/intel/ixgbe/ixgbe_main.c b/drivers/net/ethernet/intel/ixgbe/ixgbe_main.c
index 2f8a4cfc5fa1..d1623af30125 100644
--- a/drivers/net/ethernet/intel/ixgbe/ixgbe_main.c
+++ b/drivers/net/ethernet/intel/ixgbe/ixgbe_main.c
@@ -11032,7 +11032,7 @@ static int ixgbe_probe(struct pci_dev *pdev, const struct pci_device_id *ent)
true);
err = ixgbe_mii_bus_init(hw);
- if (err)
+ if (err && err != -ENODEV)
goto err_netdev;
return 0;
--
2.26.1
^ permalink raw reply related [flat|nested] 4+ messages in thread
* Re: [PATCH] net: ethernet: ixgbe: don't propagate -ENODEV from ixgbe_mii_bus_init()
2020-09-28 7:17 [PATCH] net: ethernet: ixgbe: don't propagate -ENODEV from ixgbe_mii_bus_init() Bartosz Golaszewski
@ 2020-10-12 12:20 ` Bartosz Golaszewski
2020-10-12 15:16 ` Jakub Kicinski
0 siblings, 1 reply; 4+ messages in thread
From: Bartosz Golaszewski @ 2020-10-12 12:20 UTC (permalink / raw)
To: Jeff Kirsher, Jakub Kicinski
Cc: intel-wired-lan, netdev, Linux Kernel Mailing List,
Bartosz Golaszewski, Yongxin Liu, David S . Miller
On Mon, Sep 28, 2020 at 9:17 AM Bartosz Golaszewski <brgl@bgdev.pl> wrote:
>
> From: Bartosz Golaszewski <bgolaszewski@baylibre.com>
>
> It's a valid use-case for ixgbe_mii_bus_init() to return -ENODEV - we
> still want to finalize the registration of the ixgbe device. Check the
> error code and don't bail out if err == -ENODEV.
>
> This fixes an issue on C3000 family of SoCs where four ixgbe devices
> share a single MDIO bus and ixgbe_mii_bus_init() returns -ENODEV for
> three of them but we still want to register them.
>
> Fixes: 09ef193fef7e ("net: ethernet: ixgbe: check the return value of ixgbe_mii_bus_init()")
> Reported-by: Yongxin Liu <yongxin.liu@windriver.com>
> Signed-off-by: Bartosz Golaszewski <bgolaszewski@baylibre.com>
> ---
> drivers/net/ethernet/intel/ixgbe/ixgbe_main.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/net/ethernet/intel/ixgbe/ixgbe_main.c b/drivers/net/ethernet/intel/ixgbe/ixgbe_main.c
> index 2f8a4cfc5fa1..d1623af30125 100644
> --- a/drivers/net/ethernet/intel/ixgbe/ixgbe_main.c
> +++ b/drivers/net/ethernet/intel/ixgbe/ixgbe_main.c
> @@ -11032,7 +11032,7 @@ static int ixgbe_probe(struct pci_dev *pdev, const struct pci_device_id *ent)
> true);
>
> err = ixgbe_mii_bus_init(hw);
> - if (err)
> + if (err && err != -ENODEV)
> goto err_netdev;
>
> return 0;
> --
> 2.26.1
>
Hi!
Gentle ping for this patch. Who's picking up networking patches now
that David is OoO? Should I Cc someone else?
Bartosz
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] net: ethernet: ixgbe: don't propagate -ENODEV from ixgbe_mii_bus_init()
2020-10-12 12:20 ` Bartosz Golaszewski
@ 2020-10-12 15:16 ` Jakub Kicinski
2020-10-12 16:26 ` [Intel-wired-lan] " Nguyen, Anthony L
0 siblings, 1 reply; 4+ messages in thread
From: Jakub Kicinski @ 2020-10-12 15:16 UTC (permalink / raw)
To: Bartosz Golaszewski, Tony Nguyen
Cc: Jeff Kirsher, intel-wired-lan, netdev, Linux Kernel Mailing List,
Bartosz Golaszewski, Yongxin Liu, David S . Miller
On Mon, 12 Oct 2020 14:20:16 +0200 Bartosz Golaszewski wrote:
> On Mon, Sep 28, 2020 at 9:17 AM Bartosz Golaszewski <brgl@bgdev.pl> wrote:
> >
> > From: Bartosz Golaszewski <bgolaszewski@baylibre.com>
> >
> > It's a valid use-case for ixgbe_mii_bus_init() to return -ENODEV - we
> > still want to finalize the registration of the ixgbe device. Check the
> > error code and don't bail out if err == -ENODEV.
> >
> > This fixes an issue on C3000 family of SoCs where four ixgbe devices
> > share a single MDIO bus and ixgbe_mii_bus_init() returns -ENODEV for
> > three of them but we still want to register them.
> >
> > Fixes: 09ef193fef7e ("net: ethernet: ixgbe: check the return value of ixgbe_mii_bus_init()")
> > Reported-by: Yongxin Liu <yongxin.liu@windriver.com>
> > Signed-off-by: Bartosz Golaszewski <bgolaszewski@baylibre.com>
> > ---
> > drivers/net/ethernet/intel/ixgbe/ixgbe_main.c | 2 +-
> > 1 file changed, 1 insertion(+), 1 deletion(-)
> >
> > diff --git a/drivers/net/ethernet/intel/ixgbe/ixgbe_main.c b/drivers/net/ethernet/intel/ixgbe/ixgbe_main.c
> > index 2f8a4cfc5fa1..d1623af30125 100644
> > --- a/drivers/net/ethernet/intel/ixgbe/ixgbe_main.c
> > +++ b/drivers/net/ethernet/intel/ixgbe/ixgbe_main.c
> > @@ -11032,7 +11032,7 @@ static int ixgbe_probe(struct pci_dev *pdev, const struct pci_device_id *ent)
> > true);
> >
> > err = ixgbe_mii_bus_init(hw);
> > - if (err)
> > + if (err && err != -ENODEV)
> > goto err_netdev;
> >
> > return 0;
>
> Gentle ping for this patch. Who's picking up networking patches now
> that David is OoO? Should I Cc someone else?
Intel went through a maintainer change of its own, and they usually
pick up their patches and send a PR.
Tony, do you want me to apply this directly?
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [Intel-wired-lan] [PATCH] net: ethernet: ixgbe: don't propagate -ENODEV from ixgbe_mii_bus_init()
2020-10-12 15:16 ` Jakub Kicinski
@ 2020-10-12 16:26 ` Nguyen, Anthony L
0 siblings, 0 replies; 4+ messages in thread
From: Nguyen, Anthony L @ 2020-10-12 16:26 UTC (permalink / raw)
To: kuba@kernel.org, brgl@bgdev.pl
Cc: netdev@vger.kernel.org, linux-kernel@vger.kernel.org,
intel-wired-lan@lists.osuosl.org, davem@davemloft.net,
yongxin.liu@windriver.com, bgolaszewski@baylibre.com
On Mon, 2020-10-12 at 08:16 -0700, Jakub Kicinski wrote:
> On Mon, 12 Oct 2020 14:20:16 +0200 Bartosz Golaszewski wrote:
> > On Mon, Sep 28, 2020 at 9:17 AM Bartosz Golaszewski <brgl@bgdev.pl>
> > wrote:
> > >
> > > From: Bartosz Golaszewski <bgolaszewski@baylibre.com>
> > >
> > > It's a valid use-case for ixgbe_mii_bus_init() to return -ENODEV
> > > - we
> > > still want to finalize the registration of the ixgbe device.
> > > Check the
> > > error code and don't bail out if err == -ENODEV.
> > >
> > > This fixes an issue on C3000 family of SoCs where four ixgbe
> > > devices
> > > share a single MDIO bus and ixgbe_mii_bus_init() returns -ENODEV
> > > for
> > > three of them but we still want to register them.
> > >
> > > Fixes: 09ef193fef7e ("net: ethernet: ixgbe: check the return
> > > value of ixgbe_mii_bus_init()")
> > > Reported-by: Yongxin Liu <yongxin.liu@windriver.com>
> > > Signed-off-by: Bartosz Golaszewski <bgolaszewski@baylibre.com>
> > > ---
> > > drivers/net/ethernet/intel/ixgbe/ixgbe_main.c | 2 +-
> > > 1 file changed, 1 insertion(+), 1 deletion(-)
> > >
> > > diff --git a/drivers/net/ethernet/intel/ixgbe/ixgbe_main.c
> > > b/drivers/net/ethernet/intel/ixgbe/ixgbe_main.c
> > > index 2f8a4cfc5fa1..d1623af30125 100644
> > > --- a/drivers/net/ethernet/intel/ixgbe/ixgbe_main.c
> > > +++ b/drivers/net/ethernet/intel/ixgbe/ixgbe_main.c
> > > @@ -11032,7 +11032,7 @@ static int ixgbe_probe(struct pci_dev
> > > *pdev, const struct pci_device_id *ent)
> > > true);
> > >
> > > err = ixgbe_mii_bus_init(hw);
> > > - if (err)
> > > + if (err && err != -ENODEV)
> > > goto err_netdev;
> > >
> > > return 0;
> >
> > Gentle ping for this patch. Who's picking up networking patches now
> > that David is OoO? Should I Cc someone else?
>
> Intel went through a maintainer change of its own, and they usually
> pick up their patches and send a PR.
>
> Tony, do you want me to apply this directly?
Hi Jakub,
I can take it. That way we can get some testing done on it.
Thanks,
Tony
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2020-10-12 16:26 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2020-09-28 7:17 [PATCH] net: ethernet: ixgbe: don't propagate -ENODEV from ixgbe_mii_bus_init() Bartosz Golaszewski
2020-10-12 12:20 ` Bartosz Golaszewski
2020-10-12 15:16 ` Jakub Kicinski
2020-10-12 16:26 ` [Intel-wired-lan] " Nguyen, Anthony L
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).