From: Axel Lin <axel.lin@gmail.com>
To: linux-kernel@vger.kernel.org
Cc: Alessandro Zummo <a.zummo@towertech.it>,
Dale Farnsworth <dale@farnsworth.org>,
Minkyu Kang <mk7.kang@samsung.com>,
Joonyoung Shim <jy0922.shim@samsung.com>,
rtc-linux@googlegroups.com
Subject: RTC: Add MODULE_DEVICE_TABLE to rtc-ds1672/rtc-max6900/rtc-max8998
Date: Mon, 18 Apr 2011 20:16:57 +0800 [thread overview]
Message-ID: <1303129017.8158.1.camel@phoenix> (raw)
The device table is required to load modules based on modaliases.
After adding MODULE_DEVICE_TABLE, below entries will be added to modules.alias:
alias i2c:ds1672 rtc_ds1672
alias i2c:max6900 rtc_max6900
alias platform:lp3974-rtc rtc_max8998
alias platform:max8998-rtc rtc_max8998
Signed-off-by: Axel Lin <axel.lin@gmail.com>
Cc: Alessandro Zummo <a.zummo@towertech.it>
Cc: Dale Farnsworth <dale@farnsworth.org>
Cc: Minkyu Kang <mk7.kang@samsung.com>
Cc: Joonyoung Shim <jy0922.shim@samsung.com>
---
drivers/rtc/rtc-ds1672.c | 1 +
drivers/rtc/rtc-max6900.c | 1 +
drivers/rtc/rtc-max8998.c | 1 +
3 files changed, 3 insertions(+), 0 deletions(-)
diff --git a/drivers/rtc/rtc-ds1672.c b/drivers/rtc/rtc-ds1672.c
index 06dfb54..fa301d4 100644
--- a/drivers/rtc/rtc-ds1672.c
+++ b/drivers/rtc/rtc-ds1672.c
@@ -191,6 +191,7 @@ static struct i2c_device_id ds1672_id[] = {
{ "ds1672", 0 },
{ }
};
+MODULE_DEVICE_TABLE(i2c, ds1672_id);
static struct i2c_driver ds1672_driver = {
.driver = {
diff --git a/drivers/rtc/rtc-max6900.c b/drivers/rtc/rtc-max6900.c
index 486142c..ef834c1 100644
--- a/drivers/rtc/rtc-max6900.c
+++ b/drivers/rtc/rtc-max6900.c
@@ -251,6 +251,7 @@ static struct i2c_device_id max6900_id[] = {
{ "max6900", 0 },
{ }
};
+MODULE_DEVICE_TABLE(i2c, max6900_id);
static struct i2c_driver max6900_driver = {
.driver = {
diff --git a/drivers/rtc/rtc-max8998.c b/drivers/rtc/rtc-max8998.c
index 3f7bc6b..dade62e 100644
--- a/drivers/rtc/rtc-max8998.c
+++ b/drivers/rtc/rtc-max8998.c
@@ -315,6 +315,7 @@ static const struct platform_device_id max8998_rtc_id[] = {
{ "lp3974-rtc", TYPE_LP3974 },
{ }
};
+MODULE_DEVICE_TABLE(platform, max8998_rtc_id);
static struct platform_driver max8998_rtc_driver = {
.driver = {
WARNING: multiple messages have this Message-ID (diff)
From: Axel Lin <axel.lin@gmail.com>
To: linux-kernel@vger.kernel.org
Cc: Alessandro Zummo <a.zummo@towertech.it>,
Dale Farnsworth <dale@farnsworth.org>,
Minkyu Kang <mk7.kang@samsung.com>,
Joonyoung Shim <jy0922.shim@samsung.com>,
rtc-linux@googlegroups.com
Subject: [PATCH] RTC: Add MODULE_DEVICE_TABLE to rtc-ds1672/rtc-max6900/rtc-max8998
Date: Mon, 18 Apr 2011 20:16:57 +0800 [thread overview]
Message-ID: <1303129017.8158.1.camel@phoenix> (raw)
The device table is required to load modules based on modaliases.
After adding MODULE_DEVICE_TABLE, below entries will be added to modules.alias:
alias i2c:ds1672 rtc_ds1672
alias i2c:max6900 rtc_max6900
alias platform:lp3974-rtc rtc_max8998
alias platform:max8998-rtc rtc_max8998
Signed-off-by: Axel Lin <axel.lin@gmail.com>
Cc: Alessandro Zummo <a.zummo@towertech.it>
Cc: Dale Farnsworth <dale@farnsworth.org>
Cc: Minkyu Kang <mk7.kang@samsung.com>
Cc: Joonyoung Shim <jy0922.shim@samsung.com>
---
drivers/rtc/rtc-ds1672.c | 1 +
drivers/rtc/rtc-max6900.c | 1 +
drivers/rtc/rtc-max8998.c | 1 +
3 files changed, 3 insertions(+), 0 deletions(-)
diff --git a/drivers/rtc/rtc-ds1672.c b/drivers/rtc/rtc-ds1672.c
index 06dfb54..fa301d4 100644
--- a/drivers/rtc/rtc-ds1672.c
+++ b/drivers/rtc/rtc-ds1672.c
@@ -191,6 +191,7 @@ static struct i2c_device_id ds1672_id[] = {
{ "ds1672", 0 },
{ }
};
+MODULE_DEVICE_TABLE(i2c, ds1672_id);
static struct i2c_driver ds1672_driver = {
.driver = {
diff --git a/drivers/rtc/rtc-max6900.c b/drivers/rtc/rtc-max6900.c
index 486142c..ef834c1 100644
--- a/drivers/rtc/rtc-max6900.c
+++ b/drivers/rtc/rtc-max6900.c
@@ -251,6 +251,7 @@ static struct i2c_device_id max6900_id[] = {
{ "max6900", 0 },
{ }
};
+MODULE_DEVICE_TABLE(i2c, max6900_id);
static struct i2c_driver max6900_driver = {
.driver = {
diff --git a/drivers/rtc/rtc-max8998.c b/drivers/rtc/rtc-max8998.c
index 3f7bc6b..dade62e 100644
--- a/drivers/rtc/rtc-max8998.c
+++ b/drivers/rtc/rtc-max8998.c
@@ -315,6 +315,7 @@ static const struct platform_device_id max8998_rtc_id[] = {
{ "lp3974-rtc", TYPE_LP3974 },
{ }
};
+MODULE_DEVICE_TABLE(platform, max8998_rtc_id);
static struct platform_driver max8998_rtc_driver = {
.driver = {
--
1.7.1
next reply other threads:[~2011-04-18 12:16 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-04-18 12:16 Axel Lin [this message]
2011-04-18 12:16 ` [PATCH] RTC: Add MODULE_DEVICE_TABLE to rtc-ds1672/rtc-max6900/rtc-max8998 Axel Lin
2015-05-18 22:26 ` [rtc-linux] " Alexandre Belloni
2015-05-18 22:26 ` Alexandre Belloni
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1303129017.8158.1.camel@phoenix \
--to=axel.lin@gmail.com \
--cc=a.zummo@towertech.it \
--cc=dale@farnsworth.org \
--cc=jy0922.shim@samsung.com \
--cc=linux-kernel@vger.kernel.org \
--cc=mk7.kang@samsung.com \
--cc=rtc-linux@googlegroups.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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.