2010-02-14 10:57:27

by Erik Andrén

[permalink] [raw]
Subject: [PATCH 1/1] platform/x86/dell-laptop: Add another Dell laptop to the DMI whitelist

The Latitude C640 has another variation of dell in its DMI vendor entry.
Add it to the whitelist in order to enjoy the sweet fruits of software backlight toggling.

Signed-off-by: Erik Andren <[email protected]>
---
drivers/platform/x86/dell-laptop.c | 7 +++++++
1 files changed, 7 insertions(+), 0 deletions(-)

diff --git a/drivers/platform/x86/dell-laptop.c b/drivers/platform/x86/dell-laptop.c
index 3780994..b5246f1 100644
--- a/drivers/platform/x86/dell-laptop.c
+++ b/drivers/platform/x86/dell-laptop.c
@@ -79,6 +79,13 @@ static const struct dmi_system_id __initdata dell_device_table[] = {
DMI_MATCH(DMI_CHASSIS_TYPE, "8"),
},
},
+ {
+ .ident = "Dell Computer Corporation",
+ .matches = {
+ DMI_MATCH(DMI_SYS_VENDOR, "Dell Computer Corporation"),
+ DMI_MATCH(DMI_CHASSIS_TYPE, "8"),
+ },
+ },
{ }
};

--
1.6.3.3


2010-02-14 15:47:13

by Andreas Mohr

[permalink] [raw]
Subject: Re: [PATCH 1/1] platform/x86/dell-laptop: Add another Dell laptop to the DMI whitelist

> The Latitude C640 has another variation of dell in its DMI vendor entry.
> Add it to the whitelist in order to enjoy the sweet fruits of software
> backlight toggling.

Definitely not only this one. E.g. my Inspiron 8000 (P3/700) has (dmidecode):

Handle 0x0300, DMI type 3, 13 bytes
Chassis Information
Manufacturer: Dell Computer Corporation
Type: Portable

which, if "Portable" happens to be "8", means that it would match.

So:
- do all older matching machines grok this?
- if not, do something about it? ;)

[I should probably just offer myself to be a guinea pig]

Thanks for a very interesting piece of work!

Andreas Mohr

2010-02-14 16:55:32

by Matthew Garrett

[permalink] [raw]
Subject: Re: [PATCH 1/1] platform/x86/dell-laptop: Add another Dell laptop to the DMI whitelist

On Sun, Feb 14, 2010 at 11:54:57AM +0100, Erik Andren wrote:
> The Latitude C640 has another variation of dell in its DMI vendor entry.
> Add it to the whitelist in order to enjoy the sweet fruits of software backlight toggling.

Thanks, picked up for .34.

--
Matthew Garrett | [email protected]

2010-02-14 16:57:38

by Matthew Garrett

[permalink] [raw]
Subject: Re: [PATCH 1/1] platform/x86/dell-laptop: Add another Dell laptop to the DMI whitelist

On Sun, Feb 14, 2010 at 04:47:10PM +0100, Andreas Mohr wrote:
> Definitely not only this one. E.g. my Inspiron 8000 (P3/700) has (dmidecode):
>
> Handle 0x0300, DMI type 3, 13 bytes
> Chassis Information
> Manufacturer: Dell Computer Corporation
> Type: Portable
>
> which, if "Portable" happens to be "8", means that it would match.

8 should be portable, yes. 9 would be laptop (and 10 notebook), but I
haven't seen any examples of those in Dells.

> So:
> - do all older matching machines grok this?

The dcdbas call should fail if they don't, so I think we're ok.

--
Matthew Garrett | [email protected]

2010-02-14 18:59:11

by Erik Andrén

[permalink] [raw]
Subject: Re: [PATCH 1/1] platform/x86/dell-laptop: Add another Dell laptop to the DMI whitelist

2010/2/14 Matthew Garrett <[email protected]>:
> On Sun, Feb 14, 2010 at 11:54:57AM +0100, Erik Andren wrote:
>> The Latitude C640 has another variation of dell in its DMI vendor entry.
>> Add it to the whitelist in order to enjoy the sweet fruits of software backlight toggling.
>
> Thanks, picked up for .34.
>

Darn, I forgot to add another module alias.
Shall I respin the whole patch or create another one depending on the old one?

Best regards,
Erik

> --
> Matthew Garrett | [email protected]
>

2010-02-14 19:04:34

by Matthew Garrett

[permalink] [raw]
Subject: Re: [PATCH 1/1] platform/x86/dell-laptop: Add another Dell laptop to the DMI whitelist

On Sun, Feb 14, 2010 at 07:59:06PM +0100, Erik Andr?n wrote:

> Darn, I forgot to add another module alias.
> Shall I respin the whole patch or create another one depending on the old one?

Oh, good point! I can add that myself and merge it in.

--
Matthew Garrett | [email protected]

2010-02-14 19:07:59

by Erik Andrén

[permalink] [raw]
Subject: Re: [PATCH 1/1] platform/x86/dell-laptop: Add another Dell laptop to the DMI whitelist

2010/2/14 Matthew Garrett <[email protected]>:
> On Sun, Feb 14, 2010 at 07:59:06PM +0100, Erik Andr?n wrote:
>
>> Darn, I forgot to add another module alias.
>> Shall I respin the whole patch or create another one depending on the old one?
>
> Oh, good point! I can add that myself and merge it in.
>

Thanks!
FWIW I've verified that the following string works:
MODULE_ALIAS("dmi:*svnDellComputerCorporation:*:ct8:*");

Best regards,
Erik

> --
> Matthew Garrett | [email protected]
>