rcutorture: Make cur_ops->format_gp_seqs take buffer length
authorPaul E. McKenney <paulmck@kernel.org>
Wed, 18 Dec 2024 18:23:06 +0000 (10:23 -0800)
committerBoqun Feng <boqun.feng@gmail.com>
Wed, 5 Feb 2025 15:14:39 +0000 (07:14 -0800)
commit7acc2d90151fe6f5d8409df44e10cd24a0296e9f
tree4028ea84e0f59c4c95fb4d78380c0baa052b516e
parent65e6ff0f31184bd9ce01c7bfef28558e6b70f96a
rcutorture: Make cur_ops->format_gp_seqs take buffer length

The Tree and Tiny implementations of rcutorture_format_gp_seqs() use
hard-coded constants for the length of the buffer that they format into.
This is of course an accident waiting to happen, so this commit therefore
makes them take a length argument.  The rcutorture calling code uses
ARRAY_SIZE() to safely compute this new argument.

Signed-off-by: Paul E. McKenney <paulmck@kernel.org>
Signed-off-by: Boqun Feng <boqun.feng@gmail.com>
kernel/rcu/rcu.h
kernel/rcu/rcutorture.c
kernel/rcu/tiny.c
kernel/rcu/tree.c