• Dave Lambley's avatar
    ACPI / battery: If _BIX fails, retry with _BIF · 2d09af4a
    Dave Lambley authored
    The Lenovo Yoga 300 laptop's firmware advertises that it provides the _BIX
    the method to retrieve battery information. Unfortunately (some versions
    of?) the implementation return with an error.
    
    [   21.712228] ACPI Exception: AE_AML_PACKAGE_LIMIT, Index (0x000000010) is beyond end of object (length 0xD) (20160422/exoparg2-427)
    [   21.712244] ACPI Error: Method parse/execution failed [\_SB.PCI0.LPCB.H_EC.BAT1._BIX] (Node ffff95f8ff0b20f0), AE_AML_PACKAGE_LIMIT (20160422/psparse-542)
    
    The _BIF method does succeed and returns convincing data. We detect _BIX
    failing and automatically retry with _BIF.
    Signed-off-by: default avatarDave Lambley <linux@davel.me.uk>
    Signed-off-by: default avatarRafael J. Wysocki <rafael.j.wysocki@intel.com>
    2d09af4a
battery.c 38.5 KB