Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 86811
b: refs/heads/master
c: 544adb4
h: refs/heads/master
i:
  86809: 162796f
  86807: 1f9fdab
v: v3
  • Loading branch information
Jesper Juhl authored and Linus Torvalds committed Mar 5, 2008
1 parent e36f0a9 commit 6f26d25
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 5 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 7088655477b51a5a248fa54190388e1283ba7ebf
refs/heads/master: 544adb41077a10d299a1094f12ec55a5843a9bdb
9 changes: 5 additions & 4 deletions trunk/kernel/marker.c
Original file line number Diff line number Diff line change
Expand Up @@ -698,27 +698,28 @@ int marker_probe_unregister(const char *name,
{
struct marker_entry *entry;
struct marker_probe_closure *old;
int ret = 0;
int ret = -ENOENT;

mutex_lock(&markers_mutex);
entry = get_marker(name);
if (!entry) {
ret = -ENOENT;
if (!entry)
goto end;
}
if (entry->rcu_pending)
rcu_barrier();
old = marker_entry_remove_probe(entry, probe, probe_private);
mutex_unlock(&markers_mutex);
marker_update_probes(); /* may update entry */
mutex_lock(&markers_mutex);
entry = get_marker(name);
if (!entry)
goto end;
entry->oldptr = old;
entry->rcu_pending = 1;
/* write rcu_pending before calling the RCU callback */
smp_wmb();
call_rcu(&entry->rcu, free_old_closure);
remove_marker(name); /* Ignore busy error message */
ret = 0;
end:
mutex_unlock(&markers_mutex);
return ret;
Expand Down

0 comments on commit 6f26d25

Please sign in to comment.