|
@@ -53,6 +53,54 @@ static acpi_status
|
|
acpi_hw_enable_wakeup_gpe_block(struct acpi_gpe_xrupt_info *gpe_xrupt_info,
|
|
acpi_hw_enable_wakeup_gpe_block(struct acpi_gpe_xrupt_info *gpe_xrupt_info,
|
|
struct acpi_gpe_block_info *gpe_block);
|
|
struct acpi_gpe_block_info *gpe_block);
|
|
|
|
|
|
|
|
+/******************************************************************************
|
|
|
|
+ *
|
|
|
|
+ * FUNCTION: acpi_hw_low_disable_gpe
|
|
|
|
+ *
|
|
|
|
+ * PARAMETERS: gpe_event_info - Info block for the GPE to be disabled
|
|
|
|
+ *
|
|
|
|
+ * RETURN: Status
|
|
|
|
+ *
|
|
|
|
+ * DESCRIPTION: Disable a single GPE in the enable register.
|
|
|
|
+ *
|
|
|
|
+ ******************************************************************************/
|
|
|
|
+
|
|
|
|
+acpi_status acpi_hw_low_disable_gpe(struct acpi_gpe_event_info *gpe_event_info)
|
|
|
|
+{
|
|
|
|
+ struct acpi_gpe_register_info *gpe_register_info;
|
|
|
|
+ acpi_status status;
|
|
|
|
+ u32 enable_mask;
|
|
|
|
+
|
|
|
|
+ /* Get the info block for the entire GPE register */
|
|
|
|
+
|
|
|
|
+ gpe_register_info = gpe_event_info->register_info;
|
|
|
|
+ if (!gpe_register_info) {
|
|
|
|
+ return (AE_NOT_EXIST);
|
|
|
|
+ }
|
|
|
|
+
|
|
|
|
+ /* Get current value of the enable register that contains this GPE */
|
|
|
|
+
|
|
|
|
+ status = acpi_hw_low_level_read(ACPI_GPE_REGISTER_WIDTH, &enable_mask,
|
|
|
|
+ &gpe_register_info->enable_address);
|
|
|
|
+ if (ACPI_FAILURE(status)) {
|
|
|
|
+ return (status);
|
|
|
|
+ }
|
|
|
|
+
|
|
|
|
+ /* Clear just the bit that corresponds to this GPE */
|
|
|
|
+
|
|
|
|
+ ACPI_CLEAR_BIT(enable_mask,
|
|
|
|
+ ((u32) 1 <<
|
|
|
|
+ (gpe_event_info->gpe_number -
|
|
|
|
+ gpe_register_info->base_gpe_number)));
|
|
|
|
+
|
|
|
|
+ /* Write the updated enable mask */
|
|
|
|
+
|
|
|
|
+ status = acpi_hw_low_level_write(ACPI_GPE_REGISTER_WIDTH, enable_mask,
|
|
|
|
+ &gpe_register_info->enable_address);
|
|
|
|
+
|
|
|
|
+ return (status);
|
|
|
|
+}
|
|
|
|
+
|
|
/******************************************************************************
|
|
/******************************************************************************
|
|
*
|
|
*
|
|
* FUNCTION: acpi_hw_write_gpe_enable_reg
|
|
* FUNCTION: acpi_hw_write_gpe_enable_reg
|
|
@@ -68,7 +116,7 @@ acpi_hw_enable_wakeup_gpe_block(struct acpi_gpe_xrupt_info *gpe_xrupt_info,
|
|
******************************************************************************/
|
|
******************************************************************************/
|
|
|
|
|
|
acpi_status
|
|
acpi_status
|
|
-acpi_hw_write_gpe_enable_reg(struct acpi_gpe_event_info *gpe_event_info)
|
|
|
|
|
|
+acpi_hw_write_gpe_enable_reg(struct acpi_gpe_event_info * gpe_event_info)
|
|
{
|
|
{
|
|
struct acpi_gpe_register_info *gpe_register_info;
|
|
struct acpi_gpe_register_info *gpe_register_info;
|
|
acpi_status status;
|
|
acpi_status status;
|