Skip to contentSkip to conversation

regulator: lochnagar: Add missing MODULE_DEVICE_TABLE

PATCH In review Charles Keepax 2 participants 4 messages Jan 18, 2019 – Jan 21, 2019

Subsystems (2)
lore
Share & tools
lore

Charles Keepax

author maintainer
#0 lore raw

PATCH 1/2 regulator: lochnagar: Add missing MODULE_DEVICE_TABLE

Add the missing MODULE_DEVICE_TABLE and remove the comma from the separator on the end of the of_device_id array.

---
 drivers/regulator/lochnagar-regulator.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)
drivers/regulator/lochnagar-regulator.c +2 -1
index 818d204105186..4962d13659aab 100644
@@ -232,8 +232,9 @@ static const struct of_device_id lochnagar_of_match[] = {
 		.compatible = "cirrus,lochnagar2-vddcore",
 		.data = &lochnagar_regulators[LOCHNAGAR_VDDCORE],
 	},
-	{},
+	{}
 };
+MODULE_DEVICE_TABLE(of, lochnagar_of_match);
 
 static int lochnagar_regulator_probe(struct platform_device *pdev)
 {
Signature · 1 line
2.11.0
author maintainer
#1 lore raw

PATCH 2/2 regulator: lochnagar: Remove redundant MODULE_ALIAS

The module alias has no effect as the driver can only be loaded through device tree at this time.

---
 drivers/regulator/lochnagar-regulator.c | 1 -
 1 file changed, 1 deletion(-)
drivers/regulator/lochnagar-regulator.c +0 -1
index 4962d13659aab..41de3b715b4db 100644
@@ -280,4 +280,3 @@ module_platform_driver(lochnagar_regulator_driver);
 MODULE_AUTHOR("Charles Keepax <[email protected]>");
 MODULE_DESCRIPTION("Regulator driver for Cirrus Logic Lochnagar Board");
 MODULE_LICENSE("GPL v2");
-MODULE_ALIAS("platform:lochnagar-regulator");
Signature · 1 line
2.11.0
maintainer
#2 lore raw

Re: [PATCH 2/2] regulator: lochnagar: Remove redundant MODULE_ALIAS

Quoted 2 lines · Charles Keepax

The module alias has no effect as the driver can only be loaded through device tree at this time.

It also does no harm...

author maintainer
#3 lore raw

Re: [PATCH 2/2] regulator: lochnagar: Remove redundant MODULE_ALIAS

Quoted 5 lines · Mark Brown
Quoted 2 lines · Charles Keepax

The module alias has no effect as the driver can only be loaded through device tree at this time.

It also does no harm...

Indeed yes, I have no problem with leaving it.

Thanks,
Charles