dsp: add blocking call support in event notifier

Add support for blocking call events in event notifier
to support functions which require waiting for events.

Change-Id: I255c19bc956506ea5076bb5fb1f09327141611a6
Signed-off-by: Ramprasad Katkam <katkam@codeaurora.org>
This commit is contained in:
Ramprasad Katkam
2018-08-31 03:29:24 +05:30
committed by Gerrit - the friendly Code Review server
parent 37e3245375
commit b5528d39f2
2 changed files with 60 additions and 0 deletions

View File

@@ -20,6 +20,9 @@
int msm_aud_evt_register_client(struct notifier_block *nb);
int msm_aud_evt_unregister_client(struct notifier_block *nb);
int msm_aud_evt_notifier_call_chain(unsigned long val, void *v);
int msm_aud_evt_blocking_register_client(struct notifier_block *nb);
int msm_aud_evt_blocking_unregister_client(struct notifier_block *nb);
int msm_aud_evt_blocking_notifier_call_chain(unsigned long val, void *v);
#else
static inline int msm_aud_evt_register_client(struct notifier_block *nb)
{
@@ -35,10 +38,31 @@ static inline int msm_aud_evt_notifier_call_chain(unsigned long val, void *v)
{
return -ENOSYS;
}
static inline int msm_aud_evt_blocking_register_client(
struct notifier_block *nb)
{
return -ENOSYS;
}
static inline int msm_aud_evt_blocking_unregister_client(
struct notifier_block *nb)
{
return -ENOSYS;
}
static inline int msm_aud_evt_blocking_notifier_call_chain(
unsigned long val, void *v)
{
return -ENOSYS;
}
#endif
enum {
MSM_AUD_DC_EVENT = 1,
SWR_WAKE_IRQ_REGISTER,
SWR_WAKE_IRQ_DEREGISTER,
SWR_WAKE_IRQ_EVENT,
};
#endif