• Zhang Rui's avatar
    ACPI: bugfix reporting of event handler status · ed206fac
    Zhang Rui authored
    Introduce a new flag showing whether the event has an event handler/method.
    
    For all the GPEs and Fixed Events,
     1. ACPI_EVENT_FLAG_HANDLE is cleared, it's an "invalid" ACPI event.
     2. Both ACPI_EVENT_FLAG_HANDLE and ACPI_EVENT_FLAG_DISABLE are set,
        it's "disabled".
     3. Both ACPI_EVENT_FLAG_HANDLE and ACPI_EVENT_FLAG_ENABLE are set,
        it's "enabled".
     4. Both ACPI_EVENT_FLAG_HANDLE and ACPI_EVENT_FLAG_WAKE_ENABLE are set,
        it's "wake_enabled".
    
    Among other things, this prevents incorrect reporting of ACPI events
    as being "invalid" when it's really just (temporarily) "disabled".
    Signed-off-by: default avatarZhang Rui <rui.zhang@intel.com>
    Signed-off-by: default avatarDavid Brownell <dbrownell@users.sourceforge.net>
    Signed-off-by: default avatarLen Brown <len.brown@intel.com>
    ed206fac
system.c 15.8 KB