linux-gpio.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
To: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>,
	Andy Shevchenko <andriy.shevchenko@linux.intel.com>,
	Alexander Stein <alexander.stein@ew.tq-group.com>,
	linux-kernel@vger.kernel.org, linux-gpio@vger.kernel.org
Cc: Linus Walleij <linus.walleij@linaro.org>,
	Bartosz Golaszewski <brgl@bgdev.pl>,
	Andy Shevchenko <andy@kernel.org>,
	Geert Uytterhoeven <geert+renesas@glider.be>
Subject: [PATCH v2 1/4] gpio: aggregator: Remove CONFIG_OF and of_match_ptr() protections
Date: Thu, 15 Jun 2023 02:14:43 +0300	[thread overview]
Message-ID: <20230614231446.3687-2-andriy.shevchenko@linux.intel.com> (raw)
In-Reply-To: <20230614231446.3687-1-andriy.shevchenko@linux.intel.com>

They stop the driver being used with ACPI PRP0001 and are something
I want to avoid being cut and paste into new drivers. Also include
mod_devicetable.h as we struct of_device_id is defined in there.

Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
---
 drivers/gpio/gpio-aggregator.c | 7 +++----
 1 file changed, 3 insertions(+), 4 deletions(-)

diff --git a/drivers/gpio/gpio-aggregator.c b/drivers/gpio/gpio-aggregator.c
index 20a686f12df7..1aa7455672d3 100644
--- a/drivers/gpio/gpio-aggregator.c
+++ b/drivers/gpio/gpio-aggregator.c
@@ -12,6 +12,7 @@
 #include <linux/ctype.h>
 #include <linux/idr.h>
 #include <linux/kernel.h>
+#include <linux/mod_devicetable.h>
 #include <linux/module.h>
 #include <linux/mutex.h>
 #include <linux/overflow.h>
@@ -500,23 +501,21 @@ static int gpio_aggregator_probe(struct platform_device *pdev)
 	return 0;
 }
 
-#ifdef CONFIG_OF
 static const struct of_device_id gpio_aggregator_dt_ids[] = {
 	/*
 	 * Add GPIO-operated devices controlled from userspace below,
-	 * or use "driver_override" in sysfs
+	 * or use "driver_override" in sysfs.
 	 */
 	{}
 };
 MODULE_DEVICE_TABLE(of, gpio_aggregator_dt_ids);
-#endif
 
 static struct platform_driver gpio_aggregator_driver = {
 	.probe = gpio_aggregator_probe,
 	.driver = {
 		.name = DRV_NAME,
 		.groups = gpio_aggregator_groups,
-		.of_match_table = of_match_ptr(gpio_aggregator_dt_ids),
+		.of_match_table = gpio_aggregator_dt_ids,
 	},
 };
 
-- 
2.40.0.1.gaa8946217a0b


  reply	other threads:[~2023-06-14 23:18 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-06-14 23:14 [PATCH v2 0/4] gpio: aggregator: Incorporate gpio-delay functionality Andy Shevchenko
2023-06-14 23:14 ` Andy Shevchenko [this message]
2023-06-15  6:34   ` [PATCH v2 1/4] gpio: aggregator: Remove CONFIG_OF and of_match_ptr() protections Linus Walleij
2023-06-15  7:28   ` Geert Uytterhoeven
2023-06-14 23:14 ` [PATCH v2 2/4] gpio: aggregator: Support delay for setting up individual GPIOs Andy Shevchenko
2023-06-15  6:35   ` Linus Walleij
2023-06-15  7:42   ` Geert Uytterhoeven
2023-06-14 23:14 ` [PATCH v2 3/4] gpio: aggregator: Set up a parser of delay line parameters Andy Shevchenko
2023-06-15  6:37   ` Linus Walleij
2023-06-15  8:52     ` Andy Shevchenko
2023-06-15  7:48   ` Geert Uytterhoeven
2023-06-15  9:07     ` Andy Shevchenko
2023-06-14 23:14 ` [PATCH v2 4/4] gpio: delay: Remove duplicative functionality Andy Shevchenko
2023-06-15  6:38   ` Linus Walleij
2023-06-15  7:49   ` Geert Uytterhoeven
2023-06-15  9:10 ` [PATCH v2 0/4] gpio: aggregator: Incorporate gpio-delay functionality Andy Shevchenko

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=20230614231446.3687-2-andriy.shevchenko@linux.intel.com \
    --to=andriy.shevchenko@linux.intel.com \
    --cc=alexander.stein@ew.tq-group.com \
    --cc=andy@kernel.org \
    --cc=bartosz.golaszewski@linaro.org \
    --cc=brgl@bgdev.pl \
    --cc=geert+renesas@glider.be \
    --cc=linus.walleij@linaro.org \
    --cc=linux-gpio@vger.kernel.org \
    --cc=linux-kernel@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).