linux-clk.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Akshu Agrawal <akshu.agrawal@amd.com>
To: akshu.agrawal@amd.com
Cc: sboyd@kernel.org, rafael@kernel.org, rjw@rjwysocki.net,
	lenb@kernel.org, mturquette@baylibre.com,
	linux-acpi@vger.kernel.org, linux-kernel@vger.kernel.org,
	linux-clk@vger.kernel.org, rahul.tanwar@linux.intel.com
Subject: [3/4] ACPI: APD: Add a fmw property is_raven
Date: Fri, 31 Jul 2020 19:06:03 +0530	[thread overview]
Message-ID: <20200731133604.12512-4-akshu.agrawal@amd.com> (raw)
In-Reply-To: <20200731133604.12512-1-akshu.agrawal@amd.com>

Since there is slight difference in AMD RV based soc in misc
clk architecture. The fmw property will help in differentiating
the SoCs.

Signed-off-by: Akshu Agrawal <akshu.agrawal@amd.com>
---
 drivers/acpi/acpi_apd.c               | 4 ++++
 include/linux/platform_data/clk-fch.h | 1 +
 2 files changed, 5 insertions(+)

diff --git a/drivers/acpi/acpi_apd.c b/drivers/acpi/acpi_apd.c
index 2d99e46add1a..d879ba28826c 100644
--- a/drivers/acpi/acpi_apd.c
+++ b/drivers/acpi/acpi_apd.c
@@ -82,6 +82,7 @@ static int misc_check_res(struct acpi_resource *ares, void *data)
 static int fch_misc_setup(struct apd_private_data *pdata)
 {
 	struct acpi_device *adev = pdata->adev;
+	const union acpi_object *obj;
 	struct platform_device *clkdev;
 	struct fch_clk_data *clk_data;
 	struct resource_entry *rentry;
@@ -98,6 +99,9 @@ static int fch_misc_setup(struct apd_private_data *pdata)
 	if (ret < 0)
 		return -ENOENT;
 
+	acpi_dev_get_property(adev, "is-rv", ACPI_TYPE_INTEGER, &obj);
+	clk_data->is_rv = obj->integer.value;
+
 	list_for_each_entry(rentry, &resource_list, node) {
 		clk_data->base = devm_ioremap(&adev->dev, rentry->res->start,
 					      resource_size(rentry->res));
diff --git a/include/linux/platform_data/clk-fch.h b/include/linux/platform_data/clk-fch.h
index 850ca776156d..b9f682459f08 100644
--- a/include/linux/platform_data/clk-fch.h
+++ b/include/linux/platform_data/clk-fch.h
@@ -12,6 +12,7 @@
 
 struct fch_clk_data {
 	void __iomem *base;
+	u32 is_rv;
 };
 
 #endif /* __CLK_FCH_H */
-- 
2.20.1


  parent reply	other threads:[~2020-07-31 13:37 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-07-31 13:36 [0/4] Extend AMD SoC general purpose clk for all versions Akshu Agrawal
2020-07-31 13:36 ` [v2 1/4] ACPI: APD: Change name from ST to FCH Akshu Agrawal
2020-07-31 13:36 ` [v2 2/4] clk: x86: " Akshu Agrawal
2020-07-31 13:36 ` Akshu Agrawal [this message]
2020-07-31 13:36 ` [v3 4/4] clk: x86: Support RV architecture Akshu Agrawal
2020-08-07 18:17 ` [0/4] Extend AMD SoC general purpose clk for all versions Rafael J. Wysocki

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=20200731133604.12512-4-akshu.agrawal@amd.com \
    --to=akshu.agrawal@amd.com \
    --cc=lenb@kernel.org \
    --cc=linux-acpi@vger.kernel.org \
    --cc=linux-clk@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mturquette@baylibre.com \
    --cc=rafael@kernel.org \
    --cc=rahul.tanwar@linux.intel.com \
    --cc=rjw@rjwysocki.net \
    --cc=sboyd@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).