From: Edward Lin <yidi.lin@canonical.com>
To: Matthew Garrett <mjg59@srcf.ucam.org>,
platform-driver-x86@vger.kernel.org
Cc: yidi.lin@canonical.com, yk@canonical.com
Subject: [PATCH] dell-laptop: Enable rfkill on Inspiron 3437
Date: Wed, 7 May 2014 15:10:03 +0800 [thread overview]
Message-ID: <1399446603-8467-1-git-send-email-yidi.lin@canonical.com> (raw)
Create a rfkill whitelist for the specific models.
Add Inspiron 3437 to rfkill whitelist.
Signed-off-by: Edward Lin <yidi.lin@canonical.com>
---
drivers/platform/x86/dell-laptop.c | 13 ++++++++++++-
1 file changed, 12 insertions(+), 1 deletion(-)
diff --git a/drivers/platform/x86/dell-laptop.c b/drivers/platform/x86/dell-laptop.c
index fed4111..4ead97e 100644
--- a/drivers/platform/x86/dell-laptop.c
+++ b/drivers/platform/x86/dell-laptop.c
@@ -271,6 +271,17 @@ static struct dmi_system_id dell_quirks[] = {
{ }
};
+static struct dmi_system_id dell_rfkill_whitelist[] = {
+ {
+ .ident = "Dell Inspiron 3437",
+ .matches = {
+ DMI_MATCH(DMI_SYS_VENDOR, "Dell Inc."),
+ DMI_MATCH(DMI_PRODUCT_NAME, "Inspiron 3437"),
+ },
+ },
+ {}
+};
+
static struct calling_interface_buffer *buffer;
static struct page *bufferpage;
static DEFINE_MUTEX(buffer_mutex);
@@ -597,7 +608,7 @@ static int __init dell_setup_rfkill(void)
if (product && (strncmp(product, "Latitude", 8) == 0 ||
strncmp(product, "Precision", 9) == 0))
whitelisted = 1;
- if (!force_rfkill && !whitelisted)
+ if (!force_rfkill && !whitelisted && !dmi_check_system(dell_rfkill_whitelist))
return 0;
get_buffer();
--
1.7.9.5
next reply other threads:[~2014-05-07 7:10 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-05-07 7:10 Edward Lin [this message]
2014-05-07 11:53 ` [PATCH] dell-laptop: Enable rfkill on Inspiron 3437 Matthew Garrett
2014-05-08 7:19 ` Yidi Lin
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=1399446603-8467-1-git-send-email-yidi.lin@canonical.com \
--to=yidi.lin@canonical.com \
--cc=mjg59@srcf.ucam.org \
--cc=platform-driver-x86@vger.kernel.org \
--cc=yk@canonical.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox