[RESEND PATCH 0/4] i2c: Fix module autoload for OF platform drivers

STALE3982d

6 messages, 2 authors, 2015-10-20 · open the first message on its own page

[RESEND PATCH 0/4] i2c: Fix module autoload for OF platform drivers

From: Luis de Bethencourt <hidden>
Date: 2015-10-20 14:16:30

Hello,

This is a resend of this patch series. It was posted on September 17. [0]

These patches add the missing MODULE_DEVICE_TABLE() for OF to export
the information so modules have the correct aliases built-in and
autoloading works correctly.

A longer explanation by Javier Canillas can be found here:
https://lkml.org/lkml/2015/7/30/519

The 4th patch of the series is Acked-by Linus Walleij.

[0] https://lkml.org/lkml/2015/9/17/558
[1] https://lkml.org/lkml/2015/9/17/559
[2] https://lkml.org/lkml/2015/9/17/560
[3] https://lkml.org/lkml/2015/9/17/561
[4] https://lkml.org/lkml/2015/9/17/562

Thanks,
Luis

Luis de Bethencourt (4):
  i2c: ibm-iic: Fix module autoload for OF platform driver
  i2c: meson: Fix module autoload for OF platform driver
  i2c: rk3x: Fix module autoload for OF platform driver
  i2c: stu300: Fix module autoload for OF platform driver

 drivers/i2c/busses/i2c-ibm_iic.c | 1 +
 drivers/i2c/busses/i2c-meson.c   | 1 +
 drivers/i2c/busses/i2c-rk3x.c    | 1 +
 drivers/i2c/busses/i2c-stu300.c  | 1 +
 4 files changed, 4 insertions(+)

-- 
2.5.3

[RESEND PATCH 3/4] i2c: rk3x: Fix module autoload for OF platform driver

From: Luis de Bethencourt <hidden>
Date: 2015-10-20 14:16:38

From: Luis de Bethencourt <redacted>

This platform driver has a OF device ID table but the OF module
alias information is not created so module autoloading won't work.

Signed-off-by: Luis de Bethencourt <redacted>
---
 drivers/i2c/busses/i2c-rk3x.c | 1 +
 1 file changed, 1 insertion(+)
diff --git a/drivers/i2c/busses/i2c-rk3x.c b/drivers/i2c/busses/i2c-rk3x.c
index 72e97e30..c1935eb 100644
--- a/drivers/i2c/busses/i2c-rk3x.c
+++ b/drivers/i2c/busses/i2c-rk3x.c
@@ -858,6 +858,7 @@ static const struct of_device_id rk3x_i2c_match[] = {
 	{ .compatible = "rockchip,rk3288-i2c", .data = (void *)&soc_data[2] },
 	{},
 };
+MODULE_DEVICE_TABLE(of, rk3x_i2c_match);
 
 static int rk3x_i2c_probe(struct platform_device *pdev)
 {
-- 
2.5.3

[RESEND PATCH 2/4] i2c: meson: Fix module autoload for OF platform driver

From: Luis de Bethencourt <hidden>
Date: 2015-10-20 14:16:39

From: Luis de Bethencourt <redacted>

This platform driver has a OF device ID table but the OF module
alias information is not created so module autoloading won't work.

Signed-off-by: Luis de Bethencourt <redacted>
---
 drivers/i2c/busses/i2c-meson.c | 1 +
 1 file changed, 1 insertion(+)
diff --git a/drivers/i2c/busses/i2c-meson.c b/drivers/i2c/busses/i2c-meson.c
index 5e176ad..71d3929 100644
--- a/drivers/i2c/busses/i2c-meson.c
+++ b/drivers/i2c/busses/i2c-meson.c
@@ -475,6 +475,7 @@ static const struct of_device_id meson_i2c_match[] = {
 	{ .compatible = "amlogic,meson6-i2c" },
 	{ },
 };
+MODULE_DEVICE_TABLE(of, meson_i2c_match);
 
 static struct platform_driver meson_i2c_driver = {
 	.probe   = meson_i2c_probe,
-- 
2.5.3

[RESEND PATCH 4/4] i2c: stu300: Fix module autoload for OF platform driver

From: Luis de Bethencourt <hidden>
Date: 2015-10-20 14:17:05

From: Luis de Bethencourt <redacted>

This platform driver has a OF device ID table but the OF module
alias information is not created so module autoloading won't work.

Signed-off-by: Luis de Bethencourt <redacted>
Acked-by: Linus Walleij <redacted>
---
 drivers/i2c/busses/i2c-stu300.c | 1 +
 1 file changed, 1 insertion(+)
diff --git a/drivers/i2c/busses/i2c-stu300.c b/drivers/i2c/busses/i2c-stu300.c
index 4885da9..460c134 100644
--- a/drivers/i2c/busses/i2c-stu300.c
+++ b/drivers/i2c/busses/i2c-stu300.c
@@ -977,6 +977,7 @@ static const struct of_device_id stu300_dt_match[] = {
 	{ .compatible = "st,ddci2c" },
 	{},
 };
+MODULE_DEVICE_TABLE(of, stu300_dt_match);
 
 static struct platform_driver stu300_i2c_driver = {
 	.driver = {
-- 
2.5.3

[RESEND PATCH 1/4] i2c: ibm-iic: Fix module autoload for OF platform driver

From: Luis de Bethencourt <hidden>
Date: 2015-10-20 14:17:06

From: Luis de Bethencourt <redacted>

This platform driver has a OF device ID table but the OF module
alias information is not created so module autoloading won't work.

Signed-off-by: Luis de Bethencourt <redacted>
---
 drivers/i2c/busses/i2c-ibm_iic.c | 1 +
 1 file changed, 1 insertion(+)
diff --git a/drivers/i2c/busses/i2c-ibm_iic.c b/drivers/i2c/busses/i2c-ibm_iic.c
index 722f839..ab49230 100644
--- a/drivers/i2c/busses/i2c-ibm_iic.c
+++ b/drivers/i2c/busses/i2c-ibm_iic.c
@@ -798,6 +798,7 @@ static const struct of_device_id ibm_iic_match[] = {
 	{ .compatible = "ibm,iic", },
 	{}
 };
+MODULE_DEVICE_TABLE(of, ibm_iic_match);
 
 static struct platform_driver ibm_iic_driver = {
 	.driver = {
-- 
2.5.3

Re: [RESEND PATCH 0/4] i2c: Fix module autoload for OF platform drivers

From: Wolfram Sang <hidden>
Date: 2015-10-20 16:18:28

On Tue, Oct 20, 2015 at 03:16:26PM +0100, Luis de Bethencourt wrote:
Hello,

This is a resend of this patch series. It was posted on September 17. [0]

These patches add the missing MODULE_DEVICE_TABLE() for OF to export
the information so modules have the correct aliases built-in and
autoloading works correctly.

A longer explanation by Javier Canillas can be found here:
https://lkml.org/lkml/2015/7/30/519

The 4th patch of the series is Acked-by Linus Walleij.
Applied to for-next, thanks!

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: Digital signature
URL: <http://lists.infradead.org/pipermail/linux-arm-kernel/attachments/20151020/88299910/attachment.sig>
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help