summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPaolo Bonzini <pbonzini@redhat.com>2012-07-05 17:16:23 +0200
committerAvi Kivity <avi@redhat.com>2012-07-12 14:06:12 +0300
commitebe7acea532fba4a0ad7aaf74e59bff729867d93 (patch)
tree5314160e5a29cf2ebabe87bac4eada2aecd20c6b
parent2ec10b952b40d287037a50387a8b66d9ccc5124b (diff)
event_notifier: remove event_notifier_test
The function is useless (and unused). Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> Signed-off-by: Avi Kivity <avi@redhat.com>
-rw-r--r--event_notifier.c15
-rw-r--r--event_notifier.h1
2 files changed, 0 insertions, 16 deletions
diff --git a/event_notifier.c b/event_notifier.c
index 2b210f4b44..c339bfee50 100644
--- a/event_notifier.c
+++ b/event_notifier.c
@@ -51,18 +51,3 @@ int event_notifier_test_and_clear(EventNotifier *e)
int r = read(e->fd, &value, sizeof(value));
return r == sizeof(value);
}
-
-int event_notifier_test(EventNotifier *e)
-{
- uint64_t value;
- int r = read(e->fd, &value, sizeof(value));
- if (r == sizeof(value)) {
- /* restore previous value. */
- int s = write(e->fd, &value, sizeof(value));
- /* never blocks because we use EFD_SEMAPHORE.
- * If we didn't we'd get EAGAIN on overflow
- * and we'd have to write code to ignore it. */
- assert(s == sizeof(value));
- }
- return r == sizeof(value);
-}
diff --git a/event_notifier.h b/event_notifier.h
index efca852d10..9b2edf41a7 100644
--- a/event_notifier.h
+++ b/event_notifier.h
@@ -24,6 +24,5 @@ void event_notifier_cleanup(EventNotifier *);
int event_notifier_get_fd(EventNotifier *);
int event_notifier_set(EventNotifier *);
int event_notifier_test_and_clear(EventNotifier *);
-int event_notifier_test(EventNotifier *);
#endif