[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20201009081532.30411d62@kicinski-fedora-pc1c0hjn.dhcp.thefacebook.com>
Date: Fri, 9 Oct 2020 08:15:32 -0700
From: Jakub Kicinski <kuba@...nel.org>
To: Marek Vasut <marex@...x.de>
Cc: Florian Fainelli <f.fainelli@...il.com>, netdev@...r.kernel.org,
Christoph Niedermaier <cniedermaier@...electronics.com>,
"David S . Miller" <davem@...emloft.net>,
NXP Linux Team <linux-imx@....com>,
Richard Leitner <richard.leitner@...data.com>,
Shawn Guo <shawnguo@...nel.org>, Andrew Lunn <andrew@...n.ch>,
Heiner Kallweit <hkallweit1@...il.com>
Subject: Re: [PATCH] net: fec: Fix phy_device lookup for
phy_reset_after_clk_enable()
On Fri, 9 Oct 2020 09:20:30 +0200 Marek Vasut wrote:
> > Can you describe your problem in detail?
>
> Yes, I tried to do that in the commit message and the extra detailed
> comment above the code. What exactly do you not understand from that?
Why it's not bound on the first open (I'm guessing it's the first open
that has the ndev->phydev == NULL? I shouldn't have to guess).
> > To an untrained eye this looks pretty weird.
>
> I see, I'm not quite sure how to address this comment.
If ndev->phydev sometimes is not-NULL on open, then that's a valid
state to be in. Why not make sure that we're always in that state
and can depend on ndev->phydev rather than rummaging around for
the phy_device instance.
Powered by blists - more mailing lists