linux-gpio.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH RFT 0/6] gpio: mmio: remove struct bgpio_pdata
@ 2025-06-24 13:19 Bartosz Golaszewski
  2025-06-24 13:19 ` [PATCH RFT 1/6] gpio: mmio: drop the big-endian platform device variant Bartosz Golaszewski
                   ` (5 more replies)
  0 siblings, 6 replies; 24+ messages in thread
From: Bartosz Golaszewski @ 2025-06-24 13:19 UTC (permalink / raw)
  To: Linus Walleij, Bartosz Golaszewski, Lee Jones, Liviu Dudau,
	Sudeep Holla, Lorenzo Pieralisi, Aaro Koskinen,
	Janusz Krzysztofik, Tony Lindgren, Russell King,
	Krzysztof Kozlowski, Alim Akhtar
  Cc: linux-gpio, linux-kernel, linux-arm-kernel, linux-omap, patches,
	linux-samsung-soc, Bartosz Golaszewski

I'm working on removing the fields relevant only to gpio-mmio from
struct gpio_chip. One of the bits that need addressing before we can do
this is the removal of struct bgpio_pdata from the kernel. Fortunately
there are only 3 users left treewide.

This series adds support for parsing of generic device properties to
gpio-mmio, converts all users to setting up software nodes containing
relevant values in their property sets and removes struct bgpio_pdata.

As for merging: it would be best for MFD/OMAP/s3c maintainers to ack the
changes and let me route them through the GPIO tree. I can provide an
immutable tag if needed.

Obviously I was only able to build-test the changes so any actual
verification is appreciated.

Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
---
Bartosz Golaszewski (6):
      gpio: mmio: drop the big-endian platform device variant
      gpio: mmio: get chip label and GPIO base from device properties
      mfd: vexpress-sysreg: set-up software nodes for gpio-mmio
      ARM: omap1: ams-delta: use generic device properties for gpio-mmio
      ARM: s3c: crag6410: use generic device properties for gpio-mmio
      gpio: mmio: remove struct bgpio_pdata

 arch/arm/mach-omap1/board-ams-delta.c | 42 ++++++++++++--------------
 arch/arm/mach-s3c/mach-crag6410.c     | 17 ++++++-----
 drivers/gpio/gpio-mmio.c              | 57 +++++++++--------------------------
 drivers/mfd/vexpress-sysreg.c         | 46 +++++++++++++++++-----------
 include/linux/gpio/driver.h           |  6 ----
 5 files changed, 73 insertions(+), 95 deletions(-)
---
base-commit: f817b6dd2b62d921a6cdc0a3ac599cd1851f343c
change-id: 20250623-gpio-mmio-pdata-a831b96e8dd2

Best regards,
-- 
Bartosz Golaszewski <bartosz.golaszewski@linaro.org>


^ permalink raw reply	[flat|nested] 24+ messages in thread

* [PATCH RFT 1/6] gpio: mmio: drop the big-endian platform device variant
  2025-06-24 13:19 [PATCH RFT 0/6] gpio: mmio: remove struct bgpio_pdata Bartosz Golaszewski
@ 2025-06-24 13:19 ` Bartosz Golaszewski
  2025-06-24 19:41   ` Linus Walleij
  2025-06-24 13:19 ` [PATCH RFT 2/6] gpio: mmio: get chip label and GPIO base from device properties Bartosz Golaszewski
                   ` (4 subsequent siblings)
  5 siblings, 1 reply; 24+ messages in thread
From: Bartosz Golaszewski @ 2025-06-24 13:19 UTC (permalink / raw)
  To: Linus Walleij, Bartosz Golaszewski, Lee Jones, Liviu Dudau,
	Sudeep Holla, Lorenzo Pieralisi, Aaro Koskinen,
	Janusz Krzysztofik, Tony Lindgren, Russell King,
	Krzysztof Kozlowski, Alim Akhtar
  Cc: linux-gpio, linux-kernel, linux-arm-kernel, linux-omap, patches,
	linux-samsung-soc, Bartosz Golaszewski

From: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>

There are no more users of the "basic-mmio-gpio-be" platform device ID
in the kernel. We can safely drop it.

Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
---
 drivers/gpio/gpio-mmio.c | 3 ---
 1 file changed, 3 deletions(-)

diff --git a/drivers/gpio/gpio-mmio.c b/drivers/gpio/gpio-mmio.c
index 08466e123818e958755fe6e7baf5a4e8b8d863c1..ffe6b6f6cc9b1e9341e1c42cf8fee917e0147bf3 100644
--- a/drivers/gpio/gpio-mmio.c
+++ b/drivers/gpio/gpio-mmio.c
@@ -831,9 +831,6 @@ static const struct platform_device_id bgpio_id_table[] = {
 	{
 		.name		= "basic-mmio-gpio",
 		.driver_data	= 0,
-	}, {
-		.name		= "basic-mmio-gpio-be",
-		.driver_data	= BGPIOF_BIG_ENDIAN,
 	},
 	{ }
 };

-- 
2.48.1


^ permalink raw reply related	[flat|nested] 24+ messages in thread

* [PATCH RFT 2/6] gpio: mmio: get chip label and GPIO base from device properties
  2025-06-24 13:19 [PATCH RFT 0/6] gpio: mmio: remove struct bgpio_pdata Bartosz Golaszewski
  2025-06-24 13:19 ` [PATCH RFT 1/6] gpio: mmio: drop the big-endian platform device variant Bartosz Golaszewski
@ 2025-06-24 13:19 ` Bartosz Golaszewski
  2025-06-24 19:43   ` Linus Walleij
  2025-06-24 13:19 ` [PATCH RFT 3/6] mfd: vexpress-sysreg: set-up software nodes for gpio-mmio Bartosz Golaszewski
                   ` (3 subsequent siblings)
  5 siblings, 1 reply; 24+ messages in thread
From: Bartosz Golaszewski @ 2025-06-24 13:19 UTC (permalink / raw)
  To: Linus Walleij, Bartosz Golaszewski, Lee Jones, Liviu Dudau,
	Sudeep Holla, Lorenzo Pieralisi, Aaro Koskinen,
	Janusz Krzysztofik, Tony Lindgren, Russell King,
	Krzysztof Kozlowski, Alim Akhtar
  Cc: linux-gpio, linux-kernel, linux-arm-kernel, linux-omap, patches,
	linux-samsung-soc, Bartosz Golaszewski

From: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>

Ahead of removing struct bgpio_pdata support from the gpio-mmio generic
module, let's add support for getting the relevant values from generic
device properties. "label" is a semi-standardized property in some GPIO
drivers so let's go with it. There's no standard "base" property, so
let's use the name "gpio-mmio,base" to tie it to this driver
specifically. The number of GPIOs will be retrieved using
gpiochip_get_ngpios() so there's no need to look it up in the software
node.

Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
---
 drivers/gpio/gpio-mmio.c | 11 +++++++++++
 1 file changed, 11 insertions(+)

diff --git a/drivers/gpio/gpio-mmio.c b/drivers/gpio/gpio-mmio.c
index ffe6b6f6cc9b1e9341e1c42cf8fee917e0147bf3..8108aa8e6b86ae3d0b520a0f22a09689ab1d9bc5 100644
--- a/drivers/gpio/gpio-mmio.c
+++ b/drivers/gpio/gpio-mmio.c
@@ -737,6 +737,9 @@ MODULE_DEVICE_TABLE(of, bgpio_of_match);
 static struct bgpio_pdata *bgpio_parse_fw(struct device *dev, unsigned long *flags)
 {
 	struct bgpio_pdata *pdata;
+	const char *label;
+	unsigned int base;
+	int ret;
 
 	if (!dev_fwnode(dev))
 		return NULL;
@@ -753,6 +756,14 @@ static struct bgpio_pdata *bgpio_parse_fw(struct device *dev, unsigned long *fla
 	if (device_property_read_bool(dev, "no-output"))
 		*flags |= BGPIOF_NO_OUTPUT;
 
+	ret = device_property_read_string(dev, "label", &label);
+	if (!ret)
+		pdata->label = label;
+
+	ret = device_property_read_u32(dev, "gpio-mmio,base", &base);
+	if (!ret && base <= INT_MAX)
+		pdata->base = base;
+
 	return pdata;
 }
 

-- 
2.48.1


^ permalink raw reply related	[flat|nested] 24+ messages in thread

* [PATCH RFT 3/6] mfd: vexpress-sysreg: set-up software nodes for gpio-mmio
  2025-06-24 13:19 [PATCH RFT 0/6] gpio: mmio: remove struct bgpio_pdata Bartosz Golaszewski
  2025-06-24 13:19 ` [PATCH RFT 1/6] gpio: mmio: drop the big-endian platform device variant Bartosz Golaszewski
  2025-06-24 13:19 ` [PATCH RFT 2/6] gpio: mmio: get chip label and GPIO base from device properties Bartosz Golaszewski
@ 2025-06-24 13:19 ` Bartosz Golaszewski
  2025-06-24 19:45   ` Linus Walleij
                     ` (2 more replies)
  2025-06-24 13:19 ` [PATCH RFT 4/6] ARM: omap1: ams-delta: use generic device properties " Bartosz Golaszewski
                   ` (2 subsequent siblings)
  5 siblings, 3 replies; 24+ messages in thread
From: Bartosz Golaszewski @ 2025-06-24 13:19 UTC (permalink / raw)
  To: Linus Walleij, Bartosz Golaszewski, Lee Jones, Liviu Dudau,
	Sudeep Holla, Lorenzo Pieralisi, Aaro Koskinen,
	Janusz Krzysztofik, Tony Lindgren, Russell King,
	Krzysztof Kozlowski, Alim Akhtar
  Cc: linux-gpio, linux-kernel, linux-arm-kernel, linux-omap, patches,
	linux-samsung-soc, Bartosz Golaszewski

From: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>

Replace struct bgpio_pdata - that we plan to remove - with software
nodes containing properties encoding the same values thatr can now be
parsed by gpio-mmio.

Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
---
 drivers/mfd/vexpress-sysreg.c | 46 ++++++++++++++++++++++++++-----------------
 1 file changed, 28 insertions(+), 18 deletions(-)

diff --git a/drivers/mfd/vexpress-sysreg.c b/drivers/mfd/vexpress-sysreg.c
index ef03d6cec9ff6927668d051ca459eb1d8ff7269e..fc2daffc4352cca763cefbf6e17bdd5242290198 100644
--- a/drivers/mfd/vexpress-sysreg.c
+++ b/drivers/mfd/vexpress-sysreg.c
@@ -11,6 +11,7 @@
 #include <linux/module.h>
 #include <linux/of_platform.h>
 #include <linux/platform_device.h>
+#include <linux/property.h>
 #include <linux/slab.h>
 #include <linux/stat.h>
 
@@ -37,22 +38,34 @@
 
 /* The sysreg block is just a random collection of various functions... */
 
-static struct bgpio_pdata vexpress_sysreg_sys_led_pdata = {
-	.label = "sys_led",
-	.base = -1,
-	.ngpio = 8,
+static const struct property_entry vexpress_sysreg_sys_led_props[] = {
+	PROPERTY_ENTRY_STRING("label", "sys_led"),
+	PROPERTY_ENTRY_U32("ngpios", 8),
+	{ }
 };
 
-static struct bgpio_pdata vexpress_sysreg_sys_mci_pdata = {
-	.label = "sys_mci",
-	.base = -1,
-	.ngpio = 2,
+static const struct software_node vexpress_sysreg_sys_led_swnode = {
+	.properties = vexpress_sysreg_sys_led_props,
 };
 
-static struct bgpio_pdata vexpress_sysreg_sys_flash_pdata = {
-	.label = "sys_flash",
-	.base = -1,
-	.ngpio = 1,
+static const struct property_entry vexpress_sysreg_sys_mci_props[] = {
+	PROPERTY_ENTRY_STRING("label", "sys_mci"),
+	PROPERTY_ENTRY_U32("ngpios", 2),
+	{ }
+};
+
+static const struct software_node vexpress_sysreg_sys_mci_swnode = {
+	.properties = vexpress_sysreg_sys_mci_props,
+};
+
+static const struct property_entry vexpress_sysreg_sys_flash_props[] = {
+	PROPERTY_ENTRY_STRING("label", "sys_flash"),
+	PROPERTY_ENTRY_U32("ngpios", 1),
+	{ }
+};
+
+static const struct software_node vexpress_sysreg_sys_flash_swnode = {
+	.properties = vexpress_sysreg_sys_flash_props,
 };
 
 static struct mfd_cell vexpress_sysreg_cells[] = {
@@ -61,22 +74,19 @@ static struct mfd_cell vexpress_sysreg_cells[] = {
 		.of_compatible = "arm,vexpress-sysreg,sys_led",
 		.num_resources = 1,
 		.resources = &DEFINE_RES_MEM_NAMED(SYS_LED, 0x4, "dat"),
-		.platform_data = &vexpress_sysreg_sys_led_pdata,
-		.pdata_size = sizeof(vexpress_sysreg_sys_led_pdata),
+		.swnode = &vexpress_sysreg_sys_led_swnode,
 	}, {
 		.name = "basic-mmio-gpio",
 		.of_compatible = "arm,vexpress-sysreg,sys_mci",
 		.num_resources = 1,
 		.resources = &DEFINE_RES_MEM_NAMED(SYS_MCI, 0x4, "dat"),
-		.platform_data = &vexpress_sysreg_sys_mci_pdata,
-		.pdata_size = sizeof(vexpress_sysreg_sys_mci_pdata),
+		.swnode = &vexpress_sysreg_sys_mci_swnode,
 	}, {
 		.name = "basic-mmio-gpio",
 		.of_compatible = "arm,vexpress-sysreg,sys_flash",
 		.num_resources = 1,
 		.resources = &DEFINE_RES_MEM_NAMED(SYS_FLASH, 0x4, "dat"),
-		.platform_data = &vexpress_sysreg_sys_flash_pdata,
-		.pdata_size = sizeof(vexpress_sysreg_sys_flash_pdata),
+		.swnode = &vexpress_sysreg_sys_flash_swnode,
 	}, {
 		.name = "vexpress-syscfg",
 		.num_resources = 1,

-- 
2.48.1


^ permalink raw reply related	[flat|nested] 24+ messages in thread

* [PATCH RFT 4/6] ARM: omap1: ams-delta: use generic device properties for gpio-mmio
  2025-06-24 13:19 [PATCH RFT 0/6] gpio: mmio: remove struct bgpio_pdata Bartosz Golaszewski
                   ` (2 preceding siblings ...)
  2025-06-24 13:19 ` [PATCH RFT 3/6] mfd: vexpress-sysreg: set-up software nodes for gpio-mmio Bartosz Golaszewski
@ 2025-06-24 13:19 ` Bartosz Golaszewski
  2025-06-24 19:45   ` Linus Walleij
  2025-06-24 13:19 ` [PATCH RFT 5/6] ARM: s3c: crag6410: " Bartosz Golaszewski
  2025-06-24 13:19 ` [PATCH RFT 6/6] gpio: mmio: remove struct bgpio_pdata Bartosz Golaszewski
  5 siblings, 1 reply; 24+ messages in thread
From: Bartosz Golaszewski @ 2025-06-24 13:19 UTC (permalink / raw)
  To: Linus Walleij, Bartosz Golaszewski, Lee Jones, Liviu Dudau,
	Sudeep Holla, Lorenzo Pieralisi, Aaro Koskinen,
	Janusz Krzysztofik, Tony Lindgren, Russell King,
	Krzysztof Kozlowski, Alim Akhtar
  Cc: linux-gpio, linux-kernel, linux-arm-kernel, linux-omap, patches,
	linux-samsung-soc, Bartosz Golaszewski

From: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>

The two latch GPIO devices in ams-delta are registered with struct
bgpio_pdata passed as platform_data to the gpio-mmio driver. We want to
remove the bgpio_pdata from the kernel and the gpio-mmio driver is now
also able to get the relevant values from the software node. Set up
device properties and switch to using platform_device_info to register
the devices as platform_add_devices() doesn't allow us to pass device
properties to the driver model.

Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
---
 arch/arm/mach-omap1/board-ams-delta.c | 42 +++++++++++++++++------------------
 1 file changed, 20 insertions(+), 22 deletions(-)

diff --git a/arch/arm/mach-omap1/board-ams-delta.c b/arch/arm/mach-omap1/board-ams-delta.c
index 0daf6c5b5c1cbcfd5bd15203cad119d39aa95f19..16392720296cd224732450c85419c35bbab506f6 100644
--- a/arch/arm/mach-omap1/board-ams-delta.c
+++ b/arch/arm/mach-omap1/board-ams-delta.c
@@ -19,6 +19,7 @@
 #include <linux/mtd/nand-gpio.h>
 #include <linux/mtd/partitions.h>
 #include <linux/platform_device.h>
+#include <linux/property.h>
 #include <linux/regulator/consumer.h>
 #include <linux/regulator/fixed.h>
 #include <linux/regulator/machine.h>
@@ -175,20 +176,18 @@ static struct resource latch1_resources[] = {
 
 #define LATCH1_LABEL	"latch1"
 
-static struct bgpio_pdata latch1_pdata = {
-	.label	= LATCH1_LABEL,
-	.base	= -1,
-	.ngpio	= LATCH1_NGPIO,
+static const struct property_entry latch1_gpio_props[] = {
+	PROPERTY_ENTRY_STRING("label", LATCH1_LABEL),
+	PROPERTY_ENTRY_U32("ngpios", LATCH1_NGPIO),
+	{ }
 };
 
-static struct platform_device latch1_gpio_device = {
+static const struct platform_device_info latch1_gpio_devinfo = {
 	.name		= "basic-mmio-gpio",
 	.id		= 0,
-	.resource	= latch1_resources,
-	.num_resources	= ARRAY_SIZE(latch1_resources),
-	.dev		= {
-		.platform_data	= &latch1_pdata,
-	},
+	.res		= latch1_resources,
+	.num_res	= ARRAY_SIZE(latch1_resources),
+	.properties	= latch1_gpio_props,
 };
 
 #define LATCH1_PIN_LED_CAMERA		0
@@ -213,20 +212,18 @@ static struct resource latch2_resources[] = {
 
 #define LATCH2_LABEL	"latch2"
 
-static struct bgpio_pdata latch2_pdata = {
-	.label	= LATCH2_LABEL,
-	.base	= -1,
-	.ngpio	= LATCH2_NGPIO,
+static const struct property_entry latch2_gpio_props[] = {
+	PROPERTY_ENTRY_STRING("label", LATCH2_LABEL),
+	PROPERTY_ENTRY_U32("ngpios", LATCH2_NGPIO),
+	{ }
 };
 
-static struct platform_device latch2_gpio_device = {
+static struct platform_device_info latch2_gpio_devinfo = {
 	.name		= "basic-mmio-gpio",
 	.id		= 1,
-	.resource	= latch2_resources,
-	.num_resources	= ARRAY_SIZE(latch2_resources),
-	.dev		= {
-		.platform_data	= &latch2_pdata,
-	},
+	.res		= latch2_resources,
+	.num_res	= ARRAY_SIZE(latch2_resources),
+	.properties	= latch2_gpio_props,
 };
 
 #define LATCH2_PIN_LCD_VBLEN		0
@@ -542,8 +539,6 @@ static struct gpiod_lookup_table keybrd_pwr_gpio_table = {
 };
 
 static struct platform_device *ams_delta_devices[] __initdata = {
-	&latch1_gpio_device,
-	&latch2_gpio_device,
 	&ams_delta_kp_device,
 	&ams_delta_audio_device,
 	&ams_delta_serio_device,
@@ -697,6 +692,9 @@ static void __init ams_delta_init(void)
 	omap1_usb_init(&ams_delta_usb_config);
 	platform_add_devices(ams_delta_devices, ARRAY_SIZE(ams_delta_devices));
 
+	platform_device_register_full(&latch1_gpio_devinfo);
+	platform_device_register_full(&latch2_gpio_devinfo);
+
 	/*
 	 * As soon as regulator consumers have been registered, assign their
 	 * dev_names to consumer supply entries of respective regulators.

-- 
2.48.1


^ permalink raw reply related	[flat|nested] 24+ messages in thread

* [PATCH RFT 5/6] ARM: s3c: crag6410: use generic device properties for gpio-mmio
  2025-06-24 13:19 [PATCH RFT 0/6] gpio: mmio: remove struct bgpio_pdata Bartosz Golaszewski
                   ` (3 preceding siblings ...)
  2025-06-24 13:19 ` [PATCH RFT 4/6] ARM: omap1: ams-delta: use generic device properties " Bartosz Golaszewski
@ 2025-06-24 13:19 ` Bartosz Golaszewski
  2025-06-24 16:33   ` Charles Keepax
                     ` (2 more replies)
  2025-06-24 13:19 ` [PATCH RFT 6/6] gpio: mmio: remove struct bgpio_pdata Bartosz Golaszewski
  5 siblings, 3 replies; 24+ messages in thread
From: Bartosz Golaszewski @ 2025-06-24 13:19 UTC (permalink / raw)
  To: Linus Walleij, Bartosz Golaszewski, Lee Jones, Liviu Dudau,
	Sudeep Holla, Lorenzo Pieralisi, Aaro Koskinen,
	Janusz Krzysztofik, Tony Lindgren, Russell King,
	Krzysztof Kozlowski, Alim Akhtar
  Cc: linux-gpio, linux-kernel, linux-arm-kernel, linux-omap, patches,
	linux-samsung-soc, Bartosz Golaszewski

From: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>

The GPIO device in crag6410 is registered with struct bgpio_pdata passed
as platform_data to the gpio-mmio driver. We want to remove the
bgpio_pdata from the kernel and the gpio-mmio driver is now also able to
get the relevant values from the software node. Set up device properties
and switch to using platform_device_info to register the device as
platform_add_devices() doesn't allow us to pass device properties to the
driver model.

Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
---
 arch/arm/mach-s3c/mach-crag6410.c | 17 ++++++++++-------
 1 file changed, 10 insertions(+), 7 deletions(-)

diff --git a/arch/arm/mach-s3c/mach-crag6410.c b/arch/arm/mach-s3c/mach-crag6410.c
index e5df2cb51ab27896d9dd80571f421e959db1fd1e..028169c7debf325ab6f51475d3595b92b1307189 100644
--- a/arch/arm/mach-s3c/mach-crag6410.c
+++ b/arch/arm/mach-s3c/mach-crag6410.c
@@ -252,14 +252,17 @@ static struct resource crag6410_mmgpio_resource[] = {
 	[0] = DEFINE_RES_MEM_NAMED(S3C64XX_PA_XM0CSN4, 1, "dat"),
 };
 
-static struct platform_device crag6410_mmgpio = {
+static const struct property_entry crag6410_mmgpio_props[] = {
+	PROPERTY_ENTRY_U32("gpio-mmio,base", MMGPIO_GPIO_BASE),
+	{ }
+};
+
+static struct platform_device_info crag6410_mmgpio_devinfo = {
 	.name		= "basic-mmio-gpio",
 	.id		= -1,
-	.resource	= crag6410_mmgpio_resource,
-	.num_resources	= ARRAY_SIZE(crag6410_mmgpio_resource),
-	.dev.platform_data = &(struct bgpio_pdata) {
-		.base	= MMGPIO_GPIO_BASE,
-	},
+	.res		= crag6410_mmgpio_resource,
+	.num_res	= ARRAY_SIZE(crag6410_mmgpio_resource),
+	.properties	= crag6410_mmgpio_props,
 };
 
 static struct platform_device speyside_device = {
@@ -373,7 +376,6 @@ static struct platform_device *crag6410_devices[] __initdata = {
 	&crag6410_gpio_keydev,
 	&crag6410_dm9k_device,
 	&s3c64xx_device_spi0,
-	&crag6410_mmgpio,
 	&crag6410_lcd_powerdev,
 	&crag6410_backlight_device,
 	&speyside_device,
@@ -871,6 +873,7 @@ static void __init crag6410_machine_init(void)
 
 	pwm_add_table(crag6410_pwm_lookup, ARRAY_SIZE(crag6410_pwm_lookup));
 	platform_add_devices(crag6410_devices, ARRAY_SIZE(crag6410_devices));
+	platform_device_register_full(&crag6410_mmgpio_devinfo);
 
 	gpio_led_register_device(-1, &gpio_leds_pdata);
 

-- 
2.48.1


^ permalink raw reply related	[flat|nested] 24+ messages in thread

* [PATCH RFT 6/6] gpio: mmio: remove struct bgpio_pdata
  2025-06-24 13:19 [PATCH RFT 0/6] gpio: mmio: remove struct bgpio_pdata Bartosz Golaszewski
                   ` (4 preceding siblings ...)
  2025-06-24 13:19 ` [PATCH RFT 5/6] ARM: s3c: crag6410: " Bartosz Golaszewski
@ 2025-06-24 13:19 ` Bartosz Golaszewski
  5 siblings, 0 replies; 24+ messages in thread
From: Bartosz Golaszewski @ 2025-06-24 13:19 UTC (permalink / raw)
  To: Linus Walleij, Bartosz Golaszewski, Lee Jones, Liviu Dudau,
	Sudeep Holla, Lorenzo Pieralisi, Aaro Koskinen,
	Janusz Krzysztofik, Tony Lindgren, Russell King,
	Krzysztof Kozlowski, Alim Akhtar
  Cc: linux-gpio, linux-kernel, linux-arm-kernel, linux-omap, patches,
	linux-samsung-soc, Bartosz Golaszewski

From: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>

With no more users, we can now remove struct bgpio_pdata. Move the
relevant bits from bgpio_parse_fw() into bgpio_pdev_probe() while
maintaining the logical ordering (get flags before calling
bgpio_init()).

Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
---
 drivers/gpio/gpio-mmio.c    | 65 +++++++++++----------------------------------
 include/linux/gpio/driver.h |  6 -----
 2 files changed, 15 insertions(+), 56 deletions(-)

diff --git a/drivers/gpio/gpio-mmio.c b/drivers/gpio/gpio-mmio.c
index 8108aa8e6b86ae3d0b520a0f22a09689ab1d9bc5..cf4d3f968af52bb750038d32f78d1c39498d3f06 100644
--- a/drivers/gpio/gpio-mmio.c
+++ b/drivers/gpio/gpio-mmio.c
@@ -734,39 +734,6 @@ static const struct of_device_id bgpio_of_match[] = {
 };
 MODULE_DEVICE_TABLE(of, bgpio_of_match);
 
-static struct bgpio_pdata *bgpio_parse_fw(struct device *dev, unsigned long *flags)
-{
-	struct bgpio_pdata *pdata;
-	const char *label;
-	unsigned int base;
-	int ret;
-
-	if (!dev_fwnode(dev))
-		return NULL;
-
-	pdata = devm_kzalloc(dev, sizeof(*pdata), GFP_KERNEL);
-	if (!pdata)
-		return ERR_PTR(-ENOMEM);
-
-	pdata->base = -1;
-
-	if (device_is_big_endian(dev))
-		*flags |= BGPIOF_BIG_ENDIAN_BYTE_ORDER;
-
-	if (device_property_read_bool(dev, "no-output"))
-		*flags |= BGPIOF_NO_OUTPUT;
-
-	ret = device_property_read_string(dev, "label", &label);
-	if (!ret)
-		pdata->label = label;
-
-	ret = device_property_read_u32(dev, "gpio-mmio,base", &base);
-	if (!ret && base <= INT_MAX)
-		pdata->base = base;
-
-	return pdata;
-}
-
 static int bgpio_pdev_probe(struct platform_device *pdev)
 {
 	struct device *dev = &pdev->dev;
@@ -778,18 +745,10 @@ static int bgpio_pdev_probe(struct platform_device *pdev)
 	void __iomem *dirin;
 	unsigned long sz;
 	unsigned long flags = 0;
+	unsigned int base;
 	int err;
 	struct gpio_chip *gc;
-	struct bgpio_pdata *pdata;
-
-	pdata = bgpio_parse_fw(dev, &flags);
-	if (IS_ERR(pdata))
-		return PTR_ERR(pdata);
-
-	if (!pdata) {
-		pdata = dev_get_platdata(dev);
-		flags = pdev->id_entry->driver_data;
-	}
+	const char *label;
 
 	r = platform_get_resource_byname(pdev, IORESOURCE_MEM, "dat");
 	if (!r)
@@ -821,17 +780,23 @@ static int bgpio_pdev_probe(struct platform_device *pdev)
 	if (!gc)
 		return -ENOMEM;
 
+	if (device_is_big_endian(dev))
+		flags |= BGPIOF_BIG_ENDIAN_BYTE_ORDER;
+
+	if (device_property_read_bool(dev, "no-output"))
+		flags |= BGPIOF_NO_OUTPUT;
+
 	err = bgpio_init(gc, dev, sz, dat, set, clr, dirout, dirin, flags);
 	if (err)
 		return err;
 
-	if (pdata) {
-		if (pdata->label)
-			gc->label = pdata->label;
-		gc->base = pdata->base;
-		if (pdata->ngpio > 0)
-			gc->ngpio = pdata->ngpio;
-	}
+	err = device_property_read_string(dev, "label", &label);
+	if (!err)
+		gc->label = label;
+
+	err = device_property_read_u32(dev, "gpio-mmio,base", &base);
+	if (!err && base <= INT_MAX)
+		gc->base = base;
 
 	platform_set_drvdata(pdev, gc);
 
diff --git a/include/linux/gpio/driver.h b/include/linux/gpio/driver.h
index 97cc75623261917e9b3624e1e636d2432c0db205..4b984e8f8fcdbba5c008fc67ff0557bda11df40b 100644
--- a/include/linux/gpio/driver.h
+++ b/include/linux/gpio/driver.h
@@ -718,12 +718,6 @@ const unsigned long *gpiochip_query_valid_mask(const struct gpio_chip *gc);
 /* get driver data */
 void *gpiochip_get_data(struct gpio_chip *gc);
 
-struct bgpio_pdata {
-	const char *label;
-	int base;
-	int ngpio;
-};
-
 #ifdef CONFIG_IRQ_DOMAIN_HIERARCHY
 
 int gpiochip_populate_parent_fwspec_twocell(struct gpio_chip *gc,

-- 
2.48.1


^ permalink raw reply related	[flat|nested] 24+ messages in thread

* Re: [PATCH RFT 5/6] ARM: s3c: crag6410: use generic device properties for gpio-mmio
  2025-06-24 13:19 ` [PATCH RFT 5/6] ARM: s3c: crag6410: " Bartosz Golaszewski
@ 2025-06-24 16:33   ` Charles Keepax
  2025-06-24 19:46   ` Linus Walleij
  2025-06-26 19:51   ` Krzysztof Kozlowski
  2 siblings, 0 replies; 24+ messages in thread
From: Charles Keepax @ 2025-06-24 16:33 UTC (permalink / raw)
  To: Bartosz Golaszewski, broonie
  Cc: Linus Walleij, Lee Jones, Liviu Dudau, Sudeep Holla,
	Lorenzo Pieralisi, Aaro Koskinen, Janusz Krzysztofik,
	Tony Lindgren, Russell King, Krzysztof Kozlowski, Alim Akhtar,
	linux-gpio, linux-kernel, linux-arm-kernel, linux-omap, patches,
	linux-samsung-soc, Bartosz Golaszewski

On Tue, Jun 24, 2025 at 03:19:16PM +0200, Bartosz Golaszewski wrote:
> From: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
> 
> The GPIO device in crag6410 is registered with struct bgpio_pdata passed
> as platform_data to the gpio-mmio driver. We want to remove the
> bgpio_pdata from the kernel and the gpio-mmio driver is now also able to
> get the relevant values from the software node. Set up device properties
> and switch to using platform_device_info to register the device as
> platform_add_devices() doesn't allow us to pass device properties to the
> driver model.
> 
> Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
> ---

+ Broonie, as I think he might still use Cragganmore for testing.

But from my side I think it looks fine to me.

Reviewed-by: Charles Keepax <ckeepax@opensource.cirrus.com>

Thanks,
Charles

>  arch/arm/mach-s3c/mach-crag6410.c | 17 ++++++++++-------
>  1 file changed, 10 insertions(+), 7 deletions(-)
> 
> diff --git a/arch/arm/mach-s3c/mach-crag6410.c b/arch/arm/mach-s3c/mach-crag6410.c
> index e5df2cb51ab27896d9dd80571f421e959db1fd1e..028169c7debf325ab6f51475d3595b92b1307189 100644
> --- a/arch/arm/mach-s3c/mach-crag6410.c
> +++ b/arch/arm/mach-s3c/mach-crag6410.c
> @@ -252,14 +252,17 @@ static struct resource crag6410_mmgpio_resource[] = {
>  	[0] = DEFINE_RES_MEM_NAMED(S3C64XX_PA_XM0CSN4, 1, "dat"),
>  };
>  
> -static struct platform_device crag6410_mmgpio = {
> +static const struct property_entry crag6410_mmgpio_props[] = {
> +	PROPERTY_ENTRY_U32("gpio-mmio,base", MMGPIO_GPIO_BASE),
> +	{ }
> +};
> +
> +static struct platform_device_info crag6410_mmgpio_devinfo = {
>  	.name		= "basic-mmio-gpio",
>  	.id		= -1,
> -	.resource	= crag6410_mmgpio_resource,
> -	.num_resources	= ARRAY_SIZE(crag6410_mmgpio_resource),
> -	.dev.platform_data = &(struct bgpio_pdata) {
> -		.base	= MMGPIO_GPIO_BASE,
> -	},
> +	.res		= crag6410_mmgpio_resource,
> +	.num_res	= ARRAY_SIZE(crag6410_mmgpio_resource),
> +	.properties	= crag6410_mmgpio_props,
>  };
>  
>  static struct platform_device speyside_device = {
> @@ -373,7 +376,6 @@ static struct platform_device *crag6410_devices[] __initdata = {
>  	&crag6410_gpio_keydev,
>  	&crag6410_dm9k_device,
>  	&s3c64xx_device_spi0,
> -	&crag6410_mmgpio,
>  	&crag6410_lcd_powerdev,
>  	&crag6410_backlight_device,
>  	&speyside_device,
> @@ -871,6 +873,7 @@ static void __init crag6410_machine_init(void)
>  
>  	pwm_add_table(crag6410_pwm_lookup, ARRAY_SIZE(crag6410_pwm_lookup));
>  	platform_add_devices(crag6410_devices, ARRAY_SIZE(crag6410_devices));
> +	platform_device_register_full(&crag6410_mmgpio_devinfo);
>  
>  	gpio_led_register_device(-1, &gpio_leds_pdata);
>  
> 
> -- 
> 2.48.1
> 

^ permalink raw reply	[flat|nested] 24+ messages in thread

* Re: [PATCH RFT 1/6] gpio: mmio: drop the big-endian platform device variant
  2025-06-24 13:19 ` [PATCH RFT 1/6] gpio: mmio: drop the big-endian platform device variant Bartosz Golaszewski
@ 2025-06-24 19:41   ` Linus Walleij
  0 siblings, 0 replies; 24+ messages in thread
From: Linus Walleij @ 2025-06-24 19:41 UTC (permalink / raw)
  To: Bartosz Golaszewski
  Cc: Lee Jones, Liviu Dudau, Sudeep Holla, Lorenzo Pieralisi,
	Aaro Koskinen, Janusz Krzysztofik, Tony Lindgren, Russell King,
	Krzysztof Kozlowski, Alim Akhtar, linux-gpio, linux-kernel,
	linux-arm-kernel, linux-omap, patches, linux-samsung-soc,
	Bartosz Golaszewski

On Tue, Jun 24, 2025 at 3:19 PM Bartosz Golaszewski <brgl@bgdev.pl> wrote:

> From: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
>
> There are no more users of the "basic-mmio-gpio-be" platform device ID
> in the kernel. We can safely drop it.
>
> Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>

Reviewed-by: Linus Walleij <linus.walleij@linaro.org>

Yours,
Linus Walleij

^ permalink raw reply	[flat|nested] 24+ messages in thread

* Re: [PATCH RFT 2/6] gpio: mmio: get chip label and GPIO base from device properties
  2025-06-24 13:19 ` [PATCH RFT 2/6] gpio: mmio: get chip label and GPIO base from device properties Bartosz Golaszewski
@ 2025-06-24 19:43   ` Linus Walleij
  2025-06-25  7:35     ` Bartosz Golaszewski
  0 siblings, 1 reply; 24+ messages in thread
From: Linus Walleij @ 2025-06-24 19:43 UTC (permalink / raw)
  To: Bartosz Golaszewski
  Cc: Lee Jones, Liviu Dudau, Sudeep Holla, Lorenzo Pieralisi,
	Aaro Koskinen, Janusz Krzysztofik, Tony Lindgren, Russell King,
	Krzysztof Kozlowski, Alim Akhtar, linux-gpio, linux-kernel,
	linux-arm-kernel, linux-omap, patches, linux-samsung-soc,
	Bartosz Golaszewski

On Tue, Jun 24, 2025 at 3:19 PM Bartosz Golaszewski <brgl@bgdev.pl> wrote:

> From: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
>
> Ahead of removing struct bgpio_pdata support from the gpio-mmio generic
> module, let's add support for getting the relevant values from generic
> device properties. "label" is a semi-standardized property in some GPIO
> drivers so let's go with it. There's no standard "base" property, so
> let's use the name "gpio-mmio,base" to tie it to this driver
> specifically. The number of GPIOs will be retrieved using
> gpiochip_get_ngpios() so there's no need to look it up in the software
> node.
>
> Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>

This works for me.
I wouldn't be stoked to see device trees abusing the "gpio-mmio,base"
property all of a sudden just because it now exists as a device
property though... I kind of wish we had a way to opt out of exposing
this to all the sub-property paths. But it seems tiresome, so:

Reviewed-by: Linus Walleij <linus.walleij@linaro.org>

Yours,
Linus Walleij

^ permalink raw reply	[flat|nested] 24+ messages in thread

* Re: [PATCH RFT 3/6] mfd: vexpress-sysreg: set-up software nodes for gpio-mmio
  2025-06-24 13:19 ` [PATCH RFT 3/6] mfd: vexpress-sysreg: set-up software nodes for gpio-mmio Bartosz Golaszewski
@ 2025-06-24 19:45   ` Linus Walleij
  2025-06-26 13:22   ` Lee Jones
  2025-06-26 22:20   ` Liviu Dudau
  2 siblings, 0 replies; 24+ messages in thread
From: Linus Walleij @ 2025-06-24 19:45 UTC (permalink / raw)
  To: Bartosz Golaszewski
  Cc: Lee Jones, Liviu Dudau, Sudeep Holla, Lorenzo Pieralisi,
	Aaro Koskinen, Janusz Krzysztofik, Tony Lindgren, Russell King,
	Krzysztof Kozlowski, Alim Akhtar, linux-gpio, linux-kernel,
	linux-arm-kernel, linux-omap, patches, linux-samsung-soc,
	Bartosz Golaszewski

On Tue, Jun 24, 2025 at 3:19 PM Bartosz Golaszewski <brgl@bgdev.pl> wrote:

> From: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
>
> Replace struct bgpio_pdata - that we plan to remove - with software
> nodes containing properties encoding the same values thatr can now be
> parsed by gpio-mmio.
>
> Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>

Neat!
Reviewed-by: Linus Walleij <linus.walleij@linaro.org>

Yours,
Linus Walleij

^ permalink raw reply	[flat|nested] 24+ messages in thread

* Re: [PATCH RFT 4/6] ARM: omap1: ams-delta: use generic device properties for gpio-mmio
  2025-06-24 13:19 ` [PATCH RFT 4/6] ARM: omap1: ams-delta: use generic device properties " Bartosz Golaszewski
@ 2025-06-24 19:45   ` Linus Walleij
  0 siblings, 0 replies; 24+ messages in thread
From: Linus Walleij @ 2025-06-24 19:45 UTC (permalink / raw)
  To: Bartosz Golaszewski
  Cc: Lee Jones, Liviu Dudau, Sudeep Holla, Lorenzo Pieralisi,
	Aaro Koskinen, Janusz Krzysztofik, Tony Lindgren, Russell King,
	Krzysztof Kozlowski, Alim Akhtar, linux-gpio, linux-kernel,
	linux-arm-kernel, linux-omap, patches, linux-samsung-soc,
	Bartosz Golaszewski

On Tue, Jun 24, 2025 at 3:19 PM Bartosz Golaszewski <brgl@bgdev.pl> wrote:

> From: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
>
> The two latch GPIO devices in ams-delta are registered with struct
> bgpio_pdata passed as platform_data to the gpio-mmio driver. We want to
> remove the bgpio_pdata from the kernel and the gpio-mmio driver is now
> also able to get the relevant values from the software node. Set up
> device properties and switch to using platform_device_info to register
> the devices as platform_add_devices() doesn't allow us to pass device
> properties to the driver model.
>
> Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>

Reviewed-by: Linus Walleij <linus.walleij@linaro.org>

Yours,
Linus Walleij

^ permalink raw reply	[flat|nested] 24+ messages in thread

* Re: [PATCH RFT 5/6] ARM: s3c: crag6410: use generic device properties for gpio-mmio
  2025-06-24 13:19 ` [PATCH RFT 5/6] ARM: s3c: crag6410: " Bartosz Golaszewski
  2025-06-24 16:33   ` Charles Keepax
@ 2025-06-24 19:46   ` Linus Walleij
  2025-06-26 19:51   ` Krzysztof Kozlowski
  2 siblings, 0 replies; 24+ messages in thread
From: Linus Walleij @ 2025-06-24 19:46 UTC (permalink / raw)
  To: Bartosz Golaszewski
  Cc: Lee Jones, Liviu Dudau, Sudeep Holla, Lorenzo Pieralisi,
	Aaro Koskinen, Janusz Krzysztofik, Tony Lindgren, Russell King,
	Krzysztof Kozlowski, Alim Akhtar, linux-gpio, linux-kernel,
	linux-arm-kernel, linux-omap, patches, linux-samsung-soc,
	Bartosz Golaszewski

On Tue, Jun 24, 2025 at 3:19 PM Bartosz Golaszewski <brgl@bgdev.pl> wrote:

> From: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
>
> The GPIO device in crag6410 is registered with struct bgpio_pdata passed
> as platform_data to the gpio-mmio driver. We want to remove the
> bgpio_pdata from the kernel and the gpio-mmio driver is now also able to
> get the relevant values from the software node. Set up device properties
> and switch to using platform_device_info to register the device as
> platform_add_devices() doesn't allow us to pass device properties to the
> driver model.
>
> Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>


Reviewed-by: Linus Walleij <linus.walleij@linaro.org>

Yours,
Linus Walleij

^ permalink raw reply	[flat|nested] 24+ messages in thread

* Re: [PATCH RFT 2/6] gpio: mmio: get chip label and GPIO base from device properties
  2025-06-24 19:43   ` Linus Walleij
@ 2025-06-25  7:35     ` Bartosz Golaszewski
  2025-06-25  8:53       ` Krzysztof Kozlowski
  0 siblings, 1 reply; 24+ messages in thread
From: Bartosz Golaszewski @ 2025-06-25  7:35 UTC (permalink / raw)
  To: Linus Walleij
  Cc: Bartosz Golaszewski, Lee Jones, Liviu Dudau, Sudeep Holla,
	Lorenzo Pieralisi, Aaro Koskinen, Janusz Krzysztofik,
	Tony Lindgren, Russell King, Krzysztof Kozlowski, Alim Akhtar,
	linux-gpio, linux-kernel, linux-arm-kernel, linux-omap, patches,
	linux-samsung-soc

On Tue, 24 Jun 2025 at 21:44, Linus Walleij <linus.walleij@linaro.org> wrote:
>
> On Tue, Jun 24, 2025 at 3:19 PM Bartosz Golaszewski <brgl@bgdev.pl> wrote:
>
> > From: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
> >
> > Ahead of removing struct bgpio_pdata support from the gpio-mmio generic
> > module, let's add support for getting the relevant values from generic
> > device properties. "label" is a semi-standardized property in some GPIO
> > drivers so let's go with it. There's no standard "base" property, so
> > let's use the name "gpio-mmio,base" to tie it to this driver
> > specifically. The number of GPIOs will be retrieved using
> > gpiochip_get_ngpios() so there's no need to look it up in the software
> > node.
> >
> > Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
>
> This works for me.
> I wouldn't be stoked to see device trees abusing the "gpio-mmio,base"
> property all of a sudden just because it now exists as a device
> property though... I kind of wish we had a way to opt out of exposing
> this to all the sub-property paths. But it seems tiresome, so:
>
> Reviewed-by: Linus Walleij <linus.walleij@linaro.org>
>
> Yours,
> Linus Walleij

That's not a problem - this property is not in any DT bindings and as
such is not an allowed property in DT sources. For out-of-tree DTs? We
don't care about those.

Bartosz

^ permalink raw reply	[flat|nested] 24+ messages in thread

* Re: [PATCH RFT 2/6] gpio: mmio: get chip label and GPIO base from device properties
  2025-06-25  7:35     ` Bartosz Golaszewski
@ 2025-06-25  8:53       ` Krzysztof Kozlowski
  2025-06-25 10:23         ` Bartosz Golaszewski
  0 siblings, 1 reply; 24+ messages in thread
From: Krzysztof Kozlowski @ 2025-06-25  8:53 UTC (permalink / raw)
  To: Bartosz Golaszewski, Linus Walleij
  Cc: Bartosz Golaszewski, Lee Jones, Liviu Dudau, Sudeep Holla,
	Lorenzo Pieralisi, Aaro Koskinen, Janusz Krzysztofik,
	Tony Lindgren, Russell King, Alim Akhtar, linux-gpio,
	linux-kernel, linux-arm-kernel, linux-omap, patches,
	linux-samsung-soc

On 25/06/2025 09:35, Bartosz Golaszewski wrote:
> On Tue, 24 Jun 2025 at 21:44, Linus Walleij <linus.walleij@linaro.org> wrote:
>>
>> On Tue, Jun 24, 2025 at 3:19 PM Bartosz Golaszewski <brgl@bgdev.pl> wrote:
>>
>>> From: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
>>>
>>> Ahead of removing struct bgpio_pdata support from the gpio-mmio generic
>>> module, let's add support for getting the relevant values from generic
>>> device properties. "label" is a semi-standardized property in some GPIO
>>> drivers so let's go with it. There's no standard "base" property, so
>>> let's use the name "gpio-mmio,base" to tie it to this driver
>>> specifically. The number of GPIOs will be retrieved using
>>> gpiochip_get_ngpios() so there's no need to look it up in the software
>>> node.
>>>
>>> Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
>>
>> This works for me.
>> I wouldn't be stoked to see device trees abusing the "gpio-mmio,base"
>> property all of a sudden just because it now exists as a device
>> property though... I kind of wish we had a way to opt out of exposing
>> this to all the sub-property paths. But it seems tiresome, so:
>>
>> Reviewed-by: Linus Walleij <linus.walleij@linaro.org>
>>
>> Yours,
>> Linus Walleij
> 
> That's not a problem - this property is not in any DT bindings and as
> such is not an allowed property in DT sources. For out-of-tree DTs? We
> don't care about those.
That's not true, we do care about implied ABI. Try changing/breaking
this later, when users complain their out of tree DTS is affected, and
explaining this all to Greg.

Rob was/is working on tools checking this for such implied ABI, I think.
For of_xxx() calls it is obvious, for device_xxx() or fwnode_xxx() it is
not, therefore please add a comment that this is not allowed to be used
by Devicetree platforms (or that this is only for
ACPI/platform_data/whatever). I don't have any other guideline/solution
other than a comment.

Best regards,
Krzysztof

^ permalink raw reply	[flat|nested] 24+ messages in thread

* Re: [PATCH RFT 2/6] gpio: mmio: get chip label and GPIO base from device properties
  2025-06-25  8:53       ` Krzysztof Kozlowski
@ 2025-06-25 10:23         ` Bartosz Golaszewski
  2025-06-25 10:26           ` Krzysztof Kozlowski
  0 siblings, 1 reply; 24+ messages in thread
From: Bartosz Golaszewski @ 2025-06-25 10:23 UTC (permalink / raw)
  To: Krzysztof Kozlowski
  Cc: Bartosz Golaszewski, Linus Walleij, Lee Jones, Liviu Dudau,
	Sudeep Holla, Lorenzo Pieralisi, Aaro Koskinen,
	Janusz Krzysztofik, Tony Lindgren, Russell King, Alim Akhtar,
	linux-gpio, linux-kernel, linux-arm-kernel, linux-omap, patches,
	linux-samsung-soc

On Wed, Jun 25, 2025 at 10:54 AM Krzysztof Kozlowski <krzk@kernel.org> wrote:
>
> On 25/06/2025 09:35, Bartosz Golaszewski wrote:
> > On Tue, 24 Jun 2025 at 21:44, Linus Walleij <linus.walleij@linaro.org> wrote:
> >>
> >> On Tue, Jun 24, 2025 at 3:19 PM Bartosz Golaszewski <brgl@bgdev.pl> wrote:
> >>
> >>> From: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
> >>>
> >>> Ahead of removing struct bgpio_pdata support from the gpio-mmio generic
> >>> module, let's add support for getting the relevant values from generic
> >>> device properties. "label" is a semi-standardized property in some GPIO
> >>> drivers so let's go with it. There's no standard "base" property, so
> >>> let's use the name "gpio-mmio,base" to tie it to this driver
> >>> specifically. The number of GPIOs will be retrieved using
> >>> gpiochip_get_ngpios() so there's no need to look it up in the software
> >>> node.
> >>>
> >>> Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
> >>
> >> This works for me.
> >> I wouldn't be stoked to see device trees abusing the "gpio-mmio,base"
> >> property all of a sudden just because it now exists as a device
> >> property though... I kind of wish we had a way to opt out of exposing
> >> this to all the sub-property paths. But it seems tiresome, so:
> >>
> >> Reviewed-by: Linus Walleij <linus.walleij@linaro.org>
> >>
> >> Yours,
> >> Linus Walleij
> >
> > That's not a problem - this property is not in any DT bindings and as
> > such is not an allowed property in DT sources. For out-of-tree DTs? We
> > don't care about those.
> That's not true, we do care about implied ABI. Try changing/breaking
> this later, when users complain their out of tree DTS is affected, and
> explaining this all to Greg.
>

Wait, seriously? I thought that the upstream bindings are the source
of truth for device-tree sources...

> Rob was/is working on tools checking this for such implied ABI, I think.
> For of_xxx() calls it is obvious, for device_xxx() or fwnode_xxx() it is
> not, therefore please add a comment that this is not allowed to be used
> by Devicetree platforms (or that this is only for
> ACPI/platform_data/whatever). I don't have any other guideline/solution
> other than a comment.
>

Ok.

Bart

^ permalink raw reply	[flat|nested] 24+ messages in thread

* Re: [PATCH RFT 2/6] gpio: mmio: get chip label and GPIO base from device properties
  2025-06-25 10:23         ` Bartosz Golaszewski
@ 2025-06-25 10:26           ` Krzysztof Kozlowski
  2025-06-25 10:28             ` Bartosz Golaszewski
  0 siblings, 1 reply; 24+ messages in thread
From: Krzysztof Kozlowski @ 2025-06-25 10:26 UTC (permalink / raw)
  To: Bartosz Golaszewski
  Cc: Bartosz Golaszewski, Linus Walleij, Lee Jones, Liviu Dudau,
	Sudeep Holla, Lorenzo Pieralisi, Aaro Koskinen,
	Janusz Krzysztofik, Tony Lindgren, Russell King, Alim Akhtar,
	linux-gpio, linux-kernel, linux-arm-kernel, linux-omap, patches,
	linux-samsung-soc

On 25/06/2025 12:23, Bartosz Golaszewski wrote:
> On Wed, Jun 25, 2025 at 10:54 AM Krzysztof Kozlowski <krzk@kernel.org> wrote:
>>
>> On 25/06/2025 09:35, Bartosz Golaszewski wrote:
>>> On Tue, 24 Jun 2025 at 21:44, Linus Walleij <linus.walleij@linaro.org> wrote:
>>>>
>>>> On Tue, Jun 24, 2025 at 3:19 PM Bartosz Golaszewski <brgl@bgdev.pl> wrote:
>>>>
>>>>> From: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
>>>>>
>>>>> Ahead of removing struct bgpio_pdata support from the gpio-mmio generic
>>>>> module, let's add support for getting the relevant values from generic
>>>>> device properties. "label" is a semi-standardized property in some GPIO
>>>>> drivers so let's go with it. There's no standard "base" property, so
>>>>> let's use the name "gpio-mmio,base" to tie it to this driver
>>>>> specifically. The number of GPIOs will be retrieved using
>>>>> gpiochip_get_ngpios() so there's no need to look it up in the software
>>>>> node.
>>>>>
>>>>> Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
>>>>
>>>> This works for me.
>>>> I wouldn't be stoked to see device trees abusing the "gpio-mmio,base"
>>>> property all of a sudden just because it now exists as a device
>>>> property though... I kind of wish we had a way to opt out of exposing
>>>> this to all the sub-property paths. But it seems tiresome, so:
>>>>
>>>> Reviewed-by: Linus Walleij <linus.walleij@linaro.org>
>>>>
>>>> Yours,
>>>> Linus Walleij
>>>
>>> That's not a problem - this property is not in any DT bindings and as
>>> such is not an allowed property in DT sources. For out-of-tree DTs? We
>>> don't care about those.
>> That's not true, we do care about implied ABI. Try changing/breaking
>> this later, when users complain their out of tree DTS is affected, and
>> explaining this all to Greg.
>>
> 
> Wait, seriously? I thought that the upstream bindings are the source
> of truth for device-tree sources...


They are, until they are not... ok, we don't really care that much about
out of tree DTS, but in-tree DTS still could use these and don't care
about bindings check, right?

Best regards,
Krzysztof

^ permalink raw reply	[flat|nested] 24+ messages in thread

* Re: [PATCH RFT 2/6] gpio: mmio: get chip label and GPIO base from device properties
  2025-06-25 10:26           ` Krzysztof Kozlowski
@ 2025-06-25 10:28             ` Bartosz Golaszewski
  2025-06-25 10:42               ` Krzysztof Kozlowski
  0 siblings, 1 reply; 24+ messages in thread
From: Bartosz Golaszewski @ 2025-06-25 10:28 UTC (permalink / raw)
  To: Krzysztof Kozlowski
  Cc: Bartosz Golaszewski, Linus Walleij, Lee Jones, Liviu Dudau,
	Sudeep Holla, Lorenzo Pieralisi, Aaro Koskinen,
	Janusz Krzysztofik, Tony Lindgren, Russell King, Alim Akhtar,
	linux-gpio, linux-kernel, linux-arm-kernel, linux-omap, patches,
	linux-samsung-soc

On Wed, Jun 25, 2025 at 12:26 PM Krzysztof Kozlowski <krzk@kernel.org> wrote:
>
> >>>> I wouldn't be stoked to see device trees abusing the "gpio-mmio,base"
> >>>> property all of a sudden just because it now exists as a device
> >>>> property though... I kind of wish we had a way to opt out of exposing
> >>>> this to all the sub-property paths. But it seems tiresome, so:
> >>>>
> >>>> Reviewed-by: Linus Walleij <linus.walleij@linaro.org>
> >>>>
> >>>> Yours,
> >>>> Linus Walleij
> >>>
> >>> That's not a problem - this property is not in any DT bindings and as
> >>> such is not an allowed property in DT sources. For out-of-tree DTs? We
> >>> don't care about those.
> >> That's not true, we do care about implied ABI. Try changing/breaking
> >> this later, when users complain their out of tree DTS is affected, and
> >> explaining this all to Greg.
> >>
> >
> > Wait, seriously? I thought that the upstream bindings are the source
> > of truth for device-tree sources...
>
>
> They are, until they are not... ok, we don't really care that much about
> out of tree DTS, but in-tree DTS still could use these and don't care
> about bindings check, right?
>

Could they though? I can imagine this happening by accident but in
general: you'd expect new sources to follow the bindings and be
verifiable against them? Otherwise, what's the point of the schema?

Bart

^ permalink raw reply	[flat|nested] 24+ messages in thread

* Re: [PATCH RFT 2/6] gpio: mmio: get chip label and GPIO base from device properties
  2025-06-25 10:28             ` Bartosz Golaszewski
@ 2025-06-25 10:42               ` Krzysztof Kozlowski
  0 siblings, 0 replies; 24+ messages in thread
From: Krzysztof Kozlowski @ 2025-06-25 10:42 UTC (permalink / raw)
  To: Bartosz Golaszewski
  Cc: Bartosz Golaszewski, Linus Walleij, Lee Jones, Liviu Dudau,
	Sudeep Holla, Lorenzo Pieralisi, Aaro Koskinen,
	Janusz Krzysztofik, Tony Lindgren, Russell King, Alim Akhtar,
	linux-gpio, linux-kernel, linux-arm-kernel, linux-omap, patches,
	linux-samsung-soc

On 25/06/2025 12:28, Bartosz Golaszewski wrote:
> On Wed, Jun 25, 2025 at 12:26 PM Krzysztof Kozlowski <krzk@kernel.org> wrote:
>>
>>>>>> I wouldn't be stoked to see device trees abusing the "gpio-mmio,base"
>>>>>> property all of a sudden just because it now exists as a device
>>>>>> property though... I kind of wish we had a way to opt out of exposing
>>>>>> this to all the sub-property paths. But it seems tiresome, so:
>>>>>>
>>>>>> Reviewed-by: Linus Walleij <linus.walleij@linaro.org>
>>>>>>
>>>>>> Yours,
>>>>>> Linus Walleij
>>>>>
>>>>> That's not a problem - this property is not in any DT bindings and as
>>>>> such is not an allowed property in DT sources. For out-of-tree DTs? We
>>>>> don't care about those.
>>>> That's not true, we do care about implied ABI. Try changing/breaking
>>>> this later, when users complain their out of tree DTS is affected, and
>>>> explaining this all to Greg.
>>>>
>>>
>>> Wait, seriously? I thought that the upstream bindings are the source
>>> of truth for device-tree sources...
>>
>>
>> They are, until they are not... ok, we don't really care that much about
>> out of tree DTS, but in-tree DTS still could use these and don't care
>> about bindings check, right?
>>
> 
> Could they though? I can imagine this happening by accident but in
> general: you'd expect new sources to follow the bindings and be

Yes, that is what I would expect.

> verifiable against them? Otherwise, what's the point of the schema?

Of course, but do you really think most SoC maintainers even run
dtbs_check on their existing or new code?

I think some maintainers pay attention, but RISC-V and my tree are the
only ones actually actively checking this for existing and new code.
Except me, no other maintainer even referenced maintainer-soc-clean-dts
profile.

I can easily imagine DTS with warnings and undocumented ABI gets merged
and then released in some kernel. And when you release such kernel in
v6.17 with DTS and drivers, isn't this already an implied ABI?

Best regards,
Krzysztof

^ permalink raw reply	[flat|nested] 24+ messages in thread

* Re: [PATCH RFT 3/6] mfd: vexpress-sysreg: set-up software nodes for gpio-mmio
  2025-06-24 13:19 ` [PATCH RFT 3/6] mfd: vexpress-sysreg: set-up software nodes for gpio-mmio Bartosz Golaszewski
  2025-06-24 19:45   ` Linus Walleij
@ 2025-06-26 13:22   ` Lee Jones
  2025-06-26 13:25     ` Bartosz Golaszewski
  2025-06-26 22:20   ` Liviu Dudau
  2 siblings, 1 reply; 24+ messages in thread
From: Lee Jones @ 2025-06-26 13:22 UTC (permalink / raw)
  To: Bartosz Golaszewski
  Cc: Linus Walleij, Liviu Dudau, Sudeep Holla, Lorenzo Pieralisi,
	Aaro Koskinen, Janusz Krzysztofik, Tony Lindgren, Russell King,
	Krzysztof Kozlowski, Alim Akhtar, linux-gpio, linux-kernel,
	linux-arm-kernel, linux-omap, patches, linux-samsung-soc,
	Bartosz Golaszewski

On Tue, 24 Jun 2025, Bartosz Golaszewski wrote:

> From: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
> 
> Replace struct bgpio_pdata - that we plan to remove - with software
> nodes containing properties encoding the same values thatr can now be

Spelling.

> parsed by gpio-mmio.
> 
> Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
> ---
>  drivers/mfd/vexpress-sysreg.c | 46 ++++++++++++++++++++++++++-----------------
>  1 file changed, 28 insertions(+), 18 deletions(-)

Can this go in on its own, or does it have depend{encies,ants}?

-- 
Lee Jones [李琼斯]

^ permalink raw reply	[flat|nested] 24+ messages in thread

* Re: [PATCH RFT 3/6] mfd: vexpress-sysreg: set-up software nodes for gpio-mmio
  2025-06-26 13:22   ` Lee Jones
@ 2025-06-26 13:25     ` Bartosz Golaszewski
  2025-06-27 12:55       ` Lee Jones
  0 siblings, 1 reply; 24+ messages in thread
From: Bartosz Golaszewski @ 2025-06-26 13:25 UTC (permalink / raw)
  To: Lee Jones
  Cc: Linus Walleij, Liviu Dudau, Sudeep Holla, Lorenzo Pieralisi,
	Aaro Koskinen, Janusz Krzysztofik, Tony Lindgren, Russell King,
	Krzysztof Kozlowski, Alim Akhtar, linux-gpio, linux-kernel,
	linux-arm-kernel, linux-omap, patches, linux-samsung-soc,
	Bartosz Golaszewski

On Thu, Jun 26, 2025 at 3:23 PM Lee Jones <lee@kernel.org> wrote:
>
> On Tue, 24 Jun 2025, Bartosz Golaszewski wrote:
>
> > From: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
> >
> > Replace struct bgpio_pdata - that we plan to remove - with software
> > nodes containing properties encoding the same values thatr can now be
>
> Spelling.
>
> > parsed by gpio-mmio.
> >
> > Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
> > ---
> >  drivers/mfd/vexpress-sysreg.c | 46 ++++++++++++++++++++++++++-----------------
> >  1 file changed, 28 insertions(+), 18 deletions(-)
>
> Can this go in on its own, or does it have depend{encies,ants}?

It will break the MFD GPIO sub-driver without patch 1/6 from this
series. It would be best if you could Ack it and I can set up an
immutable branch for v6.17 if you need it.

Bartosz

^ permalink raw reply	[flat|nested] 24+ messages in thread

* Re: [PATCH RFT 5/6] ARM: s3c: crag6410: use generic device properties for gpio-mmio
  2025-06-24 13:19 ` [PATCH RFT 5/6] ARM: s3c: crag6410: " Bartosz Golaszewski
  2025-06-24 16:33   ` Charles Keepax
  2025-06-24 19:46   ` Linus Walleij
@ 2025-06-26 19:51   ` Krzysztof Kozlowski
  2 siblings, 0 replies; 24+ messages in thread
From: Krzysztof Kozlowski @ 2025-06-26 19:51 UTC (permalink / raw)
  To: Bartosz Golaszewski, Linus Walleij, Lee Jones, Liviu Dudau,
	Sudeep Holla, Lorenzo Pieralisi, Aaro Koskinen,
	Janusz Krzysztofik, Tony Lindgren, Russell King, Alim Akhtar
  Cc: linux-gpio, linux-kernel, linux-arm-kernel, linux-omap, patches,
	linux-samsung-soc, Bartosz Golaszewski

On 24/06/2025 15:19, Bartosz Golaszewski wrote:
> From: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
> 
> The GPIO device in crag6410 is registered with struct bgpio_pdata passed
> as platform_data to the gpio-mmio driver. We want to remove the
> bgpio_pdata from the kernel and the gpio-mmio driver is now also able to
> get the relevant values from the software node. Set up device properties
> and switch to using platform_device_info to register the device as
> platform_add_devices() doesn't allow us to pass device properties to the
> driver model.
> 
> Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>

Acked-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>

Best regards,
Krzysztof

^ permalink raw reply	[flat|nested] 24+ messages in thread

* Re: [PATCH RFT 3/6] mfd: vexpress-sysreg: set-up software nodes for gpio-mmio
  2025-06-24 13:19 ` [PATCH RFT 3/6] mfd: vexpress-sysreg: set-up software nodes for gpio-mmio Bartosz Golaszewski
  2025-06-24 19:45   ` Linus Walleij
  2025-06-26 13:22   ` Lee Jones
@ 2025-06-26 22:20   ` Liviu Dudau
  2 siblings, 0 replies; 24+ messages in thread
From: Liviu Dudau @ 2025-06-26 22:20 UTC (permalink / raw)
  To: Bartosz Golaszewski
  Cc: Linus Walleij, Lee Jones, Sudeep Holla, Lorenzo Pieralisi,
	Aaro Koskinen, Janusz Krzysztofik, Tony Lindgren, Russell King,
	Krzysztof Kozlowski, Alim Akhtar, linux-gpio, linux-kernel,
	linux-arm-kernel, linux-omap, patches, linux-samsung-soc,
	Bartosz Golaszewski

On Tue, Jun 24, 2025 at 03:19:14PM +0200, Bartosz Golaszewski wrote:
> From: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
> 
> Replace struct bgpio_pdata - that we plan to remove - with software
> nodes containing properties encoding the same values thatr can now be
> parsed by gpio-mmio.
> 
> Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>

Reviewed-by: Liviu Dudau <liviu.dudau@arm.com>

I'm OK with this going through the GPIO tree.

Best regards,
Liviu

> ---
>  drivers/mfd/vexpress-sysreg.c | 46 ++++++++++++++++++++++++++-----------------
>  1 file changed, 28 insertions(+), 18 deletions(-)
> 
> diff --git a/drivers/mfd/vexpress-sysreg.c b/drivers/mfd/vexpress-sysreg.c
> index ef03d6cec9ff6927668d051ca459eb1d8ff7269e..fc2daffc4352cca763cefbf6e17bdd5242290198 100644
> --- a/drivers/mfd/vexpress-sysreg.c
> +++ b/drivers/mfd/vexpress-sysreg.c
> @@ -11,6 +11,7 @@
>  #include <linux/module.h>
>  #include <linux/of_platform.h>
>  #include <linux/platform_device.h>
> +#include <linux/property.h>
>  #include <linux/slab.h>
>  #include <linux/stat.h>
>  
> @@ -37,22 +38,34 @@
>  
>  /* The sysreg block is just a random collection of various functions... */
>  
> -static struct bgpio_pdata vexpress_sysreg_sys_led_pdata = {
> -	.label = "sys_led",
> -	.base = -1,
> -	.ngpio = 8,
> +static const struct property_entry vexpress_sysreg_sys_led_props[] = {
> +	PROPERTY_ENTRY_STRING("label", "sys_led"),
> +	PROPERTY_ENTRY_U32("ngpios", 8),
> +	{ }
>  };
>  
> -static struct bgpio_pdata vexpress_sysreg_sys_mci_pdata = {
> -	.label = "sys_mci",
> -	.base = -1,
> -	.ngpio = 2,
> +static const struct software_node vexpress_sysreg_sys_led_swnode = {
> +	.properties = vexpress_sysreg_sys_led_props,
>  };
>  
> -static struct bgpio_pdata vexpress_sysreg_sys_flash_pdata = {
> -	.label = "sys_flash",
> -	.base = -1,
> -	.ngpio = 1,
> +static const struct property_entry vexpress_sysreg_sys_mci_props[] = {
> +	PROPERTY_ENTRY_STRING("label", "sys_mci"),
> +	PROPERTY_ENTRY_U32("ngpios", 2),
> +	{ }
> +};
> +
> +static const struct software_node vexpress_sysreg_sys_mci_swnode = {
> +	.properties = vexpress_sysreg_sys_mci_props,
> +};
> +
> +static const struct property_entry vexpress_sysreg_sys_flash_props[] = {
> +	PROPERTY_ENTRY_STRING("label", "sys_flash"),
> +	PROPERTY_ENTRY_U32("ngpios", 1),
> +	{ }
> +};
> +
> +static const struct software_node vexpress_sysreg_sys_flash_swnode = {
> +	.properties = vexpress_sysreg_sys_flash_props,
>  };
>  
>  static struct mfd_cell vexpress_sysreg_cells[] = {
> @@ -61,22 +74,19 @@ static struct mfd_cell vexpress_sysreg_cells[] = {
>  		.of_compatible = "arm,vexpress-sysreg,sys_led",
>  		.num_resources = 1,
>  		.resources = &DEFINE_RES_MEM_NAMED(SYS_LED, 0x4, "dat"),
> -		.platform_data = &vexpress_sysreg_sys_led_pdata,
> -		.pdata_size = sizeof(vexpress_sysreg_sys_led_pdata),
> +		.swnode = &vexpress_sysreg_sys_led_swnode,
>  	}, {
>  		.name = "basic-mmio-gpio",
>  		.of_compatible = "arm,vexpress-sysreg,sys_mci",
>  		.num_resources = 1,
>  		.resources = &DEFINE_RES_MEM_NAMED(SYS_MCI, 0x4, "dat"),
> -		.platform_data = &vexpress_sysreg_sys_mci_pdata,
> -		.pdata_size = sizeof(vexpress_sysreg_sys_mci_pdata),
> +		.swnode = &vexpress_sysreg_sys_mci_swnode,
>  	}, {
>  		.name = "basic-mmio-gpio",
>  		.of_compatible = "arm,vexpress-sysreg,sys_flash",
>  		.num_resources = 1,
>  		.resources = &DEFINE_RES_MEM_NAMED(SYS_FLASH, 0x4, "dat"),
> -		.platform_data = &vexpress_sysreg_sys_flash_pdata,
> -		.pdata_size = sizeof(vexpress_sysreg_sys_flash_pdata),
> +		.swnode = &vexpress_sysreg_sys_flash_swnode,
>  	}, {
>  		.name = "vexpress-syscfg",
>  		.num_resources = 1,
> 
> -- 
> 2.48.1
> 

-- 
====================
| I would like to |
| fix the world,  |
| but they're not |
| giving me the   |
 \ source code!  /
  ---------------
    ¯\_(ツ)_/¯

^ permalink raw reply	[flat|nested] 24+ messages in thread

* Re: [PATCH RFT 3/6] mfd: vexpress-sysreg: set-up software nodes for gpio-mmio
  2025-06-26 13:25     ` Bartosz Golaszewski
@ 2025-06-27 12:55       ` Lee Jones
  0 siblings, 0 replies; 24+ messages in thread
From: Lee Jones @ 2025-06-27 12:55 UTC (permalink / raw)
  To: Bartosz Golaszewski
  Cc: Linus Walleij, Liviu Dudau, Sudeep Holla, Lorenzo Pieralisi,
	Aaro Koskinen, Janusz Krzysztofik, Tony Lindgren, Russell King,
	Krzysztof Kozlowski, Alim Akhtar, linux-gpio, linux-kernel,
	linux-arm-kernel, linux-omap, patches, linux-samsung-soc,
	Bartosz Golaszewski

On Thu, 26 Jun 2025, Bartosz Golaszewski wrote:

> On Thu, Jun 26, 2025 at 3:23 PM Lee Jones <lee@kernel.org> wrote:
> >
> > On Tue, 24 Jun 2025, Bartosz Golaszewski wrote:
> >
> > > From: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
> > >
> > > Replace struct bgpio_pdata - that we plan to remove - with software
> > > nodes containing properties encoding the same values thatr can now be
> >
> > Spelling.
> >
> > > parsed by gpio-mmio.
> > >
> > > Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
> > > ---
> > >  drivers/mfd/vexpress-sysreg.c | 46 ++++++++++++++++++++++++++-----------------
> > >  1 file changed, 28 insertions(+), 18 deletions(-)
> >
> > Can this go in on its own, or does it have depend{encies,ants}?
> 
> It will break the MFD GPIO sub-driver without patch 1/6 from this
> series. It would be best if you could Ack it and I can set up an
> immutable branch for v6.17 if you need it.

Yes please.

Acked-by: Lee Jones <lee@kernel.org>

-- 
Lee Jones [李琼斯]

^ permalink raw reply	[flat|nested] 24+ messages in thread

end of thread, other threads:[~2025-06-27 12:55 UTC | newest]

Thread overview: 24+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-06-24 13:19 [PATCH RFT 0/6] gpio: mmio: remove struct bgpio_pdata Bartosz Golaszewski
2025-06-24 13:19 ` [PATCH RFT 1/6] gpio: mmio: drop the big-endian platform device variant Bartosz Golaszewski
2025-06-24 19:41   ` Linus Walleij
2025-06-24 13:19 ` [PATCH RFT 2/6] gpio: mmio: get chip label and GPIO base from device properties Bartosz Golaszewski
2025-06-24 19:43   ` Linus Walleij
2025-06-25  7:35     ` Bartosz Golaszewski
2025-06-25  8:53       ` Krzysztof Kozlowski
2025-06-25 10:23         ` Bartosz Golaszewski
2025-06-25 10:26           ` Krzysztof Kozlowski
2025-06-25 10:28             ` Bartosz Golaszewski
2025-06-25 10:42               ` Krzysztof Kozlowski
2025-06-24 13:19 ` [PATCH RFT 3/6] mfd: vexpress-sysreg: set-up software nodes for gpio-mmio Bartosz Golaszewski
2025-06-24 19:45   ` Linus Walleij
2025-06-26 13:22   ` Lee Jones
2025-06-26 13:25     ` Bartosz Golaszewski
2025-06-27 12:55       ` Lee Jones
2025-06-26 22:20   ` Liviu Dudau
2025-06-24 13:19 ` [PATCH RFT 4/6] ARM: omap1: ams-delta: use generic device properties " Bartosz Golaszewski
2025-06-24 19:45   ` Linus Walleij
2025-06-24 13:19 ` [PATCH RFT 5/6] ARM: s3c: crag6410: " Bartosz Golaszewski
2025-06-24 16:33   ` Charles Keepax
2025-06-24 19:46   ` Linus Walleij
2025-06-26 19:51   ` Krzysztof Kozlowski
2025-06-24 13:19 ` [PATCH RFT 6/6] gpio: mmio: remove struct bgpio_pdata Bartosz Golaszewski

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).