From: Corentin Labbe <clabbe.montjoie@gmail.com>
To: Andre Przywara <andre.przywara@arm.com>
Cc: Andrew Lunn <andrew+netdev@lunn.ch>,
"David S . Miller" <davem@davemloft.net>,
Eric Dumazet <edumazet@google.com>,
Jakub Kicinski <kuba@kernel.org>, Paolo Abeni <pabeni@redhat.com>,
Chen-Yu Tsai <wens@csie.org>,
Jernej Skrabec <jernej.skrabec@gmail.com>,
Samuel Holland <samuel@sholland.org>, Yixun Lan <dlan@gentoo.org>,
Maxime Ripard <mripard@kernel.org>,
netdev@vger.kernel.org, linux-sunxi@lists.linux.dev,
linux-kernel@vger.kernel.org
Subject: Re: [RFC PATCH net-next] net: stmmac: sun8i: drop unneeded default syscon value
Date: Wed, 23 Apr 2025 12:06:46 +0200 [thread overview]
Message-ID: <aAi7tq-otdhJRpTy@Red> (raw)
In-Reply-To: <20250423095222.1517507-1-andre.przywara@arm.com>
Le Wed, Apr 23, 2025 at 10:52:22AM +0100, Andre Przywara a écrit :
> For some odd reason we are very picky about the value of the EMAC clock
> register from the syscon block, insisting on a certain reset value and
> only doing read-modify-write operations on that register, even though we
> pretty much know the register layout.
> This already led to a basically redundant variant entry for the H6, which
> only differs by that value. We will have the same situation with the new
> A523 SoC, which again is compatible to the A64, but has a different syscon
> reset value.
>
> Drop any assumptions about that value, and set or clear the bits that we
> want to program, from scratch (starting with a value of 0). For the
> remove() implementation, we just turn on the POWERDOWN bit, and deselect
> the internal PHY, which mimics the existing code.
>
> Signed-off-by: Andre Przywara <andre.przywara@arm.com>
> ---
> Hi,
>
> if anyone can shed some light on why we had this value and its handling
> in the first place, I would be grateful. I don't really get its purpose,
> and especially the warning message about the reset value seems odd.
> I briefly tested this on A523, H3, H6, but would be glad to see more
> testing on this.
>
Hello
The origin is me, when doing initial sun8i-emac I feared to miss something and so added some strict tests on its value.
Another goal was to detect half init from firmware/bootloader.
But I agree it is now useless.
I will send this patch on all my CI boards, so you will have extra test.
Acked-by: Corentin LABBE <clabbe.montjoie@gmail.com>
Thanks
Regards
next prev parent reply other threads:[~2025-04-23 10:06 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-04-23 9:52 [RFC PATCH net-next] net: stmmac: sun8i: drop unneeded default syscon value Andre Przywara
2025-04-23 10:06 ` Corentin Labbe [this message]
2025-04-24 18:39 ` Jernej Škrabec
2025-04-24 18:46 ` Corentin Labbe
2025-06-27 16:08 ` Paul Kocialkowski
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=aAi7tq-otdhJRpTy@Red \
--to=clabbe.montjoie@gmail.com \
--cc=andre.przywara@arm.com \
--cc=andrew+netdev@lunn.ch \
--cc=davem@davemloft.net \
--cc=dlan@gentoo.org \
--cc=edumazet@google.com \
--cc=jernej.skrabec@gmail.com \
--cc=kuba@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-sunxi@lists.linux.dev \
--cc=mripard@kernel.org \
--cc=netdev@vger.kernel.org \
--cc=pabeni@redhat.com \
--cc=samuel@sholland.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).