From nobody Fri May 10 19:21:03 2024 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass(p=none dis=none) header.from=linaro.org ARC-Seal: i=1; a=rsa-sha256; t=1668178700; cv=none; d=zohomail.com; s=zohoarc; b=WkF1zCStObh+NtvBHdK2/o8PHfF2CJ6hlsAbjhZulQRcNoa+qt5Lt8jvbM1InWQ5lTe6rtcuvoBMntShz++3SA7CFtRYQoKlboLlAmfqBJ41wiZQNyltH9B9ozkAXCqtgQhCbbMt6920yUIiKHGykSlqbzFp+zQyXzbwMipGODk= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1668178700; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To; bh=XsIUPL4URppAX7w6NGrUdBT/BUmCRhwxzbv6AwfzKCA=; b=lgNvcw/g50QWtjzPrqfoWznAtdF+yG/MVkxkGbsiyLqcPT5nZoZRY2RKfaANRQ7EqlFkNssjxR8umEyDPG7f7zgoO7fglCMvPJKry6MtCXI4DRj2tWFXfH4vbpUkXzRoadUTyZkLaUeycWdENaPpHLBKsBuPlXcN4Kr7bd8j24E= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass header.from= (p=none dis=none) Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1668178700105533.5192570762217; Fri, 11 Nov 2022 06:58:20 -0800 (PST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1otVRa-000745-38; Fri, 11 Nov 2022 09:55:46 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1otVRO-000708-Ls for qemu-devel@nongnu.org; Fri, 11 Nov 2022 09:55:35 -0500 Received: from mail-wr1-x433.google.com ([2a00:1450:4864:20::433]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1otVRN-0007wS-3N for qemu-devel@nongnu.org; Fri, 11 Nov 2022 09:55:34 -0500 Received: by mail-wr1-x433.google.com with SMTP id w14so6773367wru.8 for ; Fri, 11 Nov 2022 06:55:32 -0800 (PST) Received: from zen.linaroharston ([185.81.254.11]) by smtp.gmail.com with ESMTPSA id q12-20020a05600c46cc00b003b4ac05a8a4sm11740229wmo.27.2022.11.11.06.55.30 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 11 Nov 2022 06:55:30 -0800 (PST) Received: from zen.lan (localhost [127.0.0.1]) by zen.linaroharston (Postfix) with ESMTP id 16F6E1FFB8; Fri, 11 Nov 2022 14:55:30 +0000 (GMT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=XsIUPL4URppAX7w6NGrUdBT/BUmCRhwxzbv6AwfzKCA=; b=HtrhliDQn7ww5CSLs9qkjc3/H9NCaHO6AI326r3eZ27wZVABgVxI2mwwi77VAmRWaS Ygtb2k/snzSDMeYrPzRSEk4+9pEjIe61a4XzMWmmI8JI0BInwgbH1nMDf0AnfIRWMfFp /fGRvFR2lbrPzwG7E4faFgHoojXljvMymXHFBRTR9QoxlbSJuuIuw8rvd0jwT6X3Nhtu aO5OoX69iL9nbzkLdwHqpCscjMloH4GXW+lhpYXkQK/nkGtiEZxWHm26bfFaJMxoC6dO c4kjHlKpBgdFq1FZKmIvW2N8PH4kxS/YF0lLUtWMx3VmLlBZC/nYZeklhLDct6c/bDOr lyVQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=XsIUPL4URppAX7w6NGrUdBT/BUmCRhwxzbv6AwfzKCA=; b=j91vbJokMZnpSXfvMOcRYtMcs0/8yZWVPItoXwx0HT23OhqgfmfI0YqhFvdbFxyGKU OmJ+sJFYhcfjApspzlIlEGJjiKm/KhdqsT4vnt+HyB1ZIWgGBkxRjxuJ4mkQsZk3w0Yf 8sok/cWt2ifh8jX9koVYJfFEgIn1A2NebL7ktXCOaFFuKrcB0/VQDmfR5q9atGqza2Ka LB/D7euUD/eIVN6EFYF7GePEsJbpa26iuIEtOLsRDpDpH9ZEzcTU064e+3506+xopu14 kbcXh9JoZZQOeYmJWY3evtv/iA9GGcKS1HBvPKFTHX9wcn/0OOL2BK9VekSorf5YRC1p +L1w== X-Gm-Message-State: ANoB5pk/NQ/GfxmzFdXNY11oTWpNQq+6+xiPFpMdhls/seYPnPH58msg NDLtqKsZDJQ+gh8s0hzTirGXOw== X-Google-Smtp-Source: AA0mqf6an5BShu2rU1uFIofrQtXMOHs5jKhK41eOfk0lNzpwuhE9Q7JEE/qg3ASMawRt3MPiq1ztbg== X-Received: by 2002:adf:f211:0:b0:23a:43b7:cdd5 with SMTP id p17-20020adff211000000b0023a43b7cdd5mr1445319wro.387.1668178531149; Fri, 11 Nov 2022 06:55:31 -0800 (PST) From: =?UTF-8?q?Alex=20Benn=C3=A9e?= To: qemu-devel@nongnu.org Cc: fam@euphon.net, berrange@redhat.com, f4bug@amsat.org, aurelien@aurel32.net, pbonzini@redhat.com, stefanha@redhat.com, crosa@redhat.com, Stefan Weil , =?UTF-8?q?Alex=20Benn=C3=A9e?= , Thomas Huth Subject: [PATCH v2 01/12] Run docker probe only if docker or podman are available Date: Fri, 11 Nov 2022 14:55:18 +0000 Message-Id: <20221111145529.4020801-2-alex.bennee@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20221111145529.4020801-1-alex.bennee@linaro.org> References: <20221111145529.4020801-1-alex.bennee@linaro.org> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=2a00:1450:4864:20::433; envelope-from=alex.bennee@linaro.org; helo=mail-wr1-x433.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: qemu-devel-bounces+importer=patchew.org@nongnu.org X-ZohoMail-DKIM: pass (identity @linaro.org) X-ZM-MESSAGEID: 1668178702310100005 From: Stefan Weil The docker probe uses "sudo -n" which can cause an e-mail with a security w= arning each time when configure is run. Therefore run docker probe only if either = docker or podman are available. That avoids the problematic "sudo -n" on build environments which have neit= her docker nor podman installed. Fixes: c4575b59155e2e00 ("configure: store container engine in config-host.= mak") Signed-off-by: Stefan Weil Message-Id: <20221030083510.310584-1-sw@weilnetz.de> Signed-off-by: Alex Benn=C3=A9e Reviewed-by: Thomas Huth --- configure | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/configure b/configure index 66928692b0..26c7bc5154 100755 --- a/configure +++ b/configure @@ -1780,7 +1780,7 @@ fi # functions to probe cross compilers =20 container=3D"no" -if test $use_containers =3D "yes"; then +if test $use_containers =3D "yes" && (has "docker" || has "podman"); then case $($python "$source_path"/tests/docker/docker.py probe) in *docker) container=3Ddocker ;; podman) container=3Dpodman ;; --=20 2.34.1 From nobody Fri May 10 19:21:03 2024 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass(p=none dis=none) header.from=linaro.org ARC-Seal: i=1; a=rsa-sha256; t=1668178708; cv=none; d=zohomail.com; s=zohoarc; b=ndxzpvqsx4b3iKq7AiQJ1DT/UUjxfqITuwmtpVmsYvpCHm8wPU8RnrajVbu9omB/Vg3WP95gjgO56ozeUkXslyM8QW4gcXnWQ5T4zibCuoe65VxY2eVWohk1CFxg3AeTyXUUu/aaqkdUTgc+4TnyN/8Sbn4FVrYZwcn+ajllxSE= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1668178708; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To; bh=75StTBtdrjatadUr5+DBEpHqiRy77mt4SctT5IRzcL0=; b=OCdaWKlQ+oeCl00+oxBaK17yg+wu2xi+q4Wiw2vAwL2kcxQhVQtKVm9I1gLoaYX524oq4xl5wVapeU/79ic+ivqDd3gEYxDkhtbmAcsCGdI1GX5UUNut7c4FXk/Q19JMJiuYJy0wLEfgCaJC40Kurtt2fSa6/utxyDR6PnHyC4E= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass header.from= (p=none dis=none) Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1668178708646388.9474446076023; Fri, 11 Nov 2022 06:58:28 -0800 (PST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1otVRa-00074R-4a; Fri, 11 Nov 2022 09:55:46 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1otVRR-00070h-Ld for qemu-devel@nongnu.org; Fri, 11 Nov 2022 09:55:38 -0500 Received: from mail-wm1-x32c.google.com ([2a00:1450:4864:20::32c]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1otVRO-0007wc-T1 for qemu-devel@nongnu.org; Fri, 11 Nov 2022 09:55:36 -0500 Received: by mail-wm1-x32c.google.com with SMTP id i10-20020a1c3b0a000000b003cfd36eff5fso655660wma.3 for ; Fri, 11 Nov 2022 06:55:34 -0800 (PST) Received: from zen.linaroharston ([185.81.254.11]) by smtp.gmail.com with ESMTPSA id b3-20020adff903000000b002366fb99cdasm2126461wrr.50.2022.11.11.06.55.30 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 11 Nov 2022 06:55:31 -0800 (PST) Received: from zen.lan (localhost [127.0.0.1]) by zen.linaroharston (Postfix) with ESMTP id 2E41B1FFBA; Fri, 11 Nov 2022 14:55:30 +0000 (GMT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=75StTBtdrjatadUr5+DBEpHqiRy77mt4SctT5IRzcL0=; b=ztsHlHrPcLJPcjESV0+FxRD8thgTLVajkWt9MP/FxRxNkGNCmIkcoHCqi7pAYsIs9U YsfOXln2gJ3ELN/ystPLYdmb0NDClSf4/a6kRzDiFTdkKwjeBUk0zqaQyoZ3+QfcHokC tRESEmriBYTdvO+lcCLh5h4BMhuzSlntWKdH1ItJOe7xbWdoL8828Olf88SAQtyA5Ly3 WVzMxXB52D9e4sTIj23seyn8GahD1YMymZpZxawMfO8MK8EbfB45Gx0jL/Vs6TlfAJ0e xnXb/XD9o+2mZdSFwPnuRJrO/QKvxj8e7sTky+7ghAvmadLyW2Kk7fjOvmCJwKUOtu3p uZ6Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=75StTBtdrjatadUr5+DBEpHqiRy77mt4SctT5IRzcL0=; b=rZeoKNqVEzv8uD+aq7k5EefF8mg/QT1XZrLjFP7sJGij7jWncydSFHqUWP5HePExAC u+ETjp6UZXzaUH1pBB7FxagChVsiDso/FSHAYRsgfNICUcZwEsQs9bir5wMsTT3t4AvW HIt/HwsB85ZRjGf+95euQBM5rP2yYpgrZEYl8g7G4Cir/UtbheYJs51GighOdR5naoKV WVkEDVUToaAeUPJ0pECVw63/LH/Gti2XTV0vQaz58wuRYtqBuI4N/R+SAv6tl/AjzSuJ vK8CYIIYKhDyCvzadgzrux1X4vQ5BxZEIUR7Ega0FW68+FHzbgLhM20/XW4rHfedSkDQ dQOw== X-Gm-Message-State: ANoB5pl6yzzxI1HFla5oaP9yua/C68BMc3TYKtjA9KKuWy5M6QA29/ps 0LwctIuyY9SDx/5k7dyrFc504g== X-Google-Smtp-Source: AA0mqf5ypihLRxhijYPdPaksSEPtGkMqMazC9GGjV5L4/nW0OlP09sN3sCXKbYYMnU+UaQB0Ne9D8w== X-Received: by 2002:a05:600c:358e:b0:3cf:8b53:747f with SMTP id p14-20020a05600c358e00b003cf8b53747fmr1537819wmq.192.1668178532563; Fri, 11 Nov 2022 06:55:32 -0800 (PST) From: =?UTF-8?q?Alex=20Benn=C3=A9e?= To: qemu-devel@nongnu.org Cc: fam@euphon.net, berrange@redhat.com, f4bug@amsat.org, aurelien@aurel32.net, pbonzini@redhat.com, stefanha@redhat.com, crosa@redhat.com, =?UTF-8?q?Alex=20Benn=C3=A9e?= , =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= , Wainer dos Santos Moschetta , Beraldo Leal Subject: [PATCH v2 02/12] tests/avocado: improve behaviour waiting for login prompts Date: Fri, 11 Nov 2022 14:55:19 +0000 Message-Id: <20221111145529.4020801-3-alex.bennee@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20221111145529.4020801-1-alex.bennee@linaro.org> References: <20221111145529.4020801-1-alex.bennee@linaro.org> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=2a00:1450:4864:20::32c; envelope-from=alex.bennee@linaro.org; helo=mail-wm1-x32c.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: qemu-devel-bounces+importer=patchew.org@nongnu.org X-ZohoMail-DKIM: pass (identity @linaro.org) X-ZM-MESSAGEID: 1668178710203100003 This attempts to deal with the problem of login prompts not being guaranteed to be terminated with a newline. The solution to this is to peek at the incoming data looking to see if we see an up-coming match before we fall back to the old readline() logic. The reason to mostly rely on readline is because I am occasionally seeing the peek stalling despite data being there. This seems kinda hacky and gross so I'm open to alternative approaches and cleaner python code. Signed-off-by: Alex Benn=C3=A9e Reviewed-by: Philippe Mathieu-Daud=C3=A9 --- v2 - remove superfluous /r/n --- tests/avocado/avocado_qemu/__init__.py | 89 +++++++++++++++++++++++++- 1 file changed, 88 insertions(+), 1 deletion(-) diff --git a/tests/avocado/avocado_qemu/__init__.py b/tests/avocado/avocado= _qemu/__init__.py index 910f3ba1ea..20cba57161 100644 --- a/tests/avocado/avocado_qemu/__init__.py +++ b/tests/avocado/avocado_qemu/__init__.py @@ -131,6 +131,58 @@ def pick_default_qemu_bin(bin_prefix=3D'qemu-system-',= arch=3DNone): return path return None =20 +def _peek_ahead(console, min_match, success_message): + """ + peek ahead in the console stream keeping an eye out for the + success message. + + Returns some message to process or None, indicating the normal + readline should occur. + """ + console_logger =3D logging.getLogger('console') + peek_len =3D 0 + retries =3D 0 + + while True: + try: + old_peek_len =3D peek_len + peek_ahead =3D console.peek(min_match).decode() + peek_len =3D len(peek_ahead) + + # if we get stuck too long lets just fallback to readline + if peek_len <=3D old_peek_len: + retries +=3D 1 + if retries > 10: + return None + + # if we see a newline in the peek we can let safely bail + # and let the normal readline() deal with it + if peek_ahead.endswith(('\n', '\r')): + return None + + # if we haven't seen enough for the whole message but the + # first part matches lets just loop again + if len(peek_ahead) < min_match and \ + success_message[:peek_len] in peek_ahead: + continue + + # if we see the whole success_message we are done, consume + # it and pass back so we can exit to the user + if success_message in peek_ahead: + return console.read(peek_len).decode() + + # of course if we've seen enough then this line probably + # doesn't contain what we are looking for, fallback + if peek_len > min_match: + return None + + except UnicodeDecodeError: + console_logger.log("error in decode of peek") + return None + + # we should never get here + return None + =20 def _console_interaction(test, success_message, failure_message, send_string, keep_sending=3DFalse, vm=3DNone): @@ -139,17 +191,52 @@ def _console_interaction(test, success_message, failu= re_message, vm =3D test.vm console =3D vm.console_socket.makefile(mode=3D'rb', encoding=3D'utf-8') console_logger =3D logging.getLogger('console') + + # Establish the minimum number of bytes we would need to + # potentially match against success_message + if success_message is not None: + min_match =3D len(success_message) + else: + min_match =3D 0 + + console_logger.debug("looking for %d:(%s), sending %s (always=3D%s)", + min_match, success_message, send_string, keep_sen= ding) + while True: + msg =3D None + + # First send our string, optionally repeating the send next + # cycle. if send_string: vm.console_socket.sendall(send_string.encode()) if not keep_sending: send_string =3D None # send only once + + # If the console has no data to read we briefly + # sleep before continuing. + if not console.readable(): + time.sleep(0.1) + continue + try: - msg =3D console.readline().decode().strip() + + # First we shall peek ahead for a potential match to cover wai= ting + # for lines without any newlines. + if min_match > 0: + msg =3D _peek_ahead(console, min_match, success_message) + + # otherwise we block here for a full line + if not msg: + msg =3D console.readline().decode().strip() + except UnicodeDecodeError: + console_logger.debug("skipped unicode error") msg =3D None + + # if nothing came out we continue and try again if not msg: continue + console_logger.debug(msg) if success_message is None or success_message in msg: break --=20 2.34.1 From nobody Fri May 10 19:21:03 2024 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass(p=none dis=none) header.from=linaro.org ARC-Seal: i=1; a=rsa-sha256; t=1668178624; cv=none; d=zohomail.com; s=zohoarc; b=hRyUqMCXlSJdMJIlM61cT96vSXSmqEGaLWMztp4VSn9ZCrMQnUfGgX3+et6ymNB7e94G0Nr+WfUN924kInnn6dZUR3VV4Bm2fKwJyfFLJDo7Zxv4mej9STrIBeDjOO9r98AcbPojkgTWaKphTnmWdPnjmhlVNu79jqOaylaPy84= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1668178624; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To; bh=qBC/zqhe+w8c2MXv32aYnBZCDh2hCBt3ueKfoisA7Og=; b=L0goOQeoZWlCR+STDmSytesFHSAFzbij/yZSYXBUm+DxaiNZ9cJz88ub50EsapOT5QlGBDWiyQLfYHrQRhSJYRtfi9AHEiKWbJNfKF+Wj+DUh/T8jT3qA5hIzYZi+BSQ/QpnfW8rRSBq5jJRUwn+TqE37v3Ah92uCzsRXxpkZQI= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass header.from= (p=none dis=none) Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1668178623964299.9873902198734; Fri, 11 Nov 2022 06:57:03 -0800 (PST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1otVRc-000761-PS; Fri, 11 Nov 2022 09:55:48 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1otVRZ-00073e-IO for qemu-devel@nongnu.org; Fri, 11 Nov 2022 09:55:45 -0500 Received: from mail-wr1-x42e.google.com ([2a00:1450:4864:20::42e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1otVRR-0007wr-E8 for qemu-devel@nongnu.org; Fri, 11 Nov 2022 09:55:45 -0500 Received: by mail-wr1-x42e.google.com with SMTP id o4so6796685wrq.6 for ; Fri, 11 Nov 2022 06:55:35 -0800 (PST) Received: from zen.linaroharston ([185.81.254.11]) by smtp.gmail.com with ESMTPSA id a26-20020a05600c225a00b003c21ba7d7d6sm2941674wmm.44.2022.11.11.06.55.30 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 11 Nov 2022 06:55:31 -0800 (PST) Received: from zen.lan (localhost [127.0.0.1]) by zen.linaroharston (Postfix) with ESMTP id 44DB01FFBB; Fri, 11 Nov 2022 14:55:30 +0000 (GMT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=qBC/zqhe+w8c2MXv32aYnBZCDh2hCBt3ueKfoisA7Og=; b=gp5Zjrazc6exjxIuGhuX/4RSkoj+jz2xD3mKno/aoPch/sgpDIxGdBR+YQajbE7/aK ZfKFqP2UYTyZQ0JSDWshKsSZMrW5s+2a37zEI8H5qHLiRV6y8OjGzkltZEU/CvfiAWPR Ji6twZe1TnxjoPRo8GK5pFM0YQEwC+g2e0ZagQYLpcuCa8SoWT/sWUrZXMVoqV7TcyFB PR0U0I0+Xxk9AVUg9ZoGHrfh3KZFonUktDUAYZ7FrHZO3eRkQsMy64qnpbXR490dlwYJ FOcSv1cDG1IIrS/x5y4C7buh5ZQWzhZUjNrYM2STkc4GT4QAXrgU+trxkkWC4ymFAmur X6ag== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=qBC/zqhe+w8c2MXv32aYnBZCDh2hCBt3ueKfoisA7Og=; b=7A8tSvcCAcmXTQQE/1lAxjk5GJtTlBkl4QL9hxhQwcv7hOYTsvkvVpVOEGKTjefbfl ybn6EuR2xmAs5tTxfbOac7RYO8Ir+Aaj8cini69dufQufLJgCxQ9oEjOMbEz8u5pW2P9 sqOGsVfPtWX7VYlQkP8nDuuerEoEajIg+lnFDcVJupuPEchiSDiP6wcqOBMfduGQWHRH 8Sg7DD4FkMm7F1dMNARSUdoewa5X/rs4jAxr4zjvi78/cbolxyEhgg5MvcsCJSJZGSI7 LXicW/J894iUbxPZXsvCwB6vvPWFokll1utaLkMdCzSTf/+3KP93VSlPNXRBqh5JOtX2 1m5A== X-Gm-Message-State: ANoB5pl9GNfsDk+2TCo6AwikvylnNByk5Hgc4d6JWHxNQQYM0hsgh67T SIEhqPl3+Qlugz1uDixXiCn3aQ== X-Google-Smtp-Source: AA0mqf5L2v+K9HRA0Z1adYZQEcEA+2TQeICxwg4VU2JWhktztlwFTA3ZhotA4GCq4U3eOa+RjI/QAw== X-Received: by 2002:adf:e78c:0:b0:236:704f:29f4 with SMTP id n12-20020adfe78c000000b00236704f29f4mr1486225wrm.11.1668178534336; Fri, 11 Nov 2022 06:55:34 -0800 (PST) From: =?UTF-8?q?Alex=20Benn=C3=A9e?= To: qemu-devel@nongnu.org Cc: fam@euphon.net, berrange@redhat.com, f4bug@amsat.org, aurelien@aurel32.net, pbonzini@redhat.com, stefanha@redhat.com, crosa@redhat.com, =?UTF-8?q?C=C3=A9dric=20Le=20Goater?= , =?UTF-8?q?Alex=20Benn=C3=A9e?= , =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= , Wainer dos Santos Moschetta , Beraldo Leal Subject: [PATCH v2 03/12] tests/avocado/machine_aspeed.py: Reduce noise on the console for SDK tests Date: Fri, 11 Nov 2022 14:55:20 +0000 Message-Id: <20221111145529.4020801-4-alex.bennee@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20221111145529.4020801-1-alex.bennee@linaro.org> References: <20221111145529.4020801-1-alex.bennee@linaro.org> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=2a00:1450:4864:20::42e; envelope-from=alex.bennee@linaro.org; helo=mail-wr1-x42e.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: qemu-devel-bounces+importer=patchew.org@nongnu.org X-ZohoMail-DKIM: pass (identity @linaro.org) X-ZM-MESSAGEID: 1668178625709100003 From: C=C3=A9dric Le Goater The Aspeed SDK images are based on OpenBMC which starts a lot of services. The output noise on the console can break from time to time the test waiting for the logging prompt. Change the U-Boot bootargs variable to add "quiet" to the kernel command line and reduce the output volume. This also drops the test on the CPU id which was nice to have but not essential. Signed-off-by: C=C3=A9dric Le Goater Message-Id: <20221104075347.370503-1-clg@kaod.org> Signed-off-by: Alex Benn=C3=A9e --- tests/avocado/machine_aspeed.py | 17 ++++++++++++----- 1 file changed, 12 insertions(+), 5 deletions(-) diff --git a/tests/avocado/machine_aspeed.py b/tests/avocado/machine_aspeed= .py index fba6527026..1fc385e1c8 100644 --- a/tests/avocado/machine_aspeed.py +++ b/tests/avocado/machine_aspeed.py @@ -12,6 +12,7 @@ from avocado_qemu import wait_for_console_pattern from avocado_qemu import exec_command from avocado_qemu import exec_command_and_wait_for_pattern +from avocado_qemu import interrupt_interactive_console_until_pattern from avocado.utils import archive from avocado import skipIf =20 @@ -182,6 +183,8 @@ def test_arm_ast2600_evb_buildroot(self): =20 class AST2x00MachineSDK(QemuSystemTest): =20 + EXTRA_BOOTARGS =3D ' quiet' + # FIXME: Although these tests boot a whole distro they are still # slower than comparable machine models. There may be some # optimisations which bring down the runtime. In the meantime they @@ -194,7 +197,7 @@ def wait_for_console_pattern(self, success_message, vm= =3DNone): failure_message=3D'Kernel panic - not syn= cing', vm=3Dvm) =20 - def do_test_arm_aspeed_sdk_start(self, image, cpu_id): + def do_test_arm_aspeed_sdk_start(self, image): self.require_netdev('user') self.vm.set_console() self.vm.add_args('-drive', 'file=3D' + image + ',if=3Dmtd,format= =3Draw', @@ -202,9 +205,13 @@ def do_test_arm_aspeed_sdk_start(self, image, cpu_id): self.vm.launch() =20 self.wait_for_console_pattern('U-Boot 2019.04') - self.wait_for_console_pattern('## Loading kernel from FIT Image') + interrupt_interactive_console_until_pattern( + self, 'Hit any key to stop autoboot:', 'ast#') + exec_command_and_wait_for_pattern( + self, 'setenv bootargs ${bootargs}' + self.EXTRA_BOOTARGS, 'as= t#') + exec_command_and_wait_for_pattern( + self, 'boot', '## Loading kernel from FIT Image') self.wait_for_console_pattern('Starting kernel ...') - self.wait_for_console_pattern('Booting Linux on physical CPU ' + c= pu_id) =20 @skipIf(os.getenv('GITLAB_CI'), 'Running on GitLab') def test_arm_ast2500_evb_sdk(self): @@ -221,7 +228,7 @@ def test_arm_ast2500_evb_sdk(self): archive.extract(image_path, self.workdir) =20 self.do_test_arm_aspeed_sdk_start( - self.workdir + '/ast2500-default/image-bmc', '0x0') + self.workdir + '/ast2500-default/image-bmc') self.wait_for_console_pattern('ast2500-default login:') =20 @skipIf(os.getenv('GITLAB_CI'), 'Running on GitLab') @@ -243,7 +250,7 @@ def test_arm_ast2600_evb_sdk(self): self.vm.add_args('-device', 'ds1338,bus=3Daspeed.i2c.bus.5,address=3D0x32'); self.do_test_arm_aspeed_sdk_start( - self.workdir + '/ast2600-default/image-bmc', '0xf00') + self.workdir + '/ast2600-default/image-bmc') self.wait_for_console_pattern('ast2600-default login:') exec_command_and_wait_for_pattern(self, 'root', 'Password:') exec_command_and_wait_for_pattern(self, '0penBmc', 'root@ast2600-d= efault:~#') --=20 2.34.1 From nobody Fri May 10 19:21:03 2024 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass(p=none dis=none) header.from=linaro.org ARC-Seal: i=1; a=rsa-sha256; t=1668178612; cv=none; d=zohomail.com; s=zohoarc; b=TqAi9vYyWRTLTo6XXZRUIQkC9WkhJl1ivBzL1RxDBLxOmwDiWRNWqicQcK9LGDzjx8PG/I2usCHR+2gC49tY1WngzpwGKvAsgU1yh4Ia/MDNNdqLwxvDyDXrFJUhl3lEPKZPK68UPJIWDv3kAqjPPukGFgHZL62hB5MjA22MFRM= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1668178612; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To; bh=7uXwU/1og6Y5YFCCkzlXH6mHIAZKAJashuR6BqLq8xE=; b=RaQ6jzz+Uv2Ozy6fKuHn4mxjLQZTvuAxgBRVWpYBHTTuVOqqRQCRWPM264cgpu+IWqa3UVhQKWUXHrljdtqCJgfIGHF67MnQzXV20lkRYHlOCA5N7Xkzjm6rGBUy+hpFS6FxX/vIICUjsTWPa+8/tccuqAKQ9HVUwlUs0X4RcEs= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass header.from= (p=none dis=none) Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1668178612022541.2607283801258; Fri, 11 Nov 2022 06:56:52 -0800 (PST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1otVRW-00072u-SP; Fri, 11 Nov 2022 09:55:42 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1otVRU-00072j-Vh for qemu-devel@nongnu.org; Fri, 11 Nov 2022 09:55:40 -0500 Received: from mail-wm1-x32b.google.com ([2a00:1450:4864:20::32b]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1otVRR-0007ws-EY for qemu-devel@nongnu.org; Fri, 11 Nov 2022 09:55:40 -0500 Received: by mail-wm1-x32b.google.com with SMTP id t25-20020a1c7719000000b003cfa34ea516so5644537wmi.1 for ; Fri, 11 Nov 2022 06:55:35 -0800 (PST) Received: from zen.linaroharston ([185.81.254.11]) by smtp.gmail.com with ESMTPSA id cy6-20020a056000400600b002416ecb8c33sm1802202wrb.105.2022.11.11.06.55.30 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 11 Nov 2022 06:55:32 -0800 (PST) Received: from zen.lan (localhost [127.0.0.1]) by zen.linaroharston (Postfix) with ESMTP id 5ECD41FFBC; Fri, 11 Nov 2022 14:55:30 +0000 (GMT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=7uXwU/1og6Y5YFCCkzlXH6mHIAZKAJashuR6BqLq8xE=; b=hISuD/8oCArKVnAiTPxR6SY2cVCunPN/PNrA6NKRnggfjKVi75e841i50s9ERTXpsF OB0Hclo2GKqviJSRwTTR2zd6HZ2cd+GHsCoxHwMJxD/JRHvWmRtgmCbVvmlU/LQnhqWD cPdf2BqLKj7JqAvNUM4iUc1vo0M+hNz/8TvddrlSXDWTUZM4FQLYeVSnRXOaQoREZcSS VjHKGbHG2nqMZjlZa7SBFo4OlC/RoNKcear6xo5O+9qpcqrU5VYGY4C6dif88jfEyZ6+ DNrLEs+I2V7FmlAoO9gzddNL55UgnAmV+XEN/FxFwDI7SmCGX2op9JGdIwcyEVJ1lnsH uv6A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=7uXwU/1og6Y5YFCCkzlXH6mHIAZKAJashuR6BqLq8xE=; b=r9bKdNNDu46NTzvRUPzrXaGE4MRgR91VBTkgJD0SpxpUeW4A6JGm1pRpuWWza0HGBK 6/R/94vnAYBUuIwXXG+vSPlRJcjnU7fsCCNAX8V8KNwjOAg31edJRkUFAz4eM5Eel9iD I4dLXwyTHS3ZMvSVz0znxOcob0+BO10gM0UI6g4NtUSI4rpBDAmsurzXZa9XjBwFhgMi W/HkN2e2+ncQrDX7ggp9DyldUvfhcnak7bQcketoq08FdErqTaKbZucAD8tphdT7a+yA 2c70sgKCkVwUObqt76PfYYAMGyWg0Yyd7O+hGN1AbNzVra/4WNChpzheQuD1E6BHTLtc Gg6A== X-Gm-Message-State: ANoB5pnvCEKUU6IC60L7EUbsz2m8Oq6gu9dCNUf4+PJ23aNuF+tcs5aF v2HWHKT/PIKpQVkLJNMcqlK7NQ== X-Google-Smtp-Source: AA0mqf6Y9NMwFfRuDv4pB6xWb9WnmoI+YiTAaw0h/hjLNc2DAIxotdHdez2Dn2kcIFY/RGWS1TQUNg== X-Received: by 2002:a1c:730a:0:b0:3cf:89c3:3837 with SMTP id d10-20020a1c730a000000b003cf89c33837mr1467779wmb.92.1668178534787; Fri, 11 Nov 2022 06:55:34 -0800 (PST) From: =?UTF-8?q?Alex=20Benn=C3=A9e?= To: qemu-devel@nongnu.org Cc: fam@euphon.net, berrange@redhat.com, f4bug@amsat.org, aurelien@aurel32.net, pbonzini@redhat.com, stefanha@redhat.com, crosa@redhat.com, =?UTF-8?q?Alex=20Benn=C3=A9e?= , =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= , Thomas Huth , Wainer dos Santos Moschetta , Beraldo Leal Subject: [PATCH v2 04/12] tests/docker: allow user to override check target Date: Fri, 11 Nov 2022 14:55:21 +0000 Message-Id: <20221111145529.4020801-5-alex.bennee@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20221111145529.4020801-1-alex.bennee@linaro.org> References: <20221111145529.4020801-1-alex.bennee@linaro.org> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=2a00:1450:4864:20::32b; envelope-from=alex.bennee@linaro.org; helo=mail-wm1-x32b.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: qemu-devel-bounces+importer=patchew.org@nongnu.org X-ZohoMail-DKIM: pass (identity @linaro.org) X-ZM-MESSAGEID: 1668178613539100003 This is useful when trying to bisect a particular failing test behind a docker run. For example: make docker-test-clang@fedora \ TARGET_LIST=3Darm-softmmu \ TEST_COMMAND=3D"meson test qtest-arm/qos-test" \ J=3D9 V=3D1 Signed-off-by: Alex Benn=C3=A9e Reviewed-by: Philippe Mathieu-Daud=C3=A9 --- v1 - fix s/target /target./ - CHECK_TARGET -> TEST_COMMAND --- tests/docker/Makefile.include | 2 ++ tests/docker/common.rc | 6 +++--- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/tests/docker/Makefile.include b/tests/docker/Makefile.include index c87f14477a..fc7a3b7e71 100644 --- a/tests/docker/Makefile.include +++ b/tests/docker/Makefile.include @@ -184,6 +184,7 @@ docker: @echo ' TARGET_LIST=3Da,b,c Override target list in builds.' @echo ' EXTRA_CONFIGURE_OPTS=3D"..."' @echo ' Extra configure options.' + @echo ' TEST_COMMAND=3D"..." Override the default `make check` targe= t.' @echo ' IMAGES=3D"a b c ..": Restrict available images to subset.' @echo ' TESTS=3D"x y z .." Restrict available tests to subset.' @echo ' J=3D[0..9]* Overrides the -jN parameter for make co= mmands' @@ -230,6 +231,7 @@ docker-run: docker-qemu-src $(if $(NETWORK),$(if $(subst $(NETWORK),,1),--net=3D$(NETWORK)),--net= =3Dnone) \ -e TARGET_LIST=3D$(subst $(SPACE),$(COMMA),$(TARGET_LIST)) \ -e EXTRA_CONFIGURE_OPTS=3D"$(EXTRA_CONFIGURE_OPTS)" \ + -e TEST_COMMAND=3D"$(TEST_COMMAND)" \ -e V=3D$V -e J=3D$J -e DEBUG=3D$(DEBUG) \ -e SHOW_ENV=3D$(SHOW_ENV) \ $(if $(NOUSER),, \ diff --git a/tests/docker/common.rc b/tests/docker/common.rc index e6f8cee0d6..9a33df2832 100755 --- a/tests/docker/common.rc +++ b/tests/docker/common.rc @@ -63,12 +63,12 @@ check_qemu() { # default to make check unless the caller specifies if [ $# =3D 0 ]; then - INVOCATION=3D"check" + INVOCATION=3D"${TEST_COMMAND:-make $MAKEFLAGS check}" else - INVOCATION=3D"$@" + INVOCATION=3D"make $MAKEFLAGS $@" fi =20 - make $MAKEFLAGS $INVOCATION + $INVOCATION } =20 test_fail() --=20 2.34.1 From nobody Fri May 10 19:21:03 2024 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass(p=none dis=none) header.from=linaro.org ARC-Seal: i=1; a=rsa-sha256; t=1668178679; cv=none; d=zohomail.com; s=zohoarc; b=ZEQs4TShGgZ8UXxWNbgt5dHJfR0B/5SJ+9uQWO9JJy/H6vcrdAEMd5gUVkD+EGL8lSicdVDGpajJXdbZr1CT+BEjQL1Ffef2chYJjFBjHrtoyR942QciTjTrxEMqJQEaV1l2VfDyASngqXX68mEXDFvqdXOQXwLTr62QLCBAyUM= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1668178679; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To; bh=PETkHCmmDlOk/l4eNJN9a+MTbBUaCZh7Q5yajW/EJQg=; b=L3raGv8qKDnlPq+2K/nbJD6mrKJ3Gw30Mlx1qlyu39nxxAYoI4IVopEdBKWUtzUJriyMHFanHEEJk1NXdVvVCZMEhI1WEFVZ/ZH2qwpaaX1Bql+WF6wNDJJOEbdQxRFbbcblIDqmM2U/JXzMRGpEKc2yKXgxYy2Jc8PUH0S1Plo= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass header.from= (p=none dis=none) Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1668178679798694.9062138298032; Fri, 11 Nov 2022 06:57:59 -0800 (PST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1otVRa-00074k-S4; Fri, 11 Nov 2022 09:55:46 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1otVRW-00072v-Os for qemu-devel@nongnu.org; Fri, 11 Nov 2022 09:55:42 -0500 Received: from mail-wr1-x431.google.com ([2a00:1450:4864:20::431]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1otVRS-0007wV-4N for qemu-devel@nongnu.org; Fri, 11 Nov 2022 09:55:42 -0500 Received: by mail-wr1-x431.google.com with SMTP id cl5so6774578wrb.9 for ; Fri, 11 Nov 2022 06:55:36 -0800 (PST) Received: from zen.linaroharston ([185.81.254.11]) by smtp.gmail.com with ESMTPSA id i11-20020a05600c354b00b003b4ff30e566sm3815281wmq.3.2022.11.11.06.55.31 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 11 Nov 2022 06:55:32 -0800 (PST) Received: from zen.lan (localhost [127.0.0.1]) by zen.linaroharston (Postfix) with ESMTP id 7BB3A1FFBD; Fri, 11 Nov 2022 14:55:30 +0000 (GMT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=PETkHCmmDlOk/l4eNJN9a+MTbBUaCZh7Q5yajW/EJQg=; b=lmqNFhAPd0uq4pdqXqI6JeP+inMkacYALfhJKy83/YTHUEOpoS0sAJU1TMa93K2siT crmNJ4Z9G8gnS33GWwGTBa04gmSm61Bzc9UAonZnqfJhxJcYljT6Qxvfq3l5nTpb2PwX vK4Gexd9TLd7ytpemHeDlW6ucnlOKqPtt1zVuOMvYP8xgaenzkSG/5He7a8PieYlznPs t5k7nwoApKHliG31NZKXAxgu2hm9c70I99LI/r/l2K4G2J+fxRTTHirN7UpYAgtOTbFH 03BOgZCKhmbimhfzBfHxGqY/BlTm85BVVl9Cbrd0vpGk9tIOtRjEcVbduyq9nlwhlVbx YO4Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=PETkHCmmDlOk/l4eNJN9a+MTbBUaCZh7Q5yajW/EJQg=; b=E2kJRIGi4TJYq4d9fhMQwsSXsGgX6e4BbG0a8F089U6PC1risEtSzVpWv89tRZv3n/ /eRfqyZNXNiZLhmSX0afB3wApHFWZBAPdODVzCLCsVywrZjvor7YnC0sFJeM4ZrSXRF6 RnTXPLFKd8OU3ahQ3VCUIBlD3Qi19G46z3N3/zyW/+ObLsBnw0Tyt/en2TWw+KSAPGod Ire2UAt+REhJIOyoUuCXJTG3GV90+pU+9ynKHjHXLB2Zl8RgJSdp6obky4ilfkBpoef3 w6izP5fkTRYow7tyYXzl64fk53RZMHSiVpYb04opaBMJ9dBGH8mNF8KmZRrP5DqArN71 duug== X-Gm-Message-State: ANoB5pkf/iwoov3swsoGUAB5Pw0hX8ULNPOBdzuq8FAMaEwerTZWOEGw wcVDPS/NxrcdK75ljLmOEHW1Qg== X-Google-Smtp-Source: AA0mqf4nW7Yi83FO1boqUlsNSl/PhhZnwVCjFsZ6xjf/cL95S8U/Pnu3rrbLZ2FxJV5I5uAQViifUw== X-Received: by 2002:adf:fc8c:0:b0:235:9aae:35a6 with SMTP id g12-20020adffc8c000000b002359aae35a6mr1396708wrr.686.1668178536152; Fri, 11 Nov 2022 06:55:36 -0800 (PST) From: =?UTF-8?q?Alex=20Benn=C3=A9e?= To: qemu-devel@nongnu.org Cc: fam@euphon.net, berrange@redhat.com, f4bug@amsat.org, aurelien@aurel32.net, pbonzini@redhat.com, stefanha@redhat.com, crosa@redhat.com, =?UTF-8?q?Alex=20Benn=C3=A9e?= Subject: [PATCH v2 05/12] docs/devel: add a maintainers section to development process Date: Fri, 11 Nov 2022 14:55:22 +0000 Message-Id: <20221111145529.4020801-6-alex.bennee@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20221111145529.4020801-1-alex.bennee@linaro.org> References: <20221111145529.4020801-1-alex.bennee@linaro.org> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=2a00:1450:4864:20::431; envelope-from=alex.bennee@linaro.org; helo=mail-wr1-x431.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: qemu-devel-bounces+importer=patchew.org@nongnu.org X-ZohoMail-DKIM: pass (identity @linaro.org) X-ZM-MESSAGEID: 1668178682040100007 We don't currently have a clear place in the documentation to describe the roles and responsibilities of a maintainer. Lets create one so we can. I've moved a few small bits out of other files to try and keep everything in one place. Signed-off-by: Alex Benn=C3=A9e Reviewed-by: Stefan Hajnoczi Reviewed-by: Paolo Bonzini Message-Id: <20221012121152.1179051-2-alex.bennee@linaro.org> --- v2 - s/roll/role - s/projects/project's - mention looking after the long term health of area - add a section on becoming a reviewer - expand becoming section - add footnote about key signing --- docs/devel/code-of-conduct.rst | 2 + docs/devel/index-process.rst | 1 + docs/devel/maintainers.rst | 106 +++++++++++++++++++++++ docs/devel/submitting-a-pull-request.rst | 12 +-- 4 files changed, 113 insertions(+), 8 deletions(-) create mode 100644 docs/devel/maintainers.rst diff --git a/docs/devel/code-of-conduct.rst b/docs/devel/code-of-conduct.rst index 195444d1b4..f734ed0317 100644 --- a/docs/devel/code-of-conduct.rst +++ b/docs/devel/code-of-conduct.rst @@ -1,3 +1,5 @@ +.. _code_of_conduct: + Code of Conduct =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D =20 diff --git a/docs/devel/index-process.rst b/docs/devel/index-process.rst index d0d7a200fd..d50dd74c3e 100644 --- a/docs/devel/index-process.rst +++ b/docs/devel/index-process.rst @@ -8,6 +8,7 @@ Notes about how to interact with the community and how and = where to submit patch =20 code-of-conduct conflict-resolution + maintainers style submitting-a-patch trivial-patches diff --git a/docs/devel/maintainers.rst b/docs/devel/maintainers.rst new file mode 100644 index 0000000000..05110909d1 --- /dev/null +++ b/docs/devel/maintainers.rst @@ -0,0 +1,106 @@ +.. _maintainers: + +The Role of Maintainers +=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D + +Maintainers are a critical part of the project's contributor ecosystem. +They come from a wide range of backgrounds from unpaid hobbyists +working in their spare time to employees who work on the project as +part of their job. Maintainer activities include: + + - reviewing patches and suggesting changes + - collecting patches and preparing pull requests + - tending to the long term health of their area + - participating in other project activities + +They are also human and subject to the same pressures as everyone else +including overload and burnout. Like everyone else they are subject +to project's :ref:`code_of_conduct` and should also be exemplars of +excellent community collaborators. + +The MAINTAINERS file +-------------------- + +The `MAINTAINERS +`__ +file contains the canonical list of who is a maintainer. The file +is machine readable so an appropriately configured git (see +:ref:`cc_the_relevant_maintainer`) can automatically Cc them on +patches that touch their area of code. + +The file also describes the status of the area of code to give an idea +of how actively that section is maintained. + +.. list-table:: Meaning of support status in MAINTAINERS + :widths: 25 75 + :header-rows: 1 + + * - Status + - Meaning + * - Supported + - Someone is actually paid to look after this. + * - Maintained + - Someone actually looks after it. + * - Odd Fixes + - It has a maintainer but they don't have time to do + much other than throw the odd patch in. + * - Orphan + - No current maintainer. + * - Obsolete + - Old obsolete code, should use something else. + +Please bear in mind that even if someone is paid to support something +it does not mean they are paid to support you. This is open source and +the code comes with no warranty and the project makes no guarantees +about dealing with bugs or features requests. + + + +Becoming a reviewer +------------------- + +Most maintainers start by becoming subsystem reviewers. While anyone +is welcome to review code on the mailing list getting added to the +MAINTAINERS file with a line like:: + + R: Random Hacker + +will ensure that patches touching a given subsystem will automatically +be CC'd to you. + +Becoming a maintainer +--------------------- + +Maintainers are volunteers who put themselves forward or have been +asked by others to keep an eye on an area of code. They have generally +demonstrated to the community, usually via contributions and code +reviews, that they have a good understanding of the subsystem. They +are also trusted to make a positive contribution to the project and +work well with the other contributors. + +The process is simple - simply send a patch to the list that updates +the ``MAINTAINERS`` file. Sometimes this is done as part of a larger +series when a new sub-system is being added to the code base. This can +also be done by a retiring maintainer who nominates their replacement +after discussion with other contributors. + +Once the patch is reviewed and merged the only other step is to make +sure your GPG key is signed. + +.. _maintainer_keys: + +Maintainer GPG Keys +~~~~~~~~~~~~~~~~~~~ + +GPG is used to sign pull requests so they can be identified as really +coming from the maintainer. If your key is not already signed by +members of the QEMU community, you should make arrangements to attend +a `KeySigningParty `__ (for +example at KVM Forum) or make alternative arrangements to have your +key signed by an attendee. Key signing requires meeting another +community member **in person** [#]_ so please make appropriate +arrangements. + +.. [#] In recent pandemic times we have had to exercise some + flexibility here. Maintainers still need to sign their pull + requests though. diff --git a/docs/devel/submitting-a-pull-request.rst b/docs/devel/submitti= ng-a-pull-request.rst index c9d1e8afd9..a4cd7ebbb6 100644 --- a/docs/devel/submitting-a-pull-request.rst +++ b/docs/devel/submitting-a-pull-request.rst @@ -53,14 +53,10 @@ series) and that "make check" passes before sending out= the pull request. As a submaintainer you're one of QEMU's lines of defense against bad code, so double check the details. =20 -**All pull requests must be signed**. If your key is not already signed -by members of the QEMU community, you should make arrangements to attend -a `KeySigningParty `__ (for -example at KVM Forum) or make alternative arrangements to have your key -signed by an attendee. Key signing requires meeting another community -member \*in person\* so please make appropriate arrangements. By -"signed" here we mean that the pullreq email should quote a tag which is -a GPG-signed tag (as created with 'gpg tag -s ...'). +**All pull requests must be signed**. By "signed" here we mean that +the pullreq email should quote a tag which is a GPG-signed tag (as +created with 'gpg tag -s ...'). See :ref:`maintainer_keys` for +details. =20 **Pull requests not for master should say "not for master" and have "PULL SUBSYSTEM whatever" in the subject tag**. If your pull request is --=20 2.34.1 From nobody Fri May 10 19:21:03 2024 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass(p=none dis=none) header.from=linaro.org ARC-Seal: i=1; a=rsa-sha256; t=1668178659; cv=none; d=zohomail.com; s=zohoarc; b=EKnaSj4nmIWyDFb9IZu957Ly9ipmhrDmWhjU8RPmImtd8RbJDSDw3htHtH5aG+Jb3CxvEtkGrHKTZVT/aSdTmlidKEzLEUOj5ORPahrvn6uHjbjLJ7h0lKt4OPFtxrhwc2VdUoHUnib8LHdN0wQKsmDbva4RXz0srtS5c0R1Ngg= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1668178659; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To; bh=U0bUaw8dD9ywC6S/a5dl4BRNFGfCaE47JrvKC4nt86Q=; b=XPg6RKId3J1lGN5dhZuG6IqNPOLUXwx/2wl4wzKhT4m1UEQEiTsr0ZpqWHzZDBlIRHgQEJH8JK9lCe0mLrU2RYbq43yNbTQCEKT1mklLyNI3zdlZJfUrWDsNc/L+oB/zmlbU/aG9ykFTJZCeJvtZhJteoI3AJbCKdXKkyDWVWws= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass header.from= (p=none dis=none) Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1668178659888336.2824198943731; Fri, 11 Nov 2022 06:57:39 -0800 (PST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1otVRc-00075L-Cf; Fri, 11 Nov 2022 09:55:48 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1otVRW-00072s-Cl for qemu-devel@nongnu.org; Fri, 11 Nov 2022 09:55:42 -0500 Received: from mail-wr1-x433.google.com ([2a00:1450:4864:20::433]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1otVRT-0007wS-Hb for qemu-devel@nongnu.org; Fri, 11 Nov 2022 09:55:42 -0500 Received: by mail-wr1-x433.google.com with SMTP id w14so6773668wru.8 for ; Fri, 11 Nov 2022 06:55:36 -0800 (PST) Received: from zen.linaroharston ([185.81.254.11]) by smtp.gmail.com with ESMTPSA id r8-20020a05600c2f0800b003c701c12a17sm8502540wmn.12.2022.11.11.06.55.31 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 11 Nov 2022 06:55:32 -0800 (PST) Received: from zen.lan (localhost [127.0.0.1]) by zen.linaroharston (Postfix) with ESMTP id 911ED1FFBE; Fri, 11 Nov 2022 14:55:30 +0000 (GMT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=U0bUaw8dD9ywC6S/a5dl4BRNFGfCaE47JrvKC4nt86Q=; b=sIG5iSMC/omS9k1NJKAw5LBpio5CRXti6av7czKWEtxG+GPka1zuKgL/RwjXb7YHDL W29dLwrIDXABGqamAVAYs9w1aQ2QUXWDRoBm0Qes+6ohkyEUXoLAdb3nKxvWFuUk8Z5F xwg754ePJbrSQall5Fj/lEYpmktclvQxbvbF387tn4Fi13BeIRMqN2um8DGR3X9+cxHc 6zNifyiuE0/grvVogzBqB9Ne0mI+h1bPPCggiLNDQX1S1U8B1gCCaXadvaG2HOE3DpEg gxHfZRuY1BFckcNTZHSi/kue1J/MBpwlze8pF1+fDoM5FB2O6X/J39/H7h9iQMcCr8aW uchw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=U0bUaw8dD9ywC6S/a5dl4BRNFGfCaE47JrvKC4nt86Q=; b=O/lkgw3xkoWjBQAxHgZgHS+K8Opqu58bRZCTe36SWSlt/vDtfNO6spQopm6Ef5xUuk FZAf7Ugb9yPh2Q1jFlAIafhDSqn2i/E3/EQZvvrmV/Na2b2PgIZw53mToBlNwC6BmuGZ BNhnzWTyQTUWR1KKXou/032qgEgwIxPrhCgKhgr7oooTKNjhA/2WYw5ZB6Sy8yZKkL/V 75TTf8nYIGJK1pK6UJ35zrxugOzHqQ3LkjM7II7TzfT4X1mBMjF2VWOoJKCowFG2wLG2 SIusylbnmwZAbODT16WMMqc6VLTN1jhVcLMofCaDFAGEU39mn0tfuAnurLq1I4YpPem4 wP/g== X-Gm-Message-State: ANoB5pmrR2S1I5koCevNeEbrWwBQlwAqxgoEgi39bxHmXTLG3TezEYmJ X+WvltsgFOU3SKf0fdydltu6Vw== X-Google-Smtp-Source: AA0mqf7vUMI2bGdl7zt4PDfv1FGWkSpvP9xpuy9phtlkZGYPUrK407i7IT+uMKPZg8sjk676k3GYDg== X-Received: by 2002:adf:db4e:0:b0:236:bad6:44df with SMTP id f14-20020adfdb4e000000b00236bad644dfmr1390631wrj.489.1668178535683; Fri, 11 Nov 2022 06:55:35 -0800 (PST) From: =?UTF-8?q?Alex=20Benn=C3=A9e?= To: qemu-devel@nongnu.org Cc: fam@euphon.net, berrange@redhat.com, f4bug@amsat.org, aurelien@aurel32.net, pbonzini@redhat.com, stefanha@redhat.com, crosa@redhat.com, =?UTF-8?q?Alex=20Benn=C3=A9e?= Subject: [PATCH v2 06/12] docs/devel: make language a little less code centric Date: Fri, 11 Nov 2022 14:55:23 +0000 Message-Id: <20221111145529.4020801-7-alex.bennee@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20221111145529.4020801-1-alex.bennee@linaro.org> References: <20221111145529.4020801-1-alex.bennee@linaro.org> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=2a00:1450:4864:20::433; envelope-from=alex.bennee@linaro.org; helo=mail-wr1-x433.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: qemu-devel-bounces+importer=patchew.org@nongnu.org X-ZohoMail-DKIM: pass (identity @linaro.org) X-ZM-MESSAGEID: 1668178661964100003 We welcome all sorts of patches. Signed-off-by: Alex Benn=C3=A9e Reviewed-by: Stefan Hajnoczi Reviewed-by: Paolo Bonzini Message-Id: <20221012121152.1179051-3-alex.bennee@linaro.org> --- docs/devel/submitting-a-patch.rst | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/docs/devel/submitting-a-patch.rst b/docs/devel/submitting-a-pa= tch.rst index fec33ce148..9c7c4331f3 100644 --- a/docs/devel/submitting-a-patch.rst +++ b/docs/devel/submitting-a-patch.rst @@ -3,11 +3,11 @@ Submitting a Patch =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D =20 -QEMU welcomes contributions of code (either fixing bugs or adding new -functionality). However, we get a lot of patches, and so we have some -guidelines about submitting patches. If you follow these, you'll help -make our task of code review easier and your patch is likely to be -committed faster. +QEMU welcomes contributions to fix bugs, add functionality or improve +the documentation. However, we get a lot of patches, and so we have +some guidelines about submitting them. If you follow these, you'll +help make our task of code review easier and your patch is likely to +be committed faster. =20 This page seems very long, so if you are only trying to post a quick one-shot fix, the bare minimum we ask is that: --=20 2.34.1 From nobody Fri May 10 19:21:03 2024 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass(p=none dis=none) header.from=linaro.org ARC-Seal: i=1; a=rsa-sha256; t=1668178635; cv=none; d=zohomail.com; s=zohoarc; b=eOpvIu6IfqKyHbAp0Rswq8/ljAdOEc9pFtc157dIPowwJOz4w7oYH+QTotWGwPBOtOQ2wYULObXloK3belLUXWM7b2VCX8fHMbScke7mc0rmZIlRap980Xxa9O5tJ1oajkgAcmUHi34gWddQQfY5Ka3zdi5uZyYmQoivAZuseUQ= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1668178635; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To; bh=Tx51MAAfbml8CiT50HNaT+ihFTBqcLj/nxt/MFriuNA=; b=PSaIIbuEW3x1MB6cAZ00fwqjdNoEcMhsMob7Je2d4ykbW4lOI0dy7ooVtEU6OvDqY4dcsRuDfOPD9wiihv5hL3iuf/y0dY1LQg+TDTiFmh1yi7HZkWzfY+rXdh58e2XAbPIYnzh/fqAxKn8hgu7wB3H21R11eoDQeeHCA2+hAOA= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass header.from= (p=none dis=none) Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1668178635701467.6699194725593; Fri, 11 Nov 2022 06:57:15 -0800 (PST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1otVRb-00075B-OO; Fri, 11 Nov 2022 09:55:47 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1otVRW-00072w-QG for qemu-devel@nongnu.org; Fri, 11 Nov 2022 09:55:42 -0500 Received: from mail-wm1-x334.google.com ([2a00:1450:4864:20::334]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1otVRT-0007xS-IS for qemu-devel@nongnu.org; Fri, 11 Nov 2022 09:55:42 -0500 Received: by mail-wm1-x334.google.com with SMTP id m7-20020a05600c090700b003cf8a105d9eso3285052wmp.5 for ; Fri, 11 Nov 2022 06:55:38 -0800 (PST) Received: from zen.linaroharston ([185.81.254.11]) by smtp.gmail.com with ESMTPSA id y15-20020a5d614f000000b0022ae401e9e0sm2126489wrt.78.2022.11.11.06.55.31 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 11 Nov 2022 06:55:32 -0800 (PST) Received: from zen.lan (localhost [127.0.0.1]) by zen.linaroharston (Postfix) with ESMTP id A78B41FFBF; Fri, 11 Nov 2022 14:55:30 +0000 (GMT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=Tx51MAAfbml8CiT50HNaT+ihFTBqcLj/nxt/MFriuNA=; b=zHIJYHDPPlQgEPEMWsPKCWMwdePRvj8e9G/sTzxGSX7YrSxB4BeED0NVQBkerYmpJr BSTY5Je18CIP7suUj0MbbvUX0+o5z4s3OBRTSnmelnBZjMQUzhw0TCGRGIVFPyc+KNuD pc+BIh2/IKr4GWN/i3GkgMJkK4A1moCbDrDnek9/fCAIe2MMeofHGjxm4X+bkRliVT23 LvfLwRha4pM6gwCYHXc1Ix5MA/ZyOEoOfVPaEmtQp8tzUhrNbwQ6Qq+lOV0sveggb0bp Nz6/fmGoS8wPGUOJrFzjzvcxJVHuScEbml1IwT1yXbzTtN6Xx0FQDmVtQYhfjrL8f1ll HEjw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=Tx51MAAfbml8CiT50HNaT+ihFTBqcLj/nxt/MFriuNA=; b=npTB5aDBDHNqx3NJ0ByIDdoD5IsljuJDww+jVCF9ErK6tCLk8hHMfNlvaMrPebqRus Wc942aY8ubUXwXIuxv1bHfwcrYdAcQfer3yV6ctcaTDNb9l45r80qHQlgmZgTK4VWjVM PBdr2tIXNGwHDvSUk085IILzhMPsPEXbUi8/gm2w9pETHHLgUjqDA7TzyfP/L/vVLz/2 7kMqftK0X8FgYfH8uvNKsqcPLyhdfIuVWOK09GkEdUII4gZtNHEQ8SGaXrDDLqzBGw6Y 4WvjjZxNVnskHF+7yiJ9IkgVvbjuaKAtS7Nm7W++AtSdDQTGUmOs0KPyTj1sdr6RpES4 emTg== X-Gm-Message-State: ANoB5pncf0Lbjf8tmyuFuqYz9j86FwDlqbfPiCQ9YvXBRbIKLh23+NS5 t4UtcY7tz28hTUjD14Mgypipfw== X-Google-Smtp-Source: AA0mqf5B5TlpeHRd0S+YlxevfSZrMA49lOEq32gqNKB7mnFhfXgKz+disFDy7DZZ4XtbVqMTUFu06w== X-Received: by 2002:a7b:c04a:0:b0:3cf:a5b8:2a09 with SMTP id u10-20020a7bc04a000000b003cfa5b82a09mr1473816wmc.125.1668178537379; Fri, 11 Nov 2022 06:55:37 -0800 (PST) From: =?UTF-8?q?Alex=20Benn=C3=A9e?= To: qemu-devel@nongnu.org Cc: fam@euphon.net, berrange@redhat.com, f4bug@amsat.org, aurelien@aurel32.net, pbonzini@redhat.com, stefanha@redhat.com, crosa@redhat.com, =?UTF-8?q?Alex=20Benn=C3=A9e?= Subject: [PATCH v2 07/12] docs/devel: simplify the minimal checklist Date: Fri, 11 Nov 2022 14:55:24 +0000 Message-Id: <20221111145529.4020801-8-alex.bennee@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20221111145529.4020801-1-alex.bennee@linaro.org> References: <20221111145529.4020801-1-alex.bennee@linaro.org> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=2a00:1450:4864:20::334; envelope-from=alex.bennee@linaro.org; helo=mail-wm1-x334.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: qemu-devel-bounces+importer=patchew.org@nongnu.org X-ZohoMail-DKIM: pass (identity @linaro.org) X-ZM-MESSAGEID: 1668178637656100006 The bullet points are quite long and contain process tips. Move those bits of the bullet to the relevant sections and link to them. Use a table for nicer formatting of the checklist. Signed-off-by: Alex Benn=C3=A9e Reviewed-by: Stefan Hajnoczi Reviewed-by: Paolo Bonzini Message-Id: <20221012121152.1179051-4-alex.bennee@linaro.org> --- v2 - emphasise a Real Name should be used - s/therefor/therefore/ --- docs/devel/submitting-a-patch.rst | 75 ++++++++++++++++++++----------- 1 file changed, 49 insertions(+), 26 deletions(-) diff --git a/docs/devel/submitting-a-patch.rst b/docs/devel/submitting-a-pa= tch.rst index 9c7c4331f3..1f2bde0625 100644 --- a/docs/devel/submitting-a-patch.rst +++ b/docs/devel/submitting-a-patch.rst @@ -12,25 +12,18 @@ be committed faster. This page seems very long, so if you are only trying to post a quick one-shot fix, the bare minimum we ask is that: =20 -- You **must** provide a Signed-off-by: line (this is a hard - requirement because it's how you say "I'm legally okay to contribute - this and happy for it to go into QEMU", modeled after the `Linux kernel - `__ - policy.) ``git commit -s`` or ``git format-patch -s`` will add one. -- All contributions to QEMU must be **sent as patches** to the - qemu-devel `mailing list `__. - Patch contributions should not be posted on the bug tracker, posted on - forums, or externally hosted and linked to. (We have other mailing list= s too, - but all patches must go to qemu-devel, possibly with a Cc: to another - list.) ``git send-email`` (`step-by-step setup - guide `__ and `hints and - tips `__) - works best for delivering the patch without mangling it, but - attachments can be used as a last resort on a first-time submission. -- You must read replies to your message, and be willing to act on them. - Note, however, that maintainers are often willing to manually fix up - first-time contributions, since there is a learning curve involved in - making an ideal patch submission. +.. list-table:: Minimal Checklist for Patches + :widths: 35 65 + :header-rows: 1 + + * - Check + - Reason + * - Patches contain Signed-off-by: Real Name + - States you are legally able to contribute the code. See :ref:`patch= _emails_must_include_a_signed_off_by_line` + * - Sent as patch emails to ``qemu-devel@nongnu.org`` + - The project uses an email list based workflow. See :ref:`submitting= _your_patches` + * - Be prepared to respond to review comments + - Code that doesn't pass review will not get merged. See :ref:`partic= ipating_in_code_review` =20 You do not have to subscribe to post (list policy is to reply-to-all to preserve CCs and keep non-subscribers in the loop on the threads they @@ -229,6 +222,19 @@ bisection doesn't land on a known-broken state. Submitting your Patches ----------------------- =20 +The QEMU project uses a public email based workflow for reviewing and +merging patches. As a result all contributions to QEMU must be **sent +as patches** to the qemu-devel `mailing list +`__. Patch +contributions should not be posted on the bug tracker, posted on +forums, or externally hosted and linked to. (We have other mailing +lists too, but all patches must go to qemu-devel, possibly with a Cc: +to another list.) ``git send-email`` (`step-by-step setup guide +`__ and `hints and tips +`__) +works best for delivering the patch without mangling it, but +attachments can be used as a last resort on a first-time submission. + .. _if_you_cannot_send_patch_emails: =20 If you cannot send patch emails @@ -314,10 +320,12 @@ git repository to fetch the original commit. Patch emails must include a ``Signed-off-by:`` line ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ =20 -For more information see `SubmittingPatches 1.12 -`__. -This is vital or we will not be able to apply your patch! Please use -your real name to sign a patch (not an alias or acronym). +Your patches **must** include a Signed-off-by: line. This is a hard +requirement because it's how you say "I'm legally okay to contribute +this and happy for it to go into QEMU". The process is modelled after +the `Linux kernel +`__ +policy. =20 If you wrote the patch, make sure your "From:" and "Signed-off-by:" lines use the same spelling. It's okay if you subscribe or contribute to @@ -327,6 +335,11 @@ include a "From:" line in the body of the email (diffe= rent from your envelope From:) that will give credit to the correct author; but again, that author's Signed-off-by: line is mandatory, with the same spelling. =20 +There are various tooling options for automatically adding these tags +include using ``git commit -s`` or ``git format-patch -s``. For more +information see `SubmittingPatches 1.12 +`__. + .. _include_a_meaningful_cover_letter: =20 Include a meaningful cover letter @@ -397,9 +410,19 @@ Participating in Code Review ---------------------------- =20 All patches submitted to the QEMU project go through a code review -process before they are accepted. Some areas of code that are well -maintained may review patches quickly, lesser-loved areas of code may -have a longer delay. +process before they are accepted. This will often mean a series will +go through a number of iterations before being picked up by +:ref:`maintainers`. You therefore should be prepared to +read replies to your messages and be willing to act on them. + +Maintainers are often willing to manually fix up first-time +contributions, since there is a learning curve involved in making an +ideal patch submission. However for the best results you should +proactively respond to suggestions with changes or justifications for +your current approach. + +Some areas of code that are well maintained may review patches +quickly, lesser-loved areas of code may have a longer delay. =20 .. _stay_around_to_fix_problems_raised_in_code_review: =20 --=20 2.34.1 From nobody Fri May 10 19:21:03 2024 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass(p=none dis=none) header.from=linaro.org ARC-Seal: i=1; a=rsa-sha256; t=1668178662; cv=none; d=zohomail.com; s=zohoarc; b=Bnb0MMdorIuwylr2sEGD3i1/tchzdCDA2O6Wo6Z29FzJvRGJoUOv4MAAKHtHCZEuFjqE6Wd4rqP+uAel5v4cav2UxlNDgBMHKjfPikUSUYy8Z6nzpHIzHwFI+MhrkWmpNY9HUJk2EyDVTCMTh64SiLOvVUc4S41b/H6HCu5lZ8Y= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1668178662; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To; bh=yLNK2qdPNMQMvzK3A+Wa0kPh913JqNLXh3QyXKK7U+k=; b=DZdsuoDLRWl9647jt1ORd9F6Mqmf9f7RYe38ToEEXyXxoC6fGvZLLZV1MNb8pHw3Dj27E55LEUwByaDd0n9ubXtC/rmKs4o7hAUh/vEtoE9Gr2lhe67ROrP5nE1jt9gm4D/eQsXocXnvQUOjtH87C58G87Hd1CXCi2J/7CkLnP4= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass header.from= (p=none dis=none) Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1668178662567281.1842477407937; Fri, 11 Nov 2022 06:57:42 -0800 (PST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1otVRb-00075C-NE; Fri, 11 Nov 2022 09:55:47 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1otVRW-00072t-DN for qemu-devel@nongnu.org; Fri, 11 Nov 2022 09:55:42 -0500 Received: from mail-wm1-x32b.google.com ([2a00:1450:4864:20::32b]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1otVRT-0007xV-Hx for qemu-devel@nongnu.org; Fri, 11 Nov 2022 09:55:42 -0500 Received: by mail-wm1-x32b.google.com with SMTP id t4so3072008wmj.5 for ; Fri, 11 Nov 2022 06:55:38 -0800 (PST) Received: from zen.linaroharston ([185.81.254.11]) by smtp.gmail.com with ESMTPSA id n2-20020a05600c3b8200b003b476cabf1csm3672104wms.26.2022.11.11.06.55.31 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 11 Nov 2022 06:55:32 -0800 (PST) Received: from zen.lan (localhost [127.0.0.1]) by zen.linaroharston (Postfix) with ESMTP id BD5D71FFC0; Fri, 11 Nov 2022 14:55:30 +0000 (GMT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=yLNK2qdPNMQMvzK3A+Wa0kPh913JqNLXh3QyXKK7U+k=; b=BoeQrQnI2ZGynBzAvlcqSMhgTLDrnrzj5VQILDx2IiaEyT0k5ab4id+mD6gswK1tlg RjVH2YqCPaMmyykL1JEhreuc56uXeYnBBE4360FNR+HeZHEfwGmn6q8tzGi18Ynj15JO qhnJqnkU+P08rGX122no8HIBYBdWfAUk0Rzp96dbcmN9kb0H1cf2WLSFMCUTYsGg992Y Rp1SNWIhCWil30LpnAZsl3xIbJmjO74i8kUZupjUOFqMcimURqR+IW1KesYJD59yFqoM yJNV4jNncqzBIAtCB5Mdgr3KXUNzz2DPXc/KpVQhdyLYolq/1va1+1ulju18al8eAJxq 6ioQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=yLNK2qdPNMQMvzK3A+Wa0kPh913JqNLXh3QyXKK7U+k=; b=ShDmYgi6zINtqc7XaVfG1ofk/KHctqDk4Yy2z1CqEMuKj0pN2/7Uxb2/Pq/J71riFG JvEFD81nMyF2ITx0Y9f+iSfrMlmqgxZR3+InqgTWlt7ogELND8ZEii7BCJd5Ucn40R5z Uyubv9Q5IcazzoArOicrFAXjL2rkhA3BPt6Bq1+dwNN+HrRnAgVuFnT5Ste0Y/KKxOkK COytcJJK4Ks81EUrQ3MUj7I6sYAsxWKEb66ICPQkwQpUXrqimunRdpa3OvW6t55irbYB eTVSKV+YRHMESbHAW3qxjMoS2FHx8upcsPsUyr3qsiCbA8WZ2a4aw0Owr3u2E3tkRFsW 18Mw== X-Gm-Message-State: ANoB5pnhqoLsHZMhoW7ryU99WbT21256KKiQkZCkb84RRQeMcg35Ofjn t+pFReLX2RFmwGa5ZkVbOAIxCQ== X-Google-Smtp-Source: AA0mqf6Fteo0elof9NunwwuvA9CV1HGVGikFFNnjrEKtiFFDoE2XWaZpeSVF8OvsGzcK8vwnOHW80A== X-Received: by 2002:a7b:c4d3:0:b0:3cf:88e7:f808 with SMTP id g19-20020a7bc4d3000000b003cf88e7f808mr1492201wmk.200.1668178537813; Fri, 11 Nov 2022 06:55:37 -0800 (PST) From: =?UTF-8?q?Alex=20Benn=C3=A9e?= To: qemu-devel@nongnu.org Cc: fam@euphon.net, berrange@redhat.com, f4bug@amsat.org, aurelien@aurel32.net, pbonzini@redhat.com, stefanha@redhat.com, crosa@redhat.com, =?UTF-8?q?Alex=20Benn=C3=A9e?= , Markus Armbruster Subject: [PATCH v2 08/12] docs/devel: try and improve the language around patch review Date: Fri, 11 Nov 2022 14:55:25 +0000 Message-Id: <20221111145529.4020801-9-alex.bennee@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20221111145529.4020801-1-alex.bennee@linaro.org> References: <20221111145529.4020801-1-alex.bennee@linaro.org> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=2a00:1450:4864:20::32b; envelope-from=alex.bennee@linaro.org; helo=mail-wm1-x32b.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: qemu-devel-bounces+importer=patchew.org@nongnu.org X-ZohoMail-DKIM: pass (identity @linaro.org) X-ZM-MESSAGEID: 1668178663883100005 It is important that contributors take the review process seriously and we collaborate in a respectful way while avoiding personal attacks. Try and make this clear in the language. Signed-off-by: Alex Benn=C3=A9e Reviewed-by: Markus Armbruster Reviewed-by: Stefan Hajnoczi Reviewed-by: Paolo Bonzini Message-Id: <20221012121152.1179051-5-alex.bennee@linaro.org> --- docs/devel/submitting-a-patch.rst | 16 +++++++++++----- 1 file changed, 11 insertions(+), 5 deletions(-) diff --git a/docs/devel/submitting-a-patch.rst b/docs/devel/submitting-a-pa= tch.rst index 1f2bde0625..80e8693bb6 100644 --- a/docs/devel/submitting-a-patch.rst +++ b/docs/devel/submitting-a-patch.rst @@ -434,14 +434,20 @@ developers will identify bugs, or suggest a cleaner a= pproach, or even just point out code style issues or commit message typos. You'll need to respond to these, and then send a second version of your patches with the issues fixed. This takes a little time and effort on your part, but -if you don't do it then your changes will never get into QEMU. It's also -just polite -- it is quite disheartening for a developer to spend time -reviewing your code and suggesting improvements, only to find that -you're not going to do anything further and it was all wasted effort. +if you don't do it then your changes will never get into QEMU. + +Remember that a maintainer is under no obligation to take your +patches. If someone has spent the time reviewing your code and +suggesting improvements and you simply re-post without either +addressing the comment directly or providing additional justification +for the change then it becomes wasted effort. You cannot demand others +merge and then fix up your code after the fact. =20 When replying to comments on your patches **reply to all and not just the sender** -- keeping discussion on the mailing list means everybody -can follow it. +can follow it. Remember the spirit of the :ref:`code_of_conduct` and +keep discussions respectful and collaborative and avoid making +personal comments. =20 .. _pay_attention_to_review_comments: =20 --=20 2.34.1 From nobody Fri May 10 19:21:03 2024 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass(p=none dis=none) header.from=linaro.org ARC-Seal: i=1; a=rsa-sha256; t=1668178669; cv=none; d=zohomail.com; s=zohoarc; b=e+VoIUmaqbNHwl2i/Ce74iHw/ctJUq75TSMIP7HYyUnr4t///C//xbGgCiXAf2btbEhbXejcE0ZRuCpmHoQpF+lyFlvlMjUz8BqyO+Cw7xmrkq9W4LU8UaP//b3bVqJAMZRlD1bRCr1eY71ACNVoZDHWNjHNVCECXgPAUC/f+cg= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1668178669; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To; bh=xz/+zZudDZVBoYNxMc0z6HI0lRrD/gYGRwz0JYOqFX8=; b=PV3i2NwYFU3924WNEvkqaBpDK82Fb531d73hOzxFNwOgrq/Rx+svMKRmy73avI4QJjX3F2t43T/pS4R8yMmspXEi79xNPOtVoR963Mn3BJZMaARciqMJT+z3qg0eF09Ju8TvDzeGaSbWN+sSMCDbsBrXpX29dK95Y0Dvviwptt0= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass header.from= (p=none dis=none) Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1668178669605172.2742619558286; Fri, 11 Nov 2022 06:57:49 -0800 (PST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1otVRa-00074m-Va; Fri, 11 Nov 2022 09:55:47 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1otVRZ-00073d-EP for qemu-devel@nongnu.org; Fri, 11 Nov 2022 09:55:45 -0500 Received: from mail-wr1-x431.google.com ([2a00:1450:4864:20::431]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1otVRW-0007yI-Eq for qemu-devel@nongnu.org; Fri, 11 Nov 2022 09:55:44 -0500 Received: by mail-wr1-x431.google.com with SMTP id y16so6770377wrt.12 for ; Fri, 11 Nov 2022 06:55:42 -0800 (PST) Received: from zen.linaroharston ([185.81.254.11]) by smtp.gmail.com with ESMTPSA id v23-20020a1cf717000000b003c6c4639ac6sm2993443wmh.34.2022.11.11.06.55.32 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 11 Nov 2022 06:55:38 -0800 (PST) Received: from zen.lan (localhost [127.0.0.1]) by zen.linaroharston (Postfix) with ESMTP id D66B31FFC1; Fri, 11 Nov 2022 14:55:30 +0000 (GMT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=xz/+zZudDZVBoYNxMc0z6HI0lRrD/gYGRwz0JYOqFX8=; b=wqB85alrjz15FAC8JVT/wxBDv23j8WuRbzxe9zLMGxDeSBmmXDT7uRts4XGwBruhLQ ft6gMdJK+nh/xtXIMENVeoxep2iAPqbVA0Wo2ybbejq1aEwgbYuoutwVriBSJ3Sbkm8x CCPCH2VqY0xz+7qxYpXSSU4OBer+aWr8CTj569ohuXuezT4oVyOxNzQitkwYmDi0xN+q BrojgPcASs215mUy5+2GwIBvbvgHPuSewPqVetdVXpD2bd4TZc3YAfmOJFYjZyyAhBWw Fl3lGOJqqp6Bl78R4RcK5lHJDEFbOP+tut3xEB6BYZrl1rZ9VhfWtW3w8PcBS5R7fy7G N34Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=xz/+zZudDZVBoYNxMc0z6HI0lRrD/gYGRwz0JYOqFX8=; b=WJep4GYzS2Xa3mfY35oWkcUSN377RWE2cJeMaAHbn18iRgwlRq7DRkTqhLP3ESVz/9 PT5tT1nj4EezHXtiVVj0GRRaAH7ub50rRudOgdILVkDI62CbuI+D3i2rJ7deb6O6UdQk 02gMqbjgQIiadpen1bgR8q5YC0heepku2FF7DKCBoygBqlNgqBO68q0yAxqgzBvrj8KA nFQqbpFlY+475GUR6m2tazRSihge7rSnZkRJ5srTMmqeitz3uaeA8TXqCmT12AZi2SFG SrFQU407TwHwCrmOJ7lWzEMKx8mHB2Zog7GrmNW8Nmy7+5uogQgS+XP9a00/+RhYiMEv nmoA== X-Gm-Message-State: ANoB5pm2I38fbBR3YJmXfeyAW4de4GSLm+AKZX1Yytm0HDbpS/ugQkbm GcsmFyEre5004ruGdkA2DREQEA== X-Google-Smtp-Source: AA0mqf7xDQKsjG5etjne0mle/pimD0J0pFU0JQff5P8T1OU/0Oq+rXEyh2qdFZ8DQIQDQLTwmWKQGg== X-Received: by 2002:a05:6000:181a:b0:236:6fc5:e624 with SMTP id m26-20020a056000181a00b002366fc5e624mr1449175wrh.110.1668178540953; Fri, 11 Nov 2022 06:55:40 -0800 (PST) From: =?UTF-8?q?Alex=20Benn=C3=A9e?= To: qemu-devel@nongnu.org Cc: fam@euphon.net, berrange@redhat.com, f4bug@amsat.org, aurelien@aurel32.net, pbonzini@redhat.com, stefanha@redhat.com, crosa@redhat.com, =?UTF-8?q?Alex=20Benn=C3=A9e?= , Idan Horowitz , Alexandre Iooss , Mahmoud Mandour Subject: [PATCH v2 09/12] tests/plugins: add a new vcpu state tracking plugin Date: Fri, 11 Nov 2022 14:55:26 +0000 Message-Id: <20221111145529.4020801-10-alex.bennee@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20221111145529.4020801-1-alex.bennee@linaro.org> References: <20221111145529.4020801-1-alex.bennee@linaro.org> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=2a00:1450:4864:20::431; envelope-from=alex.bennee@linaro.org; helo=mail-wr1-x431.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: qemu-devel-bounces+importer=patchew.org@nongnu.org X-ZohoMail-DKIM: pass (identity @linaro.org) X-ZM-MESSAGEID: 1668178670008100001 Although we call qemu_plugin_register_vcpu_idle_cb() in the bb test we don't really exercise the rest of the state change callbacks. Add a new test that tests the whole API. [AJB: I wrote this in an attempt to flush out a reproducer for #1195 although so far no joy.] Signed-off-by: Alex Benn=C3=A9e Cc: Idan Horowitz ---- v2 - and min max tracking - fix { style on get_timestamp --- tests/plugin/vcpu.c | 153 +++++++++++++++++++++++++++++++++++++++ tests/plugin/meson.build | 2 +- 2 files changed, 154 insertions(+), 1 deletion(-) create mode 100644 tests/plugin/vcpu.c diff --git a/tests/plugin/vcpu.c b/tests/plugin/vcpu.c new file mode 100644 index 0000000000..f4fa518420 --- /dev/null +++ b/tests/plugin/vcpu.c @@ -0,0 +1,153 @@ +/* + * Test plugin for exercising the vcpu event callbacks. These exist + * for when vcpus are created and destroyed (especially in linux-user + * where vcpu ~=3D thread) and when they pause and restart (generally + * for wfi and the like in system emulation). + * + * Copyright (c) 2022 Linaro Ltd + * + * SPDX-License-Identifier: GPL-2.0-or-later + */ + +#include +#include +#include +#include +#include +#include +#include + +#include + +QEMU_PLUGIN_EXPORT int qemu_plugin_version =3D QEMU_PLUGIN_VERSION; + +typedef struct { + uint64_t start_time_ns; + uint64_t idle_count; + uint64_t last_idle_ts; + uint64_t min_idle_ns; + uint64_t max_idle_ns; + uint64_t total_idle_ns; + uint64_t exit_time_ns; +} VCPUData; + +static GMutex expand_counts_lock; +static GArray *counts; /* array of VCPUData */ +static bool sys_emu; + +/* + * Fetch VCPU data for a given index, allocate if required. + */ +static VCPUData *get_vcpu_data(int cpu_index) +{ + if (cpu_index >=3D counts->len) { + g_mutex_lock(&expand_counts_lock); + counts =3D g_array_set_size(counts, cpu_index + 1); + g_mutex_unlock(&expand_counts_lock); + } + /* race if set size re-allocs? */ + return &g_array_index(counts, VCPUData, cpu_index); +} + +static uint64_t get_timestamp(void) +{ + struct timespec ts; + clock_gettime(CLOCK_MONOTONIC, &ts); + return ts.tv_sec * 1000000000LL + ts.tv_nsec; +} + +static void vcpu_init(qemu_plugin_id_t id, unsigned int cpu_index) +{ + VCPUData *d =3D get_vcpu_data(cpu_index); + d->start_time_ns =3D get_timestamp(); + d->min_idle_ns =3D UINT64_MAX; +} + +static void vcpu_idle(qemu_plugin_id_t id, unsigned int cpu_index) +{ + VCPUData *d =3D get_vcpu_data(cpu_index); + d->last_idle_ts =3D get_timestamp(); + d->idle_count++; +} + +static void vcpu_resume(qemu_plugin_id_t id, unsigned int cpu_index) +{ + VCPUData *d =3D get_vcpu_data(cpu_index); + uint64_t now =3D get_timestamp(); + uint64_t delta =3D now - d->last_idle_ts; + d->total_idle_ns +=3D delta; + if (delta > d->max_idle_ns) { + d->max_idle_ns =3D delta; + } else if (delta < d->min_idle_ns) { + d->min_idle_ns =3D delta; + } +} + +static void vcpu_exit(qemu_plugin_id_t id, unsigned int cpu_index) +{ + VCPUData *d =3D get_vcpu_data(cpu_index); + d->exit_time_ns =3D get_timestamp(); +} + +/* + * Report our final stats + */ +static void plugin_exit(qemu_plugin_id_t id, void *p) +{ + g_autoptr(GString) report =3D g_string_new(""); + const char *vcpu_or_thread =3D sys_emu ? "vcpu" : "thread"; + int i; + + g_string_printf(report, "Exit: we had a total of %d %ss\n", + counts->len, vcpu_or_thread); + + for (i =3D 0; i < counts->len; i++) { + VCPUData *d =3D &g_array_index(counts, VCPUData, i); + + /* FIXME: we never see vcpu_exit for the main thread */ + if (!d->exit_time_ns) { + d->exit_time_ns =3D get_timestamp(); + } + + g_string_append_printf(report, "%s %d: %"PRId64" =C2=B5s lifetime", + vcpu_or_thread, i, + (d->exit_time_ns - d->start_time_ns) / 1000= ); + if (d->idle_count) { + uint64_t idle_us =3D d->total_idle_ns / 1000; + uint64_t idle_avg =3D d->total_idle_ns / d->idle_count; + g_string_append_printf(report, ", %"PRId64" idles, %" + PRId64 " =C2=B5s total idle time, %" + PRId64 " ns min, %" + PRId64 " ns max, %" + PRId64 " ns per idle", + d->idle_count, idle_us, + d->min_idle_ns, d->max_idle_ns, idle_av= g); + } + g_string_append_printf(report, "\n"); + } + qemu_plugin_outs(report->str); +} + + +QEMU_PLUGIN_EXPORT int qemu_plugin_install(qemu_plugin_id_t id, + const qemu_info_t *info, + int argc, char **argv) +{ + int entries =3D 2; + + if (info->system_emulation) { + entries =3D info->system.max_vcpus; + sys_emu =3D true; + } + + counts =3D g_array_sized_new(true, true, sizeof(VCPUData), entries); + g_mutex_init(&expand_counts_lock); + + qemu_plugin_register_vcpu_init_cb(id, vcpu_init); + qemu_plugin_register_vcpu_idle_cb(id, vcpu_idle); + qemu_plugin_register_vcpu_resume_cb(id, vcpu_resume); + qemu_plugin_register_vcpu_exit_cb(id, vcpu_exit); + + qemu_plugin_register_atexit_cb(id, plugin_exit, NULL); + return 0; +} diff --git a/tests/plugin/meson.build b/tests/plugin/meson.build index 2bbfc4b19e..8c6b232183 100644 --- a/tests/plugin/meson.build +++ b/tests/plugin/meson.build @@ -1,5 +1,5 @@ t =3D [] -foreach i : ['bb', 'empty', 'insn', 'mem', 'syscall'] +foreach i : ['bb', 'empty', 'insn', 'mem', 'syscall', 'vcpu'] t +=3D shared_module(i, files(i + '.c'), include_directories: '../../include/qemu', dependencies: glib) --=20 2.34.1 From nobody Fri May 10 19:21:03 2024 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass(p=none dis=none) header.from=linaro.org ARC-Seal: i=1; a=rsa-sha256; t=1668178678; cv=none; d=zohomail.com; s=zohoarc; b=lubCyM1n/uBKcBN9xBEsUpt66vei2KfXopdkiDaKrPSuz6rJB+U3fhu8N5yGtz7O4kZp7Ux0GXWXzj3WFVkIjrq5rIekr4oR2Y9sVFl3piloqsqmPm3Yifg6g5dWb6C+ZpaG8kl6rauaE3xxg5pHiTnMqQaz4eE1l1jnHH9mmAU= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1668178678; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To; bh=WRTLAcdznhrZedskLf6RFnKz3rdvDI3Rrzd5Vwnc2gw=; b=Uflz+0TCY4VZnTrkoQ13AZdSgNYAmH5p6QecdIYmpVq7plfdL1EJH9nxMPX6mn/8lAYKCmN86GBvD79j3KCYwJ4RWOobkb+CoTY8Qifp/NrLYnAy6bD4u8Obl2JfkFWGBzWQ1xIdeklTg1X/GhuTCwsNr+UVH8Ql4yTaemvIHuo= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass header.from= (p=none dis=none) Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1668178678971574.1135244624787; Fri, 11 Nov 2022 06:57:58 -0800 (PST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1otVRd-00076T-3L; Fri, 11 Nov 2022 09:55:49 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1otVRY-00073V-89 for qemu-devel@nongnu.org; Fri, 11 Nov 2022 09:55:45 -0500 Received: from mail-wm1-x336.google.com ([2a00:1450:4864:20::336]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1otVRU-0007xm-Ra for qemu-devel@nongnu.org; Fri, 11 Nov 2022 09:55:43 -0500 Received: by mail-wm1-x336.google.com with SMTP id m7-20020a05600c090700b003cf8a105d9eso3285106wmp.5 for ; Fri, 11 Nov 2022 06:55:40 -0800 (PST) Received: from zen.linaroharston ([185.81.254.11]) by smtp.gmail.com with ESMTPSA id l22-20020a05600c16d600b003cf4eac8e80sm3614909wmn.23.2022.11.11.06.55.32 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 11 Nov 2022 06:55:38 -0800 (PST) Received: from zen.lan (localhost [127.0.0.1]) by zen.linaroharston (Postfix) with ESMTP id EDCE81FFC2; Fri, 11 Nov 2022 14:55:30 +0000 (GMT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=WRTLAcdznhrZedskLf6RFnKz3rdvDI3Rrzd5Vwnc2gw=; b=Sh+y+Lb4IUJ8Fl45EFZQNU27hNoNU14n3vGgT+9YA1zz9paCMu7U8Q328Qxef61Wne BC8Flz2WtUfuniXiVvosYsAHoisSVBa88e1noBrKEGl/EzVwQrVY2zOmHQAlxOzWO2Ox WcNu5GMm3crIJJjQtFejExJBAd4oxiafEIvF5fUQ81uNXByuoXh6NfAY/hp+NjL7kikb QpLOsto4U6KDHY2b1JwcZcsHnyPB1ip71v0COt/lhjuCDJMZUtfhMKJ6cwvHQsV/J+nF A6ORYyCEcWfQvDjSW5dMva8RRsTkWvM7fuElJrLSX3LZufQvQbiLL4BCL/rtfMc3LTYL crMg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=WRTLAcdznhrZedskLf6RFnKz3rdvDI3Rrzd5Vwnc2gw=; b=JEzuj3IBXlmKtRF3cFpFRYIHHGpTB0/BbhqTlg6o4Y4LXwu0pZoqWHMtcwAbgLqHrP arYT/bUyJ9PZb6LgTOX7DEtoN5i43IEUyUV54cve/4L/lBp34m5Mydo3dl4tW6Qi0HS9 /v0IGGaKBxLJksoGLdEWCplnCFGTawDEa7Y3uont2KKYULcbu0vG7tl3s28aiTqr08xW g71ej3taKSPJ0oYrVyEbUf1SYFdCwgp7C9j95gaU1MIxzpK5fbcl/IJh5w9V2S7ej3/o s4C43F2XRdViO+MySFUP7qN4PYOEV/Io5NMNNtJMJQBppsTYe3ajEhj4Mq+ouNVDj/YO iAdw== X-Gm-Message-State: ANoB5pmnPFTTzxFZGXwiRlAgKO82Yh4AriDr89JMLGRAq6n76GNSmq2o SuqS+b84vGaecEJoia6ygfKlTw== X-Google-Smtp-Source: AA0mqf6Z0nAh5HsTF4YT/H6c2lNHrZC90sf9jdSv0uZtxAgjDH5Q88L/zZgiv/XFYhVPVWTN3QEEVg== X-Received: by 2002:a05:600c:19c7:b0:3cf:7066:cf53 with SMTP id u7-20020a05600c19c700b003cf7066cf53mr1492095wmq.135.1668178539520; Fri, 11 Nov 2022 06:55:39 -0800 (PST) From: =?UTF-8?q?Alex=20Benn=C3=A9e?= To: qemu-devel@nongnu.org Cc: fam@euphon.net, berrange@redhat.com, f4bug@amsat.org, aurelien@aurel32.net, pbonzini@redhat.com, stefanha@redhat.com, crosa@redhat.com, Peter Maydell , =?UTF-8?q?Alex=20Benn=C3=A9e?= , =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= , Wainer dos Santos Moschetta , Beraldo Leal Subject: [PATCH v2 10/12] tests/avocado: Raise timeout for boot_linux.py:BootLinuxPPC64.test_pseries_tcg Date: Fri, 11 Nov 2022 14:55:27 +0000 Message-Id: <20221111145529.4020801-11-alex.bennee@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20221111145529.4020801-1-alex.bennee@linaro.org> References: <20221111145529.4020801-1-alex.bennee@linaro.org> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=2a00:1450:4864:20::336; envelope-from=alex.bennee@linaro.org; helo=mail-wm1-x336.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: qemu-devel-bounces+importer=patchew.org@nongnu.org X-ZohoMail-DKIM: pass (identity @linaro.org) X-ZM-MESSAGEID: 1668178680040100003 From: Peter Maydell On my machine, a debug build of QEMU takes about 260 seconds to complete this test, so with the current timeout value of 180 seconds it always times out. Double the timeout value to 360 so the test definitely has enough time to complete. Signed-off-by: Peter Maydell Signed-off-by: Alex Benn=C3=A9e Message-Id: <20221110142901.3832318-1-peter.maydell@linaro.org> --- tests/avocado/boot_linux.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/avocado/boot_linux.py b/tests/avocado/boot_linux.py index 571d33882a..2be4be395d 100644 --- a/tests/avocado/boot_linux.py +++ b/tests/avocado/boot_linux.py @@ -116,7 +116,7 @@ class BootLinuxPPC64(LinuxTest): :avocado: tags=3Darch:ppc64 """ =20 - timeout =3D 180 + timeout =3D 360 =20 def test_pseries_tcg(self): """ --=20 2.34.1 From nobody Fri May 10 19:21:03 2024 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass(p=none dis=none) header.from=linaro.org ARC-Seal: i=1; a=rsa-sha256; t=1668178635; cv=none; d=zohomail.com; s=zohoarc; b=K/osTagQkPVJa3H5LQZ2QTA9l8R0SbGdTixfS8ZtF8qWOrqvcqRhDqYf2Wu7jnNHXGg5WPoN48E/WqEU30wh43Dh0c/ui8b+gQQZ+i4lgOPR1Uz6ibeX10ZlrjiPMY+e7fVW79KosPoh8jEgTqIxK2Ro3G5uwnp6L5z9Nf3XzPM= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1668178635; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To; bh=GVzdQxsHhnuYq5mRH3xtvS6YyI7O0gS+e+/HR5H+7a8=; b=nBktWR6uT5FhNhsudX+bIjqrQQyWZV/k2eb5cv519qBIm9MbKSit1s6cgpf8izJRRtYHJ++lg4K3hs7ArUDk1yL8eNoj05/vyDLutH3ry0Hti2K8a7aGX5EFf7Q99vPyt+1lGFeOnLPDuqNj3QeAqZDqoAp5e3LCqcidjAwsjWQ= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass header.from= (p=none dis=none) Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1668178635721984.3148654347027; Fri, 11 Nov 2022 06:57:15 -0800 (PST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1otVRb-00075A-KP; Fri, 11 Nov 2022 09:55:47 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1otVRY-00073W-8N for qemu-devel@nongnu.org; Fri, 11 Nov 2022 09:55:45 -0500 Received: from mail-wm1-x333.google.com ([2a00:1450:4864:20::333]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1otVRV-0007xo-UU for qemu-devel@nongnu.org; Fri, 11 Nov 2022 09:55:43 -0500 Received: by mail-wm1-x333.google.com with SMTP id p13-20020a05600c468d00b003cf8859ed1bso3300483wmo.1 for ; Fri, 11 Nov 2022 06:55:41 -0800 (PST) Received: from zen.linaroharston ([185.81.254.11]) by smtp.gmail.com with ESMTPSA id t67-20020a1c4646000000b003cfa622a18asm8890923wma.3.2022.11.11.06.55.34 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 11 Nov 2022 06:55:38 -0800 (PST) Received: from zen.lan (localhost [127.0.0.1]) by zen.linaroharston (Postfix) with ESMTP id 109141FFC3; Fri, 11 Nov 2022 14:55:31 +0000 (GMT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=GVzdQxsHhnuYq5mRH3xtvS6YyI7O0gS+e+/HR5H+7a8=; b=mBcf2KfbKpC5B1l0tpd425lKEVZ7Is3T0ONaIHhl7IzOlxnLCV1nodqvvfc21fvIy2 1IaajB3RE3Yt7gUhpTNJMiJ9BnosOe7hpXeYupli2zenk7lVo2rvD56Ao60HPfifp67m wVQ/ppmXYR/KeD6+6itBrs4a84g5AS3eRz/kpbhbq5AbfHJPKKnU55Qoc5/DgDr4I6Qj NpNoYoz8GcjFoWqtS8ssfPf5FdzADkaCzwwWF+c+r5JEJh5eNk9uoPD1cJOSALT+3Ugu Xjry66L9KJF6toLpbeYRhkPeZaht992LRt0k34H3k/8BHmZwuj9rSCAdf/i6MAgxgVIp 4qRw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=GVzdQxsHhnuYq5mRH3xtvS6YyI7O0gS+e+/HR5H+7a8=; b=vIRmsg5JNNfBiImoEwPKAVN3zloP9b8GGdpGS8qY8hKxh14RqmtZMXjKgYnscwK/Pp 8R+nE8q2HuOb7ANBlqJ9b8E1s2xiZKhWGm8nbg8080qDjN5MihHjgh2zKqizUKLcf4EL mLtgim56yeNSx98g0akdtvSTiMqng1akzpksUzll298qqVfa2KfjhYr8C6xhV818jhny N8SkP3DnTwkDAbm+ve5oXinPTDUi4aSoDcUD/A8sye/nCw3YRjp6OcXiliHQ1R7P2u2s J543fKFuwsN24roiNLB/N78knogxkwwZB7f3QCxCPg/V0Ic1RUzQengI2ZvBIxbLz7y+ hCMg== X-Gm-Message-State: ANoB5pnAZGYArqZh2sdR5Iq/3aHNyIaZxoEbBpM2mqbz0tfoa81chAGW 7nRM0ICF18qL8H2zEM9GwPhDeg== X-Google-Smtp-Source: AA0mqf7A+QjXsWjgukBrVmWYB7PGM4XijjajUxKDGSBWg7GQbMZ5vhIsxk8zjr9tEQ4k3D8Oj3WOZw== X-Received: by 2002:a05:600c:43d6:b0:3cf:a18d:39b1 with SMTP id f22-20020a05600c43d600b003cfa18d39b1mr1447850wmn.149.1668178539906; Fri, 11 Nov 2022 06:55:39 -0800 (PST) From: =?UTF-8?q?Alex=20Benn=C3=A9e?= To: qemu-devel@nongnu.org Cc: fam@euphon.net, berrange@redhat.com, f4bug@amsat.org, aurelien@aurel32.net, pbonzini@redhat.com, stefanha@redhat.com, crosa@redhat.com, =?UTF-8?q?Alex=20Benn=C3=A9e?= , =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= , Thomas Huth , Wainer dos Santos Moschetta , Beraldo Leal Subject: [PATCH v2 11/12] gitlab: integrate coverage report Date: Fri, 11 Nov 2022 14:55:28 +0000 Message-Id: <20221111145529.4020801-12-alex.bennee@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20221111145529.4020801-1-alex.bennee@linaro.org> References: <20221111145529.4020801-1-alex.bennee@linaro.org> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=2a00:1450:4864:20::333; envelope-from=alex.bennee@linaro.org; helo=mail-wm1-x333.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: qemu-devel-bounces+importer=patchew.org@nongnu.org X-ZohoMail-DKIM: pass (identity @linaro.org) X-ZM-MESSAGEID: 1668178637613100005 This should hopefully give is nice coverage information about what our tests (or at least the subset we are running) have hit. Ideally we would want a way to trigger coverage on tests likely to be affected by the current commit. Signed-off-by: Alex Benn=C3=A9e Acked-by: Stefan Hajnoczi --- .gitlab-ci.d/buildtest.yml | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/.gitlab-ci.d/buildtest.yml b/.gitlab-ci.d/buildtest.yml index 7173749c52..d21b4a1fd4 100644 --- a/.gitlab-ci.d/buildtest.yml +++ b/.gitlab-ci.d/buildtest.yml @@ -494,7 +494,17 @@ check-gprof-gcov: IMAGE: ubuntu2004 MAKE_CHECK_ARGS: check after_script: - - ${CI_PROJECT_DIR}/scripts/ci/coverage-summary.sh + - cd build + - gcovr --xml-pretty --exclude-unreachable-branches --print-summary + -o coverage.xml --root ${CI_PROJECT_DIR} . *.p + coverage: /^\s*lines:\s*\d+.\d+\%/ + artifacts: + name: ${CI_JOB_NAME}-${CI_COMMIT_REF_NAME}-${CI_COMMIT_SHA} + expire_in: 2 days + reports: + coverage_report: + coverage_format: cobertura + path: build/coverage.xml =20 build-oss-fuzz: extends: .native_build_job_template --=20 2.34.1 From nobody Fri May 10 19:21:03 2024 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass(p=none dis=none) header.from=linaro.org ARC-Seal: i=1; a=rsa-sha256; t=1668178700; cv=none; d=zohomail.com; s=zohoarc; b=EQWPVFkpuquXAiSFVnpungGzoQ2dFRsT1LXBYh3dkzTC5z5laPbptpsgRTyyKJrtgUlg8pQBSe6c4aV+AucjJa7xT2SQXls3lApJzn1dQ321QrNSB1yUmj9E3L73/WHuJaMvCNMVzUtWVoB6kXYiU6H+WFmNKJNRHNJe85qNHkY= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1668178700; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To; bh=3w4mX1qsjSiPO0pJ/lfZfSTSL+aAl8Bv1zC1N3BSyI8=; b=CUPlC4xHxttianOIe/wKwYv04zCY6wtNmdr3p4qPCpd9wiHEFLV3ydiRZy382hZER9ZD+EzVgWh5aNM1GIRQTcZ+tOGxbz4oWrihNFG8IxLVP7xZUQMojBOCzyzN0IQrbcL8YCo7mIeVq/bJfLsSPIJQimlaLHnBHf+ZBQqEY4c= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass header.from= (p=none dis=none) Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1668178700839808.960804276752; Fri, 11 Nov 2022 06:58:20 -0800 (PST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1otVRa-00074i-P0; Fri, 11 Nov 2022 09:55:46 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1otVRZ-00073c-Dz for qemu-devel@nongnu.org; Fri, 11 Nov 2022 09:55:45 -0500 Received: from mail-wr1-x434.google.com ([2a00:1450:4864:20::434]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1otVRW-0007yP-KT for qemu-devel@nongnu.org; Fri, 11 Nov 2022 09:55:45 -0500 Received: by mail-wr1-x434.google.com with SMTP id l14so6808453wrw.2 for ; Fri, 11 Nov 2022 06:55:42 -0800 (PST) Received: from zen.linaroharston ([185.81.254.11]) by smtp.gmail.com with ESMTPSA id n19-20020a05600c3b9300b003b4c979e6bcsm9831705wms.10.2022.11.11.06.55.34 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 11 Nov 2022 06:55:38 -0800 (PST) Received: from zen.lan (localhost [127.0.0.1]) by zen.linaroharston (Postfix) with ESMTP id 26F421FFC4; Fri, 11 Nov 2022 14:55:31 +0000 (GMT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=3w4mX1qsjSiPO0pJ/lfZfSTSL+aAl8Bv1zC1N3BSyI8=; b=fMTvIFFDCorfBpb/boI/HoBjuSOj1lrwBEdBgCRLf/iRw1+F//eR6oStfvCoMXWMnG nO/yAOIb6SctuwUgcLfA2mF1qJZRxigh1NCFKiO2iFYHxW+lvNJwNFbJ2uJ6jSXJwXt2 4daJd8KEHWXYfZ4YIRQoQBYlUEQRtSt+vgdlksKrwDiz7XDvGba3/K1BMR8qofMCu6yV 19jbbF8xMRPhLYcLGyXv5/LTBs4HsDeu3Z/4v6ypdy99BJ3aHZYa6aC270leKVO40Sli cx2RPyvkLN8tRQAZ+Hu2009uUzn2yFJacOvQJkIXZAE3IMj0NaFW/apUtIuU1gV28Hpx XIQg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=3w4mX1qsjSiPO0pJ/lfZfSTSL+aAl8Bv1zC1N3BSyI8=; b=oQBeVnmCtf/mmWDTJgOt8FjXMjiRv9CEyAFkzYRIJ9yHFfiaGU5wlujlJAXBPYJYkU 6ce0kYSGtkpO6RUWAJjoxK778ovMHlZPHZ/MKjmjhd09sINoNxjQ3fMxZnVduxKSD0Mo OJO1oMaqlDbuLhozYGSmjuhzwjO1yGN/rZhI+sUhdiUNoed/F3vDVUBrBIanUUEGKqmD QtprJ9kkkiJSkLz6RRmaQYR0w0Jtp0b3XC6gmv4JIGqB5T5alHlzdqHv6PzIXIzq4Xwq GA81ArSwSFSccVCnlpHiQV2GUVsCd6KepWg4gTH0SGanKOGM0P02Uzq6Oudt/x3meQH5 cPyg== X-Gm-Message-State: ANoB5pkj4SPSgaxHjtYyvcQ8B537J43ayp9IcJky1wdmCt4hPFVIvKIV +CCyXLy6octubiNFrPKjHFpvPQ== X-Google-Smtp-Source: AA0mqf7W+gJDbUZRg7VZLLiC8KBQUwhPhNiKZ+4j/iqQPEHRdHItYqdxHTaYLGg6sEqKYdJRT6FbSg== X-Received: by 2002:adf:e70c:0:b0:236:6578:48ad with SMTP id c12-20020adfe70c000000b00236657848admr1472896wrm.405.1668178541326; Fri, 11 Nov 2022 06:55:41 -0800 (PST) From: =?UTF-8?q?Alex=20Benn=C3=A9e?= To: qemu-devel@nongnu.org Cc: fam@euphon.net, berrange@redhat.com, f4bug@amsat.org, aurelien@aurel32.net, pbonzini@redhat.com, stefanha@redhat.com, crosa@redhat.com, =?UTF-8?q?Alex=20Benn=C3=A9e?= , Peter Maydell , qemu-arm@nongnu.org (open list:ARM cores) Subject: [PATCH v2 12/12] hw/intc: add implementation of GICD_IIDR to Arm GIC Date: Fri, 11 Nov 2022 14:55:29 +0000 Message-Id: <20221111145529.4020801-13-alex.bennee@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20221111145529.4020801-1-alex.bennee@linaro.org> References: <20221111145529.4020801-1-alex.bennee@linaro.org> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=2a00:1450:4864:20::434; envelope-from=alex.bennee@linaro.org; helo=mail-wr1-x434.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=unavailable autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: qemu-devel-bounces+importer=patchew.org@nongnu.org X-ZohoMail-DKIM: pass (identity @linaro.org) X-ZM-MESSAGEID: 1668178702153100003 a66a24585f (hw/intc/arm_gic: Implement read of GICC_IIDR) implemented this for the CPU interface register. The fact we don't implement it shows up when running Xen with -d guest_error which is definitely wrong because the guest is perfectly entitled to read it. Lightly re-factor this region of registers and also add a comment to the function in case anyway was under the illusion we only return bytes from a function called readb. Signed-off-by: Alex Benn=C3=A9e --- v2 - checkpatch fixes. --- hw/intc/arm_gic.c | 44 ++++++++++++++++++++++++++++++-------------- 1 file changed, 30 insertions(+), 14 deletions(-) diff --git a/hw/intc/arm_gic.c b/hw/intc/arm_gic.c index 492b2421ab..65b1ef7151 100644 --- a/hw/intc/arm_gic.c +++ b/hw/intc/arm_gic.c @@ -941,6 +941,10 @@ static void gic_complete_irq(GICState *s, int cpu, int= irq, MemTxAttrs attrs) gic_update(s); } =20 +/* + * Although this is named a byte read we don't always return bytes and + * rely on the calling function oring bits together. + */ static uint32_t gic_dist_readb(void *opaque, hwaddr offset, MemTxAttrs att= rs) { GICState *s =3D (GICState *)opaque; @@ -954,23 +958,35 @@ static uint32_t gic_dist_readb(void *opaque, hwaddr o= ffset, MemTxAttrs attrs) cpu =3D gic_get_current_cpu(s); cm =3D 1 << cpu; if (offset < 0x100) { - if (offset =3D=3D 0) { /* GICD_CTLR */ - if (s->security_extn && !attrs.secure) { - /* The NS bank of this register is just an alias of the - * EnableGrp1 bit in the S bank version. - */ - return extract32(s->ctlr, 1, 1); - } else { - return s->ctlr; + if (offset < 0xc) { + switch (offset) { + case 0: /* GICD_CTLR[7:0] */ + { + if (s->security_extn && !attrs.secure) { + /* + * The NS bank of this register is just an alias of the + * EnableGrp1 bit in the S bank version. + */ + return extract32(s->ctlr, 1, 1); + } else { + return s->ctlr; + } } - } - if (offset =3D=3D 4) - /* Interrupt Controller Type Register */ - return ((s->num_irq / 32) - 1) + case 4: /* GIC_TYPER - Interrupt Controller Type Register */ + { + return ((s->num_irq / 32) - 1) | ((s->num_cpu - 1) << 5) | (s->security_extn << 10); - if (offset < 0x08) - return 0; + } + case 8: /* GICD_IIDR - Implementer ID Register */ + { + return 0x43b; /* Arm JEP106 identity */ + } + default: + /* return 0 for high bits of above */ + return 0; + } + } if (offset >=3D 0x80) { /* Interrupt Group Registers: these RAZ/WI if this is an NS * access to a GIC with the security extensions, or if the GIC --=20 2.34.1