From 9e8dd45164af05a5dab00324dd10b037f5bd1e2a Mon Sep 17 00:00:00 2001 From: Jan Kiszka Date: Mon, 20 Jun 2011 14:06:26 +0200 Subject: notifier: Pass data argument to callback This allows to pass additional information to the notifier callback which is useful if sender and receiver do not share any other distinct data structure. Will be used first for the clock reset notifier. Signed-off-by: Jan Kiszka Signed-off-by: Anthony Liguori --- notify.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'notify.h') diff --git a/notify.h b/notify.h index b40522f582..54fc57cec1 100644 --- a/notify.h +++ b/notify.h @@ -20,7 +20,7 @@ typedef struct Notifier Notifier; struct Notifier { - void (*notify)(Notifier *notifier); + void (*notify)(Notifier *notifier, void *data); QTAILQ_ENTRY(Notifier) node; }; @@ -38,6 +38,6 @@ void notifier_list_add(NotifierList *list, Notifier *notifier); void notifier_list_remove(NotifierList *list, Notifier *notifier); -void notifier_list_notify(NotifierList *list); +void notifier_list_notify(NotifierList *list, void *data); #endif -- cgit v1.2.1