linux-acpi.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
To: Mark Brown <broonie@kernel.org>,
	linux-kernel@vger.kernel.org,
	Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
	"Rafael J. Wysocki" <rafael@kernel.org>,
	linux-acpi@vger.kernel.org, Marc Zyngier <marc.zyngier@arm.com>,
	Thomas Gleixner <tglx@linutronix.de>
Cc: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Subject: [PATCH v2 3/5] irqdomain: Replace open coded of_node_to_fwnode()
Date: Fri, 30 Oct 2020 18:59:17 +0200	[thread overview]
Message-ID: <20201030165919.86234-4-andriy.shevchenko@linux.intel.com> (raw)
In-Reply-To: <20201030165919.86234-1-andriy.shevchenko@linux.intel.com>

We can convert device node to fwnode with of_node_to_fwnode().
Replace open coded variant of it in of_phandle_args_to_fwspec().

Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
---
 kernel/irq/irqdomain.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/kernel/irq/irqdomain.c b/kernel/irq/irqdomain.c
index cf8b374b892d..831526f2e728 100644
--- a/kernel/irq/irqdomain.c
+++ b/kernel/irq/irqdomain.c
@@ -737,7 +737,7 @@ static void of_phandle_args_to_fwspec(struct device_node *np, const u32 *args,
 {
 	int i;
 
-	fwspec->fwnode = np ? &np->fwnode : NULL;
+	fwspec->fwnode = of_node_to_fwnode(np);
 	fwspec->param_count = count;
 
 	for (i = 0; i < count; i++)
-- 
2.28.0


  parent reply	other threads:[~2020-10-30 17:00 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-10-30 16:59 [PATCH v2 0/5] irqdomain: clean up, add irq_domain_create_legacy() Andy Shevchenko
2020-10-30 16:59 ` [PATCH v2 1/5] irqdomain: Remove unused of_device_id forward declaration Andy Shevchenko
2020-10-30 16:59 ` [PATCH v2 2/5] irqdomain: Add forward declaration of fwnode_handle Andy Shevchenko
2020-10-30 16:59 ` Andy Shevchenko [this message]
2020-10-30 16:59 ` [PATCH v2 4/5] irqdomain: Introduce irq_domain_create_legacy() API Andy Shevchenko
2020-10-30 16:59 ` [PATCH v2 5/5] regmap: irq: Convert to use fwnode directly Andy Shevchenko
2020-11-02 19:23 ` [PATCH v2 0/5] irqdomain: clean up, add irq_domain_create_legacy() 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=20201030165919.86234-4-andriy.shevchenko@linux.intel.com \
    --to=andriy.shevchenko@linux.intel.com \
    --cc=broonie@kernel.org \
    --cc=gregkh@linuxfoundation.org \
    --cc=linux-acpi@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=marc.zyngier@arm.com \
    --cc=rafael@kernel.org \
    --cc=tglx@linutronix.de \
    /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).