From: guohanjun@huawei.com (Hanjun Guo)
To: linux-arm-kernel@lists.infradead.org
Subject: [RFC PATCH 06/10] msi: platform: make platform_msi_create_device_domain() ACPI aware
Date: Tue, 9 Aug 2016 15:06:02 +0800 [thread overview]
Message-ID: <1470726366-40809-7-git-send-email-guohanjun@huawei.com> (raw)
In-Reply-To: <1470726366-40809-1-git-send-email-guohanjun@huawei.com>
From: Hanjun Guo <hanjun.guo@linaro.org>
With the platform msi domain created for ITS, irqchip such as
mbi-gen connecting ITS, which needs ctreate its own irqdomain.
Fortunately with the platform msi support upstreamed by Marc,
we just need to add minor code to make it run properly.
platform_msi_create_device_domain() is almost ready for ACPI use
except of_node_to_fwnode() is for dt only, make it ACPI aware then
things will work in both DTS and ACPI.
Signed-off-by: Hanjun Guo <hanjun.guo@linaro.org>
---
drivers/base/platform-msi.c | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/drivers/base/platform-msi.c b/drivers/base/platform-msi.c
index d8b28d3..5603756 100644
--- a/drivers/base/platform-msi.c
+++ b/drivers/base/platform-msi.c
@@ -339,16 +339,17 @@ platform_msi_create_device_domain(struct device *dev,
{
struct platform_msi_priv_data *data;
struct irq_domain *domain;
+ struct fwnode_handle *fwnode;
int err;
data = platform_msi_alloc_priv_data(dev, nvec, write_msi_msg);
if (IS_ERR(data))
return NULL;
+ fwnode = dev->of_node ? &dev->of_node->fwnode : dev->fwnode;
data->host_data = host_data;
domain = irq_domain_create_hierarchy(dev->msi_domain, 0, nvec,
- of_node_to_fwnode(dev->of_node),
- ops, data);
+ fwnode, ops, data);
if (!domain)
goto free_priv;
--
1.7.12.4
next prev parent reply other threads:[~2016-08-09 7:06 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-08-09 7:05 [RFC PATCH 00/10] ACPI platform MSI, interrupt producer and its example mbi-gen Hanjun Guo
2016-08-09 7:05 ` [RFC PATCH 01/10] irqchip: gicv3-its: platform-msi: refactor its_pmsi_prepare() Hanjun Guo
2016-08-09 7:05 ` [RFC PATCH 02/10] ACPI: platform-msi: retrieve dev id from IORT Hanjun Guo
2016-08-09 7:05 ` [RFC PATCH 03/10] irqchip: gicv3-its: platform-msi: refactor its_pmsi_init() to prepare for ACPI Hanjun Guo
2016-08-09 7:06 ` [RFC PATCH 04/10] irqchip: gicv3-its: platform-msi: scan MADT to create platform msi domain Hanjun Guo
2016-08-09 7:06 ` [RFC PATCH 05/10] ACPI: platform: setup MSI domain for ACPI based platform device Hanjun Guo
2016-08-09 7:06 ` Hanjun Guo [this message]
2016-08-09 7:06 ` [RFC PATCH 07/10] ACPI: irq: introduce interrupt producer Hanjun Guo
2016-08-09 7:06 ` [RFC PATCH 08/10] irqchip: mbigen: drop module owner Hanjun Guo
2016-08-09 7:06 ` [RFC PATCH 09/10] irqchip: mbigen: introduce mbigen_of_create_domain() Hanjun Guo
2016-08-09 7:06 ` [RFC PATCH 10/10] irqchip: mbigen: Add ACPI support Hanjun Guo
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=1470726366-40809-7-git-send-email-guohanjun@huawei.com \
--to=guohanjun@huawei.com \
--cc=linux-arm-kernel@lists.infradead.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).