From nobody Mon Feb 9 23:18:17 2026 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of gnu.org designates 208.118.235.17 as permitted sender) client-ip=208.118.235.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Authentication-Results: mx.zohomail.com; spf=pass (zoho.com: domain of gnu.org designates 208.118.235.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org Return-Path: Received: from lists.gnu.org (lists.gnu.org [208.118.235.17]) by mx.zohomail.com with SMTPS id 1520965571436193.14615012086392; Tue, 13 Mar 2018 11:26:11 -0700 (PDT) Received: from localhost ([::1]:41875 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1evock-0003kP-K0 for importer@patchew.org; Tue, 13 Mar 2018 14:26:10 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:55198) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1evnoU-0008NO-Ln for qemu-devel@nongnu.org; Tue, 13 Mar 2018 13:34:15 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1evnoT-0007iV-Rz for qemu-devel@nongnu.org; Tue, 13 Mar 2018 13:34:14 -0400 Received: from mout.kundenserver.de ([212.227.126.133]:53305) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1evnoT-0007hV-Iz for qemu-devel@nongnu.org; Tue, 13 Mar 2018 13:34:13 -0400 Received: from localhost.localdomain ([78.238.229.36]) by mrelayeu.kundenserver.de (mreue005 [212.227.15.167]) with ESMTPSA (Nemesis) id 0LvxEH-1eZEOc0poL-017pJd; Tue, 13 Mar 2018 18:34:03 +0100 From: Laurent Vivier To: qemu-devel@nongnu.org Date: Tue, 13 Mar 2018 18:33:40 +0100 Message-Id: <20180313173355.4468-4-laurent@vivier.eu> X-Mailer: git-send-email 2.14.3 In-Reply-To: <20180313173355.4468-1-laurent@vivier.eu> References: <20180313173355.4468-1-laurent@vivier.eu> X-Provags-ID: V03:K0:DE52FzSxomF7po7fkowLcXnk0g90NTU+qsP2Vm1hUZJB16n3KWb JvoujtxcEYKXCASc98VLtl+YO7UGgc2Y8znchA8YhCT7hHPFSmFA14Juwso+oEw2CygNA1S H8kOO0458Wz69PHuRihcaXwUcRZYeCPZ4GgWhl2Ct+9rOdGywSTHbzYiBtbXqNgxqJchiw2 6JTLtpTYbqbFn4gRuSPcg== X-UI-Out-Filterresults: notjunk:1;V01:K0:fiwl8b3qfzE=:c1Vh1wTzPLy3rI5WCDdseF JPov1rEioJvpfzs3Gl6QHc+klSPnxvoK8fwX5UwOZ/jqQ5718yJLb2nsCEAT7HK4rg7UCEUS2 0ZkmYxp/9mKBr9MeweO+cswo+AXsaGSq007I5qrcfe5nYmhJVK1Hr4P56qxeT1fATjC5vBHX9 T7uocQElIFWOWY2ZscW3rjBVIQtOeZrThcsyQrZgvjJR+HLoltOyI6v0TibJUI6l1Y+3apJDX zYHNHKHXvIyaM51WeiDF6yQPV6PDdsXkJp49WIW+noIbC4cPNb2QTXYOyYFbpM2/WOE2a1OZI 8JApojGOqh3t1TOZqsZNAIyYz8iOfQ+qMdLR+wKAwzdWSzDKAJyN6Tt4nUTEwI7zOFxi0YsM9 c0lwF5O+tpPpe5n/7r/IVcLEu23E9PQoT5y2zpjHtcJ0KMPZfwtgPslmgZS3FwCquvdKP1+MX VVfaU36ZFjo2riU+LiuTXqpC2ARHWTwZRQjgvLCtnhkBLvyThiYXJct9UNxNuZspzxWHF77Ef YRoQ2wbd65Q+kITw2qgDluprQ3mUfRDoNTi8SI35cKPWIq+t/d3Ob0BFO7b4As4wYLrcoYdhO DOh0tUq7O57qKKTmPVg9ZwjkbmdqSzeWWS0oO0oVlQF+tCQAYugSPfzffMUpYtL4jmjTZEiaW zRo1AfbWzLLju1/O1IDMQWu6cJjtthTYz5ADdEIWsWu8FA/hW3USAefVPvuOawB3W2GyNsape vJUkb2W+i0fb3PKB/Gyy08hNFcBEM8TK4KfuWg== X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] [fuzzy] X-Received-From: 212.227.126.133 Subject: [Qemu-devel] [PULL 03/18] linux-user: allows to use "--systemd ALL" with qemu-binfmt-conf.sh X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Riku Voipio , Laurent Vivier Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" X-ZohoMail: RSF_0 Z_629925259 SPT_0 Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" qemu-binfmt-conf.sh when it is used with systemd needs to know for which CPU the systemd-binfmt.service file must be created (i.e. "--systemd ppc"). But sometime, for instance for test purpose, we need to create an entry for all known architectures. This patch entroduce the "ALL" parameter for this purpose. Signed-off-by: Laurent Vivier Message-Id: <20180308104859.3315-1-laurent@vivier.eu> --- scripts/qemu-binfmt-conf.sh | 25 ++++++++++++++----------- 1 file changed, 14 insertions(+), 11 deletions(-) diff --git a/scripts/qemu-binfmt-conf.sh b/scripts/qemu-binfmt-conf.sh index bdb21bdd58..edaa98b070 100755 --- a/scripts/qemu-binfmt-conf.sh +++ b/scripts/qemu-binfmt-conf.sh @@ -154,7 +154,8 @@ Usage: qemu-binfmt-conf.sh [--qemu-path PATH][--debian]= [--systemd CPU] instead generate update-binfmts templates --systemd: don't write into /proc, instead generate file for systemd-binfmt.service - for the given CPU + for the given CPU. If CPU is "ALL", generate a + file for all known cpus --exportdir: define where to write configuration files (default: $SYSTEMDDIR or $DEBIANDIR) --credential: if yes, credential and security tokens are @@ -301,18 +302,20 @@ while true ; do EXPORTDIR=3D${EXPORTDIR:-$SYSTEMDDIR} shift # check given cpu is in the supported CPU list - for cpu in ${qemu_target_list} ; do + if [ "$1" !=3D "ALL" ] ; then + for cpu in ${qemu_target_list} ; do + if [ "$cpu" =3D "$1" ] ; then + break + fi + done + if [ "$cpu" =3D "$1" ] ; then - break + qemu_target_list=3D"$1" + else + echo "ERROR: unknown CPU \"$1\"" 1>&2 + usage + exit 1 fi - done - - if [ "$cpu" =3D "$1" ] ; then - qemu_target_list=3D"$1" - else - echo "ERROR: unknown CPU \"$1\"" 1>&2 - usage - exit 1 fi ;; -Q|--qemu-path) --=20 2.14.3