public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Paolo Ornati <ornati@gmail.com>
To: Linux Kernel Mailing List <linux-kernel@vger.kernel.org>
Cc: stable@kernel.org, Zhang Rui <rui.zhang@intel.com>
Subject: 2.6.32.y needs ACPI workaround on ASUS K50IJ
Date: Sun, 12 Sep 2010 13:45:31 +0200	[thread overview]
Message-ID: <20100912134531.6a97e833@gmail.com> (raw)

Hello,

ASUS K50IJ needs the following ACPI workaround on 2.6.32.y (2.6.33+ is
fine).

Since many distros are based / basing on 2.6.32.y i think it makes sense
to include the fix in the upstream stable tree :)

------------------------------------------

commit 81074e90f5c150ca70ab8dfcc77860cbe76f364d
Author: Zhang Rui <rui.zhang@intel.com>
Date:   Mon Dec 21 16:13:15 2009 +0800

    ACPI: disable _OSI(Windows 2009) on Asus K50IJ
    
    Fix a win7 compability issue on Asus K50IJ.
    
    Here is the _BCM method of this laptop:
                        Method (_BCM, 1, NotSerialized)
                        {
                            If (LGreaterEqual (OSFG, OSVT))
                            {
                                If (LNotEqual (OSFG, OSW7))
                                {
                                    Store (One, BCMD)
                                    Store (GCBL (Arg0), Local0)
                                    Subtract (0x0F, Local0, LBTN)
                                    ^^^SBRG.EC0.STBR ()
                                    ...
                                }
                                Else
                                {
                                    DBGR (0x0B, Zero, Zero, Arg0)
                                    Store (Arg0, LBTN)
                                    ^^^SBRG.EC0.STBR ()
                                    ...
                                }
                            }
                        }
    LBTN is used to store the index of the brightness level in the _BCL.
    GCBL is a method that convert the percentage value to the index value.
    If _OSI(Windows 2009) is not disabled, LBTN is stored a percentage
    value which is surely beyond the end of _BCL package.
    
    http://bugzilla.kernel.org/show_bug.cgi?id=14753
    
    Signed-off-by: Zhang Rui <rui.zhang@intel.com>
    Signed-off-by: Len Brown <len.brown@intel.com>

diff --git a/drivers/acpi/blacklist.c b/drivers/acpi/blacklist.c
index 23e5a05..2815df6 100644
--- a/drivers/acpi/blacklist.c
+++ b/drivers/acpi/blacklist.c
@@ -185,6 +185,12 @@ static int __init dmi_disable_osi_vista(const struct dmi_system_id *d)
 	acpi_osi_setup("!Windows 2006");
 	return 0;
 }
+static int __init dmi_disable_osi_win7(const struct dmi_system_id *d)
+{
+	printk(KERN_NOTICE PREFIX "DMI detected: %s\n", d->ident);
+	acpi_osi_setup("!Windows 2009");
+	return 0;
+}
 
 static struct dmi_system_id acpi_osi_dmi_table[] __initdata = {
 	{
@@ -211,6 +217,14 @@ static struct dmi_system_id acpi_osi_dmi_table[] __initdata = {
 		     DMI_MATCH(DMI_PRODUCT_NAME, "Sony VGN-SR290J"),
 		},
 	},
+	{
+	.callback = dmi_disable_osi_win7,
+	.ident = "ASUS K50IJ",
+	.matches = {
+		     DMI_MATCH(DMI_SYS_VENDOR, "ASUSTeK Computer Inc."),
+		     DMI_MATCH(DMI_PRODUCT_NAME, "K50IJ"),
+		},
+	},
 
 	/*
 	 * BIOS invocation of _OSI(Linux) is almost always a BIOS bug.


-- 
	Paolo Ornati
	Linux 2.6.35.4 on x86_64

             reply	other threads:[~2010-09-12 11:46 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-09-12 11:45 Paolo Ornati [this message]
2010-09-23 18:29 ` [stable] 2.6.32.y needs ACPI workaround on ASUS K50IJ Greg KH

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=20100912134531.6a97e833@gmail.com \
    --to=ornati@gmail.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=rui.zhang@intel.com \
    --cc=stable@kernel.org \
    /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