diff options
author | Corentin Chary <corentincj@iksaif.net> | 2010-01-06 16:07:38 -0500 |
---|---|---|
committer | Len Brown <len.brown@intel.com> | 2010-01-16 01:49:28 -0500 |
commit | 10ae4b5663ff3092553bfbd867e7bd474ce6c553 (patch) | |
tree | 585e928a8ca84111a18682d479abd640a57cebb8 /drivers/platform | |
parent | da8ba01deb98f3dc0558b1f5a37e64f40bba7904 (diff) |
eeepc-laptop: dmi blacklist to disable pci hotplug code
This is a short term workaround for Eeepc 1005HA.
refs: <http://bugzilla.kernel.org/show_bug.cgi?id=14570>
Signed-off-by: Corentin Chary <corentincj@iksaif.net>
Signed-off-by: Len Brown <len.brown@intel.com>
Diffstat (limited to 'drivers/platform')
-rw-r--r-- | drivers/platform/x86/eeepc-laptop.c | 25 |
1 files changed, 20 insertions, 5 deletions
diff --git a/drivers/platform/x86/eeepc-laptop.c b/drivers/platform/x86/eeepc-laptop.c index e954f2af5724..7fc944ac2070 100644 --- a/drivers/platform/x86/eeepc-laptop.c +++ b/drivers/platform/x86/eeepc-laptop.c | |||
@@ -161,6 +161,7 @@ struct eeepc_laptop { | |||
161 | u32 cm_supported; /* the control methods supported | 161 | u32 cm_supported; /* the control methods supported |
162 | by this BIOS */ | 162 | by this BIOS */ |
163 | bool cpufv_disabled; | 163 | bool cpufv_disabled; |
164 | bool hotplug_disabled; | ||
164 | u16 event_count[128]; /* count for each event */ | 165 | u16 event_count[128]; /* count for each event */ |
165 | 166 | ||
166 | struct platform_device *platform_device; | 167 | struct platform_device *platform_device; |
@@ -845,6 +846,9 @@ static int eeepc_rfkill_init(struct eeepc_laptop *eeepc) | |||
845 | if (result && result != -ENODEV) | 846 | if (result && result != -ENODEV) |
846 | goto exit; | 847 | goto exit; |
847 | 848 | ||
849 | if (eeepc->hotplug_disabled) | ||
850 | return 0; | ||
851 | |||
848 | result = eeepc_setup_pci_hotplug(eeepc); | 852 | result = eeepc_setup_pci_hotplug(eeepc); |
849 | /* | 853 | /* |
850 | * If we get -EBUSY then something else is handling the PCI hotplug - | 854 | * If we get -EBUSY then something else is handling the PCI hotplug - |
@@ -1314,6 +1318,10 @@ static void eeepc_dmi_check(struct eeepc_laptop *eeepc) | |||
1314 | { | 1318 | { |
1315 | const char *model; | 1319 | const char *model; |
1316 | 1320 | ||
1321 | model = dmi_get_system_info(DMI_PRODUCT_NAME); | ||
1322 | if (!model) | ||
1323 | return; | ||
1324 | |||
1317 | /* | 1325 | /* |
1318 | * Blacklist for setting cpufv (cpu speed). | 1326 | * Blacklist for setting cpufv (cpu speed). |
1319 | * | 1327 | * |
@@ -1333,17 +1341,24 @@ static void eeepc_dmi_check(struct eeepc_laptop *eeepc) | |||
1333 | * substring matching. We don't want to affect the "701SD" | 1341 | * substring matching. We don't want to affect the "701SD" |
1334 | * and "701SDX" models, because they do support S.H.E. | 1342 | * and "701SDX" models, because they do support S.H.E. |
1335 | */ | 1343 | */ |
1336 | |||
1337 | model = dmi_get_system_info(DMI_PRODUCT_NAME); | ||
1338 | if (!model) | ||
1339 | return; | ||
1340 | |||
1341 | if (strcmp(model, "701") == 0 || strcmp(model, "702") == 0) { | 1344 | if (strcmp(model, "701") == 0 || strcmp(model, "702") == 0) { |
1342 | eeepc->cpufv_disabled = true; | 1345 | eeepc->cpufv_disabled = true; |
1343 | pr_info("model %s does not officially support setting cpu " | 1346 | pr_info("model %s does not officially support setting cpu " |
1344 | "speed\n", model); | 1347 | "speed\n", model); |
1345 | pr_info("cpufv disabled to avoid instability\n"); | 1348 | pr_info("cpufv disabled to avoid instability\n"); |
1346 | } | 1349 | } |
1350 | |||
1351 | /* | ||
1352 | * Blacklist for wlan hotplug | ||
1353 | * | ||
1354 | * Eeepc 1005HA doesn't work like others models and don't need the | ||
1355 | * hotplug code. In fact, current hotplug code seems to unplug another | ||
1356 | * device... | ||
1357 | */ | ||
1358 | if (strcmp(model, "1005HA") == 0) { | ||
1359 | eeepc->hotplug_disabled = true; | ||
1360 | pr_info("wlan hotplug disabled\n"); | ||
1361 | } | ||
1347 | } | 1362 | } |
1348 | 1363 | ||
1349 | static void cmsg_quirk(struct eeepc_laptop *eeepc, int cm, const char *name) | 1364 | static void cmsg_quirk(struct eeepc_laptop *eeepc, int cm, const char *name) |