Skip to contentSkip to conversation

Torture-test updates for v5.13

PATCH New Paul E. McKenney 1 participant 3 messages Mar 4, 2021

Subsystems (2)
lore
Share & tools
lore

Paul E. McKenney

author maintainer
#0 lore raw

cover Torture-test updates for v5.13

Hello!

This series contains a couple of torture-test updates:

1. Replace torture_init_begin string with %s, courtesy of Stephen
Zhang.

2. Replace rcu_torture_stall string with %s, courtesy of Stephen
Zhang.

Thanx, Paul

------------------------------------------------------------------------

 rcu/rcutorture.c |    6 +++---
 torture.c        |    6 +++---
 2 files changed, 6 insertions(+), 6 deletions(-)
author maintainer
#1 lore raw

PATCH 1/2 torture: Replace torture_init_begin string with %s

From: Stephen Zhang <[email protected]>

This commit replaces a hard-coded "torture_init_begin" string in a pr_alert() format with "%s" and __func__.

---
 kernel/torture.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)
kernel/torture.c +3 -3
index 01e336f..0a315c3 100644
@@ -816,9 +816,9 @@ bool torture_init_begin(char *ttype, int v)
 {
 	mutex_lock(&fullstop_mutex);
 	if (torture_type != NULL) {
-		pr_alert("torture_init_begin: Refusing %s init: %s running.\n",
-			 ttype, torture_type);
-		pr_alert("torture_init_begin: One torture test at a time!\n");
+		pr_alert("%s: Refusing %s init: %s running.\n",
+			  __func__, ttype, torture_type);
+		pr_alert("%s: One torture test at a time!\n", __func__);
 		mutex_unlock(&fullstop_mutex);
 		return false;
 	}
Signature · 1 line
2.9.5
author maintainer
#2 lore raw

PATCH 2/2 rcutorture: Replace rcu_torture_stall string with %s

In reply to Paul E. McKenney

From: Stephen Zhang <[email protected]>

This commit replaces a hard-coded "rcu_torture_stall" string in a pr_alert() format with "%s" and __func__.

---
 kernel/rcu/rcutorture.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)
kernel/rcu/rcutorture.c +3 -3
index 99657ff..271726e 100644
@@ -1971,8 +1971,8 @@ static int rcu_torture_stall(void *args)
 			local_irq_disable();
 		else if (!stall_cpu_block)
 			preempt_disable();
-		pr_alert("rcu_torture_stall start on CPU %d.\n",
-			 raw_smp_processor_id());
+		pr_alert("%s start on CPU %d.\n",
+			  __func__, raw_smp_processor_id());
 		while (ULONG_CMP_LT((unsigned long)ktime_get_seconds(),
 				    stop_at))
 			if (stall_cpu_block)
@@ -1983,7 +1983,7 @@ static int rcu_torture_stall(void *args)
 			preempt_enable();
 		cur_ops->readunlock(idx);
 	}
-	pr_alert("rcu_torture_stall end.\n");
+	pr_alert("%s end.\n", __func__);
 	torture_shutdown_absorb("rcu_torture_stall");
 	while (!kthread_should_stop())
 		schedule_timeout_interruptible(10 * HZ);
Signature · 1 line
2.9.5