From: Zev Weiss <zev@bewilderbeest.net>
To: Joel Stanley <joel@jms.id.au>
Cc: "Andrew Jeffery" <andrew@aj.id.au>,
"OpenBMC Maillist" <openbmc@lists.ozlabs.org>,
"Ryan Chen" <ryan_chen@aspeedtech.com>,
"Cédric Le Goater" <clg@kaod.org>
Subject: Re: [PATCH] ftgmac100: use bus name in mdio error messages
Date: Tue, 17 May 2022 02:28:17 -0700 [thread overview]
Message-ID: <YoNqse+81EdwcguP@hatter.bewilderbeest.net> (raw)
In-Reply-To: <CACPK8Xca-07ZnYjCUmxEA3H-WQLohD-JYVEp+hM+XaHPNGfmUQ@mail.gmail.com>
On Mon, May 16, 2022 at 09:54:35PM PDT, Joel Stanley wrote:
> On Tue, 17 May 2022 at 04:51, Zev Weiss <zev@bewilderbeest.net> wrote:
> >
> > On Mon, May 16, 2022 at 09:38:25PM PDT, Zev Weiss wrote:
> > > Previously we'd been using a device name retrieved via
> > > ftgmac100_data->phydev, but the mdio read/write functions may be
> > > called before that member is initialized in ftgmac100_phy_init(),
> > > leading to a NULL pointer dereference while printing the error message
> > > issued if the mdio access fails. We can instead use bus->name, which
> > > is already available at that point.
> > >
> > > Signed-off-by: Zev Weiss <zev@bewilderbeest.net>
> > > Fixes: 538e75d3fc54 ("net: ftgmac100: add MDIO bus and phylib support")
> > > ---
> > > drivers/net/ftgmac100.c | 4 ++--
> > > 1 file changed, 2 insertions(+), 2 deletions(-)
> > >
> >
> > Sorry, forgot the subject-prefix tag on this one -- this is for u-boot
> > v2019.04-aspeed-openbmc in case it wasn't clear.
>
> Thanks, I figured that out :)
>
> How do you reproduce this one?
>
I'm in the process of trying to transition e3c246d4i off of the 2016
branch, and with the 2019 branch I'm finding u-boot spewing a bunch of
output like
: mdio read failed (phy:0 reg:2)
: mdio read failed (phy:1 reg:2)
: mdio read failed (phy:2 reg:2)
...
(sometimes with some amount of garbage before the colon at the start of
the line, and with "eth1" instead after this patch.)
I'm currently experimenting with various Kconfig settings and dts tweaks
(on two different variants of the hardware) to try to narrow down the
underlying cause and hopefully eliminate the error spew entirely, but in
the meantime I figured we might as well get that error-reporting path
smoothed out a bit.
> I didn't realise we had downstream changes for this driver, we should
> ask aspeed to submit their downstream changes to u-boot mainline.
That sounds appropriate -- though as Cédric pointed out, since the
relevant parts for this particular patch are already in mainline u-boot
I should probably send this upstream as well.
next prev parent reply other threads:[~2022-05-17 9:29 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-05-17 4:38 [PATCH] ftgmac100: use bus name in mdio error messages Zev Weiss
2022-05-17 4:51 ` Zev Weiss
2022-05-17 4:54 ` Joel Stanley
2022-05-17 9:28 ` Zev Weiss [this message]
2022-05-17 9:31 ` Joel Stanley
2022-05-17 5:44 ` Cédric Le Goater
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=YoNqse+81EdwcguP@hatter.bewilderbeest.net \
--to=zev@bewilderbeest.net \
--cc=andrew@aj.id.au \
--cc=clg@kaod.org \
--cc=joel@jms.id.au \
--cc=openbmc@lists.ozlabs.org \
--cc=ryan_chen@aspeedtech.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.