aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPierre Gondois <[email protected]>2024-01-04 17:49:34 +0100
committerAndrew Morton <[email protected]>2024-02-22 15:38:51 -0800
commit3fa2601e4a1fe3ec8068f7bee41a13afa061f6ae (patch)
treed0e8164839243254754be1b9d4879bb1b4ff5dc5
parenta43c47561e46cbefc6a2fe2c3f8f6bda0e553a83 (diff)
binder: use of hlist_count_nodes()
Make use of the newly added hlist_count_nodes(). Link: https://lkml.kernel.org/r/[email protected] Signed-off-by: Pierre Gondois <[email protected]> Acked-by: Carlos Llamas <[email protected]> Acked-by: Marco Elver <[email protected]> Reviewed-by: Andy Shevchenko <[email protected]> Cc: Arve Hjønnevåg <[email protected]> Cc: Christian Brauner <[email protected]> Cc: Coly Li <[email protected]> Cc: Greg Kroah-Hartman <[email protected]> Cc: Ingo Molnar <[email protected]> Cc: Jani Nikula <[email protected]> Cc: Joel Fernandes (Google) <[email protected]> Cc: Kees Cook <[email protected]> Cc: Kent Overstreet <[email protected]> Cc: Martijn Coenen <[email protected]> Cc: Suren Baghdasaryan <[email protected]> Cc: Todd Kjos <[email protected]> Signed-off-by: Andrew Morton <[email protected]>
-rw-r--r--drivers/android/binder.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/drivers/android/binder.c b/drivers/android/binder.c
index eca24f41556d..bad28cf42010 100644
--- a/drivers/android/binder.c
+++ b/drivers/android/binder.c
@@ -6086,9 +6086,7 @@ static void print_binder_node_nilocked(struct seq_file *m,
struct binder_work *w;
int count;
- count = 0;
- hlist_for_each_entry(ref, &node->refs, node_entry)
- count++;
+ count = hlist_count_nodes(&node->refs);
seq_printf(m, " node %d: u%016llx c%016llx hs %d hw %d ls %d lw %d is %d iw %d tr %d",
node->debug_id, (u64)node->ptr, (u64)node->cookie,