diff options
author | Randall Spangler <rspangler@chromium.org> | 2013-10-18 10:38:07 -0700 |
---|---|---|
committer | chrome-internal-fetch <chrome-internal-fetch@google.com> | 2013-10-21 21:10:36 +0000 |
commit | d9530449fd75650a53d2ee8d9cfdc8ef063781b5 (patch) | |
tree | e04f409f01e555c6a05b228a965726ab055c35a6 /include/chipset.h | |
parent | 15e2fa02fdae240411df7a4e3298b988736a4499 (diff) | |
download | chrome-ec-d9530449fd75650a53d2ee8d9cfdc8ef063781b5.tar.gz |
cleanup: Consolidate power interrupts
Every chipset had its own header file just to declare a GPIO interrupt
handler. Since this seems to be a common feature of the power
interface, make a standard power_interrupt() API provided by
chipset.h. This lets us get rid of 4 include files, and makes it
easier to add more chipsets in the future.
BUG=chrome-os-partner:18343
BRANCH=none
TEST=build all boards; pass unit tests
Change-Id: I1fc5612d42625ea46e0a8e16a83085b66d476664
Signed-off-by: Randall Spangler <rspangler@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/173745
Diffstat (limited to 'include/chipset.h')
-rw-r--r-- | include/chipset.h | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/include/chipset.h b/include/chipset.h index ddf4eb3db0..728a6be4a4 100644 --- a/include/chipset.h +++ b/include/chipset.h @@ -75,6 +75,11 @@ void chipset_force_shutdown(void); */ void chipset_reset(int cold_reset); +/** + * Interrupt handler for power GPIO inputs. + */ +void power_interrupt(enum gpio_signal signal); + #else /* !HAS_TASK_CHIPSET */ /* * Allow other modules to compile if the chipset module is disabled. This is @@ -91,6 +96,8 @@ static inline void chipset_throttle_cpu(int throttle) { } static inline void chipset_force_shutdown(void) { } static inline void chipset_reset(int cold_reset) { } +#define power_interrupt NULL + #endif /* !HAS_TASK_CHIPSET */ #endif /* __CROS_EC_CHIPSET_H */ |