From edd81e48a0045c440a722d313f3439ce793a86a6 Mon Sep 17 00:00:00 2001 From: Mathieu Desnoyers Date: Fri, 14 Nov 2008 17:47:35 -0500 Subject: [PATCH] --- yaml --- r: 121133 b: refs/heads/master c: 2bdba316c989da028a59becf7516c6350ce3c173 h: refs/heads/master i: 121131: 80fe54ab277ebddce8982058abc2a3f58589a259 v: v3 --- [refs] | 2 +- trunk/kernel/marker.c | 12 +++++++----- 2 files changed, 8 insertions(+), 6 deletions(-) diff --git a/[refs] b/[refs] index 74b21c1c9bf2..a8d9dd161936 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: 954e100d2275cb2f150f2b18d5cddcdf67b956ac +refs/heads/master: 2bdba316c989da028a59becf7516c6350ce3c173 diff --git a/trunk/kernel/marker.c b/trunk/kernel/marker.c index 2898b647d415..de683a7799e7 100644 --- a/trunk/kernel/marker.c +++ b/trunk/kernel/marker.c @@ -653,10 +653,11 @@ int marker_probe_register(const char *name, const char *format, goto end; } mutex_unlock(&markers_mutex); - marker_update_probes(); /* may update entry */ + marker_update_probes(); mutex_lock(&markers_mutex); entry = get_marker(name); - WARN_ON(!entry); + if (!entry) + goto end; if (entry->rcu_pending) rcu_barrier_sched(); entry->oldptr = old; @@ -697,7 +698,7 @@ int marker_probe_unregister(const char *name, rcu_barrier_sched(); old = marker_entry_remove_probe(entry, probe, probe_private); mutex_unlock(&markers_mutex); - marker_update_probes(); /* may update entry */ + marker_update_probes(); mutex_lock(&markers_mutex); entry = get_marker(name); if (!entry) @@ -778,10 +779,11 @@ int marker_probe_unregister_private_data(marker_probe_func *probe, rcu_barrier_sched(); old = marker_entry_remove_probe(entry, NULL, probe_private); mutex_unlock(&markers_mutex); - marker_update_probes(); /* may update entry */ + marker_update_probes(); mutex_lock(&markers_mutex); entry = get_marker_from_private_data(probe, probe_private); - WARN_ON(!entry); + if (!entry) + goto end; if (entry->rcu_pending) rcu_barrier_sched(); entry->oldptr = old;