Fix: handle sys_futex() FUTEX_WAIT interrupted by signal
[urcu.git] / urcu / urcu_ref.h
index bce711619a8b77dfb5795e5aee8421964d6028ac..5579ca6c93caed06b69c6f35d31138d2e32fe650 100644 (file)
@@ -1,47 +1,2 @@
-#ifndef _URCU_REF_H
-#define _URCU_REF_H
-
-/*
- * Userspace RCU - Reference counting
- *
- * Copyright (C) 2009 Novell Inc.
- * Copyright (C) 2010 Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
- *
- * Author: Jan Blunck <jblunck@suse.de>
- *
- * This program is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License version 2.1 as
- * published by the Free  Software Foundation.
- */
-
-#include <assert.h>
-#include <urcu/uatomic_arch.h>
-
-struct urcu_ref {
-       long refcount; /* ATOMIC */
-};
-
-static inline void urcu_ref_set(struct urcu_ref *ref, long val)
-{
-       uatomic_set(&ref->refcount, val);
-}
-
-static inline void urcu_ref_init(struct urcu_ref *ref)
-{
-       urcu_ref_set(ref, 1);
-}
-
-static inline void urcu_ref_get(struct urcu_ref *ref)
-{
-       long res = uatomic_add_return(&ref->refcount, 1);
-       assert(res != 0);
-}
-
-static inline void urcu_ref_put(struct urcu_ref *ref,
-                               void (*release)(struct urcu_ref *))
-{
-       if (!uatomic_sub_return(&ref->refcount, 1))
-               release(ref);
-}
-
-#endif /* _URCU_REF_H */
+#warning "urcu/urcu_ref.h is deprecated. Please include urcu/ref.h instead."
+#include <urcu/ref.h>
This page took 0.02307 seconds and 4 git commands to generate.