From: Zhang Rui <rui.zhang@intel.com>
To: linux-acpi@vger.kernel.org
Cc: len.brown@intel.com
Subject: [10/12] acpi: motherboard driver
Date: Fri, 22 Sep 2006 17:49:27 +0800 [thread overview]
Message-ID: <1158918567.11985.82.camel@localhost.localdomain> (raw)
From: Li Shaohua <shaohua.li@intel.com>
Consolidate motherboard1 and motherboard2 drivers into one
so that driver core doesn't complain that two drivers have
the same name.
Signed-off-by: Zhang Rui <rui.zhang@intel.com>
---
drivers/acpi/motherboard.c | 19 ++++---------------
1 files changed, 4 insertions(+), 15 deletions(-)
Index: linux-2.6.18-rc5/drivers/acpi/motherboard.c
===================================================================
--- linux-2.6.18-rc5.orig/drivers/acpi/motherboard.c 2006-09-13 14:52:04.000000000 +0800
+++ linux-2.6.18-rc5/drivers/acpi/motherboard.c 2006-09-13 17:28:19.000000000 +0800
@@ -33,8 +33,7 @@
ACPI_MODULE_NAME("acpi_motherboard")
/* Dell use PNP0C01 instead of PNP0C02 */
-#define ACPI_MB_HID1 "PNP0C01"
-#define ACPI_MB_HID2 "PNP0C02"
+#define ACPI_MB_HID "PNP0C01,PNP0C02"
/**
* Doesn't care about legacy IO ports, only IO ports beyond 0x1000 are reserved
* Doesn't care about the failure of 'request_region', since other may reserve
@@ -104,19 +103,10 @@ static int acpi_motherboard_add(struct a
return 0;
}
-static struct acpi_driver acpi_motherboard_driver1 = {
+static struct acpi_driver acpi_motherboard_driver = {
.name = "motherboard",
.class = "",
- .ids = ACPI_MB_HID1,
- .ops = {
- .add = acpi_motherboard_add,
- },
-};
-
-static struct acpi_driver acpi_motherboard_driver2 = {
- .name = "motherboard",
- .class = "",
- .ids = ACPI_MB_HID2,
+ .ids = ACPI_MB_HID,
.ops = {
.add = acpi_motherboard_add,
},
@@ -167,8 +157,7 @@ static void __init acpi_reserve_resource
static int __init acpi_motherboard_init(void)
{
- acpi_bus_register_driver(&acpi_motherboard_driver1);
- acpi_bus_register_driver(&acpi_motherboard_driver2);
+ acpi_bus_register_driver(&acpi_motherboard_driver);
/*
* Guarantee motherboard IO reservation first
* This module must run after scan.c
reply other threads:[~2006-09-22 9:48 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
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=1158918567.11985.82.camel@localhost.localdomain \
--to=rui.zhang@intel.com \
--cc=len.brown@intel.com \
--cc=linux-acpi@vger.kernel.org \
/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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox