ACPICA: Core: Always set GPIO VendorOffset
authorMika Westerberg <mika.westerberg@linux.intel.com>
Mon, 5 Jun 2017 08:39:50 +0000 (16:39 +0800)
committerRafael J. Wysocki <rafael.j.wysocki@intel.com>
Mon, 12 Jun 2017 12:58:40 +0000 (14:58 +0200)
ACPICA commit 51a92f414de7af1f7f7524de3f61daf5413cac9f

Acpiexec gives this warning when resources containing GPIOs are extracted
using Resource command:

  **** Data mismatch in descriptor [00] type 8C, Offset 00000000 ****
  Mismatch at byte offset 13: is 00, should be 25
  **** Data mismatch in descriptor [01] type 8C, Offset 00000025 ****
  Mismatch at byte offset 13: is 00, should be 25

This happens because we do not set VendorOffset when doing resource to AML
conversion. Fix this by always setting VendorOffset.

Link: https://github.com/acpica/acpica/commit/51a92f41
Signed-off-by: Mika Westerberg <mika.westerberg@linux.intel.com>
Signed-off-by: Bob Moore <robert.moore@intel.com>
Signed-off-by: Lv Zheng <lv.zheng@intel.com>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
drivers/acpi/acpica/rsmisc.c

index 2ae79613f6b703f04a019da4c07cd7476f1af0c7..cc4b5486c4bcc87d4d99a931570bdc49348a499f 100644 (file)
@@ -596,9 +596,7 @@ acpi_rs_convert_resource_to_aml(struct acpi_resource *resource,
 
                        /* Set vendor offset only if there is vendor data */
 
-                       if (resource->data.gpio.vendor_length) {
-                               ACPI_SET16(target, aml_length);
-                       }
+                       ACPI_SET16(target, aml_length);
 
                        acpi_rs_set_resource_length(aml_length, aml);
                        break;