#include "channels.h"
#include "tracercore.h"
#include "tracer.h"
+#include "urcu.h"
extern struct marker __start___markers[] __attribute__((visibility("hidden")));
extern struct marker __stop___markers[] __attribute__((visibility("hidden")));
ret = ltt_channels_unregister(e->channel);
WARN_ON(ret);
/* Make sure the call_rcu has been executed */
- if (e->rcu_pending)
- rcu_barrier_sched();
+//ust// if (e->rcu_pending)
+//ust// rcu_barrier_sched();
kfree(e);
return 0;
}
* If we detect that a call_rcu is pending for this marker,
* make sure it's executed now.
*/
- if (entry->rcu_pending)
- rcu_barrier_sched();
+//ust// if (entry->rcu_pending)
+//ust// rcu_barrier_sched();
old = marker_entry_add_probe(entry, probe, probe_private);
if (IS_ERR(old)) {
ret = PTR_ERR(old);
entry = get_marker(channel, name);
if (!entry)
goto end;
- if (entry->rcu_pending)
- rcu_barrier_sched();
+//ust// if (entry->rcu_pending)
+//ust// rcu_barrier_sched();
entry->oldptr = old;
entry->rcu_pending = 1;
/* write rcu_pending before calling the RCU callback */
smp_wmb();
- call_rcu_sched(&entry->rcu, free_old_closure);
- /*synchronize_rcu(); free_old_closure();*/
+//ust// call_rcu_sched(&entry->rcu, free_old_closure);
+ synchronize_rcu(); free_old_closure(&entry->rcu);
goto end;
error_unregister_channel:
entry = get_marker(channel, name);
if (!entry)
goto end;
- if (entry->rcu_pending)
- rcu_barrier_sched();
+//ust// if (entry->rcu_pending)
+//ust// rcu_barrier_sched();
old = marker_entry_remove_probe(entry, probe, probe_private);
mutex_unlock(&markers_mutex);
entry = get_marker(channel, name);
if (!entry)
goto end;
- if (entry->rcu_pending)
- rcu_barrier_sched();
+//ust// if (entry->rcu_pending)
+//ust// rcu_barrier_sched();
entry->oldptr = old;
entry->rcu_pending = 1;
/* write rcu_pending before calling the RCU callback */
smp_wmb();
- call_rcu_sched(&entry->rcu, free_old_closure);
+//ust// call_rcu_sched(&entry->rcu, free_old_closure);
+ synchronize_rcu(); free_old_closure(&entry->rcu);
remove_marker(channel, name); /* Ignore busy error message */
ret = 0;
end:
ret = -ENOENT;
goto end;
}
- if (entry->rcu_pending)
- rcu_barrier_sched();
+//ust// if (entry->rcu_pending)
+//ust// rcu_barrier_sched();
old = marker_entry_remove_probe(entry, NULL, probe_private);
channel = kstrdup(entry->channel, GFP_KERNEL);
name = kstrdup(entry->name, GFP_KERNEL);
entry = get_marker(channel, name);
if (!entry)
goto end;
- if (entry->rcu_pending)
- rcu_barrier_sched();
+//ust// if (entry->rcu_pending)
+//ust// rcu_barrier_sched();
entry->oldptr = old;
entry->rcu_pending = 1;
/* write rcu_pending before calling the RCU callback */
smp_wmb();
- call_rcu_sched(&entry->rcu, free_old_closure);
+//ust// call_rcu_sched(&entry->rcu, free_old_closure);
+ synchronize_rcu(); free_old_closure(&entry->rcu);
/* Ignore busy error message */
remove_marker(channel, name);
end:
//#include <linux/types.h>
//#include <linux/rcupdate.h>
+#include "urcu.h"
#include "immediate.h"
#include "kernelcompat.h"
do { \
void **it_func; \
\
- rcu_read_lock_sched_notrace(); \
+ rcu_read_lock(); /*ust rcu_read_lock_sched_notrace(); */ \
it_func = rcu_dereference((tp)->funcs); \
if (it_func) { \
do { \
((void(*)(proto))(*it_func))(args); \
} while (*(++it_func)); \
} \
- rcu_read_unlock_sched_notrace(); \
+ rcu_read_unlock(); /*ust rcu_read_unlock_sched_notrace(); */ \
} while (0)
#define __CHECK_TRACE(name, generic, proto, args) \