From: Priit Laes <plaes@plaes.org>
To: Maxime Ripard <mripard@kernel.org>, Chen-Yu Tsai <wens@csie.org>,
Rob Herring <robh+dt@kernel.org>,
linux-kernel@vger.kernel.org, linux-clk@vger.kernel.org,
linux-arm-kernel@lists.infradead.org, devicetree@vger.kernel.org,
linux-sunxi@googlegroups.com
Cc: Priit Laes <plaes@plaes.org>
Subject: [PATCH v2 0/6] ARM: sunxi: Clean up sun7i-a20-gmac-clk usage
Date: Thu, 30 Apr 2020 14:56:56 +0300 [thread overview]
Message-ID: <20200430115702.5768-1-plaes@plaes.org> (raw)
This serie implements syscon-based regmap access to dwmac-sunxi driver,
allowing to deprecate the allwinner,sun7i-a20-gmac-clk clock driver.
In order to register regmap, we firstly need to change existing clock
setups (sun7i-a20 and sun6i-a31) from CLK_OF_DECLARE to
CLK_OF_DECLARE_DRIVER to allow probing the same driver again via the
platform driver framework.
This patchset touches 3 areas:
- sun7i and sun6i CCUs now set up regmap to allow dwmac-sunxi driver
to access GMAC clock register.
- dwmac-sunxi can now handle syscon-based clock register to handle
its own clock.
- sun7i and sun6i devicetrees are converted to use the new syscon-based
access.
After this patchset:
- sun7i-a20 works fully without legacy sunxi clocks (CLK_SUNXI)
- only sun9i-a80 SoC remains as a single sun7i-a20-gmac-clk user.
Please note that sun6i-a31 changes are only build-tested, as I lack
the hardware to test this.
Changes since v2:
* Fix broken sun6i-a31 CCU patch.
* Rename series to "Clean up sun7i-a20-gmac-clk usage"
Changes since v1:
* Use CLK_OF_DECLARE_DRIVER to make it possible to probe again and set up
regmap using platform device probe.
* Clarify the meaning of "legacy" in dwmac-sunxi driver.
* Make sure we don't mess with the RX/TX delay settings when updating
clock registers.
* Update devicetree bindings
* Add sun6i-A31 support. (not tested due to lack of hardware)
Priit Laes (6):
clk: sunxi-ng: a20: Register regmap for sun7i CCU
clk: sunxi-ng: a31: Register regmap for sun6i CCU
net: stmmac: dwmac-sunxi: Implement syscon-based clock handling
dt-bindings: net: sun7i-gmac: Add syscon support
ARM: dts: sun7i: Use syscon-based implementation for gmac
ARM: dts: sun6i: Use syscon-based implementation for gmac
.../net/allwinner,sun7i-a20-gmac.yaml | 15 +-
arch/arm/boot/dts/sun6i-a31.dtsi | 35 +----
arch/arm/boot/dts/sun7i-a20.dtsi | 36 +----
drivers/clk/sunxi-ng/ccu-sun4i-a10.c | 62 ++++++++-
drivers/clk/sunxi-ng/ccu-sun6i-a31.c | 62 ++++++++-
.../net/ethernet/stmicro/stmmac/dwmac-sunxi.c | 130 ++++++++++++++++--
6 files changed, 261 insertions(+), 79 deletions(-)
--
2.26.2
next reply other threads:[~2020-04-30 11:57 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-04-30 11:56 Priit Laes [this message]
2020-04-30 11:56 ` [PATCH v3 1/6] clk: sunxi-ng: a20: Register regmap for sun7i CCU Priit Laes
2020-04-30 14:51 ` Maxime Ripard
2020-04-30 11:56 ` [PATCH v3 2/6] clk: sunxi-ng: a31: Register regmap for sun6i CCU Priit Laes
2020-04-30 11:56 ` [PATCH v3 3/6] net: stmmac: dwmac-sunxi: Implement syscon-based clock handling Priit Laes
2020-04-30 14:58 ` Maxime Ripard
2020-04-30 11:57 ` [PATCH v3 4/6] dt-bindings: net: sun7i-gmac: Add syscon support Priit Laes
2020-04-30 15:00 ` Maxime Ripard
2020-05-01 21:12 ` Rob Herring
2020-04-30 11:57 ` [PATCH v3 5/6] ARM: dts: sun7i: Use syscon-based implementation for gmac Priit Laes
2020-04-30 11:57 ` [PATCH v3 6/6] ARM: dts: sun6i: " Priit Laes
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=20200430115702.5768-1-plaes@plaes.org \
--to=plaes@plaes.org \
--cc=devicetree@vger.kernel.org \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-clk@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-sunxi@googlegroups.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