From: "Ondřej Jirman" <megous@megous.com>
To: Maxime Ripard <mripard@kernel.org>
Cc: mark.rutland@arm.com, devicetree@vger.kernel.org,
Jernej Skrabec <jernej.skrabec@siol.net>,
linux-sunxi@googlegroups.com, linux-kernel@vger.kernel.org,
wens@csie.org, robh+dt@kernel.org,
linux-arm-kernel@lists.infradead.org
Subject: Re: [PATCH] arm64: dts: allwinner: a64: pine64-plus: Add PHY regulator delay
Date: Tue, 27 Aug 2019 15:48:06 +0200 [thread overview]
Message-ID: <20190827134806.5l7dxyvzjrvabh7o@core.my.home> (raw)
In-Reply-To: <20190827133443.fdxl5wjmgkerc3uh@flea>
Hi,
On Tue, Aug 27, 2019 at 03:34:43PM +0200, Maxime Ripard wrote:
> On Sun, Aug 25, 2019 at 03:03:36PM +0200, Jernej Skrabec wrote:
> > Depending on kernel and bootloader configuration, it's possible that
> > Realtek ethernet PHY isn't powered on properly. It needs some time
> > before it can be used.
> >
> > Fix that by adding 100ms ramp delay to regulator responsible for
> > powering PHY.
> >
> > Fixes: 94dcfdc77fc5 ("arm64: allwinner: pine64-plus: Enable dwmac-sun8i")
> > Suggested-by: Ondrej Jirman <megous@megous.com>
> > Signed-off-by: Jernej Skrabec <jernej.skrabec@siol.net>
>
> How was that delay found?
I suggested it. There's no delay in the dwmac-sun8i driver, so after enabling
the phy power, it will start accessing it over MDIO right away, which is not
good.
I suggested the value based on post-reset delay in the PHY's datasheet (30ms).
Multiplied ~3x (if I remember correctly) to get some safety margin. Chip has
more to do then after the HW reset, and regulator also needs some time to
ramp-up.
regards,
o.
> It should at least have a comment explaining why it's there.
>
> Thanks!
> Maxime
>
> --
> Maxime Ripard, Bootlin
> Embedded Linux and Kernel engineering
> https://bootlin.com
_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
next prev parent reply other threads:[~2019-08-27 13:49 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-08-25 13:03 [PATCH] arm64: dts: allwinner: a64: pine64-plus: Add PHY regulator delay Jernej Skrabec
2019-08-27 13:34 ` Maxime Ripard
2019-08-27 13:48 ` Ondřej Jirman [this message]
2019-09-02 11:38 ` Maxime Ripard
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=20190827134806.5l7dxyvzjrvabh7o@core.my.home \
--to=megous@megous.com \
--cc=devicetree@vger.kernel.org \
--cc=jernej.skrabec@siol.net \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-sunxi@googlegroups.com \
--cc=mark.rutland@arm.com \
--cc=mripard@kernel.org \
--cc=robh+dt@kernel.org \
--cc=wens@csie.org \
/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).