All of lore.kernel.org
 help / color / mirror / Atom feed
From: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
To: Mika Westerberg <mika.westerberg@linux.intel.com>,
	linux-gpio@vger.kernel.org,
	Linus Walleij <linus.walleij@linaro.org>
Cc: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Subject: [PATCH v1 2/2] pinctrl: baytrail: Group GPIO IRQ chip initialization
Date: Thu, 24 Oct 2019 17:33:43 +0300	[thread overview]
Message-ID: <20191024143343.17638-2-andriy.shevchenko@linux.intel.com> (raw)
In-Reply-To: <20191024143343.17638-1-andriy.shevchenko@linux.intel.com>

After commit aee0f04d5f3b ("pinctrl: intel: baytrail: Pass irqchip
when adding gpiochip") the GPIO IRQ chip structure is being initialized under
conditional when IRQ resource has been discovered. But that commit left aside
the assignment of ->init_valid_mask() callback that is done unconditionally.

For sake of consistency and preventing some garbage in GPIO IRQ chip structure
group initialization together.

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

diff --git a/drivers/pinctrl/intel/pinctrl-baytrail.c b/drivers/pinctrl/intel/pinctrl-baytrail.c
index 9d0e32dbf970..beb26550c25f 100644
--- a/drivers/pinctrl/intel/pinctrl-baytrail.c
+++ b/drivers/pinctrl/intel/pinctrl-baytrail.c
@@ -1513,7 +1513,6 @@ static int byt_gpio_probe(struct byt_gpio *vg)
 	gc->can_sleep	= false;
 	gc->parent	= &vg->pdev->dev;
 	gc->ngpio	= vg->soc_data->npins;
-	gc->irq.init_valid_mask	= byt_init_irq_valid_mask;
 
 #ifdef CONFIG_PM_SLEEP
 	vg->saved_context = devm_kcalloc(&vg->pdev->dev, gc->ngpio,
@@ -1537,6 +1536,7 @@ static int byt_gpio_probe(struct byt_gpio *vg)
 		girq = &gc->irq;
 		girq->chip = &vg->irqchip;
 		girq->init_hw = byt_gpio_irq_init_hw;
+		girq->init_valid_mask = byt_init_irq_valid_mask;
 		girq->parent_handler = byt_gpio_irq_handler;
 		girq->num_parents = 1;
 		girq->parents = devm_kcalloc(&vg->pdev->dev, 1,
-- 
2.23.0


  reply	other threads:[~2019-10-24 14:33 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-10-24 14:33 [PATCH v1 1/2] pinctrl: baytrail: Allocate IRQ chip dynamic Andy Shevchenko
2019-10-24 14:33 ` Andy Shevchenko [this message]
2019-10-25 10:02   ` [PATCH v1 2/2] pinctrl: baytrail: Group GPIO IRQ chip initialization Mika Westerberg
2019-10-25 10:02 ` [PATCH v1 1/2] pinctrl: baytrail: Allocate IRQ chip dynamic Mika Westerberg

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=20191024143343.17638-2-andriy.shevchenko@linux.intel.com \
    --to=andriy.shevchenko@linux.intel.com \
    --cc=linus.walleij@linaro.org \
    --cc=linux-gpio@vger.kernel.org \
    --cc=mika.westerberg@linux.intel.com \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.