mfd: cros_ec: Add ACPI GPE handler for LID0 devices
This patch installs an ACPI GPE handler for LID0 ACPI device to indicate ACPI core that this GPE should stay enabled for lid to work in suspend to idle path. Signed-off-by: Archana Patni <archana.patni@intel.com> Signed-off-by: Thierry Escande <thierry.escande@collabora.com> Signed-off-by: Lee Jones <lee.jones@linaro.org>
This commit is contained in:
@@ -304,4 +304,22 @@ extern struct attribute_group cros_ec_attr_group;
|
||||
extern struct attribute_group cros_ec_lightbar_attr_group;
|
||||
extern struct attribute_group cros_ec_vbc_attr_group;
|
||||
|
||||
/* ACPI GPE handler */
|
||||
#ifdef CONFIG_ACPI
|
||||
|
||||
int cros_ec_acpi_install_gpe_handler(struct device *dev);
|
||||
void cros_ec_acpi_remove_gpe_handler(void);
|
||||
void cros_ec_acpi_clear_gpe(void);
|
||||
|
||||
#else /* CONFIG_ACPI */
|
||||
|
||||
static inline int cros_ec_acpi_install_gpe_handler(struct device *dev)
|
||||
{
|
||||
return -ENODEV;
|
||||
}
|
||||
static inline void cros_ec_acpi_remove_gpe_handler(void) {}
|
||||
static inline void cros_ec_acpi_clear_gpe(void) {}
|
||||
|
||||
#endif /* CONFIG_ACPI */
|
||||
|
||||
#endif /* __LINUX_MFD_CROS_EC_H */
|
||||
|
Reference in New Issue
Block a user