All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 0/3] stmpe module support
@ 2025-07-25  7:11 Alexander Stein
  2025-07-25  7:11 ` [PATCH 1/3] mfd: stmpe-spi: Add missing MODULE_LICENSE Alexander Stein
                   ` (3 more replies)
  0 siblings, 4 replies; 6+ messages in thread
From: Alexander Stein @ 2025-07-25  7:11 UTC (permalink / raw)
  To: Lee Jones, Maxime Coquelin, Alexandre Torgue
  Cc: Alexander Stein, linux-kernel, linux-stm32, linux-arm-kernel

Hi there,

this series adds support for building stmpe mfd driver as a module along with
the bus driver for i2c and spi. This depends on the cleanup series [1]
just for avoiding conflicts.
I'm not sure in which order module support should be added, maybe even all at
once. Please advice if necessary.

Best regards,
Alexander

[1] https://lore.kernel.org/all/20250725070752.338376-1-alexander.stein@ew.tq-group.com/

Alexander Stein (3):
  mfd: stmpe-spi: Add missing MODULE_LICENSE
  mfd: stmpe-i2c: Add missing MODULE_LICENSE
  mfd: stmpe: Allow building as module

 drivers/mfd/Kconfig     | 10 +++++-----
 drivers/mfd/stmpe-i2c.c |  1 +
 drivers/mfd/stmpe-spi.c |  1 +
 drivers/mfd/stmpe.c     |  6 ++++++
 4 files changed, 13 insertions(+), 5 deletions(-)

-- 
2.43.0



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

* [PATCH 1/3] mfd: stmpe-spi: Add missing MODULE_LICENSE
  2025-07-25  7:11 [PATCH 0/3] stmpe module support Alexander Stein
@ 2025-07-25  7:11 ` Alexander Stein
  2025-07-25  7:11 ` [PATCH 2/3] mfd: stmpe-i2c: " Alexander Stein
                   ` (2 subsequent siblings)
  3 siblings, 0 replies; 6+ messages in thread
From: Alexander Stein @ 2025-07-25  7:11 UTC (permalink / raw)
  To: Lee Jones, Maxime Coquelin, Alexandre Torgue
  Cc: Alexander Stein, linux-kernel, linux-stm32, linux-arm-kernel

This driver is licensed GPL-2.0-only, so add the corresponding module flag.

Signed-off-by: Alexander Stein <alexander.stein@ew.tq-group.com>
---
 drivers/mfd/stmpe-spi.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/mfd/stmpe-spi.c b/drivers/mfd/stmpe-spi.c
index 7fee64102cae7..dea31efface6e 100644
--- a/drivers/mfd/stmpe-spi.c
+++ b/drivers/mfd/stmpe-spi.c
@@ -145,3 +145,4 @@ module_spi_driver(stmpe_spi_driver);
 
 MODULE_DESCRIPTION("STMPE MFD SPI Interface Driver");
 MODULE_AUTHOR("Viresh Kumar <vireshk@kernel.org>");
+MODULE_LICENSE("GPL");
-- 
2.43.0



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

* [PATCH 2/3] mfd: stmpe-i2c: Add missing MODULE_LICENSE
  2025-07-25  7:11 [PATCH 0/3] stmpe module support Alexander Stein
  2025-07-25  7:11 ` [PATCH 1/3] mfd: stmpe-spi: Add missing MODULE_LICENSE Alexander Stein
@ 2025-07-25  7:11 ` Alexander Stein
  2025-07-25  7:11 ` [PATCH 3/3] mfd: stmpe: Allow building as module Alexander Stein
  2025-07-31 11:09 ` (subset) [PATCH 0/3] stmpe module support Lee Jones
  3 siblings, 0 replies; 6+ messages in thread
From: Alexander Stein @ 2025-07-25  7:11 UTC (permalink / raw)
  To: Lee Jones, Maxime Coquelin, Alexandre Torgue
  Cc: Alexander Stein, linux-kernel, linux-stm32, linux-arm-kernel

This driver is licensed GPL-2.0-only, so add the corresponding module flag.

Signed-off-by: Alexander Stein <alexander.stein@ew.tq-group.com>
---
 drivers/mfd/stmpe-i2c.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/mfd/stmpe-i2c.c b/drivers/mfd/stmpe-i2c.c
index 145836320c170..943fa363efc35 100644
--- a/drivers/mfd/stmpe-i2c.c
+++ b/drivers/mfd/stmpe-i2c.c
@@ -126,3 +126,4 @@ module_i2c_driver(stmpe_i2c_driver);
 
 MODULE_DESCRIPTION("STMPE MFD I2C Interface Driver");
 MODULE_AUTHOR("Rabin Vincent <rabin.vincent@stericsson.com>");
+MODULE_LICENSE("GPL");
-- 
2.43.0



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

* [PATCH 3/3] mfd: stmpe: Allow building as module
  2025-07-25  7:11 [PATCH 0/3] stmpe module support Alexander Stein
  2025-07-25  7:11 ` [PATCH 1/3] mfd: stmpe-spi: Add missing MODULE_LICENSE Alexander Stein
  2025-07-25  7:11 ` [PATCH 2/3] mfd: stmpe-i2c: " Alexander Stein
@ 2025-07-25  7:11 ` Alexander Stein
  2025-07-31 11:09   ` Lee Jones
  2025-07-31 11:09 ` (subset) [PATCH 0/3] stmpe module support Lee Jones
  3 siblings, 1 reply; 6+ messages in thread
From: Alexander Stein @ 2025-07-25  7:11 UTC (permalink / raw)
  To: Lee Jones, Maxime Coquelin, Alexandre Torgue
  Cc: Alexander Stein, linux-kernel, linux-stm32, linux-arm-kernel

Export the core probe and remove function to be used by modules. Add
necessary module information so the driver can be built as a module.

Signed-off-by: Alexander Stein <alexander.stein@ew.tq-group.com>
---
 drivers/mfd/Kconfig | 10 +++++-----
 drivers/mfd/stmpe.c |  6 ++++++
 2 files changed, 11 insertions(+), 5 deletions(-)

diff --git a/drivers/mfd/Kconfig b/drivers/mfd/Kconfig
index 8f11b2df14704..a58c95e5b8072 100644
--- a/drivers/mfd/Kconfig
+++ b/drivers/mfd/Kconfig
@@ -1539,8 +1539,8 @@ config MFD_DB8500_PRCMU
 	  through a register map.
 
 config MFD_STMPE
-	bool "STMicroelectronics STMPE"
-	depends on I2C=y || SPI_MASTER=y
+	tristate "STMicroelectronics STMPE"
+	depends on I2C || SPI_MASTER
 	depends on OF
 	select MFD_CORE
 	help
@@ -1568,14 +1568,14 @@ menu "STMicroelectronics STMPE Interface Drivers"
 depends on MFD_STMPE
 
 config STMPE_I2C
-	bool "STMicroelectronics STMPE I2C Interface"
-	depends on I2C=y
+	tristate "STMicroelectronics STMPE I2C Interface"
+	depends on I2C
 	default y
 	help
 	  This is used to enable I2C interface of STMPE
 
 config STMPE_SPI
-	bool "STMicroelectronics STMPE SPI Interface"
+	tristate "STMicroelectronics STMPE SPI Interface"
 	depends on SPI_MASTER
 	help
 	  This is used to enable SPI interface of STMPE
diff --git a/drivers/mfd/stmpe.c b/drivers/mfd/stmpe.c
index e1165f63aedae..5faf13fd6cf83 100644
--- a/drivers/mfd/stmpe.c
+++ b/drivers/mfd/stmpe.c
@@ -1482,6 +1482,7 @@ int stmpe_probe(struct stmpe_client_info *ci, enum stmpe_partnum partnum)
 
 	return ret;
 }
+EXPORT_SYMBOL_GPL(stmpe_probe);
 
 void stmpe_remove(struct stmpe *stmpe)
 {
@@ -1497,6 +1498,7 @@ void stmpe_remove(struct stmpe *stmpe)
 
 	mfd_remove_devices(stmpe->dev);
 }
+EXPORT_SYMBOL_GPL(stmpe_remove);
 
 static int stmpe_suspend(struct device *dev)
 {
@@ -1520,3 +1522,7 @@ static int stmpe_resume(struct device *dev)
 
 EXPORT_GPL_SIMPLE_DEV_PM_OPS(stmpe_dev_pm_ops,
 			     stmpe_suspend, stmpe_resume);
+
+MODULE_DESCRIPTION("STMPE MFD Core driver");
+MODULE_AUTHOR("Rabin Vincent <rabin.vincent@stericsson.com>");
+MODULE_LICENSE("GPL");
-- 
2.43.0



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

* Re: [PATCH 3/3] mfd: stmpe: Allow building as module
  2025-07-25  7:11 ` [PATCH 3/3] mfd: stmpe: Allow building as module Alexander Stein
@ 2025-07-31 11:09   ` Lee Jones
  0 siblings, 0 replies; 6+ messages in thread
From: Lee Jones @ 2025-07-31 11:09 UTC (permalink / raw)
  To: Alexander Stein
  Cc: Maxime Coquelin, Alexandre Torgue, linux-kernel, linux-stm32,
	linux-arm-kernel

On Fri, 25 Jul 2025, Alexander Stein wrote:

> Export the core probe and remove function to be used by modules. Add
> necessary module information so the driver can be built as a module.

because ...

> Signed-off-by: Alexander Stein <alexander.stein@ew.tq-group.com>
> ---
>  drivers/mfd/Kconfig | 10 +++++-----
>  drivers/mfd/stmpe.c |  6 ++++++
>  2 files changed, 11 insertions(+), 5 deletions(-)
> 
> diff --git a/drivers/mfd/Kconfig b/drivers/mfd/Kconfig
> index 8f11b2df14704..a58c95e5b8072 100644
> --- a/drivers/mfd/Kconfig
> +++ b/drivers/mfd/Kconfig
> @@ -1539,8 +1539,8 @@ config MFD_DB8500_PRCMU
>  	  through a register map.
>  
>  config MFD_STMPE
> -	bool "STMicroelectronics STMPE"
> -	depends on I2C=y || SPI_MASTER=y
> +	tristate "STMicroelectronics STMPE"
> +	depends on I2C || SPI_MASTER
>  	depends on OF
>  	select MFD_CORE
>  	help
> @@ -1568,14 +1568,14 @@ menu "STMicroelectronics STMPE Interface Drivers"
>  depends on MFD_STMPE
>  
>  config STMPE_I2C
> -	bool "STMicroelectronics STMPE I2C Interface"
> -	depends on I2C=y
> +	tristate "STMicroelectronics STMPE I2C Interface"
> +	depends on I2C
>  	default y
>  	help
>  	  This is used to enable I2C interface of STMPE
>  
>  config STMPE_SPI
> -	bool "STMicroelectronics STMPE SPI Interface"
> +	tristate "STMicroelectronics STMPE SPI Interface"
>  	depends on SPI_MASTER
>  	help
>  	  This is used to enable SPI interface of STMPE
> diff --git a/drivers/mfd/stmpe.c b/drivers/mfd/stmpe.c
> index e1165f63aedae..5faf13fd6cf83 100644
> --- a/drivers/mfd/stmpe.c
> +++ b/drivers/mfd/stmpe.c
> @@ -1482,6 +1482,7 @@ int stmpe_probe(struct stmpe_client_info *ci, enum stmpe_partnum partnum)
>  
>  	return ret;
>  }
> +EXPORT_SYMBOL_GPL(stmpe_probe);
>  
>  void stmpe_remove(struct stmpe *stmpe)
>  {
> @@ -1497,6 +1498,7 @@ void stmpe_remove(struct stmpe *stmpe)
>  
>  	mfd_remove_devices(stmpe->dev);
>  }
> +EXPORT_SYMBOL_GPL(stmpe_remove);
>  
>  static int stmpe_suspend(struct device *dev)
>  {
> @@ -1520,3 +1522,7 @@ static int stmpe_resume(struct device *dev)
>  
>  EXPORT_GPL_SIMPLE_DEV_PM_OPS(stmpe_dev_pm_ops,
>  			     stmpe_suspend, stmpe_resume);
> +
> +MODULE_DESCRIPTION("STMPE MFD Core driver");

Drop the MFD part.

> +MODULE_AUTHOR("Rabin Vincent <rabin.vincent@stericsson.com>");
> +MODULE_LICENSE("GPL");
> -- 
> 2.43.0
> 

-- 
Lee Jones [李琼斯]


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

* Re: (subset) [PATCH 0/3] stmpe module support
  2025-07-25  7:11 [PATCH 0/3] stmpe module support Alexander Stein
                   ` (2 preceding siblings ...)
  2025-07-25  7:11 ` [PATCH 3/3] mfd: stmpe: Allow building as module Alexander Stein
@ 2025-07-31 11:09 ` Lee Jones
  3 siblings, 0 replies; 6+ messages in thread
From: Lee Jones @ 2025-07-31 11:09 UTC (permalink / raw)
  To: Lee Jones, Maxime Coquelin, Alexandre Torgue, Alexander Stein
  Cc: linux-kernel, linux-stm32, linux-arm-kernel

On Fri, 25 Jul 2025 09:11:48 +0200, Alexander Stein wrote:
> this series adds support for building stmpe mfd driver as a module along with
> the bus driver for i2c and spi. This depends on the cleanup series [1]
> just for avoiding conflicts.
> I'm not sure in which order module support should be added, maybe even all at
> once. Please advice if necessary.
> 
> Best regards,
> Alexander
> 
> [...]

Applied, thanks!

[1/3] mfd: stmpe-spi: Add missing MODULE_LICENSE
      commit: d73bccc362448001fa1d3973af69504811b710dc
[2/3] mfd: stmpe-i2c: Add missing MODULE_LICENSE
      commit: 0420aa9dead165d893547af51704a3676634b647

--
Lee Jones [李琼斯]


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

end of thread, other threads:[~2025-07-31 11:11 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-07-25  7:11 [PATCH 0/3] stmpe module support Alexander Stein
2025-07-25  7:11 ` [PATCH 1/3] mfd: stmpe-spi: Add missing MODULE_LICENSE Alexander Stein
2025-07-25  7:11 ` [PATCH 2/3] mfd: stmpe-i2c: " Alexander Stein
2025-07-25  7:11 ` [PATCH 3/3] mfd: stmpe: Allow building as module Alexander Stein
2025-07-31 11:09   ` Lee Jones
2025-07-31 11:09 ` (subset) [PATCH 0/3] stmpe module support Lee Jones

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.