* [PATCH] power: bq27x00_battery: Add missing MODULE_ALIAS
@ 2015-04-28 20:23 Marek Belisko
2015-04-30 15:55 ` Sebastian Reichel
2015-04-30 20:05 ` Marek Belisko
0 siblings, 2 replies; 4+ messages in thread
From: Marek Belisko @ 2015-04-28 20:23 UTC (permalink / raw)
To: sre, dbaryshkov, dwmw2; +Cc: linux-pm, linux-kernel, hns, Marek Belisko
Without MODULE_ALIAS bq27x00_battery module won't get loaded automatically.
Signed-off-by: Marek Belisko <marek@goldelico.com>
---
drivers/power/bq27x00_battery.c | 6 ++++++
1 file changed, 6 insertions(+)
diff --git a/drivers/power/bq27x00_battery.c b/drivers/power/bq27x00_battery.c
index a57433d..542927e 100644
--- a/drivers/power/bq27x00_battery.c
+++ b/drivers/power/bq27x00_battery.c
@@ -1109,6 +1109,12 @@ static void __exit bq27x00_battery_exit(void)
}
module_exit(bq27x00_battery_exit);
+#ifdef CONFIG_BATTERY_BQ27X00_PLATFORM
+MODULE_ALIAS("platform:bq27000-battery");
+#else
+MODULE_ALIAS("i2c:bq27000-battery");
+#endif
+
MODULE_AUTHOR("Rodolfo Giometti <giometti@linux.it>");
MODULE_DESCRIPTION("BQ27x00 battery monitor driver");
MODULE_LICENSE("GPL");
--
1.9.1
^ permalink raw reply related [flat|nested] 4+ messages in thread
* Re: [PATCH] power: bq27x00_battery: Add missing MODULE_ALIAS
2015-04-28 20:23 [PATCH] power: bq27x00_battery: Add missing MODULE_ALIAS Marek Belisko
@ 2015-04-30 15:55 ` Sebastian Reichel
2015-04-30 20:05 ` Marek Belisko
1 sibling, 0 replies; 4+ messages in thread
From: Sebastian Reichel @ 2015-04-30 15:55 UTC (permalink / raw)
To: Marek Belisko; +Cc: dbaryshkov, dwmw2, linux-pm, linux-kernel, hns
[-- Attachment #1: Type: text/plain, Size: 1103 bytes --]
Hi,
On Tue, Apr 28, 2015 at 10:23:06PM +0200, Marek Belisko wrote:
> Without MODULE_ALIAS bq27x00_battery module won't get loaded
> automatically.
>
> Signed-off-by: Marek Belisko <marek@goldelico.com>
> ---
> drivers/power/bq27x00_battery.c | 6 ++++++
> 1 file changed, 6 insertions(+)
>
> diff --git a/drivers/power/bq27x00_battery.c b/drivers/power/bq27x00_battery.c
> index a57433d..542927e 100644
> --- a/drivers/power/bq27x00_battery.c
> +++ b/drivers/power/bq27x00_battery.c
> @@ -1109,6 +1109,12 @@ static void __exit bq27x00_battery_exit(void)
> }
> module_exit(bq27x00_battery_exit);
>
> +#ifdef CONFIG_BATTERY_BQ27X00_PLATFORM
> +MODULE_ALIAS("platform:bq27000-battery");
> +#else
> +MODULE_ALIAS("i2c:bq27000-battery");
> +#endif
> +
> MODULE_AUTHOR("Rodolfo Giometti <giometti@linux.it>");
> MODULE_DESCRIPTION("BQ27x00 battery monitor driver");
> MODULE_LICENSE("GPL");
NAK. You should set the alias by checking for
CONFIG_BATTERY_BQ27X00_PLATFORM and CONFIG_BATTERY_BQ27X00_I2C
respectively, so that all scenarios are handled.
-- Sebastian
[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 819 bytes --]
^ permalink raw reply [flat|nested] 4+ messages in thread
* [PATCH] power: bq27x00_battery: Add missing MODULE_ALIAS
2015-04-28 20:23 [PATCH] power: bq27x00_battery: Add missing MODULE_ALIAS Marek Belisko
2015-04-30 15:55 ` Sebastian Reichel
@ 2015-04-30 20:05 ` Marek Belisko
2015-05-01 21:03 ` Sebastian Reichel
1 sibling, 1 reply; 4+ messages in thread
From: Marek Belisko @ 2015-04-30 20:05 UTC (permalink / raw)
To: sre, dbaryshkov, dwmw2; +Cc: linux-pm, linux-kernel, hns, Marek Belisko
Without MODULE_ALIAS bq27x00_battery module won't get loaded automatically.
Signed-off-by: Marek Belisko <marek@goldelico.com>
---
drivers/power/bq27x00_battery.c | 8 ++++++++
1 file changed, 8 insertions(+)
diff --git a/drivers/power/bq27x00_battery.c b/drivers/power/bq27x00_battery.c
index a57433d..b6b9837 100644
--- a/drivers/power/bq27x00_battery.c
+++ b/drivers/power/bq27x00_battery.c
@@ -1109,6 +1109,14 @@ static void __exit bq27x00_battery_exit(void)
}
module_exit(bq27x00_battery_exit);
+#ifdef CONFIG_BATTERY_BQ27X00_PLATFORM
+MODULE_ALIAS("platform:bq27000-battery");
+#endif
+
+#ifdef CONFIG_BATTERY_BQ27X00_I2C
+MODULE_ALIAS("i2c:bq27000-battery");
+#endif
+
MODULE_AUTHOR("Rodolfo Giometti <giometti@linux.it>");
MODULE_DESCRIPTION("BQ27x00 battery monitor driver");
MODULE_LICENSE("GPL");
--
1.9.1
^ permalink raw reply related [flat|nested] 4+ messages in thread
* Re: [PATCH] power: bq27x00_battery: Add missing MODULE_ALIAS
2015-04-30 20:05 ` Marek Belisko
@ 2015-05-01 21:03 ` Sebastian Reichel
0 siblings, 0 replies; 4+ messages in thread
From: Sebastian Reichel @ 2015-05-01 21:03 UTC (permalink / raw)
To: Marek Belisko; +Cc: dbaryshkov, dwmw2, linux-pm, linux-kernel, hns
[-- Attachment #1: Type: text/plain, Size: 190 bytes --]
Hi,
On Thu, Apr 30, 2015 at 10:05:58PM +0200, Marek Belisko wrote:
> Without MODULE_ALIAS bq27x00_battery module won't get loaded
> automatically.
Thanks, queued into fixes.
-- Sebastian
[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 819 bytes --]
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2015-05-01 21:03 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-04-28 20:23 [PATCH] power: bq27x00_battery: Add missing MODULE_ALIAS Marek Belisko
2015-04-30 15:55 ` Sebastian Reichel
2015-04-30 20:05 ` Marek Belisko
2015-05-01 21:03 ` Sebastian Reichel
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).