]> git.ipfire.org Git - thirdparty/kernel/stable-queue.git/commitdiff
3.0 patches
authorGreg Kroah-Hartman <gregkh@suse.de>
Fri, 16 Sep 2011 07:09:30 +0000 (09:09 +0200)
committerGreg Kroah-Hartman <gregkh@suse.de>
Fri, 16 Sep 2011 07:09:30 +0000 (09:09 +0200)
queue-3.0/acpica-do-not-repair-_tss-return-package-if-_pss-is-present.patch [new file with mode: 0644]
queue-3.0/series

diff --git a/queue-3.0/acpica-do-not-repair-_tss-return-package-if-_pss-is-present.patch b/queue-3.0/acpica-do-not-repair-_tss-return-package-if-_pss-is-present.patch
new file mode 100644 (file)
index 0000000..4383e76
--- /dev/null
@@ -0,0 +1,73 @@
+From 8f9c91273e36e5762c617c23e4fd48d5172e0dac Mon Sep 17 00:00:00 2001
+From: Fenghua Yu <fenghua.yu@intel.com>
+Date: Mon, 4 Jul 2011 08:36:16 +0000
+Subject: ACPICA: Do not repair _TSS return package if _PSS is present
+
+From: Fenghua Yu <fenghua.yu@intel.com>
+
+commit 8f9c91273e36e5762c617c23e4fd48d5172e0dac upstream.
+
+We can only sort the _TSS return package if there is no _PSS
+in the same scope. This is because if _PSS is present, the ACPI
+specification dictates that the _TSS Power Dissipation field is
+to be ignored, and therefore some BIOSs leave garbage values in
+the _TSS Power field(s).  In this case, it is best to just return
+the _TSS package as-is.
+
+Reported-by: Fenghua Yu <fenghua.yu@intel.com>
+Signed-off-by: Fenghua Yu <fenghua.yu@intel.com>
+Signed-off-by: Bob Moore <robert.moore@intel.com>
+Signed-off-by: Lin Ming <ming.m.lin@intel.com>
+Signed-off-by: Len Brown <len.brown@intel.com>
+Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
+
+---
+ drivers/acpi/acpica/aclocal.h   |    1 +
+ drivers/acpi/acpica/nspredef.c  |    1 +
+ drivers/acpi/acpica/nsrepair2.c |   15 +++++++++++++++
+ 3 files changed, 17 insertions(+)
+
+--- a/drivers/acpi/acpica/aclocal.h
++++ b/drivers/acpi/acpica/aclocal.h
+@@ -357,6 +357,7 @@ struct acpi_predefined_data {
+       char *pathname;
+       const union acpi_predefined_info *predefined;
+       union acpi_operand_object *parent_package;
++      struct acpi_namespace_node *node;
+       u32 flags;
+       u8 node_flags;
+ };
+--- a/drivers/acpi/acpica/nspredef.c
++++ b/drivers/acpi/acpica/nspredef.c
+@@ -212,6 +212,7 @@ acpi_ns_check_predefined_names(struct ac
+               goto cleanup;
+       }
+       data->predefined = predefined;
++      data->node = node;
+       data->node_flags = node->flags;
+       data->pathname = pathname;
+--- a/drivers/acpi/acpica/nsrepair2.c
++++ b/drivers/acpi/acpica/nsrepair2.c
+@@ -503,6 +503,21 @@ acpi_ns_repair_TSS(struct acpi_predefine
+ {
+       union acpi_operand_object *return_object = *return_object_ptr;
+       acpi_status status;
++      struct acpi_namespace_node *node;
++
++      /*
++       * We can only sort the _TSS return package if there is no _PSS in the
++       * same scope. This is because if _PSS is present, the ACPI specification
++       * dictates that the _TSS Power Dissipation field is to be ignored, and
++       * therefore some BIOSs leave garbage values in the _TSS Power field(s).
++       * In this case, it is best to just return the _TSS package as-is.
++       * (May, 2011)
++       */
++      status =
++          acpi_ns_get_node(data->node, "^_PSS", ACPI_NS_NO_UPSEARCH, &node);
++      if (ACPI_SUCCESS(status)) {
++              return (AE_OK);
++      }
+       status = acpi_ns_check_sorted_list(data, return_object, 5, 1,
+                                          ACPI_SORT_DESCENDING,
index 334ea59fc6d6fb637164f5a62906aade7dbc8ade..8ca2f20c3cf374afcaabda34d1e81b8443f6f1da 100644 (file)
@@ -89,3 +89,4 @@ net-9p-fix-the-msize-calculation.patch
 irda-fix-smsc-ircc2-section-mismatch-warning.patch
 iommu-amd-don-t-take-domain-lock-recursivly.patch
 iommu-amd-make-sure-iommu-need_sync-contains-correct-value.patch
+acpica-do-not-repair-_tss-return-package-if-_pss-is-present.patch