mirror of https://gitee.com/openkylin/linux.git
powerpc/perf/24x7: use rb_entry
To make the code clearer, use rb_entry() instead of container_of() to deal with rbtree. Signed-off-by: Geliang Tang <geliangtang@gmail.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
This commit is contained in:
parent
7505a13f85
commit
c197922f0a
|
@ -571,7 +571,7 @@ static int event_uniq_add(struct rb_root *root, const char *name, int nl,
|
||||||
struct event_uniq *it;
|
struct event_uniq *it;
|
||||||
int result;
|
int result;
|
||||||
|
|
||||||
it = container_of(*new, struct event_uniq, node);
|
it = rb_entry(*new, struct event_uniq, node);
|
||||||
result = ev_uniq_ord(name, nl, domain, it->name, it->nl,
|
result = ev_uniq_ord(name, nl, domain, it->name, it->nl,
|
||||||
it->domain);
|
it->domain);
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue