FAQ Search Today's Posts Mark Forums Read
» Video Reviews

» Linux Archive

Linux-archive is a website aiming to archive linux email lists and to make them easily accessible for linux users/developers.


» Sponsor

» Partners

» Sponsor

Go Back   Linux Archive > Ubuntu > Ubuntu Kernel Team

 
 
LinkBack Thread Tools
 
Old 04-21-2011, 03:57 PM
Seth Forshee
 
Default acer-wmi: does not set persistence state by rfkill_init_sw_state

SRU Justification

Impact: Commit 466449c introduces a regression in acer-wmi that can
result in soft blocks being incorrectly applied to rfkill switches in
some circumstances. On the Fujitsu AMILO Li 2727 this results in wifi
being soft blocked at boot, and since the wlan hotkey isn't working
correctly this block can only be removed using the command line.

Fix: Patch from upstream which fixes the regression.

Test case: Boot affected machine and observe soft block state on wlan
rfkill switches. Tested by reporter on LP #710738.

BugLink: http://bugs.launchpad.net/bugs/710738


--
kernel-team mailing list
kernel-team@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/kernel-team
 
Old 04-21-2011, 03:57 PM
Seth Forshee
 
Default acer-wmi: does not set persistence state by rfkill_init_sw_state

From: Lee, Chun-Yi <joeyli.kernel@gmail.com>

BugLink: http://bugs.launchpad.net/bugs/710738

Acer BIOS keeps devices state when system reboot, but reset to default
device states (Wlan on, Bluetooth off, wwan on) if system cold boot.
That means BIOS's initial state is not always real persistence.

So, removed rfkill_init_sw_state because it sets initial state to
persistence then replicate to other new killswitch when rfkill-input
enabled.
After removed it, acer-wmi set initial soft-block state after rfkill
register, and doesn't allow set_block until rfkill initial finished.

Reference: bko#31002
https://bugzilla.kernel.org/show_bug.cgi?id=31002

Cc: Carlos Corbacho <carlos@strangeworlds.co.uk>
Cc: Matthew Garrett <mjg@redhat.com>
Cc: Dmitry Torokhov <dtor@mail.ru>
Cc: Corentin Chary <corentincj@iksaif.net>
Cc: Oldřich Jedlička <oldium.pro@seznam.cz>
Cc: Johannes Berg <johannes@sipsolutions.net>
Signed-off-by: Lee, Chun-Yi <jlee@novell.com>
Signed-off-by: Matthew Garrett <mjg@redhat.com>
(cherry picked from commit 8215af019040ce9182728afee9642d8fdeb17f59)

Signed-off-by: Seth Forshee <seth.forshee@canonical.com>
---
drivers/platform/x86/acer-wmi.c | 19 ++++++++++++++-----
1 files changed, 14 insertions(+), 5 deletions(-)

diff --git a/drivers/platform/x86/acer-wmi.c b/drivers/platform/x86/acer-wmi.c
index 38b34a7..fa54ba7 100644
--- a/drivers/platform/x86/acer-wmi.c
+++ b/drivers/platform/x86/acer-wmi.c
@@ -222,6 +222,7 @@ struct acer_debug {
static struct rfkill *wireless_rfkill;
static struct rfkill *bluetooth_rfkill;
static struct rfkill *threeg_rfkill;
+static bool rfkill_inited;

/* Each low-level interface must define at least some of the following */
struct wmi_interface {
@@ -1161,9 +1162,13 @@ static int acer_rfkill_set(void *data, bool blocked)
{
acpi_status status;
u32 cap = (unsigned long)data;
- status = set_u32(!blocked, cap);
- if (ACPI_FAILURE(status))
- return -ENODEV;
+
+ if (rfkill_inited) {
+ status = set_u32(!blocked, cap);
+ if (ACPI_FAILURE(status))
+ return -ENODEV;
+ }
+
return 0;
}

@@ -1187,14 +1192,16 @@ static struct rfkill *acer_rfkill_register(struct device *dev,
return ERR_PTR(-ENOMEM);

status = get_device_status(&state, cap);
- if (ACPI_SUCCESS(status))
- rfkill_init_sw_state(rfkill_dev, !state);

err = rfkill_register(rfkill_dev);
if (err) {
rfkill_destroy(rfkill_dev);
return ERR_PTR(err);
}
+
+ if (ACPI_SUCCESS(status))
+ rfkill_set_sw_state(rfkill_dev, !state);
+
return rfkill_dev;
}

@@ -1229,6 +1236,8 @@ static int acer_rfkill_init(struct device *dev)
}
}

+ rfkill_inited = true;
+
schedule_delayed_work(&acer_rfkill_work, round_jiffies_relative(HZ));

return 0;
--
1.7.4.1


--
kernel-team mailing list
kernel-team@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/kernel-team
 
Old 04-21-2011, 04:05 PM
Seth Forshee
 
Default acer-wmi: does not set persistence state by rfkill_init_sw_state

On Thu, Apr 21, 2011 at 10:57:47AM -0500, Seth Forshee wrote:
> SRU Justification
>
> Impact: Commit 466449c introduces a regression in acer-wmi that can
> result in soft blocks being incorrectly applied to rfkill switches in
> some circumstances. On the Fujitsu AMILO Li 2727 this results in wifi
> being soft blocked at boot, and since the wlan hotkey isn't working
> correctly this block can only be removed using the command line.
>
> Fix: Patch from upstream which fixes the regression.
>
> Test case: Boot affected machine and observe soft block state on wlan
> rfkill switches. Tested by reporter on LP #710738.
>
> BugLink: http://bugs.launchpad.net/bugs/710738

Ignore this. It's already in master-next via stable. I forgot to update
my tree before checking...


--
kernel-team mailing list
kernel-team@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/kernel-team
 

Thread Tools




All times are GMT. The time now is 12:39 PM.

VBulletin, Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2007, Crawlability, Inc.
Copyright 2007 - 2008, www.linux-archive.org