diff options
author | Slava Pestov <sp@daterainc.com> | 2014-05-23 14:18:35 -0400 |
---|---|---|
committer | Kent Overstreet <kmo@daterainc.com> | 2014-08-04 18:23:03 -0400 |
commit | 913dc33fb2720fb5f979011664294137ddd8b13b (patch) | |
tree | 2c32d5afad1625a9f39ef0efdc2c1b89be7c8c46 | |
parent | 60ae81eee86dd7a520db8c1e3d702b49fc0418b5 (diff) |
bcache: fix crash in bcache_btree_node_alloc_fail tracepoint
'b' was NULL.
Change-Id: Icac0fd04afa2d23f213d96d51afd53374e6dd0c0
-rw-r--r-- | drivers/md/bcache/btree.c | 2 | ||||
-rw-r--r-- | include/trace/events/bcache.h | 6 |
2 files changed, 4 insertions, 4 deletions
diff --git a/drivers/md/bcache/btree.c b/drivers/md/bcache/btree.c index 39c7f5b73724..f8237856a61b 100644 --- a/drivers/md/bcache/btree.c +++ b/drivers/md/bcache/btree.c | |||
@@ -1096,7 +1096,7 @@ err_free: | |||
1096 | err: | 1096 | err: |
1097 | mutex_unlock(&c->bucket_lock); | 1097 | mutex_unlock(&c->bucket_lock); |
1098 | 1098 | ||
1099 | trace_bcache_btree_node_alloc_fail(b); | 1099 | trace_bcache_btree_node_alloc_fail(c); |
1100 | return b; | 1100 | return b; |
1101 | } | 1101 | } |
1102 | 1102 | ||
diff --git a/include/trace/events/bcache.h b/include/trace/events/bcache.h index 6778e4135a8e..981acf74b14f 100644 --- a/include/trace/events/bcache.h +++ b/include/trace/events/bcache.h | |||
@@ -261,9 +261,9 @@ DEFINE_EVENT(btree_node, bcache_btree_node_alloc, | |||
261 | TP_ARGS(b) | 261 | TP_ARGS(b) |
262 | ); | 262 | ); |
263 | 263 | ||
264 | DEFINE_EVENT(btree_node, bcache_btree_node_alloc_fail, | 264 | DEFINE_EVENT(cache_set, bcache_btree_node_alloc_fail, |
265 | TP_PROTO(struct btree *b), | 265 | TP_PROTO(struct cache_set *c), |
266 | TP_ARGS(b) | 266 | TP_ARGS(c) |
267 | ); | 267 | ); |
268 | 268 | ||
269 | DEFINE_EVENT(btree_node, bcache_btree_node_free, | 269 | DEFINE_EVENT(btree_node, bcache_btree_node_free, |