[tip: core/rcu] torture: Set kvm.sh language to English

From: tip-bot2 for Paul E. McKenney
Date: Wed Jun 30 2021 - 09:50:43 EST


The following commit has been merged into the core/rcu branch of tip:

Commit-ID: 00ad25f6019b3bd61bd2ddc128509728b49ac589
Gitweb: https://git.kernel.org/tip/00ad25f6019b3bd61bd2ddc128509728b49ac589
Author: Paul E. McKenney <paulmck@xxxxxxxxxx>
AuthorDate: Thu, 01 Apr 2021 15:26:56 -07:00
Committer: Paul E. McKenney <paulmck@xxxxxxxxxx>
CommitterDate: Mon, 10 May 2021 16:05:06 -07:00

torture: Set kvm.sh language to English

Some of the code invoked directly and indirectly from kvm.sh parses
the output of commands. This parsing assumes English, which can cause
failures if the user has set some other language. In a few cases,
there are language-independent commands available, but this is not
always the case. Therefore, as an alternative to polyglot parsing,
this commit sets the LANG environment variable to en_US.UTF-8.

Reported-by: Frederic Weisbecker <frederic@xxxxxxxxxx>
Signed-off-by: Paul E. McKenney <paulmck@xxxxxxxxxx>
---
tools/testing/selftests/rcutorture/bin/kvm.sh | 3 +++
1 file changed, 3 insertions(+)

diff --git a/tools/testing/selftests/rcutorture/bin/kvm.sh b/tools/testing/selftests/rcutorture/bin/kvm.sh
index fab3bd9..390bb97 100755
--- a/tools/testing/selftests/rcutorture/bin/kvm.sh
+++ b/tools/testing/selftests/rcutorture/bin/kvm.sh
@@ -20,6 +20,9 @@ mkdir $T

cd `dirname $scriptname`/../../../../../

+# This script knows only English.
+LANG=en_US.UTF-8; export LANG
+
dur=$((30*60))
dryrun=""
KVM="`pwd`/tools/testing/selftests/rcutorture"; export KVM