From: Thierry Reding <thierry.reding@gmail.com>
To: Thierry Reding <thierry.reding@gmail.com>
Cc: linux-tegra@vger.kernel.org,
linux-arm-kernel@lists.infradead.org,
Jon Hunter <jonathanh@nvidia.com>
Subject: [PATCH v2 12/14] soc/tegra: pmc: Add Tegra234 support
Date: Thu, 17 Sep 2020 12:07:50 +0200 [thread overview]
Message-ID: <20200917100752.3516153-13-thierry.reding@gmail.com> (raw)
In-Reply-To: <20200917100752.3516153-1-thierry.reding@gmail.com>
From: Thierry Reding <treding@nvidia.com>
The PMC block is largely similar to that found on earlier chips, but
not completely compatible. Allow binding to the instantiation found on
Tegra234.
Signed-off-by: Thierry Reding <treding@nvidia.com>
---
drivers/soc/tegra/pmc.c | 67 +++++++++++++++++++++++++++++++++++++++++
1 file changed, 67 insertions(+)
diff --git a/drivers/soc/tegra/pmc.c b/drivers/soc/tegra/pmc.c
index 4071181a4a42..622496df6282 100644
--- a/drivers/soc/tegra/pmc.c
+++ b/drivers/soc/tegra/pmc.c
@@ -3362,6 +3362,73 @@ static const struct tegra_pmc_soc tegra194_pmc_soc = {
.has_blink_output = false,
};
+static const struct tegra_pmc_regs tegra234_pmc_regs = {
+ .scratch0 = 0x2000,
+ .dpd_req = 0,
+ .dpd_status = 0,
+ .dpd2_req = 0,
+ .dpd2_status = 0,
+ .rst_status = 0x70,
+ .rst_source_shift = 0x2,
+ .rst_source_mask = 0xfc,
+ .rst_level_shift = 0x0,
+ .rst_level_mask = 0x3,
+};
+
+static const char * const tegra234_reset_sources[] = {
+ "SYS_RESET_N",
+ "AOWDT",
+ "BCCPLEXWDT",
+ "BPMPWDT",
+ "SCEWDT",
+ "SPEWDT",
+ "APEWDT",
+ "LCCPLEXWDT",
+ "SENSOR",
+ "AOTAG",
+ "VFSENSOR",
+ "MAINSWRST",
+ "SC7",
+ "HSM",
+ "CSITE",
+ "RCEWDT",
+ "PVA0WDT",
+ "PVA1WDT",
+ "L1A_ASYNC",
+ "BPMPBOOT",
+ "FUSECRC",
+};
+
+static const struct tegra_pmc_soc tegra234_pmc_soc = {
+ .num_powergates = 0,
+ .powergates = NULL,
+ .num_cpu_powergates = 0,
+ .cpu_powergates = NULL,
+ .has_tsense_reset = false,
+ .has_gpu_clamps = false,
+ .needs_mbist_war = false,
+ .has_impl_33v_pwr = true,
+ .maybe_tz_only = false,
+ .num_io_pads = 0,
+ .io_pads = NULL,
+ .num_pin_descs = 0,
+ .pin_descs = NULL,
+ .regs = &tegra234_pmc_regs,
+ .init = NULL,
+ .setup_irq_polarity = tegra186_pmc_setup_irq_polarity,
+ .irq_set_wake = tegra186_pmc_irq_set_wake,
+ .irq_set_type = tegra186_pmc_irq_set_type,
+ .reset_sources = tegra194_reset_sources,
+ .num_reset_sources = ARRAY_SIZE(tegra194_reset_sources),
+ .reset_levels = tegra186_reset_levels,
+ .num_reset_levels = ARRAY_SIZE(tegra186_reset_levels),
+ .num_wake_events = 0,
+ .wake_events = NULL,
+ .pmc_clks_data = NULL,
+ .num_pmc_clks = 0,
+ .has_blink_output = false,
+};
+
static const struct of_device_id tegra_pmc_match[] = {
{ .compatible = "nvidia,tegra194-pmc", .data = &tegra194_pmc_soc },
{ .compatible = "nvidia,tegra186-pmc", .data = &tegra186_pmc_soc },
--
2.28.0
_______________________________________________
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:[~2020-09-17 10:12 UTC|newest]
Thread overview: 17+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-09-17 10:07 [PATCH v2 00/14] arm64: tegra: Initial Tegra234 VDK support Thierry Reding
2020-09-17 10:07 ` [PATCH v2 01/14] dt-bindings: misc: tegra-apbmisc: Add missing compatible strings Thierry Reding
2020-09-17 10:07 ` [PATCH v2 02/14] dt-bindings: misc: tegra186-misc: Add missing compatible string Thierry Reding
2020-09-17 10:07 ` [PATCH v2 03/14] dt-bindings: misc: tegra186-misc: Add Tegra234 support Thierry Reding
2020-09-17 10:07 ` [PATCH v2 04/14] dt-bindings: tegra: Add Tegra234 VDK compatible Thierry Reding
2020-09-17 10:07 ` [PATCH v2 05/14] dt-bindings: fuse: tegra: Add Tegra234 support Thierry Reding
2020-09-17 10:07 ` [PATCH v2 06/14] dt-bindings: tegra: pmc: " Thierry Reding
2020-09-17 10:07 ` [PATCH v2 07/14] soc/tegra: fuse: Extract tegra_get_platform() Thierry Reding
2020-09-17 10:07 ` [PATCH v2 08/14] soc/tegra: fuse: Implement tegra_is_silicon() Thierry Reding
2020-09-17 10:07 ` [PATCH v2 09/14] soc/tegra: fuse: Add Tegra234 support Thierry Reding
2020-09-17 10:07 ` [PATCH v2 10/14] soc/tegra: misc: " Thierry Reding
2020-09-17 10:07 ` [PATCH v2 11/14] soc/tegra: pmc: Reorder reset sources/levels definitions Thierry Reding
2020-09-17 10:07 ` Thierry Reding [this message]
2020-09-17 10:07 ` [PATCH v2 13/14] firmware: tegra: Enable BPMP support on Tegra234 Thierry Reding
2020-09-17 10:07 ` [PATCH v2 14/14] arm64: tegra: Initial Tegra234 VDK support Thierry Reding
2020-09-24 10:32 ` Mikko Perttunen
2020-09-18 12:54 ` [PATCH v2 00/14] " Jon Hunter
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=20200917100752.3516153-13-thierry.reding@gmail.com \
--to=thierry.reding@gmail.com \
--cc=jonathanh@nvidia.com \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-tegra@vger.kernel.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).