[lvc-project] [PATCH 5.10 1/1] rcutorture: Add missing return and use __func__ in warning
Fedor Pchelkin
pchelkin at ispras.ru
Fri Mar 15 14:55:54 MSK 2024
On Mon, 26. Feb 20:00, Daniil Dulov wrote:
> From: David Vernet <void at manifault.com>
>
> commit 80dcee695143255261f30c7cc2a041ba413717a4 upstream.
>
> The rcutorture module has an rcu_torture_writer task that repeatedly
> performs writes, synchronizations, and deletes. There is a corner-case
> check in rcu_torture_writer() wherein if nsynctypes is 0, a warning is
> issued and the task waits to be stopped via a call to
> torture_kthread_stopping() rather than performing any work.
>
> There should be a return statement following this call to
> torture_kthread_stopping(), as the intention with issuing the call to
> torture_kthread_stopping() in the first place is to avoid the
> rcu_torture_writer task from performing any work. Some of the work may even
> be dangerous to perform, such as potentially causing a #DE due to
> nsynctypes being used in a modulo operator when querying for sync updates
> to issue.
>
> This patch adds the missing return call. As a bonus, it also fixes a
> checkpatch warning that was emitted due to the WARN_ONCE() call using the
> name of the function rather than __func__.
>
> Signed-off-by: David Vernet <void at manifault.com>
> Signed-off-by: Paul E. McKenney <paulmck at kernel.org>
> Signed-off-by: Daniil Dulov <d.dulov at aladdin.ru>
Добавлено в ветку linux-5.10-lvc-next.
В публичной linux-5.10-lvc [1] появится при выходе ближайшего релиза.
Спасибо!
[1]: https://git.linuxtesting.ru/pub/scm/linux/kernel/git/lvc/linux-stable.git/log/
More information about the lvc-project
mailing list