1. 12 Jun, 2010 2 commits
    • Rafael J. Wysocki's avatar
      ACPI / ACPICA: Avoid writing full enable masks to GPE registers · c9a8bbb7
      Rafael J. Wysocki authored
      ACPICA uses acpi_hw_write_gpe_enable_reg() to re-enable a GPE after
      an event signaled by it has been handled.  However, this function
      writes the entire GPE enable mask to the GPE's enable register which
      may not be correct.  Namely, if one of the other GPEs in the same
      register was previously enabled by acpi_enable_gpe() and subsequently
      disabled using acpi_set_gpe(), acpi_hw_write_gpe_enable_reg() will
      re-enable it along with the target GPE.
      
      To fix this issue rework acpi_hw_write_gpe_enable_reg() so that it
      calls acpi_hw_low_set_gpe() with a special action value,
      ACPI_GPE_COND_ENABLE, that will make it only enable the GPE if the
      corresponding bit in its register's enable_for_run mask is set.
      Signed-off-by: default avatarRafael J. Wysocki <rjw@sisk.pl>
      Signed-off-by: default avatarLen Brown <len.brown@intel.com>
      c9a8bbb7
    • Rafael J. Wysocki's avatar
      ACPI / ACPICA: Fix low-level GPE manipulation code · fd247447
      Rafael J. Wysocki authored
      ACPICA uses acpi_ev_enable_gpe() for enabling GPEs at the low level,
      which is incorrect, because this function only enables the GPE if the
      corresponding bit in its enable register's enable_for_run mask is set.
      This causes acpi_set_gpe() to work incorrectly if used for enabling
      GPEs that were not previously enabled with acpi_enable_gpe().  As a
      result, among other things, wakeup-only GPEs are never enabled by
      acpi_enable_wakeup_device(), so the devices that use them are unable
      to wake up the system.
      
      To fix this issue remove acpi_ev_enable_gpe() and its counterpart
      acpi_ev_disable_gpe() and replace acpi_hw_low_disable_gpe() with
      acpi_hw_low_set_gpe() that will be used instead to manipulate GPE
      enable bits at the low level.  Make the users of acpi_ev_enable_gpe()
      and acpi_ev_disable_gpe() call acpi_hw_low_set_gpe() instead and
      make sure that GPE enable masks are only updated by acpi_enable_gpe()
      and acpi_disable_gpe() when GPE reference counters change from 0
      to 1 and from 1 to 0, respectively.
      Signed-off-by: default avatarRafael J. Wysocki <rjw@sisk.pl>
      Signed-off-by: default avatarLen Brown <len.brown@intel.com>
      fd247447
  2. 11 Jun, 2010 2 commits
  3. 20 Apr, 2010 13 commits
  4. 19 Apr, 2010 23 commits