rtc_qmsi: Add get_pending_int API
For AON peripherals on Quark SE C1000, an API is needed to retrieve the interrupt status after wake up. This enables the application to know the wake source before enabling again the interrupts. Add this API to the rtc as this is a wake event on Quark SE C1000. Jira: ZEP-1188 Change-Id: Id850ce405eb3f4857be720201e462ea8e24a334f Signed-off-by: Julien Delayen <julien.delayen@intel.com>
This commit is contained in:
parent
bd6285a3f1
commit
ee04a3f6d8
2 changed files with 29 additions and 0 deletions
|
@ -155,12 +155,18 @@ static uint32_t rtc_qmsi_read(struct device *dev)
|
|||
return QM_RTC[QM_RTC_0].rtc_ccvr;
|
||||
}
|
||||
|
||||
static uint32_t rtc_qmsi_get_pending_int(struct device *dev)
|
||||
{
|
||||
return QM_RTC[QM_RTC_0].rtc_stat;
|
||||
}
|
||||
|
||||
static const struct rtc_driver_api api = {
|
||||
.enable = rtc_qmsi_enable,
|
||||
.disable = rtc_qmsi_disable,
|
||||
.read = rtc_qmsi_read,
|
||||
.set_config = rtc_qmsi_set_config,
|
||||
.set_alarm = rtc_qmsi_set_alarm,
|
||||
.get_pending_int = rtc_qmsi_get_pending_int,
|
||||
};
|
||||
|
||||
static int rtc_qmsi_init(struct device *dev)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue