eeepc-laptop: check wireless hotplug events
commitfe17e2bb5f588ee25647a5087710bab3e70d4e86
authorAlan Jenkins <alan-jenkins@tuffmail.co.uk>
Mon, 22 Feb 2010 16:03:58 +0000 (22 16:03 +0000)
committerGreg Kroah-Hartman <gregkh@suse.de>
Mon, 2 Aug 2010 17:21:29 +0000 (2 10:21 -0700)
tree019c7ce56d0fa8eb5f2a407665788d7f36dd1a9f
parentbf1fe0bc49306efd7b822d1a90bfafbd4cb68694
eeepc-laptop: check wireless hotplug events

commit bc9d24a3aeb1532fc3e234907a8b6d671f7ed68f upstream.

Before we mark the wireless device as unplugged, check PCI config space
to see whether the wireless device is really disabled (and vice versa).
This works around newer models which don't want the hotplug code, where
we end up disabling the wired network device.

My old 701 still works correctly with this.  I can also simulate an
afflicted model by changing the hardcoded PCI bus/slot number in the
driver, and it seems to work nicely (although it is a bit noisy).

In future this type of hotplug support will be implemented by the PCI
core.  The existing blacklist and the new warning message will be
removed at that point.

Signed-off-by: Alan Jenkins <alan-jenkins@tuffmail.co.uk>
Signed-off-by: Corentin Chary <corentincj@iksaif.net>
Cc: Tim Gardner <tim.gardner@canonical.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
drivers/platform/x86/eeepc-laptop.c