From patchwork Wed Jul 1 13:56:13 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Alex_Benn=C3=A9e?= X-Patchwork-Id: 192134 Delivered-To: patch@linaro.org Received: by 2002:a92:d244:0:0:0:0:0 with SMTP id v4csp517985ilg; Wed, 1 Jul 2020 06:58:06 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyOjsbyNO1+E2wopB7nYjkSxC2tFtx6Nxo6R669eat6BHuNiVeMlttUxc7GRuFfgSqAFvft X-Received: by 2002:a25:848f:: with SMTP id v15mr44166554ybk.473.1593611885967; Wed, 01 Jul 2020 06:58:05 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1593611885; cv=none; d=google.com; s=arc-20160816; b=gCz8AwaWwQ6jXuwvAjQ78X8EEP23epC6nWyu6MvjGn+uqRU1atLdn3jqSJQUjAkju/ qTPAuoqMfdfjQU6e71b4Zm2U1O3jLI0gmXUV9a1FAn4qd2ANIrXY58/QOvkJWpUJxjej zGZ29ngQ8uh9MlApmPsFfVxnQ61vD6wKiYdXlMFeHWnBf6WFLiAkZxq4KmmkxZ0Sgbrc nBmNwAJ1tk/Ny48KXkLcuhXgWnslZXF6a6LKC4rzbSgvNo8SB0pOqkouENP/Uc+KzsOM lelrXHxgioeT0t0YU611Q/eAfPWJDcgr3ioShS92atPIgcnNYu4VtJGApKpIfJ4rSWlP b2yQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:cc:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=+TAlbHIsXZGW5UODRkH4obAQs4koVX0V9BG/gRdLybw=; b=dQuQbtvT6M54W2qkqnf6IepgLn/iwrtPDio8rYtZoPO9muhUxYHvnmQ8+eHmyb2FTc mES4ZU0zzCdbFMcv4lDADkwbHZhVIxJnoP+WNswnyLbm6t6T8gxyUcHG1hNqaEDi9n4G N829SH3S0K3GuW3HrVSxfMuahpXdUwVstSKmiLZnP3B+KIw9j+3JU3t/kbyEle1BPCK5 rxgxmpXCWlVLi6qKzpKjRCPMCp0PA789tcve0yQcEWgml9nlX3WCts4BH9LNzI0iqN8A ZoomMK0HfAf4kvfYRQlaE2Z2Gb9EhSzUJGx8Q1Hks7zxIdPS5fdzvjjgxiqE3UA0b2fP E1bQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=y09k1vHU; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id v11si6098387ybm.450.2020.07.01.06.58.05 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Wed, 01 Jul 2020 06:58:05 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=y09k1vHU; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1]:54818 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jqdFV-0002EA-BU for patch@linaro.org; Wed, 01 Jul 2020 09:58:05 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:58778) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jqdET-00028v-2k for qemu-devel@nongnu.org; Wed, 01 Jul 2020 09:57:01 -0400 Received: from mail-wr1-x443.google.com ([2a00:1450:4864:20::443]:42400) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1jqdER-0005oi-Fz for qemu-devel@nongnu.org; Wed, 01 Jul 2020 09:57:00 -0400 Received: by mail-wr1-x443.google.com with SMTP id o11so23962721wrv.9 for ; Wed, 01 Jul 2020 06:56:59 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=+TAlbHIsXZGW5UODRkH4obAQs4koVX0V9BG/gRdLybw=; b=y09k1vHUBlQF6ueTAew75bX5pYxYqt0PC9MgykKFtA/gJVlmKc7nDYFKeo1XfNNRPs 3iLZezc0+CT+/fyIz2Ohh5FF3Qh3xJdvO0O+6MbhETkDFBKFoJZrbjI9RRkwTMOfhk0r V3SO4T/AuhMj1XxRjcQKx67mMUO8PmZMn7xDi/zJR/rhJWCAb7SPYfP5tS1nvh8zQ65W 4dxM5hT9LbWkNxeaOqWIKDcDcPDlkeJ2zb/HBe1Xi9zULkpx6mbl4t6SxNHQtV0BWul5 kRYnsAodSJA8nXSKPvR8baXcvJGKya3r+PJYMEkAM45sGklUwNIytfTbL/OpVICZTdv7 y81Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=+TAlbHIsXZGW5UODRkH4obAQs4koVX0V9BG/gRdLybw=; b=DSR0X8SsXzOs3nuHIZFuqSKxAiELDv9yOtS2uipBRACn3msc6PHdsyIUBpyOFhbDDs z4cCM64a1ZY5cQ7ZntArSUT/Pt/NSKb4Yt742qkRA0593c1H0KPlsGgitxJaNhDHZFXN GW6nIkEH1cPIJrdrA3c35SseYOXOOpefBI54PF3DqWkYr/ha4pBknVMM0VqzV9FImFD6 AnIj+GSU9W2VpJO/OOPTLSuH8GhbmCdDpHsDmddnd49D3rK/ZvTqF+NM55grEdWVITgq 31czWVPd6BacR7eCTieUunbnzFgxOOWWooCYf1ZxKrCpTIZF2NvT8VAb8YAQxhoTUOqT r0cw== X-Gm-Message-State: AOAM530tXEuDpHpuIkjGO6xdhQ+OdV0xHB7WNJtQB1yaWgFUR8yvOzLP JLdRYHokwJiWiNVg3jnkopEfKA== X-Received: by 2002:a5d:4051:: with SMTP id w17mr25745216wrp.183.1593611818079; Wed, 01 Jul 2020 06:56:58 -0700 (PDT) Received: from zen.linaroharston ([51.148.130.216]) by smtp.gmail.com with ESMTPSA id v18sm7914893wrv.49.2020.07.01.06.56.53 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 01 Jul 2020 06:56:53 -0700 (PDT) Received: from zen.lan (localhost [127.0.0.1]) by zen.linaroharston (Postfix) with ESMTP id ECC7A1FF87; Wed, 1 Jul 2020 14:56:52 +0100 (BST) From: =?utf-8?q?Alex_Benn=C3=A9e?= To: qemu-devel@nongnu.org Subject: [PATCH v4 01/40] hw/isa: check for current_cpu before generating IRQ Date: Wed, 1 Jul 2020 14:56:13 +0100 Message-Id: <20200701135652.1366-2-alex.bennee@linaro.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20200701135652.1366-1-alex.bennee@linaro.org> References: <20200701135652.1366-1-alex.bennee@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::443; envelope-from=alex.bennee@linaro.org; helo=mail-wr1-x443.google.com X-detected-operating-system: by eggs.gnu.org: No matching host in p0f cache. That's all we know. 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=_AUTOLEARN X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: fam@euphon.net, berrange@redhat.com, "Michael S. Tsirkin" , =?utf-8?q?Alex_Benn=C3=A9e?= , richard.henderson@linaro.org, f4bug@amsat.org, cota@braap.org, Bug 1878645 <1878645@bugs.launchpad.net>, aurelien@aurel32.net Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: "Qemu-devel" It's possible to trigger this function from qtest/monitor at which point current_cpu won't point at the right place. Check it and fall back to first_cpu if it's NULL. Signed-off-by: Alex Bennée Cc: Bug 1878645 <1878645@bugs.launchpad.net> --- hw/isa/lpc_ich9.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) -- 2.20.1 diff --git a/hw/isa/lpc_ich9.c b/hw/isa/lpc_ich9.c index cd6e169d47a..791c878eb0b 100644 --- a/hw/isa/lpc_ich9.c +++ b/hw/isa/lpc_ich9.c @@ -439,7 +439,7 @@ static void ich9_apm_ctrl_changed(uint32_t val, void *arg) cpu_interrupt(cs, CPU_INTERRUPT_SMI); } } else { - cpu_interrupt(current_cpu, CPU_INTERRUPT_SMI); + cpu_interrupt(current_cpu ? current_cpu : first_cpu, CPU_INTERRUPT_SMI); } } } From patchwork Wed Jul 1 13:56:14 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Alex_Benn=C3=A9e?= X-Patchwork-Id: 192137 Delivered-To: patch@linaro.org Received: by 2002:a92:d244:0:0:0:0:0 with SMTP id v4csp519202ilg; Wed, 1 Jul 2020 06:59:56 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwa8rtqV6rQ7jsKCsWf1bKwCezdm0YcwA0j8gxxB9M0cLXKr7pv5FvPZfFtzS64dRPaxjYR X-Received: by 2002:a25:392:: with SMTP id 140mr44689693ybd.270.1593611996153; Wed, 01 Jul 2020 06:59:56 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1593611996; cv=none; d=google.com; s=arc-20160816; b=ZBX2wZGyI8fh/Lv2zuikSOAttbcZ/9Vhoz65n1MSl4MWhMvAvzXrUmiGWO+rKAF2hf fY78/cGEAPdE9QzX232oF5z9RxyUBVMuKrWkAJPE3FVGfTSHn56TTPBx5ZcEz/M6xzh2 +7MnXDzkDt+troS1IeWIb50L2tQ3VH7YhQrP9t1tzJkwqs0s/ayS028GrnJkxEep8slS TfnFU6MGIAWgkqxdBKTanA9eHNk+hLsj09mTuk610oib6NwEZxKI/ixiziZcpn3TdbY9 pgg9MG/1UiuhXYI96gQ2d3VGUk9pMtUGZsjJ8OSTO5Pqfig9oqsZ7DInpG5zsFD7AoZ/ 4AjA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:cc:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=KLxxBVgESg8+q++r/+fvnKLfCmcpFTynVpvVjZzQTYc=; b=jrAJ7f1ECkAFyK0EpZbp5Q6hKIHHXmNyDhz3mYDau5L0YpgrCk7dZVRJN0BnWG0wgF DXwM4+v51MSGEPsRG8Wjogu0YUZ0EWN/6ypQOt9SvYH+/wRaI64lr1KZwb6xGG/70Rhr qKoi2NJ3LxrN+c04s5NkbKCCWYu6z4M3Kgi0m0J2c3B91JUw2hjdAbQvECLohJbGbSKJ DYy6K4KlV5hk7IEBlqAEma/d3YWeE5AondYe/BlRkx3DsY7MV9c3az39gKiB6ZlTqV7a XLDTq9BtZ7Wibpznkft3drfYYHVJneJXymih9MWWglimHXlD5zYy7j3JukuGWTI9K6B2 h5sA== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=fGXJWryQ; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id x16si6748543ybk.399.2020.07.01.06.59.56 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Wed, 01 Jul 2020 06:59:56 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=fGXJWryQ; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1]:34754 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jqdHG-0005l5-IW for patch@linaro.org; Wed, 01 Jul 2020 09:59:54 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:58768) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jqdES-00028H-CS for qemu-devel@nongnu.org; Wed, 01 Jul 2020 09:57:00 -0400 Received: from mail-wr1-x429.google.com ([2a00:1450:4864:20::429]:40557) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1jqdEQ-0005oP-MT for qemu-devel@nongnu.org; Wed, 01 Jul 2020 09:57:00 -0400 Received: by mail-wr1-x429.google.com with SMTP id h5so23945925wrc.7 for ; Wed, 01 Jul 2020 06:56:58 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=KLxxBVgESg8+q++r/+fvnKLfCmcpFTynVpvVjZzQTYc=; b=fGXJWryQ2lB2psc9eeFMRSIN3DKGiQetKXI7zlHAk6i90uos8tgDmFBc3E2OOmEc7w m+ogh+EBgA1bYyzlxWR4aZlFLHcUNvdDlpMpQs/Z1p/W6cIsNFR6dcX+mj9ilrCHkTtB l8xb4VoyPkZC1SVe8n10Y4y8bIaPOXsn+htsf5NruypcjVGvxf6idP3wWN7GD3nj3ZPs sBntT076sltLoBv8pAfsxcLosKg6tCnvHBPvgxRv9PalLwS1ioTbJpTLkrOrVk27VpPT 8U/wg/AaGzO815ER6H+NqhaPhRCjzk43k+03egQpvTupMgMkLzbDN2LQowvagd5+Au5L UQAQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=KLxxBVgESg8+q++r/+fvnKLfCmcpFTynVpvVjZzQTYc=; b=OvU02tgZblIcuAV2iobvr2+sS633RHUVV5rgNK6OxnH2UOdL7kDm3g9j8N1EkB9TOI Lb/KGLQUTMBpHUduF4IvW8n+RbLWaNK6AjMTgRS7ZP8ZBcC4K+rw+gXIGOMi8bu3ode1 IcVe7bz4YVEZXrrtyZChvi41TUVr95vDPNlRURWTQ+f8iBKSST+Hg4p8wRYZnvt5YzEm /ac+aPi6F7AYGdw2HNmPk8jw15bsB20SirpJ0HlFEvuYOruzPCglKZseqTqBcO+hHdIw 21okgcvc/GWCEpC/frSVyX1h7i23jqWhdOo6nHE0dW1rewXFkDwnugwx+u8+94sqCBzl UV3w== X-Gm-Message-State: AOAM532bGmXrF+TbBxUXeuyol2vzY3HIE4FhTEuqQt9dV4ZblQyQgYWk VoX4CBuiuAkqQl5Q+vijNg1Lcg== X-Received: by 2002:a5d:4bd2:: with SMTP id l18mr26230996wrt.119.1593611817031; Wed, 01 Jul 2020 06:56:57 -0700 (PDT) Received: from zen.linaroharston ([51.148.130.216]) by smtp.gmail.com with ESMTPSA id v24sm9082410wrd.92.2020.07.01.06.56.53 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 01 Jul 2020 06:56:53 -0700 (PDT) Received: from zen.lan (localhost [127.0.0.1]) by zen.linaroharston (Postfix) with ESMTP id 0D3341FF8C; Wed, 1 Jul 2020 14:56:53 +0100 (BST) From: =?utf-8?q?Alex_Benn=C3=A9e?= To: qemu-devel@nongnu.org Subject: [PATCH v4 02/40] iotests: Fix 051 output after qdev_init_nofail() removal Date: Wed, 1 Jul 2020 14:56:14 +0100 Message-Id: <20200701135652.1366-3-alex.bennee@linaro.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20200701135652.1366-1-alex.bennee@linaro.org> References: <20200701135652.1366-1-alex.bennee@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::429; envelope-from=alex.bennee@linaro.org; helo=mail-wr1-x429.google.com X-detected-operating-system: by eggs.gnu.org: No matching host in p0f cache. That's all we know. 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=_AUTOLEARN X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: fam@euphon.net, Kevin Wolf , Thomas Huth , berrange@redhat.com, "open list:Block layer core" , =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= , richard.henderson@linaro.org, f4bug@amsat.org, Max Reitz , =?utf-8?q?Alex_Benn=C3=A9e?= , cota@braap.org, John Snow , aurelien@aurel32.net Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: "Qemu-devel" From: Philippe Mathieu-Daudé Commit 96927c744 replaced qdev_init_nofail() call by isa_realize_and_unref() which has a different error message. Update the test output accordingly. Gitlab CI error after merging b77b5b3dc7: https://gitlab.com/qemu-project/qemu/-/jobs/597414772#L4375 Reported-by: Thomas Huth Signed-off-by: Philippe Mathieu-Daudé Signed-off-by: Alex Bennée Reviewed-by: John Snow Reviewed-by: Thomas Huth Message-Id: <20200616154949.6586-1-philmd@redhat.com> --- tests/qemu-iotests/051.pc.out | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) -- 2.20.1 diff --git a/tests/qemu-iotests/051.pc.out b/tests/qemu-iotests/051.pc.out index 0ea80d35f0e..da8ad871876 100644 --- a/tests/qemu-iotests/051.pc.out +++ b/tests/qemu-iotests/051.pc.out @@ -142,7 +142,7 @@ QEMU X.Y.Z monitor - type 'help' for more information Testing: -drive if=ide QEMU X.Y.Z monitor - type 'help' for more information -(qemu) QEMU_PROG: Initialization of device ide-hd failed: Device needs media, but drive is empty +(qemu) QEMU_PROG: Device needs media, but drive is empty Testing: -drive if=virtio QEMU X.Y.Z monitor - type 'help' for more information @@ -214,7 +214,7 @@ QEMU X.Y.Z monitor - type 'help' for more information Testing: -drive file=TEST_DIR/t.qcow2,if=ide,readonly=on QEMU X.Y.Z monitor - type 'help' for more information -(qemu) QEMU_PROG: Initialization of device ide-hd failed: Block node is read-only +(qemu) QEMU_PROG: Block node is read-only Testing: -drive file=TEST_DIR/t.qcow2,if=virtio,readonly=on QEMU X.Y.Z monitor - type 'help' for more information From patchwork Wed Jul 1 13:56:15 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Alex_Benn=C3=A9e?= X-Patchwork-Id: 192132 Delivered-To: patch@linaro.org Received: by 2002:a92:d244:0:0:0:0:0 with SMTP id v4csp517572ilg; Wed, 1 Jul 2020 06:57:36 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzzqwQ9seaLRe0Kli8bZ9Z5SJQMAFt1VFvl05g9bwJjXxijsDGsyBxZSSuduAtntl2f1xuy X-Received: by 2002:a5b:808:: with SMTP id x8mr41677446ybp.134.1593611856074; Wed, 01 Jul 2020 06:57:36 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1593611856; cv=none; d=google.com; s=arc-20160816; b=DyzaU3idAKmsGfvQatrtXuXcKJqYJAd5PR/FTUcq9247jhI4S6L87QXU4cf4qSmgN+ BO6Y8Y/jCLytESmtNQ+HXm3r4tJwL3uwiZcb56PGZ6T1aYt+TLvG9k5aU5ownXkj7yGd WNebCuJLzWmZPhs1d96DJo1qvWTQxukzw0vlCNQqy8WS5EO8ap5HJdity42Ox2x1pjpU JfdFlnMZAjzVhM6AwnBIpaT7Jtz0zrk5+NSkiX/bq2Eh3Mb9JFCFx8JIK4mkUIzehTdv zWVnMYBvv8CA1PwTOBc0FaOC3qGhSqGYkovLJFtHCrCeGwnICiNq+D+mklvvo2/jTOia HOyQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:cc:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=o9fzqGYWOKLSCCS48dXnjjFGr8lTIeZq2AiEKkz+F/8=; b=fM4fOy9CPygDKoewL9RuMZcU55nv4DSfGdbeEhZc+yNDwZ5FyyL9yVkuSLAIV/hAhP iM9ixYas7jyx3wed0GUfz525V2ckLGzcljyHYhgdHwgms5GrI8ich7lIPebcDsSE/Hoc uEVvCxaXDVnSePGX2zMkOqyWqGcULOUZxWzqQUStdX9ek3p/dXtgOEkS+1FOXC0FS1XT F20ujbGK3qyVbUAiHPxGpk+ugcxJ9rTJ+hsdKG1pk4irLyy/2T58WbPw45iolDMrfp6G UTKdl0RkQwqkIGs1I3U/V0AJQJb2jYY0mPx5NQdcFpa19YLiuhr4m9HfPDdT7oUtLMtr WeWA== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=FFktANPM; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id f96si6233867ybi.131.2020.07.01.06.57.36 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Wed, 01 Jul 2020 06:57:36 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=FFktANPM; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1]:54654 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jqdF1-00028w-Hm for patch@linaro.org; Wed, 01 Jul 2020 09:57:35 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:58736) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jqdER-00027u-5m for qemu-devel@nongnu.org; Wed, 01 Jul 2020 09:56:59 -0400 Received: from mail-wm1-x32f.google.com ([2a00:1450:4864:20::32f]:52898) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1jqdEP-0005oA-DV for qemu-devel@nongnu.org; Wed, 01 Jul 2020 09:56:58 -0400 Received: by mail-wm1-x32f.google.com with SMTP id q15so22525715wmj.2 for ; Wed, 01 Jul 2020 06:56:57 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=o9fzqGYWOKLSCCS48dXnjjFGr8lTIeZq2AiEKkz+F/8=; b=FFktANPMP1gm56eJM7vU0gICRUYK+rOS9MRo4BtozhbdvJOnEuRaCqUB4lIc5skdkE +YwdLD9Xq6absutuPfYPpaTiMIeV/KYrqreKfP0dc9mCi3+pI2SlbrY6Xg05qua5BzJA kZGmjnopSBlr0PFgwWjUqv6JdsKwsNb7V/l1xt0DbX1w6SiuDGxpWf9/i/62CJY67SvL aw1i6pSppiu/226mV9mrjW+FYTEkFZ8TCNV1c8avjJSbquKbdKlaoDfoSk5KRzf+MwPa 841eF9hjogCuFDddcopaKgDj2YiIUN8kGdXY1pPt0j756ZR4j2HB3rKkLYrHzaJcJcTn TUZQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=o9fzqGYWOKLSCCS48dXnjjFGr8lTIeZq2AiEKkz+F/8=; b=ePFExLDemzLtk5bGKFdGeqyfTMaXFXARet4pSQfkk25pBnktpFqDYipBbEWNtc6UEA u4ReUEAvsx2usZNe5P2yBSjvzgS+HuV2u/ay0kmRX6QHZetsN8ScfKlnVENEFmvJN2VX oYXActFdjgDcW2UVkJYkXDVQRFqEfRS72JG4AFO1En3hL4M8nIOIW36/I9CU04XbFuad Jd/UGnPE+f4HW3KaszXhxYXtBdpB09AyjT0lrvszvVOTad07Wl1nQN49/wfR+sFj94ZD B3FJEA2vdcxaHyb79/8xw4hj9V0f4tkxM9ah3OrqHPZGIlGkAtfQS9PchYJvPzB11FxZ +yRw== X-Gm-Message-State: AOAM530czO9RYa2bPcweq2IMupb1/ZitCSYkMx3qI4OuESAAf6ILDZRn Ypyug+d514Ndi81yZsOO7m01Sw== X-Received: by 2002:a1c:7916:: with SMTP id l22mr19059046wme.115.1593611815975; Wed, 01 Jul 2020 06:56:55 -0700 (PDT) Received: from zen.linaroharston ([51.148.130.216]) by smtp.gmail.com with ESMTPSA id 33sm7781948wri.16.2020.07.01.06.56.53 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 01 Jul 2020 06:56:53 -0700 (PDT) Received: from zen.lan (localhost [127.0.0.1]) by zen.linaroharston (Postfix) with ESMTP id 2264E1FF8F; Wed, 1 Jul 2020 14:56:53 +0100 (BST) From: =?utf-8?q?Alex_Benn=C3=A9e?= To: qemu-devel@nongnu.org Subject: [PATCH v4 03/40] crypto/linux_keyring: fix 'secret_keyring' configure test Date: Wed, 1 Jul 2020 14:56:15 +0100 Message-Id: <20200701135652.1366-4-alex.bennee@linaro.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20200701135652.1366-1-alex.bennee@linaro.org> References: <20200701135652.1366-1-alex.bennee@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::32f; envelope-from=alex.bennee@linaro.org; helo=mail-wm1-x32f.google.com X-detected-operating-system: by eggs.gnu.org: No matching host in p0f cache. That's all we know. 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=_AUTOLEARN X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: fam@euphon.net, Thomas Huth , berrange@redhat.com, =?utf-8?q?Alex_Benn=C3=A9e?= , richard.henderson@linaro.org, f4bug@amsat.org, David Edmondson , cota@braap.org, aurelien@aurel32.net Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: "Qemu-devel" From: David Edmondson The configure test for 'secret_keyring' incorrectly checked the 'have_keyring' variable. Fixes: 54e7aac0562452e4fcab65ca5001d030eef2de15 Signed-off-by: David Edmondson Signed-off-by: Alex Bennée Reviewed-by: Thomas Huth Message-Id: <20200618092636.71832-1-david.edmondson@oracle.com> --- configure | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) -- 2.20.1 diff --git a/configure b/configure index 4a22dcd5631..65309a08dbc 100755 --- a/configure +++ b/configure @@ -6461,7 +6461,7 @@ EOF fi if test "$secret_keyring" != "no" then - if test "$have_keyring" == "yes" + if test "$have_keyring" = "yes" then secret_keyring=yes else From patchwork Wed Jul 1 13:56:16 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Alex_Benn=C3=A9e?= X-Patchwork-Id: 192138 Delivered-To: patch@linaro.org Received: by 2002:a92:d244:0:0:0:0:0 with SMTP id v4csp519208ilg; Wed, 1 Jul 2020 06:59:56 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyUGxqNYyRAUC65y/5woL9jdjAJzjUNWJTAfrXkx+LuqnCRe9P2MDbJDLDlRPOA6OCp+dd4 X-Received: by 2002:a25:da10:: with SMTP id n16mr39271565ybf.373.1593611996532; Wed, 01 Jul 2020 06:59:56 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1593611996; cv=none; d=google.com; s=arc-20160816; b=JqfguW2OGQ0QZ5aP3oEMASW9oQ0MfmzjPZoKgCLXWBFM6f157QkV2yT11qrsbjNrPu 21XpiUi+g4HPykkjTxOyjVBW5J8vzUkSXlH95++BH37DoybWL9G0BB550dxWAfqaYlsr 6ewLc4zKjKjZwl1J3vcnfi7HgRWNpXXE2hZPf2ZW99lBlQcYFtrSdH4UquRWKCtx2Vqh 6qUeqHvUpLuwsVlR3S6qQVr/ZaSWlEekmIUXlwR480FPHD7jucV7iAl/pxEYI+1oqLkK UPpX7f+tKXPOTeWz8Y2HuFIrGp2jw/9FD6QyoExlubcyOEPQIyXc/qrO1d7mxDXmFV6o rETw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:cc:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=/2Na6SuLR2BPH24MTaa9ZH4OY5rPBs3TXnZRAXFwy5s=; b=NIIVANQYa+2qT0Up4xTCjH/Oin/z6FoSgy65wyfwtoQccG2viymxxUrsIShyRXSaA6 m88+vt/MAFyPkJNt8MA6cTaZOBhrTxyy81yeWlaQ4v7twNicC6fs9r+Q9WgegcscwsV5 4FkT15xQn9GzYPbmIzJk/pTPt9CF42u2iGXH1ob+H/mVyTWglJ9hTg9qEQX0mm/iYNOZ eP8ic1tf20bNVCCu9nRq9rH6JEiTXtKjYaXmNaeqU9RWuSQ39K4IkeQNG4i3Bp0aK3pi nl6DtzrKoFATvWLT/GGvaEbrTcPotE9cR2tWkJkTqExd+qaN4K9z36XckkVLt7CXjbls LHMQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=HukKTbwS; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id j70si5988317ybj.220.2020.07.01.06.59.56 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Wed, 01 Jul 2020 06:59:56 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=HukKTbwS; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1]:34932 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jqdHH-0005qI-Sl for patch@linaro.org; Wed, 01 Jul 2020 09:59:55 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:58808) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jqdEU-0002Bu-Bd for qemu-devel@nongnu.org; Wed, 01 Jul 2020 09:57:02 -0400 Received: from mail-wr1-x442.google.com ([2a00:1450:4864:20::442]:38528) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1jqdES-0005q6-Ao for qemu-devel@nongnu.org; Wed, 01 Jul 2020 09:57:02 -0400 Received: by mail-wr1-x442.google.com with SMTP id z13so23959360wrw.5 for ; Wed, 01 Jul 2020 06:56:59 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=/2Na6SuLR2BPH24MTaa9ZH4OY5rPBs3TXnZRAXFwy5s=; b=HukKTbwS3xLaKvtwiGlyUulYjK3Nk/fFVapHUciO2MHMhGV7OxoU7hw43GXLEYlOkJ SH6EhPYd/uJLh9glIUnMETUJrbvDujT67OU7awC7box+xi7kDkzXVq16Asoug5nCNvMh jqbThx1296xqxTV3aUBc7wjAewd5X7tc1PPw3F2tP1VYEE5vjT9e9zFFGItoJRu/x44M xN7DkGKbTxHyclA0GROLaPr00E9mpDQO4JU44GfxNKHoer+20QIRnTfUqG9wLgWtkxeR h0itNVumENwl9cMVb2WSPFSqjrqAm05uZFhb2dFIUOkuhM1qVjLh6IbnAjTUVqkkGb7y gJ+Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=/2Na6SuLR2BPH24MTaa9ZH4OY5rPBs3TXnZRAXFwy5s=; b=H0nJhKsSM9v1+/JkDJp7MzygKroJcBLk2s9Iw+viAmi824WTxow4puXNSh0WVGEQIn 1iOEHBbsyWEJXPKZweyyM9LMJieDaPdEw9v2CfTlVO7q7NUb65TxudDibbLpgB+FrFUX gBa4lDZH8DrJPOwNl7Xvx37hJj/asPNNbGYVncklie/LDs1Mlwr7tdasUAHnRXEnQYZF 6+xYmSdf3H4OSx/MNK7wZoBxLeSfb68TBkTRyGq3gVhZ4ZBxg5UsVaF7Prvqs3kHsSLV XkY5+LTPv/yl4dGfw5jjsnZvOcfrlADHJt0NONsLdLQJzdSZmd2VL4+8vE0NbVB+v3yI MC7A== X-Gm-Message-State: AOAM533cbDIN4vv7JA0WoiH7qtPSqg9s3f+YFY/3qn08zghmEKL4gENK ExgBbuYkpES3YTJUyaUOxz4c/Q== X-Received: by 2002:a5d:4603:: with SMTP id t3mr29010137wrq.38.1593611818952; Wed, 01 Jul 2020 06:56:58 -0700 (PDT) Received: from zen.linaroharston ([51.148.130.216]) by smtp.gmail.com with ESMTPSA id k126sm7565612wmf.3.2020.07.01.06.56.53 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 01 Jul 2020 06:56:53 -0700 (PDT) Received: from zen.lan (localhost [127.0.0.1]) by zen.linaroharston (Postfix) with ESMTP id 37DB41FF90; Wed, 1 Jul 2020 14:56:53 +0100 (BST) From: =?utf-8?q?Alex_Benn=C3=A9e?= To: qemu-devel@nongnu.org Subject: [PATCH v4 04/40] util/coroutine: Cleanup start_switch_fiber_ for TSAN. Date: Wed, 1 Jul 2020 14:56:16 +0100 Message-Id: <20200701135652.1366-5-alex.bennee@linaro.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20200701135652.1366-1-alex.bennee@linaro.org> References: <20200701135652.1366-1-alex.bennee@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::442; envelope-from=alex.bennee@linaro.org; helo=mail-wr1-x442.google.com X-detected-operating-system: by eggs.gnu.org: No matching host in p0f cache. That's all we know. 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=_AUTOLEARN X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: fam@euphon.net, Kevin Wolf , berrange@redhat.com, Robert Foley , =?utf-8?q?Alex_Benn=C3=A9e?= , richard.henderson@linaro.org, f4bug@amsat.org, cota@braap.org, Stefan Hajnoczi , aurelien@aurel32.net Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: "Qemu-devel" From: Robert Foley This is a cleanup patch to follow-up the patch which introduced TSAN. This patch makes separate start_switch_fiber_ functions for TSAN and ASAN. This does two things: 1. Unrelated ASAN and TSAN code is separate and each function only has arguments that are actually needed. 2. The co->tsan_caller_fiber and co->tsan_co_fiber fields are only access from within #ifdef CONFIG_TSAN. Signed-off-by: Robert Foley Reviewed-by: Stefan Hajnoczi Signed-off-by: Alex Bennée Message-Id: <20200626170001.27017-1-robert.foley@linaro.org> --- util/coroutine-ucontext.c | 52 +++++++++++++++++++++++++-------------- 1 file changed, 34 insertions(+), 18 deletions(-) -- 2.20.1 diff --git a/util/coroutine-ucontext.c b/util/coroutine-ucontext.c index f0b66320e10..fff20aad80a 100644 --- a/util/coroutine-ucontext.c +++ b/util/coroutine-ucontext.c @@ -52,8 +52,10 @@ typedef struct { #endif sigjmp_buf env; +#ifdef CONFIG_TSAN void *tsan_co_fiber; void *tsan_caller_fiber; +#endif #ifdef CONFIG_VALGRIND_H unsigned int valgrind_stack_id; @@ -77,7 +79,10 @@ union cc_arg { int i[2]; }; -/* QEMU_ALWAYS_INLINE only does so if __OPTIMIZE__, so we cannot use it. */ +/* + * QEMU_ALWAYS_INLINE only does so if __OPTIMIZE__, so we cannot use it. + * always_inline is required to avoid TSan runtime fatal errors. + */ static inline __attribute__((always_inline)) void on_new_fiber(CoroutineUContext *co) { @@ -87,6 +92,7 @@ void on_new_fiber(CoroutineUContext *co) #endif } +/* always_inline is required to avoid TSan runtime fatal errors. */ static inline __attribute__((always_inline)) void finish_switch_fiber(void *fake_stack_save) { @@ -109,18 +115,29 @@ void finish_switch_fiber(void *fake_stack_save) #endif } -static inline __attribute__((always_inline)) void start_switch_fiber( - CoroutineAction action, void **fake_stack_save, - const void *bottom, size_t size, void *new_fiber) +/* always_inline is required to avoid TSan runtime fatal errors. */ +static inline __attribute__((always_inline)) +void start_switch_fiber_asan(CoroutineAction action, void **fake_stack_save, + const void *bottom, size_t size) { #ifdef CONFIG_ASAN __sanitizer_start_switch_fiber( action == COROUTINE_TERMINATE ? NULL : fake_stack_save, bottom, size); #endif +} + +/* always_inline is required to avoid TSan runtime fatal errors. */ +static inline __attribute__((always_inline)) +void start_switch_fiber_tsan(void **fake_stack_save, + CoroutineUContext *co, + bool caller) +{ #ifdef CONFIG_TSAN - void *curr_fiber = - __tsan_get_current_fiber(); + void *new_fiber = caller ? + co->tsan_caller_fiber : + co->tsan_co_fiber; + void *curr_fiber = __tsan_get_current_fiber(); __tsan_acquire(curr_fiber); *fake_stack_save = curr_fiber; @@ -144,12 +161,9 @@ static void coroutine_trampoline(int i0, int i1) /* Initialize longjmp environment and switch back the caller */ if (!sigsetjmp(self->env, 0)) { - start_switch_fiber( - COROUTINE_YIELD, - &fake_stack_save, - leader.stack, - leader.stack_size, - self->tsan_caller_fiber); + start_switch_fiber_asan(COROUTINE_YIELD, &fake_stack_save, leader.stack, + leader.stack_size); + start_switch_fiber_tsan(&fake_stack_save, self, true); /* true=caller */ siglongjmp(*(sigjmp_buf *)co->entry_arg, 1); } @@ -208,10 +222,10 @@ Coroutine *qemu_coroutine_new(void) /* swapcontext() in, siglongjmp() back out */ if (!sigsetjmp(old_env, 0)) { - start_switch_fiber( - COROUTINE_YIELD, - &fake_stack_save, - co->stack, co->stack_size, co->tsan_co_fiber); + start_switch_fiber_asan(COROUTINE_YIELD, &fake_stack_save, co->stack, + co->stack_size); + start_switch_fiber_tsan(&fake_stack_save, + co, false); /* false=not caller */ #ifdef CONFIG_SAFESTACK /* @@ -287,8 +301,10 @@ qemu_coroutine_switch(Coroutine *from_, Coroutine *to_, ret = sigsetjmp(from->env, 0); if (ret == 0) { - start_switch_fiber(action, &fake_stack_save, - to->stack, to->stack_size, to->tsan_co_fiber); + start_switch_fiber_asan(action, &fake_stack_save, to->stack, + to->stack_size); + start_switch_fiber_tsan(&fake_stack_save, + to, false); /* false=not caller */ siglongjmp(to->env, action); } From patchwork Wed Jul 1 13:56:17 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Alex_Benn=C3=A9e?= X-Patchwork-Id: 192136 Delivered-To: patch@linaro.org Received: by 2002:a92:d244:0:0:0:0:0 with SMTP id v4csp518940ilg; Wed, 1 Jul 2020 06:59:31 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyWpV+X3oixkq1DoLBP4sVNH1pMXeVJSPbD9hWSxVJVrej2+B4k65Jv5lW+9s0k885ckfbp X-Received: by 2002:a25:2d24:: with SMTP id t36mr42941122ybt.426.1593611971765; Wed, 01 Jul 2020 06:59:31 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1593611971; cv=none; d=google.com; s=arc-20160816; b=GxUiSY6RC3vauN6FTqHAYX2ZbmU9RhpJKlo9Dq9fe+RtLSKWKmjZTqlKkRvi+9vFDR tCYaB+puptqxKuPElNnNJ1rNucNtkl12ZalRJYTA83GhqlMldIAl2Mv8pGVpI0WQfJVw MdRVK1Fdo1PsJ3TbPv+xdbAxcmJb4qWgP7pKJExqpoZsyKxJ7DXFLpbFYbG+RBy2pN9v NSEvk0zS2KPYrzQsOlSVilL6J3jXw/jZ31TBx/Gqx0E6GUP5psVpKGPOWD24UqDgQkI4 vMQuna6FYlzLVmGpBmJwGD1JdCKh6hBr1j7IFF60QwLMi4/aKMIhweeQRlkDyXzXS3Sa cn8g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:cc:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=m1Iumf3YfxuO4NhxteboEtLnibs/CAVIrPHuCmkmoi4=; b=jM/+sFObNvNAYgxQKYy8jc3fVMMXGEHpayg//9YwZ0fMTP6u8seax87k80zaHZN09S xQ4zSbNF4ZY0A7Ch5Qs+7eoKeN9jrSMBEiOJm+nXUk0CZmrPONCmJQAK6Bm7xQJQq/v8 6kFKuneAxp0Krmccz5n9/6fjBHr7RYdpae8VmRnvnKoNWQAWvpsMppb84CfDRuzPcXJe T+eYWIJu3hBFNoXCWxK+ssSNHbUWyHquJTxfiH0+XM+awXhH3WmqS2sV734vpuaG5fqS jwjcoXSivSmGaK/7Sn1YWoktltnjoPuwJh4B9ajv+3WaMLgfX0z8R/cR8RI7/jZyJNvY UbJA== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=SnlSS0zQ; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id b14si5218942ybr.60.2020.07.01.06.59.31 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Wed, 01 Jul 2020 06:59:31 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=SnlSS0zQ; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1]:35626 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jqdGt-00068t-6H for patch@linaro.org; Wed, 01 Jul 2020 09:59:31 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:58906) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jqdEZ-0002OW-Bl for qemu-devel@nongnu.org; Wed, 01 Jul 2020 09:57:07 -0400 Received: from mail-wr1-x432.google.com ([2a00:1450:4864:20::432]:47060) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1jqdEW-0005rB-2u for qemu-devel@nongnu.org; Wed, 01 Jul 2020 09:57:07 -0400 Received: by mail-wr1-x432.google.com with SMTP id r12so23891641wrj.13 for ; Wed, 01 Jul 2020 06:57:03 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=m1Iumf3YfxuO4NhxteboEtLnibs/CAVIrPHuCmkmoi4=; b=SnlSS0zQX/Muk/NpdPlmirftbBZaI2iqZ7F8X01Q4MwhLWbv0XGRNNcT9/z4GjyVvY P99F3fUTrkK6ml5XHzFcxfCOwTzNswE1JKNc+2iiu8l24KZJIImlOmLCMIiYcc0D682j juKhCS9RWfILHaYvlM6O+XzlOHOAZaF1dtmiK+ZOLQg2+5/cRAVGaIF+ZyKfrOvNYsGw 5shIZGmXnDFscDaUWiFXEkgKttzgUj+Ucn6Njgcu2ABlGsisvbuTe58/kbcozDu7lB6H Y0TRdMoOcXwjT88OCehjlrSKDo3v5hLqOSb/wrJ1UNH4EogGz4OCzl23Mi/F1jxoJPV4 JrKA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=m1Iumf3YfxuO4NhxteboEtLnibs/CAVIrPHuCmkmoi4=; b=XEM2PXeGUlbbQozPuq3jesgSugRSVArWaTUTWBYzDLoOSuirRKfx3qd1oUfHPk9bZ8 RhDvwIv16TNPLWZM7OOv4voh7zIOx1eeUXA27iPdIN5SdwQgdge5+lGSNN6axO1jV6f8 XK/twOXH/c7RWEao6vHVeAk7c2yY+JR8WVufGD7TfqCJyUe/yGJWwgtE3tyeB0g1ymmS WpeHN4XQupFrWjwHBus51ZcP1mrnBcm4xxTz/P+e2LAWbOzqZynJgrdzQK0FMEAMWTFB uKJWbS3rep4sof9ZdlzeQsp61hwGTY3TP2vMoZHThRt2BwQS7ZlKl4hrv9yYbU7FWfFQ q3lA== X-Gm-Message-State: AOAM532G4jHTybbm8JmuWtoilhKwYMchm9U0DmUAFft37csL5s5dANtc WimK1Mx+x7cokibkQE6bH8LKuR1vGmw= X-Received: by 2002:a5d:4e48:: with SMTP id r8mr26381040wrt.309.1593611822633; Wed, 01 Jul 2020 06:57:02 -0700 (PDT) Received: from zen.linaroharston ([51.148.130.216]) by smtp.gmail.com with ESMTPSA id 65sm7973132wma.48.2020.07.01.06.56.55 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 01 Jul 2020 06:57:00 -0700 (PDT) Received: from zen.lan (localhost [127.0.0.1]) by zen.linaroharston (Postfix) with ESMTP id 4DFE71FF91; Wed, 1 Jul 2020 14:56:53 +0100 (BST) From: =?utf-8?q?Alex_Benn=C3=A9e?= To: qemu-devel@nongnu.org Subject: [PATCH v4 05/40] tests/vm: pass args through to BaseVM's __init__ Date: Wed, 1 Jul 2020 14:56:17 +0100 Message-Id: <20200701135652.1366-6-alex.bennee@linaro.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20200701135652.1366-1-alex.bennee@linaro.org> References: <20200701135652.1366-1-alex.bennee@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::432; envelope-from=alex.bennee@linaro.org; helo=mail-wr1-x432.google.com X-detected-operating-system: by eggs.gnu.org: No matching host in p0f cache. That's all we know. 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, URIBL_BLOCKED=0.001 autolearn=_AUTOLEARN X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: fam@euphon.net, berrange@redhat.com, Robert Foley , =?utf-8?q?Alex_Benn=C3=A9e?= , richard.henderson@linaro.org, f4bug@amsat.org, =?utf-8?q?Philippe_Mat?= =?utf-8?q?hieu-Daud=C3=A9?= , cota@braap.org, aurelien@aurel32.net Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: "Qemu-devel" From: Robert Foley Adding the args parameter to BaseVM's __init__. We will shortly need to pass more parameters to the class so let's just pass args rather than growing the parameter list. Signed-off-by: Robert Foley Reviewed-by: Alex Bennée Reviewed-by: Philippe Mathieu-Daudé Tested-by: Philippe Mathieu-Daudé Signed-off-by: Alex Bennée Message-Id: <20200601211421.1277-2-robert.foley@linaro.org> --- tests/vm/basevm.py | 16 +++++++--------- 1 file changed, 7 insertions(+), 9 deletions(-) -- 2.20.1 diff --git a/tests/vm/basevm.py b/tests/vm/basevm.py index a80b616a08d..5a58e6c3930 100644 --- a/tests/vm/basevm.py +++ b/tests/vm/basevm.py @@ -61,11 +61,10 @@ class BaseVM(object): # 4 is arbitrary, but greater than 2, # since we found we need to wait more than twice as long. tcg_ssh_timeout_multiplier = 4 - def __init__(self, debug=False, vcpus=None, genisoimage=None, - build_path=None): + def __init__(self, args): self._guest = None - self._genisoimage = genisoimage - self._build_path = build_path + self._genisoimage = args.genisoimage + self._build_path = args.build_path self._tmpdir = os.path.realpath(tempfile.mkdtemp(prefix="vm-test-", suffix=".tmp", dir=".")) @@ -78,7 +77,7 @@ class BaseVM(object): self._ssh_pub_key_file = os.path.join(self._tmpdir, "id_rsa.pub") open(self._ssh_pub_key_file, "w").write(SSH_PUB_KEY) - self.debug = debug + self.debug = args.debug self._stderr = sys.stderr self._devnull = open(os.devnull, "w") if self.debug: @@ -92,8 +91,8 @@ class BaseVM(object): (",ipv6=no" if not self.ipv6 else ""), "-device", "virtio-net-pci,netdev=vnet", "-vnc", "127.0.0.1:0,to=20"] - if vcpus and vcpus > 1: - self._args += ["-smp", "%d" % vcpus] + if args.jobs and args.jobs > 1: + self._args += ["-smp", "%d" % args.jobs] if kvm_available(self.arch): self._args += ["-enable-kvm"] else: @@ -456,8 +455,7 @@ def main(vmcls): return 1 logging.basicConfig(level=(logging.DEBUG if args.debug else logging.WARN)) - vm = vmcls(debug=args.debug, vcpus=args.jobs, - genisoimage=args.genisoimage, build_path=args.build_path) + vm = vmcls(args) if args.build_image: if os.path.exists(args.image) and not args.force: sys.stderr.writelines(["Image file exists: %s\n" % args.image, From patchwork Wed Jul 1 13:56:18 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Alex_Benn=C3=A9e?= X-Patchwork-Id: 192146 Delivered-To: patch@linaro.org Received: by 2002:a92:d244:0:0:0:0:0 with SMTP id v4csp524238ilg; Wed, 1 Jul 2020 07:04:38 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyHuPFJp5JTK0pHxdiFCOSPxBK+eA7mX3ngof/UuIOvRRcjWSqXreanX7ThDA0VFVaSIHZZ X-Received: by 2002:a25:d684:: with SMTP id n126mr44980107ybg.476.1593612277843; Wed, 01 Jul 2020 07:04:37 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1593612277; cv=none; d=google.com; s=arc-20160816; b=cMeIyWgIvuuE4T4DPC/d4HQLQL03R2cAAWn797JI6KvhQ2k977P+e3JmBIUCkfFtfn NNhy8I0fIiAenAzQRrlSPQkcStauH8XiIXzBGIaBO1vnqPUgBAZiWob8DnJXcSiaNETW YqDza/GW6gWh40uji0lEQ+wbaAkudC/zbHI0HPfgDSJ1edB0VycCA38o4A9UbbGTZByQ 3gz7H0WolS5ZBiHSHZ00Nc5Ry5ugAbFEpxVqxGF6K7bKH1rOFySdKpgAI7aE4qoxy5q2 Lfw91su6zHg3H09EOvtzYM676dI1WHJg1zzoniWxVUlW7p0u3/YZnMRVgmMwSMORUiXW JXsQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:cc:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=Uqu+G7KWNLFFsBFSWuF2fzigErk1o01AVduM2CJF95Y=; b=jWlh8gS4BMaj1TRPIHqztfyx7aS3ThFSaW+/FMpb9p6RtXf0MBMxl28vNYb2oUTHiT hW3fpB/nlhVv6pWfFdLuUo/CZiIBB6c0RtRC7rga0TT2LoApkjveSAY2dyNHOz2/253f h6eQ7tl9syvGSEPG1faLUbvRy0MQDT9u5QZ2C++JtIK/Tg4MsVNpGl4xyQAetEdQJbfT gPdBNrjIpSB6fg5tbQgasywUKQA6Zz+Atnze0kNaFVmOP8/9svDoZP9kCjsmXl9VfrFd 5ci8QfYu4lgcIVNJT2DBV5wqsgO+hlypEMYsMB+k8cjHRPubl4UxyjHWqwusEUxtTOtL Ivyg== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=jC87SJqb; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id h188si5638691ybh.300.2020.07.01.07.04.37 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Wed, 01 Jul 2020 07:04:37 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=jC87SJqb; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1]:51714 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jqdLp-0004b6-52 for patch@linaro.org; Wed, 01 Jul 2020 10:04:37 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:58940) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jqdEb-0002Tc-Dj for qemu-devel@nongnu.org; Wed, 01 Jul 2020 09:57:09 -0400 Received: from mail-wr1-x42a.google.com ([2a00:1450:4864:20::42a]:44109) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1jqdEY-0005rm-VH for qemu-devel@nongnu.org; Wed, 01 Jul 2020 09:57:09 -0400 Received: by mail-wr1-x42a.google.com with SMTP id b6so23927319wrs.11 for ; Wed, 01 Jul 2020 06:57:06 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=Uqu+G7KWNLFFsBFSWuF2fzigErk1o01AVduM2CJF95Y=; b=jC87SJqbYxh+evflc4EauyFWYT1fbtj+o2LsQXhz8F4Vhkb/prSZMjgIUfdav73ipH QuhAGQDudwmGLgU5TGXCufwrvvFDdeTNGsDuViG9LWvYCdw56JFaJfMKHcoKxY6AgWce UPwV52zurauMmVkMkuRwjqBhYP2ZG/TlyeSNmgZXqjKPZ+urdFAQv8EPo4JOZLJBrfKQ DppmCtksckfAmXBQepR6go2uA9qmxgS9xvWXEAfCG1Gtnw25YT9OcsVy7iv1hn0sMfnf pi/S+H8+4lNOQ4SnpIvphGU1U2OnfQ022Sdm22OxR9LcWx9RdP8ePz/4qJpSKxJc7CLZ l61g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=Uqu+G7KWNLFFsBFSWuF2fzigErk1o01AVduM2CJF95Y=; b=kZ3LzXCknRkfj9vlj0lI6aApbvHs/M/+c4/JmhyyR4nbhzVgrWoR75hh3DWH4nKLnz sF6hfsIGCgP+AMFStXSglvXNi7UED/yrq4ZaHwJS/SRsjAv4MLPFbFfFMA6TuHh3pVmB rV5nKGeql4nqBFmPfrG/FfdNOhKfTLG2lZPZTt6MlyEkdkkZRWdNDXyj5q8ePeGuMQLx P0u10UobVduoeQmbho3AGWSqjkA8TWm3qMxY7N2GseOzroelptYMdxBVpfjXCeuKEbv/ N86jCw57ptAQ6HopmamDLw5ac9n0e4VZGB5ksHfMnlZOJt0KTUDk+oml42nt+HP1lMp6 P7mQ== X-Gm-Message-State: AOAM533Y929rRpiTNslmi60GXfkQ1pSfxy9OmMKwH+AfODaP5lsPkGRb RVfEMPJlmewrwqk0XitJSoR0MQ== X-Received: by 2002:a5d:6651:: with SMTP id f17mr28880812wrw.29.1593611825174; Wed, 01 Jul 2020 06:57:05 -0700 (PDT) Received: from zen.linaroharston ([51.148.130.216]) by smtp.gmail.com with ESMTPSA id b18sm7689783wmb.18.2020.07.01.06.56.55 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 01 Jul 2020 06:57:00 -0700 (PDT) Received: from zen.lan (localhost [127.0.0.1]) by zen.linaroharston (Postfix) with ESMTP id 655F11FF92; Wed, 1 Jul 2020 14:56:53 +0100 (BST) From: =?utf-8?q?Alex_Benn=C3=A9e?= To: qemu-devel@nongnu.org Subject: [PATCH v4 06/40] tests/vm: Add configuration to basevm.py Date: Wed, 1 Jul 2020 14:56:18 +0100 Message-Id: <20200701135652.1366-7-alex.bennee@linaro.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20200701135652.1366-1-alex.bennee@linaro.org> References: <20200701135652.1366-1-alex.bennee@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::42a; envelope-from=alex.bennee@linaro.org; helo=mail-wr1-x42a.google.com X-detected-operating-system: by eggs.gnu.org: No matching host in p0f cache. That's all we know. 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, URIBL_BLOCKED=0.001 autolearn=_AUTOLEARN X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: fam@euphon.net, berrange@redhat.com, Robert Foley , =?utf-8?q?Alex_Benn=C3=A9e?= , richard.henderson@linaro.org, f4bug@amsat.org, =?utf-8?q?Philippe_Mat?= =?utf-8?q?hieu-Daud=C3=A9?= , cota@braap.org, Peter Puhov , aurelien@aurel32.net Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: "Qemu-devel" From: Robert Foley Added use of a configuration to tests/vm/basevm.py. The configuration provides parameters used to configure a VM. This allows for providing alternate configurations to the VM being created/launched. cpu, machine, memory, and NUMA configuration are all examples of configuration which we might want to vary on the VM being created or launched. This will for example allow for creating an aarch64 vm. Signed-off-by: Robert Foley Reviewed-by: Peter Puhov Reviewed-by: Alex Bennée Signed-off-by: Alex Bennée Message-Id: <20200601211421.1277-3-robert.foley@linaro.org> --- tests/vm/basevm.py | 172 +++++++++++++++++++++++++++++++++++---------- 1 file changed, 133 insertions(+), 39 deletions(-) -- 2.20.1 diff --git a/tests/vm/basevm.py b/tests/vm/basevm.py index 5a58e6c3930..cfe20c58f7e 100644 --- a/tests/vm/basevm.py +++ b/tests/vm/basevm.py @@ -29,16 +29,41 @@ import tempfile import shutil import multiprocessing import traceback - -SSH_KEY = open(os.path.join(os.path.dirname(__file__), - "..", "keys", "id_rsa")).read() -SSH_PUB_KEY = open(os.path.join(os.path.dirname(__file__), - "..", "keys", "id_rsa.pub")).read() - +import shlex + +SSH_KEY_FILE = os.path.join(os.path.dirname(__file__), + "..", "keys", "id_rsa") +SSH_PUB_KEY_FILE = os.path.join(os.path.dirname(__file__), + "..", "keys", "id_rsa.pub") + +# This is the standard configuration. +# Any or all of these can be overridden by +# passing in a config argument to the VM constructor. +DEFAULT_CONFIG = { + 'cpu' : "max", + 'machine' : 'pc', + 'guest_user' : "qemu", + 'guest_pass' : "qemupass", + 'root_pass' : "qemupass", + 'ssh_key_file' : SSH_KEY_FILE, + 'ssh_pub_key_file': SSH_PUB_KEY_FILE, + 'memory' : "4G", + 'extra_args' : [], + 'qemu_args' : "", + 'dns' : "", + 'ssh_port' : 0, + 'install_cmds' : "", + 'boot_dev_type' : "block", + 'ssh_timeout' : 1, +} +BOOT_DEVICE = { + 'block' : "-drive file={},if=none,id=drive0,cache=writeback "\ + "-device virtio-blk,drive=drive0,bootindex=0", + 'scsi' : "-device virtio-scsi-device,id=scsi "\ + "-drive file={},format=raw,if=none,id=hd0 "\ + "-device scsi-hd,drive=hd0,bootindex=0", +} class BaseVM(object): - GUEST_USER = "qemu" - GUEST_PASS = "qemupass" - ROOT_PASS = "qemupass" envvars = [ "https_proxy", @@ -57,25 +82,38 @@ class BaseVM(object): poweroff = "poweroff" # enable IPv6 networking ipv6 = True + # This is the timeout on the wait for console bytes. + socket_timeout = 120 # Scale up some timeouts under TCG. # 4 is arbitrary, but greater than 2, # since we found we need to wait more than twice as long. tcg_ssh_timeout_multiplier = 4 - def __init__(self, args): + def __init__(self, args, config=None): self._guest = None self._genisoimage = args.genisoimage self._build_path = args.build_path + # Allow input config to override defaults. + self._config = DEFAULT_CONFIG.copy() + if config != None: + self._config.update(config) + self.validate_ssh_keys() self._tmpdir = os.path.realpath(tempfile.mkdtemp(prefix="vm-test-", suffix=".tmp", dir=".")) atexit.register(shutil.rmtree, self._tmpdir) - - self._ssh_key_file = os.path.join(self._tmpdir, "id_rsa") - open(self._ssh_key_file, "w").write(SSH_KEY) - subprocess.check_call(["chmod", "600", self._ssh_key_file]) - - self._ssh_pub_key_file = os.path.join(self._tmpdir, "id_rsa.pub") - open(self._ssh_pub_key_file, "w").write(SSH_PUB_KEY) + # Copy the key files to a temporary directory. + # Also chmod the key file to agree with ssh requirements. + self._config['ssh_key'] = \ + open(self._config['ssh_key_file']).read().rstrip() + self._config['ssh_pub_key'] = \ + open(self._config['ssh_pub_key_file']).read().rstrip() + self._ssh_tmp_key_file = os.path.join(self._tmpdir, "id_rsa") + open(self._ssh_tmp_key_file, "w").write(self._config['ssh_key']) + subprocess.check_call(["chmod", "600", self._ssh_tmp_key_file]) + + self._ssh_tmp_pub_key_file = os.path.join(self._tmpdir, "id_rsa.pub") + open(self._ssh_tmp_pub_key_file, + "w").write(self._config['ssh_pub_key']) self.debug = args.debug self._stderr = sys.stderr @@ -84,11 +122,14 @@ class BaseVM(object): self._stdout = sys.stdout else: self._stdout = self._devnull + netdev = "user,id=vnet,hostfwd=:127.0.0.1:{}-:22" self._args = [ \ - "-nodefaults", "-m", "4G", - "-cpu", "max", - "-netdev", "user,id=vnet,hostfwd=:127.0.0.1:0-:22" + - (",ipv6=no" if not self.ipv6 else ""), + "-nodefaults", "-m", self._config['memory'], + "-cpu", self._config['cpu'], + "-netdev", + netdev.format(self._config['ssh_port']) + + (",ipv6=no" if not self.ipv6 else "") + + (",dns=" + self._config['dns'] if self._config['dns'] else ""), "-device", "virtio-net-pci,netdev=vnet", "-vnc", "127.0.0.1:0,to=20"] if args.jobs and args.jobs > 1: @@ -99,6 +140,55 @@ class BaseVM(object): logging.info("KVM not available, not using -enable-kvm") self._data_args = [] + if self._config['qemu_args'] != None: + qemu_args = self._config['qemu_args'] + qemu_args = qemu_args.replace('\n',' ').replace('\r','') + # shlex groups quoted arguments together + # we need this to keep the quoted args together for when + # the QEMU command is issued later. + args = shlex.split(qemu_args) + self._config['extra_args'] = [] + for arg in args: + if arg: + # Preserve quotes around arguments. + # shlex above takes them out, so add them in. + if " " in arg: + arg = '"{}"'.format(arg) + self._config['extra_args'].append(arg) + + def validate_ssh_keys(self): + """Check to see if the ssh key files exist.""" + if 'ssh_key_file' not in self._config or\ + not os.path.exists(self._config['ssh_key_file']): + raise Exception("ssh key file not found.") + if 'ssh_pub_key_file' not in self._config or\ + not os.path.exists(self._config['ssh_pub_key_file']): + raise Exception("ssh pub key file not found.") + + def wait_boot(self, wait_string=None): + """Wait for the standard string we expect + on completion of a normal boot. + The user can also choose to override with an + alternate string to wait for.""" + if wait_string is None: + if self.login_prompt is None: + raise Exception("self.login_prompt not defined") + wait_string = self.login_prompt + # Intentionally bump up the default timeout under TCG, + # since the console wait below takes longer. + timeout = self.socket_timeout + if not kvm_available(self.arch): + timeout *= 8 + self.console_init(timeout=timeout) + self.console_wait(wait_string) + + def __getattr__(self, name): + # Support direct access to config by key. + # for example, access self._config['cpu'] by self.cpu + if name.lower() in self._config.keys(): + return self._config[name.lower()] + return object.__getattribute__(self, name) + def _download_with_cache(self, url, sha256sum=None, sha512sum=None): def check_sha256sum(fname): if not sha256sum: @@ -130,8 +220,9 @@ class BaseVM(object): "-t", "-o", "StrictHostKeyChecking=no", "-o", "UserKnownHostsFile=" + os.devnull, - "-o", "ConnectTimeout=1", - "-p", self.ssh_port, "-i", self._ssh_key_file] + "-o", + "ConnectTimeout={}".format(self._config["ssh_timeout"]), + "-p", self.ssh_port, "-i", self._ssh_tmp_key_file] # If not in debug mode, set ssh to quiet mode to # avoid printing the results of commands. if not self.debug: @@ -180,14 +271,14 @@ class BaseVM(object): "virtio-blk,drive=%s,serial=%s,bootindex=1" % (name, name)] def boot(self, img, extra_args=[]): - args = self._args + [ - "-drive", "file=%s,if=none,id=drive0,cache=writeback" % img, - "-device", "virtio-blk,drive=drive0,bootindex=0"] - args += self._data_args + extra_args + boot_dev = BOOT_DEVICE[self._config['boot_dev_type']] + boot_params = boot_dev.format(img) + args = self._args + boot_params.split(' ') + args += self._data_args + extra_args + self._config['extra_args'] logging.debug("QEMU args: %s", " ".join(args)) qemu_path = get_qemu_path(self.arch, self._build_path) guest = QEMUMachine(binary=qemu_path, args=args) - guest.set_machine('pc') + guest.set_machine(self._config['machine']) guest.set_console() try: guest.launch() @@ -301,7 +392,8 @@ class BaseVM(object): self.console_send(command) def console_ssh_init(self, prompt, user, pw): - sshkey_cmd = "echo '%s' > .ssh/authorized_keys\n" % SSH_PUB_KEY.rstrip() + sshkey_cmd = "echo '%s' > .ssh/authorized_keys\n" \ + % self._config['ssh_pub_key'].rstrip() self.console_wait_send("login:", "%s\n" % user) self.console_wait_send("Password:", "%s\n" % pw) self.console_wait_send(prompt, "mkdir .ssh\n") @@ -360,23 +452,23 @@ class BaseVM(object): "local-hostname: {}-guest\n".format(name)]) mdata.close() udata = open(os.path.join(cidir, "user-data"), "w") - print("guest user:pw {}:{}".format(self.GUEST_USER, - self.GUEST_PASS)) + print("guest user:pw {}:{}".format(self._config['guest_user'], + self._config['guest_pass'])) udata.writelines(["#cloud-config\n", "chpasswd:\n", " list: |\n", - " root:%s\n" % self.ROOT_PASS, - " %s:%s\n" % (self.GUEST_USER, - self.GUEST_PASS), + " root:%s\n" % self._config['root_pass'], + " %s:%s\n" % (self._config['guest_user'], + self._config['guest_pass']), " expire: False\n", "users:\n", - " - name: %s\n" % self.GUEST_USER, + " - name: %s\n" % self._config['guest_user'], " sudo: ALL=(ALL) NOPASSWD:ALL\n", " ssh-authorized-keys:\n", - " - %s\n" % SSH_PUB_KEY, + " - %s\n" % self._config['ssh_pub_key'], " - name: root\n", " ssh-authorized-keys:\n", - " - %s\n" % SSH_PUB_KEY, + " - %s\n" % self._config['ssh_pub_key'], "locale: en_US.UTF-8\n"]) proxy = os.environ.get("http_proxy") if not proxy is None: @@ -447,15 +539,17 @@ def parse_args(vmcls): parser.disable_interspersed_args() return parser.parse_args() -def main(vmcls): +def main(vmcls, config=None): try: + if config == None: + config = {} args, argv = parse_args(vmcls) if not argv and not args.build_qemu and not args.build_image: print("Nothing to do?") return 1 logging.basicConfig(level=(logging.DEBUG if args.debug else logging.WARN)) - vm = vmcls(args) + vm = vmcls(args, config=config) if args.build_image: if os.path.exists(args.image) and not args.force: sys.stderr.writelines(["Image file exists: %s\n" % args.image, From patchwork Wed Jul 1 13:56:19 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Alex_Benn=C3=A9e?= X-Patchwork-Id: 192142 Delivered-To: patch@linaro.org Received: by 2002:a92:d244:0:0:0:0:0 with SMTP id v4csp521796ilg; Wed, 1 Jul 2020 07:02:19 -0700 (PDT) X-Google-Smtp-Source: ABdhPJz+p1y/J08ncjlZrpOtvDzNu9/AtiSe3SG/P55BVawJTfkBPAN0jf5PJrx/b1/sKk8k0J2U X-Received: by 2002:a25:acdd:: with SMTP id x29mr25943646ybd.58.1593612139905; Wed, 01 Jul 2020 07:02:19 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1593612139; cv=none; d=google.com; s=arc-20160816; b=C6qUeTElwHP2MzGiYswTmKhXnIeYYykGzjb/tjEPVacykcuB1JwZrp/9MYm87IcNAb kS3J9yIvgDSH4slPiy/xyxtLgXavJuj6DkdExD5RTxTqRUdnq01byouOiyGS8ZCtWAQs KjBdV6GmbUnFDIYg43G8ho8JD6FOcL9+lL2h/Ede3f1FD9C/Ykwh8jyp1pO1M0ZPdQl4 tMU2CCdHnURmz5cLJGUqEXOojFC1DQuBl0iyGSd7QhWHjU5wK6o4jAXL2bBYjMRA7bxH adncYHBNmpsy5+qScSOxnC8WHWP2K4DHjNm333vPA35RxPSBeDydqPUiQcIC3w1/2arD JDeA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:cc:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=Jmf45TdSZl+xaFqF4i+rpuxLxpTS1OvMPwFk/ldTir0=; b=bfF70+p0+tHqdvCj2OraAm1q2BDwIOvbGhk9JceB3AunutogjBmTVi4ph5AssqUsWs touGcr0C6PDpILYDr3f1janpb+Pt8cVNsxH7cVBya/ZHoeB8y2VL4oKjd7f1i7xCjZji OzanON2BrJl1oS/EZQjHudbVaU20w46iAXcjGDhtCsMlIY1O5YNAfe3/DGSHM8/ROxV/ uKmz1sOLWBoFdG0H0hgAmuJK0hhLRMsmKyJ8BQkGsTQfTkJhlSCx5HbzYtUP9yWtxK3e FIp+76sMORL1CGpKf2aAcJikZGMOz3U9IGDO/p2B1jOtOYm8umHFy1GyCn98ZJoikzs3 v/Gw== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=o0OvLhUp; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id n7si5337249ybo.264.2020.07.01.07.02.19 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Wed, 01 Jul 2020 07:02:19 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=o0OvLhUp; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1]:43314 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jqdJb-00012z-8J for patch@linaro.org; Wed, 01 Jul 2020 10:02:19 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:58868) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jqdEX-0002Iw-50 for qemu-devel@nongnu.org; Wed, 01 Jul 2020 09:57:05 -0400 Received: from mail-wr1-x443.google.com ([2a00:1450:4864:20::443]:39895) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1jqdEU-0005qa-1S for qemu-devel@nongnu.org; Wed, 01 Jul 2020 09:57:04 -0400 Received: by mail-wr1-x443.google.com with SMTP id q5so23946291wru.6 for ; Wed, 01 Jul 2020 06:57:01 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=Jmf45TdSZl+xaFqF4i+rpuxLxpTS1OvMPwFk/ldTir0=; b=o0OvLhUp4coY2M9yujQyNmzbo1VHRdPx7zruEY4dq/A/yKB/YqV8wiVbhHt5sF3p4q 8muQoWFk50ZVMHV2/NJ+eMWNyLcRy/QXdzd6qcgIKDtF/ittytF3+q7ycL+eRm75LTZq PLR0/ERBhUqup05n4BUxHxgOO778VxtqOuvJO7LfTsROb4gaUF5BeeoqGMhCOVCeiYpN im0ZuQyuqe7/A72cmOaRSGbO//KdOWL/F1O9zvrsd6uV4BohNPkj46PA7yeVX9Xo9rnB aMs/Cwtja2Gg6S5f++pMFGLiJ4Ys+f6M86SKSKmx4mv4eIGef/fuABIM9wDNl66uZpAi i+Uw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=Jmf45TdSZl+xaFqF4i+rpuxLxpTS1OvMPwFk/ldTir0=; b=Kz/5ei+KYwsZuJ+gjRaddzpfHAUY2IiDPb+B5aUD/1qPjsoKZVPUyCD0EiS2sMaY9A fWhYm2QsZXgf6OVt/9zmh568v67GeCcpTdnF8ac1c0NBJouLLMxEb9OelfpDHbeoOt4x tdzHw1PX2v0tNpu9fkY8pBi16cOKMFh0uZ172dKkDaYntju3R5gkVTmUvskMV7GYydKE N6Dn2Y4g5MLOaOnjGtLkpb7ZWBqks061lS8dUODLWwlkr3xOzORI3suMm734wcrKAXEl LY5g1FH/y5UrWTnZeFLGj4t3OvrG+I+8tqPsM4oYJxTkCjXm21xWgSFf+ugNFBXUj95m qx4A== X-Gm-Message-State: AOAM532pyla1A5GxXpDDV3JOujZYEIIsfgqp5ZeWUUqZmepiR1BHz07s H56KDkwiY6t5Yf7YpMbeXkCJIA== X-Received: by 2002:adf:91e1:: with SMTP id 88mr20819587wri.89.1593611820538; Wed, 01 Jul 2020 06:57:00 -0700 (PDT) Received: from zen.linaroharston ([51.148.130.216]) by smtp.gmail.com with ESMTPSA id 22sm7749511wmb.11.2020.07.01.06.56.56 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 01 Jul 2020 06:57:00 -0700 (PDT) Received: from zen.lan (localhost [127.0.0.1]) by zen.linaroharston (Postfix) with ESMTP id 823AC1FF93; Wed, 1 Jul 2020 14:56:53 +0100 (BST) From: =?utf-8?q?Alex_Benn=C3=A9e?= To: qemu-devel@nongnu.org Subject: [PATCH v4 07/40] tests/vm: Added configuration file support Date: Wed, 1 Jul 2020 14:56:19 +0100 Message-Id: <20200701135652.1366-8-alex.bennee@linaro.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20200701135652.1366-1-alex.bennee@linaro.org> References: <20200701135652.1366-1-alex.bennee@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::443; envelope-from=alex.bennee@linaro.org; helo=mail-wr1-x443.google.com X-detected-operating-system: by eggs.gnu.org: No matching host in p0f cache. That's all we know. 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, URIBL_BLOCKED=0.001 autolearn=_AUTOLEARN X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: fam@euphon.net, berrange@redhat.com, Robert Foley , =?utf-8?q?Alex_Benn=C3=A9e?= , richard.henderson@linaro.org, f4bug@amsat.org, =?utf-8?q?Philippe_Mat?= =?utf-8?q?hieu-Daud=C3=A9?= , cota@braap.org, Peter Puhov , aurelien@aurel32.net Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: "Qemu-devel" From: Robert Foley Changes to tests/vm/basevm.py to allow accepting a configuration file as a parameter. Allows for specifying VM options such as cpu, machine, memory, and arbitrary qemu arguments for specifying options such as NUMA configuration. Also added an example conf_example_aarch64.yml and conf_example_x86.yml. Signed-off-by: Robert Foley Reviewed-by: Peter Puhov Reviewed-by: Alex Bennée Signed-off-by: Alex Bennée Message-Id: <20200601211421.1277-4-robert.foley@linaro.org> --- configure | 9 ++++++ tests/vm/Makefile.include | 6 ++++ tests/vm/basevm.py | 40 +++++++++++++++++++++++- tests/vm/conf_example_aarch64.yml | 51 +++++++++++++++++++++++++++++++ tests/vm/conf_example_x86.yml | 50 ++++++++++++++++++++++++++++++ 5 files changed, 155 insertions(+), 1 deletion(-) create mode 100644 tests/vm/conf_example_aarch64.yml create mode 100644 tests/vm/conf_example_x86.yml -- 2.20.1 diff --git a/configure b/configure index 65309a08dbc..96256be057a 100755 --- a/configure +++ b/configure @@ -960,6 +960,13 @@ do fi done +# Check for existence of python3 yaml, needed to +# import yaml config files into vm-build. +python_yaml="no" +if $(python3 -c "import yaml" 2> /dev/null); then + python_yaml="yes" +fi + : ${smbd=${SMBD-/usr/sbin/smbd}} # Default objcc to clang if available, otherwise use CC @@ -6843,6 +6850,7 @@ if test "$docs" != "no"; then echo "sphinx-build $sphinx_build" fi echo "genisoimage $genisoimage" +echo "python_yaml $python_yaml" echo "slirp support $slirp $(echo_version $slirp $slirp_version)" if test "$slirp" != "no" ; then echo "smbd $smbd" @@ -7928,6 +7936,7 @@ echo "PYTHON=$python" >> $config_host_mak echo "SPHINX_BUILD=$sphinx_build" >> $config_host_mak echo "SPHINX_WERROR=$sphinx_werror" >> $config_host_mak echo "GENISOIMAGE=$genisoimage" >> $config_host_mak +echo "PYTHON_YAML=$python_yaml" >> $config_host_mak echo "CC=$cc" >> $config_host_mak if $iasl -h > /dev/null 2>&1; then echo "IASL=$iasl" >> $config_host_mak diff --git a/tests/vm/Makefile.include b/tests/vm/Makefile.include index a253aba4579..f6c3892bb28 100644 --- a/tests/vm/Makefile.include +++ b/tests/vm/Makefile.include @@ -44,6 +44,12 @@ endif @echo " QEMU_LOCAL=1 - Use QEMU binary local to this build." @echo " QEMU=/path/to/qemu - Change path to QEMU binary" @echo " QEMU_IMG=/path/to/qemu-img - Change path to qemu-img tool" +ifeq ($(PYTHON_YAML),yes) + @echo " QEMU_CONFIG=/path/conf.yml - Change path to VM configuration .yml file." +else + @echo " (install python3-yaml to enable support for yaml file to configure a VM.)" +endif + @echo " See conf_example_*.yml for file format details." vm-build-all: $(addprefix vm-build-, $(IMAGES)) diff --git a/tests/vm/basevm.py b/tests/vm/basevm.py index cfe20c58f7e..fa56fbbb4b6 100644 --- a/tests/vm/basevm.py +++ b/tests/vm/basevm.py @@ -481,7 +481,6 @@ class BaseVM(object): cwd=cidir, stdin=self._devnull, stdout=self._stdout, stderr=self._stdout) - return os.path.join(cidir, "cloud-init.iso") def get_qemu_path(arch, build_path=None): @@ -497,6 +496,41 @@ def get_qemu_path(arch, build_path=None): qemu_path = "qemu-system-" + arch return qemu_path +def parse_config(config, args): + """ Parse yaml config and populate our config structure. + The yaml config allows the user to override the + defaults for VM parameters. In many cases these + defaults can be overridden without rebuilding the VM.""" + if args.config: + config_file = args.config + elif 'QEMU_CONFIG' in os.environ: + config_file = os.environ['QEMU_CONFIG'] + else: + return config + if not os.path.exists(config_file): + raise Exception("config file {} does not exist".format(config_file)) + # We gracefully handle importing the yaml module + # since it might not be installed. + # If we are here it means the user supplied a .yml file, + # so if the yaml module is not installed we will exit with error. + try: + import yaml + except ImportError: + print("The python3-yaml package is needed "\ + "to support config.yaml files") + # Instead of raising an exception we exit to avoid + # a raft of messy (expected) errors to stdout. + exit(1) + with open(config_file) as f: + yaml_dict = yaml.safe_load(f) + + if 'qemu-conf' in yaml_dict: + config.update(yaml_dict['qemu-conf']) + else: + raise Exception("config file {} is not valid"\ + " missing qemu-conf".format(config_file)) + return config + def parse_args(vmcls): def get_default_jobs(): @@ -536,6 +570,9 @@ def parse_args(vmcls): help="run tests with a snapshot") parser.add_option("--genisoimage", default="genisoimage", help="iso imaging tool") + parser.add_option("--config", "-c", default=None, + help="Provide config yaml for configuration. "\ + "See config_example.yaml for example.") parser.disable_interspersed_args() return parser.parse_args() @@ -547,6 +584,7 @@ def main(vmcls, config=None): if not argv and not args.build_qemu and not args.build_image: print("Nothing to do?") return 1 + config = parse_config(config, args) logging.basicConfig(level=(logging.DEBUG if args.debug else logging.WARN)) vm = vmcls(args, config=config) diff --git a/tests/vm/conf_example_aarch64.yml b/tests/vm/conf_example_aarch64.yml new file mode 100644 index 00000000000..9d44ae356f7 --- /dev/null +++ b/tests/vm/conf_example_aarch64.yml @@ -0,0 +1,51 @@ +# +# Example yaml for use by any of the scripts in tests/vm. +# Can be provided as an environment variable QEMU_CONFIG +# +qemu-conf: + + # If any of the below are not provided, we will just use the qemu defaults. + + # Login username and password(has to be sudo enabled) + guest_user: qemu + guest_pass: "qemupass" + + # Password for root user can be different from guest. + root_pass: "qemupass" + + # If one key is provided, both must be provided. + #ssh_key: /complete/path/of/your/keyfile/id_rsa + #ssh_pub_key: /complete/path/of/your/keyfile/id_rsa.pub + + cpu: max + machine: virt,gic-version=max + memory: 16G + + # The below is a example for how to configure NUMA topology with + # 4 NUMA nodes and 2 different NUMA distances. + qemu_args: "-smp cpus=16,sockets=2,cores=8 + -numa node,cpus=0-3,nodeid=0 -numa node,cpus=4-7,nodeid=1 + -numa node,cpus=8-11,nodeid=2 -numa node,cpus=12-15,nodeid=3 + -numa dist,src=0,dst=1,val=15 -numa dist,src=2,dst=3,val=15 + -numa dist,src=0,dst=2,val=20 -numa dist,src=0,dst=3,val=20 + -numa dist,src=1,dst=2,val=20 -numa dist,src=1,dst=3,val=20" + + # By default we do not set the DNS. + # You override the defaults by setting the below. + #dns: 1.234.567.89 + + # By default we will use a "block" device, but + # you can also boot from a "scsi" device. + # Just keep in mind your scripts might need to change + # As you will have /dev/sda instead of /dev/vda (for block device) + boot_dev_type: "block" + + # By default the ssh port is not fixed. + # A fixed ssh port makes it easier for automated tests. + #ssh_port: 5555 + + # To install a different set of packages, provide a command to issue + #install_cmds: "apt-get update ; apt-get build-dep -y qemu" + + # Or to skip the install entirely, just provide "" + #install_cmds: "" diff --git a/tests/vm/conf_example_x86.yml b/tests/vm/conf_example_x86.yml new file mode 100644 index 00000000000..78d3f5830fa --- /dev/null +++ b/tests/vm/conf_example_x86.yml @@ -0,0 +1,50 @@ +# +# Example yaml for use by any of the x86 based scripts in tests/vm. +# Can be provided as an environment variable QEMU_CONFIG +# +qemu-conf: + + # If any of the below are not provided, we will just use the qemu defaults. + + # Login username and password(has to be sudo enabled) + guest_user: "qemu" + guest_pass: "qemupass" + + # Password for root user can be different from guest. + root_pass: "qemupass" + + # Provide default ssh keys of current user. + # You need to edit the below for your user. + #ssh_key_file: /home//.ssh/id_rsa + #ssh_pub_key_file: /home//.ssh/id_rsa.pub + + cpu: max + machine: pc + memory: 8G + + # The below is a example for how to configure NUMA topology with + # 4 NUMA nodes and 2 different NUMA distances. + qemu_args: "-smp cpus=8,sockets=2,cores=4 + -object memory-backend-ram,size=4G,policy=bind,host-nodes=0,id=ram-node0 + -object memory-backend-ram,size=4G,policy=bind,host-nodes=0,id=ram-node1 + -object memory-backend-ram,size=4G,policy=bind,host-nodes=1,id=ram-node2 + -object memory-backend-ram,size=4G,policy=bind,host-nodes=1,id=ram-node3 + -numa node,cpus=0-1,nodeid=0 -numa node,cpus=2-3,nodeid=1 + -numa node,cpus=4-5,nodeid=2 -numa node,cpus=6-7,nodeid=3 + -numa dist,src=0,dst=1,val=15 -numa dist,src=2,dst=3,val=15 + -numa dist,src=0,dst=2,val=20 -numa dist,src=0,dst=3,val=20 + -numa dist,src=1,dst=2,val=20 -numa dist,src=1,dst=3,val=20" + + # By default we do not set the DNS. + # You override the defaults by setting the below. + #dns: "1.234.567.89" + + # By default we will use a "block" device, but + # you can also boot from a "scsi" device. + # Just keep in mind your scripts might need to change + # As you will have /dev/sda instead of /dev/vda (for block device) + boot_dev_type: "block" + + # By default the ssh port is not fixed. + # A fixed ssh port makes it easier for automated tests. + ssh_port: 5555 From patchwork Wed Jul 1 13:56:20 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Alex_Benn=C3=A9e?= X-Patchwork-Id: 192139 Delivered-To: patch@linaro.org Received: by 2002:a92:d244:0:0:0:0:0 with SMTP id v4csp519227ilg; Wed, 1 Jul 2020 06:59:58 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzzRpt9MbypiGaR+UfCyNTegtjX4+pdu0ynSTNBRN64obKkCMkwPYebEZWCgPszyb89UGLp X-Received: by 2002:a25:7bc1:: with SMTP id w184mr41293873ybc.240.1593611997988; Wed, 01 Jul 2020 06:59:57 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1593611997; cv=none; d=google.com; s=arc-20160816; b=LL+lNe3LFCMou7J+m4wUIwg/w8ervDrTKS5InhTmZprhSwQfSu+MMZ4TLlcVaEIETF G3xFdsWT5ItM9Csm4s+ENTnRpuOsfGC6zq6xN8Zfw8VoMMypFEHH4llpBtUWose4KIs8 Y/augoF5YXDX/2mAwvX6Fe5j+zt1fZfgp3/u+Ke5OGfl/CD9x6SSkcrHu1CN9aBgzYN3 l2FpshHqvKCfr9A+fHiOF7ddtoNznk7vGyqgtGaQ0w7sZiIOFHgpDTVDBXHH+h3OxBsh J01zLMkQ6PbOcIFoswpprAWa/UOVVvPzlTazV6PYRNxBf7WbpddBvY/exxjb8MfdTGuR Q2aQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:cc:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=yfaWvkBHiSQ15nCnLOaiCfwwNxNyBgCuiCJ/EYYdU+8=; b=0UUdGtRJP7MlIIVgm1MzxnWGQJIyNCPMomxPe6OGgTejyVQwvn/uwi3QYPQf7Y2R7A 4//0auS+y4AUuE2Fx1QG/ittdQwseBdaOA3R3b2N5/icJuUf19ROkf9OFqtMdiSlO8vO o9hr1ORGcq7aZzQvaJht/zOIj7bjCIgXJ8BvpercMS18pAJLVBlUPGMn+5aaGBMpbXzR DH8Km7XMHz0B9miWg0HRwN/pmySegaZAR02RRhGONZRI2rXpguija5+G+i/GK0/0p+Jb tfxdV5dNROaX2o5LGbcNTHR5DtxHI7BUvdy3UHnePazBN56aTK5wQ+U9NAVyubaGXaMa 6j+Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=if3EKZ6X; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id w6si5893983ybc.441.2020.07.01.06.59.57 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Wed, 01 Jul 2020 06:59:57 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=if3EKZ6X; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1]:35088 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jqdHJ-0005vE-Eb for patch@linaro.org; Wed, 01 Jul 2020 09:59:57 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:58880) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jqdEX-0002L8-VR for qemu-devel@nongnu.org; Wed, 01 Jul 2020 09:57:05 -0400 Received: from mail-wm1-x342.google.com ([2a00:1450:4864:20::342]:34374) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1jqdEU-0005qb-1L for qemu-devel@nongnu.org; Wed, 01 Jul 2020 09:57:05 -0400 Received: by mail-wm1-x342.google.com with SMTP id g10so6887899wmc.1 for ; Wed, 01 Jul 2020 06:57:01 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=yfaWvkBHiSQ15nCnLOaiCfwwNxNyBgCuiCJ/EYYdU+8=; b=if3EKZ6XTRQMd1n/pE0OW6em6avDjU0f3oZycgdG0PACzBrCszAFZRrdE6E/uGq02o 03E7U7L6Ut92vTxxDRWuktudkQGoA4vHf62J2SlV0TlEdCFWQP8C4+iLIdXmmla9dfIb 6fQGPKHFsOyUo77BHsTM9uEWeEVGH2iexLdXF6qQytjb++kFFTpM23nc62WHjnlW5tTm eZWril+SZ+DacAQnFoMm7kjASMf5bJCMsM3KrPklsjO74XOKuEp/sUY+fDK/QL856nwy jvxyD5/nKgkAZritV+PhnYKU141aBETI5EzMzu55V9KdCTruskmRyi2xbQ3u5GYZ0r+k kI/w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=yfaWvkBHiSQ15nCnLOaiCfwwNxNyBgCuiCJ/EYYdU+8=; b=s7t76IclMYvrtXvQFLVSUv5ZbYyZQCeCmfJLLlgcwxWGYRTXtFTjXcMzfCka5mH9gG 71avP5cTM5HP9PgbpkwE6tquJv9NRyRBTMvNR8l1hf8mWyuVCaYPjqTRuB+I0YBF8ZSC GOhBCcClhEr3fIUbBRd1fkiP6AChwzSScfnWmWn2fjFXzFxqMDU8uhDOgYxNyVXHk+Qu dybmxP3xT+ynp31UUKdNWtGCYOvjZhY6TR5QQYLtDdgOB5l2OWOIRV8m0yFGeT7UfQDT rB/uiQJjgUyFgjUnwSgaASZb2wYMheQ8UM726mXh/8IXwHx3PtCQCaYv5t2syUNLak71 M5Qw== X-Gm-Message-State: AOAM531ER/WbCkIB+NbYaG/bxS72Nb9mTJ2anTKUEjPAQeN4H5rB1jyh YmVRsd15gvzWGvv33Vr1UCVFlA== X-Received: by 2002:a1c:7204:: with SMTP id n4mr19385880wmc.9.1593611820542; Wed, 01 Jul 2020 06:57:00 -0700 (PDT) Received: from zen.linaroharston ([51.148.130.216]) by smtp.gmail.com with ESMTPSA id p14sm8237564wrj.14.2020.07.01.06.56.56 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 01 Jul 2020 06:57:00 -0700 (PDT) Received: from zen.lan (localhost [127.0.0.1]) by zen.linaroharston (Postfix) with ESMTP id 98A731FF96; Wed, 1 Jul 2020 14:56:53 +0100 (BST) From: =?utf-8?q?Alex_Benn=C3=A9e?= To: qemu-devel@nongnu.org Subject: [PATCH v4 08/40] tests/vm: Add common Ubuntu python module Date: Wed, 1 Jul 2020 14:56:20 +0100 Message-Id: <20200701135652.1366-9-alex.bennee@linaro.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20200701135652.1366-1-alex.bennee@linaro.org> References: <20200701135652.1366-1-alex.bennee@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::342; envelope-from=alex.bennee@linaro.org; helo=mail-wm1-x342.google.com X-detected-operating-system: by eggs.gnu.org: No matching host in p0f cache. That's all we know. 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, URIBL_BLOCKED=0.001 autolearn=_AUTOLEARN X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: fam@euphon.net, berrange@redhat.com, Robert Foley , =?utf-8?q?Philippe_Mathieu-Da?= =?utf-8?q?ud=C3=A9?= , richard.henderson@linaro.org, f4bug@amsat.org, =?utf-8?q?Alex_Benn?= =?utf-8?b?w6ll?= , cota@braap.org, aurelien@aurel32.net Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: "Qemu-devel" From: Robert Foley Add a common Ubuntu python module and make use of it with the ubuntu.i386 script. This is preparation for adding an Ubuntu script ubuntu.aarch64. Splitting out the common logic such as build_image() will reduce duplication. Signed-off-by: Robert Foley Tested-by: Philippe Mathieu-Daudé Signed-off-by: Alex Bennée Message-Id: <20200601211421.1277-5-robert.foley@linaro.org> --- tests/vm/ubuntu.i386 | 46 +++++++++------------------------ tests/vm/ubuntuvm.py | 60 ++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 72 insertions(+), 34 deletions(-) create mode 100644 tests/vm/ubuntuvm.py -- 2.20.1 diff --git a/tests/vm/ubuntu.i386 b/tests/vm/ubuntu.i386 index 24527cc78c7..5ce72610a6c 100755 --- a/tests/vm/ubuntu.i386 +++ b/tests/vm/ubuntu.i386 @@ -11,15 +11,22 @@ # the COPYING file in the top-level directory. # -import os import sys -import subprocess import basevm -import time +import ubuntuvm -class UbuntuX86VM(basevm.BaseVM): +DEFAULT_CONFIG = { + 'install_cmds' : "apt-get update,"\ + "apt-get build-dep -y qemu,"\ + "apt-get install -y libfdt-dev language-pack-en", +} + +class UbuntuX86VM(ubuntuvm.UbuntuVM): name = "ubuntu.i386" arch = "i386" + image_link="https://cloud-images.ubuntu.com/releases/bionic/"\ + "release-20191114/ubuntu-18.04-server-cloudimg-i386.img" + image_sha256="28969840626d1ea80bb249c08eef1a4533e8904aa51a327b40f37ac4b4ff04ef" BUILD_SCRIPT = """ set -e; cd $(mktemp -d); @@ -29,34 +36,5 @@ class UbuntuX86VM(basevm.BaseVM): make --output-sync {target} -j{jobs} {verbose}; """ - def build_image(self, img): - cimg = self._download_with_cache( - "https://cloud-images.ubuntu.com/releases/bionic/release-20191114/ubuntu-18.04-server-cloudimg-i386.img", - sha256sum="28969840626d1ea80bb249c08eef1a4533e8904aa51a327b40f37ac4b4ff04ef") - img_tmp = img + ".tmp" - subprocess.check_call(["cp", "-f", cimg, img_tmp]) - self.exec_qemu_img("resize", img_tmp, "50G") - self.boot(img_tmp, extra_args = [ - "-device", "VGA", - "-cdrom", self.gen_cloud_init_iso() - ]) - self.wait_ssh() - self.ssh_root_check("touch /etc/cloud/cloud-init.disabled") - self.ssh_root_check("apt-get update") - self.ssh_root_check("apt-get install -y cloud-initramfs-growroot") - # Don't check the status in case the guest hang up too quickly - self.ssh_root("sync && reboot") - time.sleep(5) - self.wait_ssh() - # The previous update sometimes doesn't survive a reboot, so do it again - self.ssh_root_check("sed -ie s/^#\ deb-src/deb-src/g /etc/apt/sources.list") - self.ssh_root_check("apt-get update") - self.ssh_root_check("apt-get build-dep -y qemu") - self.ssh_root_check("apt-get install -y libfdt-dev language-pack-en") - self.ssh_root("poweroff") - self.wait() - os.rename(img_tmp, img) - return 0 - if __name__ == "__main__": - sys.exit(basevm.main(UbuntuX86VM)) + sys.exit(basevm.main(UbuntuX86VM, DEFAULT_CONFIG)) diff --git a/tests/vm/ubuntuvm.py b/tests/vm/ubuntuvm.py new file mode 100644 index 00000000000..6689ad87aa8 --- /dev/null +++ b/tests/vm/ubuntuvm.py @@ -0,0 +1,60 @@ +#!/usr/bin/env python3 +# +# Ubuntu VM testing library +# +# Copyright 2017 Red Hat Inc. +# Copyright 2020 Linaro +# +# Authors: +# Robert Foley +# Originally based on ubuntu.i386 Fam Zheng +# +# This code is licensed under the GPL version 2 or later. See +# the COPYING file in the top-level directory. + +import os +import subprocess +import basevm + +class UbuntuVM(basevm.BaseVM): + + def __init__(self, args, config=None): + self.login_prompt = "ubuntu-{}-guest login:".format(self.arch) + basevm.BaseVM.__init__(self, args, config) + + def build_image(self, img): + """Build an Ubuntu VM image. The child class will + define the install_cmds to init the VM.""" + os_img = self._download_with_cache(self.image_link, + sha256sum=self.image_sha256) + img_tmp = img + ".tmp" + subprocess.check_call(["cp", "-f", os_img, img_tmp]) + self.exec_qemu_img("resize", img_tmp, "+50G") + ci_img = self.gen_cloud_init_iso() + + self.boot(img_tmp, extra_args = [ "-device", "VGA", "-cdrom", ci_img, ]) + + # First command we issue is fix for slow ssh login. + self.wait_ssh(wait_root=True, + cmd="chmod -x /etc/update-motd.d/*") + # Wait for cloud init to finish + self.wait_ssh(wait_root=True, + cmd="ls /var/lib/cloud/instance/boot-finished") + self.ssh_root("touch /etc/cloud/cloud-init.disabled") + # Disable auto upgrades. + # We want to keep the VM system state stable. + self.ssh_root('sed -ie \'s/"1"/"0"/g\' '\ + '/etc/apt/apt.conf.d/20auto-upgrades') + self.ssh_root("sed -ie s/^#\ deb-src/deb-src/g /etc/apt/sources.list") + + # If the user chooses not to do the install phase, + # then we will jump right to the graceful shutdown + if self._config['install_cmds'] != "": + # Issue the install commands. + # This can be overriden by the user in the config .yml. + install_cmds = self._config['install_cmds'].split(',') + for cmd in install_cmds: + self.ssh_root(cmd) + self.graceful_shutdown() + os.rename(img_tmp, img) + return 0 From patchwork Wed Jul 1 13:56:21 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Alex_Benn=C3=A9e?= X-Patchwork-Id: 192143 Delivered-To: patch@linaro.org Received: by 2002:a92:d244:0:0:0:0:0 with SMTP id v4csp522246ilg; Wed, 1 Jul 2020 07:02:44 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyk5dzY5ypO4BiABNFMW/h+QDRNIl1hulM3iZZ6vqJ4thwoLKSe21F+NxLcdW6nVUgX04Hj X-Received: by 2002:a05:620a:579:: with SMTP id p25mr2469775qkp.176.1593612164518; Wed, 01 Jul 2020 07:02:44 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1593612164; cv=none; d=google.com; s=arc-20160816; b=dYq6IJ3/g1XFQGVU5wq40MIk52b3Y6UbQ/pgqDFRUlMhI7tnUAldDCEC2UJLjgfQwO 9AxW87jxOsGzLLN6lfmiP98sZiMUnbmDD4XuhuyMeTNnka3MkgfOiiMcxOGAi2uYCqqY 8v8z1U9tc5VWf7KpYcm3F+T5WAnMu9viLO8zE3Zrqk/JoAxdLoCI0CfRnGzZShJMnp/3 NiNvwE/6SCAbQcfz0baG0WiMv4MQQ2W5vQ69vL1DFxGZxSB4W8jKevku9gYV/dFDqRRL NPftKN8mfAoYvi00v+EeI00Xdh0Z844L8IiTjPetL4/alER0HkJnXm16aYokEC3reTCq 9rvg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:cc:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=lPp8XkbnsM3c17W7WUUEalp68Xx8V1JQ2Yf70AfovqA=; b=C2n+BeoZz7YiboFk+FLPlUp/DVImgBzcv38+2PuZ7G1sJ8e1a/A2iBNry04/VaY2pw J1xwMDaOaIv+SsP5dhFnvRdbWRbRbn/P63yxq4LSEEbacfhZSVJ5jcLDnQ97bXxt/Pkw n2UkS4fgAPZOorpNHbWrt1W7bgX8WtiYli04GuMReFTvDYzsVqlg+3yBQA8XNVznrYll UTmGFpIkzU8PF1N/ICD5edHemlB804GE3fl8RAlwYWy3PySupXJezYDeF6tkqp/xv4ML sWoFNlKTIypibhcNuTlpYdfEllxBfMF4KF7x9OX+PBiZQ0VJ++UcV94+MZa0wqTd4sw6 dRQQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=hs6B33Zu; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id 195si5701165ybe.280.2020.07.01.07.02.44 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Wed, 01 Jul 2020 07:02:44 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=hs6B33Zu; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1]:47036 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jqdJz-0002cu-Iz for patch@linaro.org; Wed, 01 Jul 2020 10:02:43 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:58922) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jqdEa-0002RS-Ii for qemu-devel@nongnu.org; Wed, 01 Jul 2020 09:57:08 -0400 Received: from mail-wr1-x431.google.com ([2a00:1450:4864:20::431]:35786) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1jqdEX-0005rS-JA for qemu-devel@nongnu.org; Wed, 01 Jul 2020 09:57:08 -0400 Received: by mail-wr1-x431.google.com with SMTP id z2so1691298wrp.2 for ; Wed, 01 Jul 2020 06:57:05 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=lPp8XkbnsM3c17W7WUUEalp68Xx8V1JQ2Yf70AfovqA=; b=hs6B33ZuIJP/corK1jB5ucTI9w3eJccTMvFHqd+Wbq40qTGa7ed8yo+pkq7kV2KPuZ dAEGGemtJ43yhk9IDG9vqLODV5/afVYJUlmy/RS+US028CU9Rt8pN8jr4g0XW314ejqh 56T1dy030+ENVNHcUYCT/xEsPH5KubVKH5bubg3J7PY/eDaow2Aku/BNEvAbdno1bJzM FL2D8Lgj9HAPnJezUG6EVXUl7f3hpgEwIsUhroz1WCfpUsOiizn2VG3bl9PiHxCsGovT h0aKfZ6IJWABO3FVCTlTMH0Qw+PdA+t9/XXFJILbCw+opBhEDHInW3Z01+yXJpsiNGJx 3Bhg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=lPp8XkbnsM3c17W7WUUEalp68Xx8V1JQ2Yf70AfovqA=; b=RmdGBPU9D7BfZs/R2LGAOMQrxFELXIeKwGKxdhmMx21Et8ylDwctqxZUuRW6CY0Klg fDNmugj5OcIkDpqJIhFToyUqClvge1oBSd6W4ju7O6I9WNvMN+A+bgT+JjiuTans0MDF 2J9VUT+sWoPkUqjtft25l8KcFLSxefABOAQAUA6PDkKXmtsAeI+YVQEZkq9ZVlVoo033 aVyc9MXpp+mPVvKMjWDnvkWg8xHGQv3xVxE6kPc/1FB0DexZlnaPNXzWzbYGDc0MBVFU gElW9W1JKlajZbhVqSxiEmNOQMWlD7ZuX1Sxau95L39YAVLlFVlYZsTU51FROBUAh2K4 ls4A== X-Gm-Message-State: AOAM530igDKYAKfAgmVxC3bNYzDw9psSas3h7Up7ex+aAhLoBXlHs+Ou pO8F1v3IGKLO3NuoKd+1kliBxw== X-Received: by 2002:a5d:484b:: with SMTP id n11mr25751128wrs.320.1593611823980; Wed, 01 Jul 2020 06:57:03 -0700 (PDT) Received: from zen.linaroharston ([51.148.130.216]) by smtp.gmail.com with ESMTPSA id 207sm8165108wme.13.2020.07.01.06.56.57 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 01 Jul 2020 06:57:00 -0700 (PDT) Received: from zen.lan (localhost [127.0.0.1]) by zen.linaroharston (Postfix) with ESMTP id B60331FF98; Wed, 1 Jul 2020 14:56:53 +0100 (BST) From: =?utf-8?q?Alex_Benn=C3=A9e?= To: qemu-devel@nongnu.org Subject: [PATCH v4 09/40] tests/vm: Added a new script for ubuntu.aarch64. Date: Wed, 1 Jul 2020 14:56:21 +0100 Message-Id: <20200701135652.1366-10-alex.bennee@linaro.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20200701135652.1366-1-alex.bennee@linaro.org> References: <20200701135652.1366-1-alex.bennee@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::431; envelope-from=alex.bennee@linaro.org; helo=mail-wr1-x431.google.com X-detected-operating-system: by eggs.gnu.org: No matching host in p0f cache. That's all we know. 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, URIBL_BLOCKED=0.001 autolearn=_AUTOLEARN X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: fam@euphon.net, berrange@redhat.com, Robert Foley , =?utf-8?q?Alex_Benn=C3=A9e?= , richard.henderson@linaro.org, f4bug@amsat.org, =?utf-8?q?Philippe_Mat?= =?utf-8?q?hieu-Daud=C3=A9?= , cota@braap.org, Peter Puhov , aurelien@aurel32.net Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: "Qemu-devel" From: Robert Foley ubuntu.aarch64 provides a script to create an Ubuntu 18.04 VM. Another new file is also added aarch64vm.py, which is a module with common methods used by aarch64 VMs, such as how to create the flash images. Signed-off-by: Robert Foley Reviewed-by: Peter Puhov Signed-off-by: Alex Bennée Message-Id: <20200601211421.1277-6-robert.foley@linaro.org> --- configure | 20 +++++++ tests/vm/Makefile.include | 11 ++++ tests/vm/aarch64vm.py | 106 ++++++++++++++++++++++++++++++++++++++ tests/vm/basevm.py | 12 +++++ tests/vm/ubuntu.aarch64 | 68 ++++++++++++++++++++++++ 5 files changed, 217 insertions(+) create mode 100644 tests/vm/aarch64vm.py create mode 100755 tests/vm/ubuntu.aarch64 -- 2.20.1 diff --git a/configure b/configure index 96256be057a..1fb4d5b61e4 100755 --- a/configure +++ b/configure @@ -418,6 +418,7 @@ prefix="/usr/local" mandir="\${prefix}/share/man" datadir="\${prefix}/share" firmwarepath="\${prefix}/share/qemu-firmware" +efi_aarch64="" qemu_docdir="\${prefix}/share/doc/qemu" bindir="\${prefix}/bin" libdir="\${prefix}/lib" @@ -1109,6 +1110,8 @@ for opt do ;; --firmwarepath=*) firmwarepath="$optarg" ;; + --efi-aarch64=*) efi_aarch64="$optarg" + ;; --host=*|--build=*|\ --disable-dependency-tracking|\ --sbindir=*|--sharedstatedir=*|\ @@ -1787,6 +1790,7 @@ Advanced options (experts only): --sysconfdir=PATH install config in PATH$confsuffix --localstatedir=PATH install local state in PATH (set at runtime on win32) --firmwarepath=PATH search PATH for firmware files + --efi-aarch64=PATH PATH of efi file to use for aarch64 VMs. --with-confsuffix=SUFFIX suffix for QEMU data inside datadir/libdir/sysconfdir [$confsuffix] --with-pkgversion=VERS use specified string as sub-version of the package --enable-debug enable common debug build options @@ -3606,6 +3610,20 @@ EOF fi fi +############################################ +# efi-aarch64 probe +# Check for efi files needed by aarch64 VMs. +# By default we will use the efi included with QEMU. +# Allow user to override the path for efi also. +if ! test -f "$efi_aarch64"; then + if test -f $source_path/pc-bios/edk2-aarch64-code.fd.bz2; then + # valid after build + efi_aarch64=$PWD/pc-bios/edk2-aarch64-code.fd + else + efi_aarch64="" + fi +fi + ########################################## # libcap-ng library probe if test "$cap_ng" != "no" ; then @@ -6850,6 +6868,7 @@ if test "$docs" != "no"; then echo "sphinx-build $sphinx_build" fi echo "genisoimage $genisoimage" +echo "efi_aarch64 $efi_aarch64" echo "python_yaml $python_yaml" echo "slirp support $slirp $(echo_version $slirp $slirp_version)" if test "$slirp" != "no" ; then @@ -7936,6 +7955,7 @@ echo "PYTHON=$python" >> $config_host_mak echo "SPHINX_BUILD=$sphinx_build" >> $config_host_mak echo "SPHINX_WERROR=$sphinx_werror" >> $config_host_mak echo "GENISOIMAGE=$genisoimage" >> $config_host_mak +echo "EFI_AARCH64=$efi_aarch64" >> $config_host_mak echo "PYTHON_YAML=$python_yaml" >> $config_host_mak echo "CC=$cc" >> $config_host_mak if $iasl -h > /dev/null 2>&1; then diff --git a/tests/vm/Makefile.include b/tests/vm/Makefile.include index f6c3892bb28..4fa292765d5 100644 --- a/tests/vm/Makefile.include +++ b/tests/vm/Makefile.include @@ -5,6 +5,9 @@ IMAGES := freebsd netbsd openbsd centos fedora ifneq ($(GENISOIMAGE),) IMAGES += ubuntu.i386 centos +ifneq ($(EFI_AARCH64),) +IMAGES += ubuntu.aarch64 +endif endif IMAGES_DIR := $(HOME)/.cache/qemu-vm/images @@ -23,6 +26,11 @@ vm-help vm-test: ifneq ($(GENISOIMAGE),) @echo " vm-build-centos - Build QEMU in CentOS VM, with Docker" @echo " vm-build-ubuntu.i386 - Build QEMU in ubuntu i386 VM" +ifneq ($(EFI_AARCH64),) + @echo " vm-build-ubuntu.aarch64 - Build QEMU in ubuntu aarch64 VM" +else + @echo " (to build centos/ubuntu aarch64 images use configure --efi-aarch64)" +endif else @echo " (install genisoimage to build centos/ubuntu images)" endif @@ -65,6 +73,7 @@ $(IMAGES_DIR)/%.img: $(SRC_PATH)/tests/vm/% \ $(if $(V)$(DEBUG), --debug) \ $(if $(GENISOIMAGE),--genisoimage $(GENISOIMAGE)) \ $(if $(QEMU_LOCAL),--build-path $(BUILD_DIR)) \ + $(if $(EFI_AARCH64),--efi-aarch64 $(EFI_AARCH64)) \ --image "$@" \ --force \ --build-image $@, \ @@ -80,6 +89,7 @@ vm-build-%: $(IMAGES_DIR)/%.img $(if $(J),--jobs $(J)) \ $(if $(V),--verbose) \ $(if $(QEMU_LOCAL),--build-path $(BUILD_DIR)) \ + $(if $(EFI_AARCH64),--efi-aarch64 $(EFI_AARCH64)) \ --image "$<" \ $(if $(BUILD_TARGET),--build-target $(BUILD_TARGET)) \ --snapshot \ @@ -102,6 +112,7 @@ vm-boot-ssh-%: $(IMAGES_DIR)/%.img $(if $(J),--jobs $(J)) \ $(if $(V)$(DEBUG), --debug) \ $(if $(QEMU_LOCAL),--build-path $(BUILD_DIR)) \ + $(if $(EFI_AARCH64),--efi-aarch64 $(EFI_AARCH64)) \ --image "$<" \ --interactive \ false, \ diff --git a/tests/vm/aarch64vm.py b/tests/vm/aarch64vm.py new file mode 100644 index 00000000000..bb04cb19c91 --- /dev/null +++ b/tests/vm/aarch64vm.py @@ -0,0 +1,106 @@ +#!/usr/bin/env python3 +# +# VM testing aarch64 library +# +# Copyright 2020 Linaro +# +# Authors: +# Robert Foley +# +# This code is licensed under the GPL version 2 or later. See +# the COPYING file in the top-level directory. +# +import os +import sys +import subprocess +import basevm +from qemu.accel import kvm_available + +# This is the config needed for current version of QEMU. +# This works for both kvm and tcg. +CURRENT_CONFIG = { + 'cpu' : "max", + 'machine' : "virt,gic-version=max", +} + +# The minimum minor version of QEMU we will support with aarch64 VMs is 3. +# QEMU versions less than 3 have various issues running these VMs. +QEMU_AARCH64_MIN_VERSION = 3 + +# The DEFAULT_CONFIG will default to a version of +# parameters that works for backwards compatibility. +DEFAULT_CONFIG = {'kvm' : {'cpu' : "host", + 'machine' : "virt,gic-version=host"}, + 'tcg' : {'cpu' : "cortex-a57", + 'machine' : "virt"}, +} + +def get_config_defaults(vmcls, default_config): + """Fetch the configuration defaults for this VM, + taking into consideration the defaults for + aarch64 first, followed by the defaults for this VM.""" + config = default_config + config.update(aarch_get_config_defaults(vmcls)) + return config + +def aarch_get_config_defaults(vmcls): + """Set the defaults for current version of QEMU.""" + config = CURRENT_CONFIG + args, argv = basevm.parse_args(vmcls) + qemu_path = basevm.get_qemu_path(vmcls.arch, args.build_path) + qemu_version = basevm.get_qemu_version(qemu_path) + if qemu_version < QEMU_AARCH64_MIN_VERSION: + error = "\nThis major version of QEMU {} is to old for aarch64 VMs.\n"\ + "The major version must be at least {}.\n"\ + "To continue with the current build of QEMU, "\ + "please restart with QEMU_LOCAL=1 .\n" + print(error.format(qemu_version, QEMU_AARCH64_MIN_VERSION)) + exit(1) + if qemu_version == QEMU_AARCH64_MIN_VERSION: + # We have an older version of QEMU, + # set the config values for backwards compatibility. + if kvm_available('aarch64'): + config.update(DEFAULT_CONFIG['kvm']) + else: + config.update(DEFAULT_CONFIG['tcg']) + return config + +def create_flash_images(flash_dir="./", efi_img=""): + """Creates the appropriate pflash files + for an aarch64 VM.""" + flash0_path = get_flash_path(flash_dir, "flash0") + flash1_path = get_flash_path(flash_dir, "flash1") + fd_null = open(os.devnull, 'w') + subprocess.check_call(["dd", "if=/dev/zero", "of={}".format(flash0_path), + "bs=1M", "count=64"], + stdout=fd_null, stderr=subprocess.STDOUT) + # A reliable way to get the QEMU EFI image is via an installed package or + # via the bios included with qemu. + if not os.path.exists(efi_img): + sys.stderr.write("*** efi argument is invalid ({})\n".format(efi_img)) + sys.stderr.write("*** please check --efi-aarch64 argument or "\ + "install qemu-efi-aarch64 package\n") + exit(3) + subprocess.check_call(["dd", "if={}".format(efi_img), + "of={}".format(flash0_path), + "conv=notrunc"], + stdout=fd_null, stderr=subprocess.STDOUT) + subprocess.check_call(["dd", "if=/dev/zero", + "of={}".format(flash1_path), + "bs=1M", "count=64"], + stdout=fd_null, stderr=subprocess.STDOUT) + fd_null.close() + +def get_pflash_args(flash_dir="./"): + """Returns a string that can be used to + boot qemu using the appropriate pflash files + for aarch64.""" + flash0_path = get_flash_path(flash_dir, "flash0") + flash1_path = get_flash_path(flash_dir, "flash1") + pflash_args_str = "-drive file={},format=raw,if=pflash "\ + "-drive file={},format=raw,if=pflash" + pflash_args = pflash_args_str.format(flash0_path, flash1_path) + return pflash_args.split(" ") + +def get_flash_path(flash_dir, name): + return os.path.join(flash_dir, "{}.img".format(name)) diff --git a/tests/vm/basevm.py b/tests/vm/basevm.py index fa56fbbb4b6..5fd66f6b26a 100644 --- a/tests/vm/basevm.py +++ b/tests/vm/basevm.py @@ -92,6 +92,7 @@ class BaseVM(object): self._guest = None self._genisoimage = args.genisoimage self._build_path = args.build_path + self._efi_aarch64 = args.efi_aarch64 # Allow input config to override defaults. self._config = DEFAULT_CONFIG.copy() if config != None: @@ -496,6 +497,14 @@ def get_qemu_path(arch, build_path=None): qemu_path = "qemu-system-" + arch return qemu_path +def get_qemu_version(qemu_path): + """Get the version number from the current QEMU, + and return the major number.""" + output = subprocess.check_output([qemu_path, '--version']) + version_line = output.decode("utf-8") + version_num = re.split(' |\(', version_line)[3].split('.')[0] + return int(version_num) + def parse_config(config, args): """ Parse yaml config and populate our config structure. The yaml config allows the user to override the @@ -573,6 +582,9 @@ def parse_args(vmcls): parser.add_option("--config", "-c", default=None, help="Provide config yaml for configuration. "\ "See config_example.yaml for example.") + parser.add_option("--efi-aarch64", + default="/usr/share/qemu-efi-aarch64/QEMU_EFI.fd", + help="Path to efi image for aarch64 VMs.") parser.disable_interspersed_args() return parser.parse_args() diff --git a/tests/vm/ubuntu.aarch64 b/tests/vm/ubuntu.aarch64 new file mode 100755 index 00000000000..21d454c27f1 --- /dev/null +++ b/tests/vm/ubuntu.aarch64 @@ -0,0 +1,68 @@ +#!/usr/bin/env python3 +# +# Ubuntu aarch64 image +# +# Copyright 2020 Linaro +# +# Authors: +# Robert Foley +# Originally based on ubuntu.i386 Fam Zheng +# +# This code is licensed under the GPL version 2 or later. See +# the COPYING file in the top-level directory. +# + +import sys +import basevm +import aarch64vm +import ubuntuvm + +DEFAULT_CONFIG = { + 'cpu' : "cortex-a57", + 'machine' : "virt,gic-version=3", + 'install_cmds' : "apt-get update,"\ + "apt-get build-dep -y --arch-only qemu,"\ + "apt-get install -y libfdt-dev pkg-config language-pack-en", + # We increase beyond the default time since during boot + # it can take some time (many seconds) to log into the VM + # especially using softmmu. + 'ssh_timeout' : 60, +} + +class UbuntuAarch64VM(ubuntuvm.UbuntuVM): + name = "ubuntu.aarch64" + arch = "aarch64" + image_name = "ubuntu-18.04-server-cloudimg-arm64.img" + image_link = "https://cloud-images.ubuntu.com/releases/18.04/release/" + image_name + image_sha256="0fdcba761965735a8a903d8b88df8e47f156f48715c00508e4315c506d7d3cb1" + BUILD_SCRIPT = """ + set -e; + cd $(mktemp -d); + sudo chmod a+r /dev/vdb; + tar --checkpoint=.10 -xf /dev/vdb; + ./configure {configure_opts}; + make --output-sync {target} -j{jobs} {verbose}; + """ + def boot(self, img, extra_args=None): + aarch64vm.create_flash_images(self._tmpdir, self._efi_aarch64) + default_args = aarch64vm.get_pflash_args(self._tmpdir) + if extra_args: + extra_args.extend(default_args) + else: + extra_args = default_args + # We always add these performance tweaks + # because without them, we boot so slowly that we + # can time out finding the boot efi device. + if '-smp' not in extra_args and \ + '-smp' not in self._config['extra_args'] and \ + '-smp' not in self._args: + # Only add if not already there to give caller option to change it. + extra_args.extend(["-smp", "8"]) + + # We have overridden boot() since aarch64 has additional parameters. + # Call down to the base class method. + super(UbuntuAarch64VM, self).boot(img, extra_args=extra_args) + +if __name__ == "__main__": + defaults = aarch64vm.get_config_defaults(UbuntuAarch64VM, DEFAULT_CONFIG) + sys.exit(basevm.main(UbuntuAarch64VM, defaults)) From patchwork Wed Jul 1 13:56:22 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Alex_Benn=C3=A9e?= X-Patchwork-Id: 192141 Delivered-To: patch@linaro.org Received: by 2002:a92:d244:0:0:0:0:0 with SMTP id v4csp521183ilg; Wed, 1 Jul 2020 07:01:48 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwLodMXbPLSbvI6jJymaD6XdhXk64HU0OPncozyMDnt5bt0pbmbryy4ZacQmwyEVCZDytvs X-Received: by 2002:a05:6214:328:: with SMTP id j8mr10899915qvu.75.1593612107825; Wed, 01 Jul 2020 07:01:47 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1593612107; cv=none; d=google.com; s=arc-20160816; b=cbxDN9XaEaspVeOeAxh3tSxOVA2IqEqnu1msepbxW8X86CwF1FItm5g+IinNRIhX/q 6dlgvvQGoNPnu4xhZh+1+/Lm9F/LHyv9Be8xDWkTqKizV/dXbzYlJWt0NbZEp6CdsmYI T7O21J9hX9mYCOjCzQCTkAS/vv7XtD7RRa0oSxT2CPZLiU/2LWfSq+VwiWpzB0HfLdfi RrQd+GnIrNZwxO5Zqn4rn2WJ1WUp9WxaOwvV31q0vUBjohdquEVI1y1KOLWDxyaUqXZ4 +vHQ6TOHblWesjcfyYsDaf3ldaCjO1fxa2ocpRKge2C/1ZLH/ichhMf9D7MvD3zsOe2x S7fg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:cc:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=kdMIZtPe+aZda1/mXQW7aQb8KseTM0tT+oUaOxEz8I4=; b=L14/6fHUIdDGGPdT5OTAunXqweoAfx02O5PHDzNT1XdYoYDZ2d44WemXxz5CPnyznZ A1rmerAOevPZh8TBDFSraLArPVpaH4TV0eA40ujjv+o30GvwVck1l87r/zIx82o2oCos GuD+hgbVcEWefs+k51sfwbm5qzMthLKCBLJqYIXwxXVOqqReGPbn9w5NhkKTsEPyqGPt bLaj2+cn1Ckn83gJiGIpEZJF39jLE6Q6aYLKI2u7fWJ4R+xohYyBEVsGsQSltKX9eOUh VKXAnz+YZ3TCo7xBOzepjdg/2Lp8D0hgFFSV9Fh+mrrzOB517eMRzua7sUjzBgDLaUW1 yq4g== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=FUi1Ug+K; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id w3si4279844qvl.18.2020.07.01.07.01.47 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Wed, 01 Jul 2020 07:01:47 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=FUi1Ug+K; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1]:43588 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jqdJ5-00019n-28 for patch@linaro.org; Wed, 01 Jul 2020 10:01:47 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:58894) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jqdEY-0002NV-UA for qemu-devel@nongnu.org; Wed, 01 Jul 2020 09:57:06 -0400 Received: from mail-wr1-x442.google.com ([2a00:1450:4864:20::442]:35406) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1jqdEU-0005qj-2Z for qemu-devel@nongnu.org; Wed, 01 Jul 2020 09:57:06 -0400 Received: by mail-wr1-x442.google.com with SMTP id z2so1691002wrp.2 for ; Wed, 01 Jul 2020 06:57:01 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=kdMIZtPe+aZda1/mXQW7aQb8KseTM0tT+oUaOxEz8I4=; b=FUi1Ug+K06dvncuG77Qt7vxbcICGi5I+96sl4/hStG1FXbAG7SZQuuw5bMGbjeErhi lT04KV0E+95hhsgHwEAqw1O+zhxG5SLaaPL/Q5bMIrJB2Msft6fTpe1+CrVtboUhjynS gJrs+JSANAKdk+QzHbMpsiwMb3XGUqWTyVzE1Vvi/DZVP+UVLxjTqTykyFL7/iu3uLEk esn52Tmo5/hyBzmRjAqV7/cqRWWgeKS2BUA8n2rTSSFn+oyrJtHb9PuZ3ywwiD6vJCbb 1bGrUT/w8CoZ6h1O9oYyzItl6kRdBqx497WJKIXRpUDDFopLzyfphH4idRqP4FdqBort a9bA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=kdMIZtPe+aZda1/mXQW7aQb8KseTM0tT+oUaOxEz8I4=; b=Ym+hKxRV2P9AcUkFwjzy9My1lIBeHLo4f1w6qwt4A6lN68Kp7Vuai15RHf0RsmsmxH Z3AcbcFjdKyRpTgt4HGTIhx/zSdyr7xJDsspyYKaJGVQ7MYuL3+526yWCWFy+v+ws88w bdAte4G7eafvbnBS7bRQwTe6q/OrnshPeS9sJ404lpwts+iBx7CFm+j4emDr6KA1edVf 0OjY7n+MqPBvuQCMTfSBGr9g1mWpMdygzXaVh8+B9wAONOoFydMi7zwp8QJYucp9lFOa wU25PgyXCb0rZpCVyeS13W59la77c5K5iMXY37xBSfXiIDS5FMPkwdyJ5ldsTDsKaNyd mfzg== X-Gm-Message-State: AOAM532pUyZ+b3qZbssain1aWyahrpIkr6cSGjsjMcEIPPUWo2YstljW KpYkzthn2949uQwmTENMLLh6rA== X-Received: by 2002:a05:6000:1008:: with SMTP id a8mr27719999wrx.416.1593611820666; Wed, 01 Jul 2020 06:57:00 -0700 (PDT) Received: from zen.linaroharston ([51.148.130.216]) by smtp.gmail.com with ESMTPSA id g13sm7916366wro.84.2020.07.01.06.56.57 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 01 Jul 2020 06:57:00 -0700 (PDT) Received: from zen.lan (localhost [127.0.0.1]) by zen.linaroharston (Postfix) with ESMTP id D0AB81FF99; Wed, 1 Jul 2020 14:56:53 +0100 (BST) From: =?utf-8?q?Alex_Benn=C3=A9e?= To: qemu-devel@nongnu.org Subject: [PATCH v4 10/40] tests/vm: Added a new script for centos.aarch64. Date: Wed, 1 Jul 2020 14:56:22 +0100 Message-Id: <20200701135652.1366-11-alex.bennee@linaro.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20200701135652.1366-1-alex.bennee@linaro.org> References: <20200701135652.1366-1-alex.bennee@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::442; envelope-from=alex.bennee@linaro.org; helo=mail-wr1-x442.google.com X-detected-operating-system: by eggs.gnu.org: No matching host in p0f cache. That's all we know. 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, URIBL_BLOCKED=0.001 autolearn=_AUTOLEARN X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: fam@euphon.net, berrange@redhat.com, Robert Foley , =?utf-8?q?Alex_Benn=C3=A9e?= , richard.henderson@linaro.org, f4bug@amsat.org, =?utf-8?q?Philippe_Mat?= =?utf-8?q?hieu-Daud=C3=A9?= , cota@braap.org, Peter Puhov , aurelien@aurel32.net Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: "Qemu-devel" From: Robert Foley centos.aarch64 creates a CentOS 8 image. Also added a new kickstart script used to build the centos.aarch64 image. Signed-off-by: Robert Foley Reviewed-by: Peter Puhov Reviewed-by: Alex Bennée Signed-off-by: Alex Bennée Message-Id: <20200601211421.1277-7-robert.foley@linaro.org> --- tests/vm/Makefile.include | 3 +- tests/vm/centos-8-aarch64.ks | 51 ++++++++ tests/vm/centos.aarch64 | 227 +++++++++++++++++++++++++++++++++++ 3 files changed, 280 insertions(+), 1 deletion(-) create mode 100644 tests/vm/centos-8-aarch64.ks create mode 100755 tests/vm/centos.aarch64 -- 2.20.1 diff --git a/tests/vm/Makefile.include b/tests/vm/Makefile.include index 4fa292765d5..39f918a430a 100644 --- a/tests/vm/Makefile.include +++ b/tests/vm/Makefile.include @@ -6,7 +6,7 @@ IMAGES := freebsd netbsd openbsd centos fedora ifneq ($(GENISOIMAGE),) IMAGES += ubuntu.i386 centos ifneq ($(EFI_AARCH64),) -IMAGES += ubuntu.aarch64 +IMAGES += ubuntu.aarch64 centos.aarch64 endif endif @@ -28,6 +28,7 @@ ifneq ($(GENISOIMAGE),) @echo " vm-build-ubuntu.i386 - Build QEMU in ubuntu i386 VM" ifneq ($(EFI_AARCH64),) @echo " vm-build-ubuntu.aarch64 - Build QEMU in ubuntu aarch64 VM" + @echo " vm-build-centos.aarch64 - Build QEMU in CentOS aarch64 VM" else @echo " (to build centos/ubuntu aarch64 images use configure --efi-aarch64)" endif diff --git a/tests/vm/centos-8-aarch64.ks b/tests/vm/centos-8-aarch64.ks new file mode 100644 index 00000000000..fd6ebe4d49e --- /dev/null +++ b/tests/vm/centos-8-aarch64.ks @@ -0,0 +1,51 @@ +# CentOS aarch64 image kickstart file. +# This file is used by the CentOS installer to +# script the generation of the image. +# +# Copyright 2020 Linaro +# +ignoredisk --only-use=vda +# System bootloader configuration +bootloader --append=" crashkernel=auto" --location=mbr --boot-drive=vda +autopart --type=plain +# Partition clearing information +clearpart --linux --initlabel --drives=vda +# Use text mode install +text +repo --name="AppStream" --baseurl=file:///run/install/repo/AppStream +# Use CDROM installation media +cdrom +# Keyboard layouts +keyboard --vckeymap=us --xlayouts='' +# System language +lang en_US.UTF-8 + +# Network information +network --bootproto=dhcp --device=enp0s1 --onboot=off --ipv6=auto --no-activate +network --hostname=localhost.localdomain +# Run the Setup Agent on first boot +firstboot --enable +# Do not configure the X Window System +skipx +# System services +services --enabled="chronyd" +# System timezone +timezone America/New_York --isUtc + +# Shutdown after installation is complete. +shutdown + +%packages +@^server-product-environment +kexec-tools + +%end + +%addon com_redhat_kdump --enable --reserve-mb='auto' + +%end +%anaconda +pwpolicy root --minlen=6 --minquality=1 --notstrict --nochanges --notempty +pwpolicy user --minlen=6 --minquality=1 --notstrict --nochanges --emptyok +pwpolicy luks --minlen=6 --minquality=1 --notstrict --nochanges --notempty +%end diff --git a/tests/vm/centos.aarch64 b/tests/vm/centos.aarch64 new file mode 100755 index 00000000000..d5232ecdb8c --- /dev/null +++ b/tests/vm/centos.aarch64 @@ -0,0 +1,227 @@ +#!/usr/bin/env python3 +# +# Centos aarch64 image +# +# Copyright 2020 Linaro +# +# Authors: +# Robert Foley +# Originally based on ubuntu.aarch64 +# +# This code is licensed under the GPL version 2 or later. See +# the COPYING file in the top-level directory. +# + +import os +import sys +import subprocess +import basevm +import time +import traceback +import aarch64vm + +DEFAULT_CONFIG = { + 'cpu' : "max", + 'machine' : "virt,gic-version=max", + 'install_cmds' : "yum install -y make git python3 gcc gcc-c++ flex bison, "\ + "yum install -y glib2-devel pixman-devel zlib-devel, "\ + "yum install -y perl-Test-Harness, "\ + "alternatives --set python /usr/bin/python3, "\ + "sudo dnf config-manager "\ + "--add-repo=https://download.docker.com/linux/centos/docker-ce.repo,"\ + "sudo dnf install --nobest -y docker-ce.aarch64,"\ + "systemctl enable docker", + # We increase beyond the default time since during boot + # it can take some time (many seconds) to log into the VM. + 'ssh_timeout' : 60, +} + +class CentosAarch64VM(basevm.BaseVM): + name = "centos.aarch64" + arch = "aarch64" + login_prompt = "localhost login:" + prompt = '[root@localhost ~]#' + image_name = "CentOS-8-aarch64-1905-dvd1.iso" + image_link = "http://mirrors.usc.edu/pub/linux/distributions/centos/8.0.1905/isos/aarch64/" + image_link += image_name + BUILD_SCRIPT = """ + set -e; + cd $(mktemp -d); + sudo chmod a+r /dev/vdb; + tar --checkpoint=.10 -xf /dev/vdb; + ./configure {configure_opts}; + make --output-sync {target} -j{jobs} {verbose}; + """ + def set_key_perm(self): + """Set permissions properly on certain files to allow + ssh access.""" + self.console_wait_send(self.prompt, + "/usr/sbin/restorecon -R -v /root/.ssh\n") + self.console_wait_send(self.prompt, + "/usr/sbin/restorecon -R -v "\ + "/home/{}/.ssh\n".format(self._config["guest_user"])) + + def create_kickstart(self): + """Generate the kickstart file used to generate the centos image.""" + # Start with the template for the kickstart. + ks_file = "../tests/vm/centos-8-aarch64.ks" + subprocess.check_call("cp {} ./ks.cfg".format(ks_file), shell=True) + # Append the ssh keys to the kickstart file + # as the post processing phase of installation. + with open("ks.cfg", "a") as f: + # Add in the root pw and guest user. + rootpw = "rootpw --plaintext {}\n" + f.write(rootpw.format(self._config["root_pass"])) + add_user = "user --groups=wheel --name={} "\ + "--password={} --plaintext\n" + f.write(add_user.format(self._config["guest_user"], + self._config["guest_pass"])) + # Add the ssh keys. + f.write("%post --log=/root/ks-post.log\n") + f.write("mkdir -p /root/.ssh\n") + addkey = 'echo "{}" >> /root/.ssh/authorized_keys\n' + addkey_cmd = addkey.format(self._config["ssh_pub_key"]) + f.write(addkey_cmd) + f.write('mkdir -p /home/{}/.ssh\n'.format(self._config["guest_user"])) + addkey = 'echo "{}" >> /home/{}/.ssh/authorized_keys\n' + addkey_cmd = addkey.format(self._config["ssh_pub_key"], + self._config["guest_user"]) + f.write(addkey_cmd) + f.write("%end\n") + # Take our kickstart file and create an .iso from it. + # The .iso will be provided to qemu as we boot + # from the install dvd. + # Anaconda will recognize the label "OEMDRV" and will + # start the automated installation. + gen_iso_img = 'genisoimage -output ks.iso -volid "OEMDRV" ks.cfg' + subprocess.check_call(gen_iso_img, shell=True) + + def wait_for_shutdown(self): + """We wait for qemu to shutdown the VM and exit. + While this happens we display the console view + for easier debugging.""" + # The image creation is essentially done, + # so whether or not the wait is successful we want to + # wait for qemu to exit (the self.wait()) before we return. + try: + self.console_wait("reboot: Power down") + except Exception as e: + sys.stderr.write("Exception hit\n") + if isinstance(e, SystemExit) and e.code == 0: + return 0 + traceback.print_exc() + finally: + self.wait() + + def build_base_image(self, dest_img): + """Run through the centos installer to create + a base image with name dest_img.""" + # We create the temp image, and only rename + # to destination when we are done. + img = dest_img + ".tmp" + # Create an empty image. + # We will provide this as the install destination. + qemu_img_create = "qemu-img create {} 50G".format(img) + subprocess.check_call(qemu_img_create, shell=True) + + # Create our kickstart file to be fed to the installer. + self.create_kickstart() + # Boot the install dvd with the params as our ks.iso + os_img = self._download_with_cache(self.image_link) + dvd_iso = "centos-8-dvd.iso" + subprocess.check_call(["cp", "-f", os_img, dvd_iso]) + extra_args = "-cdrom ks.iso" + extra_args += " -drive file={},if=none,id=drive1,cache=writeback" + extra_args += " -device virtio-blk,drive=drive1,bootindex=1" + extra_args = extra_args.format(dvd_iso).split(" ") + self.boot(img, extra_args=extra_args) + self.console_wait_send("change the selection", "\n") + # We seem to need to hit esc (chr(27)) twice to abort the + # media check, which takes a long time. + # Waiting a bit seems to be more reliable before hitting esc. + self.console_wait("Checking") + time.sleep(5) + self.console_wait_send("Checking", chr(27)) + time.sleep(5) + self.console_wait_send("Checking", chr(27)) + print("Found Checking") + # Give sufficient time for the installer to create the image. + self.console_init(timeout=7200) + self.wait_for_shutdown() + os.rename(img, dest_img) + print("Done with base image build: {}".format(dest_img)) + + def check_create_base_img(self, img_base, img_dest): + """Create a base image using the installer. + We will use the base image if it exists. + This helps cut down on install time in case we + need to restart image creation, + since the base image creation can take a long time.""" + if not os.path.exists(img_base): + print("Generate new base image: {}".format(img_base)) + self.build_base_image(img_base); + else: + print("Use existing base image: {}".format(img_base)) + # Save a copy of the base image and copy it to dest. + # which we will use going forward. + subprocess.check_call(["cp", img_base, img_dest]) + + def boot(self, img, extra_args=None): + aarch64vm.create_flash_images(self._tmpdir, self._efi_aarch64) + default_args = aarch64vm.get_pflash_args(self._tmpdir) + if extra_args: + extra_args.extend(default_args) + else: + extra_args = default_args + # We always add these performance tweaks + # because without them, we boot so slowly that we + # can time out finding the boot efi device. + if '-smp' not in extra_args and \ + '-smp' not in self._config['extra_args'] and \ + '-smp' not in self._args: + # Only add if not already there to give caller option to change it. + extra_args.extend(["-smp", "8"]) + # We have overridden boot() since aarch64 has additional parameters. + # Call down to the base class method. + super(CentosAarch64VM, self).boot(img, extra_args=extra_args) + + def build_image(self, img): + img_tmp = img + ".tmp" + self.check_create_base_img(img + ".base", img_tmp) + + # Boot the new image for the first time to finish installation. + self.boot(img_tmp) + self.console_init() + self.console_wait_send(self.login_prompt, "root\n") + self.console_wait_send("Password:", + "{}\n".format(self._config["root_pass"])) + + self.set_key_perm() + self.console_wait_send(self.prompt, "rpm -q centos-release\n") + enable_adapter = "sed -i 's/ONBOOT=no/ONBOOT=yes/g'" \ + " /etc/sysconfig/network-scripts/ifcfg-enp0s1\n" + self.console_wait_send(self.prompt, enable_adapter) + self.console_wait_send(self.prompt, "ifup enp0s1\n") + self.console_wait_send(self.prompt, + 'echo "qemu ALL=(ALL) NOPASSWD:ALL" | '\ + 'sudo tee /etc/sudoers.d/qemu\n') + self.console_wait(self.prompt) + + # Rest of the commands we issue through ssh. + self.wait_ssh(wait_root=True) + + # If the user chooses *not* to do the second phase, + # then we will jump right to the graceful shutdown + if self._config['install_cmds'] != "": + install_cmds = self._config['install_cmds'].split(',') + for cmd in install_cmds: + self.ssh_root(cmd) + self.ssh_root("poweroff") + self.wait_for_shutdown() + os.rename(img_tmp, img) + print("image creation complete: {}".format(img)) + return 0 + +if __name__ == "__main__": + defaults = aarch64vm.get_config_defaults(CentosAarch64VM, DEFAULT_CONFIG) + sys.exit(basevm.main(CentosAarch64VM, defaults)) From patchwork Wed Jul 1 13:56:23 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Alex_Benn=C3=A9e?= X-Patchwork-Id: 192140 Delivered-To: patch@linaro.org Received: by 2002:a92:d244:0:0:0:0:0 with SMTP id v4csp521123ilg; Wed, 1 Jul 2020 07:01:45 -0700 (PDT) X-Google-Smtp-Source: ABdhPJy+sTPC9FqNzAn5xJx3qXAQHl4LXTeE9I7Q4405F5y6Bvz6DVaY/BRnmxNY8nTXM1j6OlQq X-Received: by 2002:a25:b211:: with SMTP id i17mr32027796ybj.241.1593612105455; Wed, 01 Jul 2020 07:01:45 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1593612105; cv=none; d=google.com; s=arc-20160816; b=0onBX3cS1t6Po0/jtNpI0DokGuX+8a1ylhN5VRids1VqoXq0gP2/NGfHbwbRUw/v7q 8FTRR7UM+5TnOuT7MFK2a9azfMA5K5p9Gt0s1VkHPDOICMDjfxvQQcq+pygjCxAdn8N8 +zIPI27r2PGsZQd4UYvmeDlRpZkqfXST27CUAOFvHxX7UdoJCuVkFlRzb29KrqRvjUiw MTolqSDlgBde+WEhUJDPo06wd5edNjNGz/kOoL70usp51lHqSLl1YbRiHjdvl5+RiNbA eEbs66Cf+MxH2wYZFbk3XHJCbGcVzOiU2EXWTn0RKzsSTUcGxP6IhtpBeIwbh8fmx/kf 14NA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:cc:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=i1iXs9z8IgQzO10xR7jkeUaTbh6mNju7MyNOqxfnXxI=; b=kOyvAbPkFmNJ5oh+u1Na4sfF+EJmX7JOdz1oO2QqyU9mHAP8up1/D5BNQ3IKsBM3UV 2QJdt2iTHqprP0PndL4yeV92OFIRIoNyHEEDCAhKmglRzi03rbPwUlbNHHNkYNW5p7er qBTW7YBMsQABNIGO5WTB1Xt8hvNwew2Qw3D67yWpeoOFXwFNlXO/ijl5YtGJeB2ZSUP3 Q7R/FP6euzjInrrS4JgZ62V4fvk7xE148ZrJUXCT1FexeIIwp0Qg1AqQkVNliAim+vhk ksrTDC+4fcURdJV3wKgdurC/5h/2+UGStJMsV4cvEZvBWLASx9IhKWR7B52hPhSWD53y 23DQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=mK8K0+v2; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id k4si7854791ybt.409.2020.07.01.07.01.45 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Wed, 01 Jul 2020 07:01:45 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=mK8K0+v2; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1]:43318 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jqdJ2-000131-Mo for patch@linaro.org; Wed, 01 Jul 2020 10:01:44 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:58862) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jqdEW-0002Hr-Pt for qemu-devel@nongnu.org; Wed, 01 Jul 2020 09:57:04 -0400 Received: from mail-wr1-x443.google.com ([2a00:1450:4864:20::443]:33189) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1jqdEU-0005qh-3A for qemu-devel@nongnu.org; Wed, 01 Jul 2020 09:57:04 -0400 Received: by mail-wr1-x443.google.com with SMTP id f18so15894175wrs.0 for ; Wed, 01 Jul 2020 06:57:01 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=i1iXs9z8IgQzO10xR7jkeUaTbh6mNju7MyNOqxfnXxI=; b=mK8K0+v2XHDmu0l81RPUdLR5im+XLOMLQ1hS4q0wTM72Xcw9c18pu5xFAFwZqVlLRU cE7icoQVOR1c1e74nf1Cj8Nn0EBRUUPMaHQdha9IzZtP+nVf5OAyp9XqNmqxa7uOboeK vCrcMLUdkHhhIfbr5JIbLruhtNfgvhhriY5H9da895iOaw/MAZp0T62NVIWgU6qtwmVg vAAnSfS9XKce6Z6xOlrt3s6fbwlgDxjxNtMfj6pg5ubeMpLr2q1T8U05n56osaStKkr0 igr7jkAvkT1J9LP4FxCgjYyExF9rzfh8CoumZA2tCcsUtmmsOM7SVXmzp7GK+Cu+m1bp yQeA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=i1iXs9z8IgQzO10xR7jkeUaTbh6mNju7MyNOqxfnXxI=; b=PCyKmWG+JAAnJRtVWPWk6Xd7mpFO0mNCBKHFze/32dr5idoOf2V/At7Mv89XeWvzvU IIp056hw+6HMVZz+19jvq8pDJ5r4LqHOLoP3+q4vzqxPvFzs/RTocWs3Qk7UTNBx0MF9 7XJc/pR5d/L+tuPPf6C0jRylkdjCuBtTZ7jptTsc1juY9BVzR4CuwBzen+w5ukwX81Ty ymWVroA7MKdHPijoAlWwrvTG6Dnp6eq9oJhfN+xLjHlY4y8DGauNrERlFHT41SaOjOKc 7BMpMeNK1GbSeWO8x/60fWD5R8xdx3n/n35xQ7a9fFj4ii8eA5mNOIg+qTrZ0GY9iZP0 jSQw== X-Gm-Message-State: AOAM530L2JCsRQ72OAHnVjh3H6HX1LzoqGOFSGcB+OQbEw/xp/GZpK7m p9vESYA1XVS84G/wNidd4ow+fg== X-Received: by 2002:adf:e74e:: with SMTP id c14mr28404490wrn.143.1593611820650; Wed, 01 Jul 2020 06:57:00 -0700 (PDT) Received: from zen.linaroharston ([51.148.130.216]) by smtp.gmail.com with ESMTPSA id m16sm2290292wro.0.2020.07.01.06.56.58 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 01 Jul 2020 06:57:00 -0700 (PDT) Received: from zen.lan (localhost [127.0.0.1]) by zen.linaroharston (Postfix) with ESMTP id ED8C71FF9A; Wed, 1 Jul 2020 14:56:53 +0100 (BST) From: =?utf-8?q?Alex_Benn=C3=A9e?= To: qemu-devel@nongnu.org Subject: [PATCH v4 11/40] tests/vm: change scripts to use self._config Date: Wed, 1 Jul 2020 14:56:23 +0100 Message-Id: <20200701135652.1366-12-alex.bennee@linaro.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20200701135652.1366-1-alex.bennee@linaro.org> References: <20200701135652.1366-1-alex.bennee@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::443; envelope-from=alex.bennee@linaro.org; helo=mail-wr1-x443.google.com X-detected-operating-system: by eggs.gnu.org: No matching host in p0f cache. That's all we know. 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, URIBL_BLOCKED=0.001 autolearn=_AUTOLEARN X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: fam@euphon.net, berrange@redhat.com, Robert Foley , =?utf-8?q?Alex_Benn=C3=A9e?= , richard.henderson@linaro.org, f4bug@amsat.org, =?utf-8?q?Philippe_Mat?= =?utf-8?q?hieu-Daud=C3=A9?= , cota@braap.org, Peter Puhov , aurelien@aurel32.net Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: "Qemu-devel" From: Robert Foley This change converts existing scripts to using for example self.ROOT_PASS, to self._config['root_pass']. We made similar changes for GUEST_USER, and GUEST_PASS. This allows us also to remove the change in basevm.py, which adds __getattr__ for backwards compatibility. Signed-off-by: Robert Foley Reviewed-by: Peter Puhov Signed-off-by: Alex Bennée Reviewed-by: Philippe Mathieu-Daudé Message-Id: <20200601211421.1277-8-robert.foley@linaro.org> --- tests/vm/basevm.py | 11 ++--------- tests/vm/fedora | 17 +++++++++-------- tests/vm/freebsd | 16 ++++++++-------- tests/vm/netbsd | 19 ++++++++++--------- tests/vm/openbsd | 17 +++++++++-------- 5 files changed, 38 insertions(+), 42 deletions(-) -- 2.20.1 diff --git a/tests/vm/basevm.py b/tests/vm/basevm.py index 5fd66f6b26a..f716798b405 100644 --- a/tests/vm/basevm.py +++ b/tests/vm/basevm.py @@ -183,13 +183,6 @@ class BaseVM(object): self.console_init(timeout=timeout) self.console_wait(wait_string) - def __getattr__(self, name): - # Support direct access to config by key. - # for example, access self._config['cpu'] by self.cpu - if name.lower() in self._config.keys(): - return self._config[name.lower()] - return object.__getattribute__(self, name) - def _download_with_cache(self, url, sha256sum=None, sha512sum=None): def check_sha256sum(fname): if not sha256sum: @@ -239,13 +232,13 @@ class BaseVM(object): return r def ssh(self, *cmd): - return self._ssh_do(self.GUEST_USER, cmd, False) + return self._ssh_do(self._config["guest_user"], cmd, False) def ssh_root(self, *cmd): return self._ssh_do("root", cmd, False) def ssh_check(self, *cmd): - self._ssh_do(self.GUEST_USER, cmd, True) + self._ssh_do(self._config["guest_user"], cmd, True) def ssh_root_check(self, *cmd): self._ssh_do("root", cmd, True) diff --git a/tests/vm/fedora b/tests/vm/fedora index a9195670f4b..b2b478fdbca 100755 --- a/tests/vm/fedora +++ b/tests/vm/fedora @@ -108,20 +108,20 @@ class FedoraVM(basevm.BaseVM): self.console_wait_send("7) [!] Root password", "7\n") self.console_wait("Password:") - self.console_send("%s\n" % self.ROOT_PASS) + self.console_send("%s\n" % self._config["root_pass"]) self.console_wait("Password (confirm):") - self.console_send("%s\n" % self.ROOT_PASS) + self.console_send("%s\n" % self._config["root_pass"]) self.console_wait_send("8) [ ] User creation", "8\n") self.console_wait_send("1) [ ] Create user", "1\n") self.console_wait_send("3) User name", "3\n") - self.console_wait_send("ENTER:", "%s\n" % self.GUEST_USER) + self.console_wait_send("ENTER:", "%s\n" % self._config["guest_user"]) self.console_wait_send("4) [ ] Use password", "4\n") self.console_wait_send("5) Password", "5\n") self.console_wait("Password:") - self.console_send("%s\n" % self.GUEST_PASS) + self.console_send("%s\n" % self._config["guest_pass"]) self.console_wait("Password (confirm):") - self.console_send("%s\n" % self.GUEST_PASS) + self.console_send("%s\n" % self._config["guest_pass"]) self.console_wait_send("7) Groups", "c\n") while True: @@ -139,7 +139,7 @@ class FedoraVM(basevm.BaseVM): if good: break time.sleep(10) - self.console_send("r\n" % self.GUEST_PASS) + self.console_send("r\n" % self._config["guest_pass"]) self.console_wait_send("'b' to begin install", "b\n") @@ -150,12 +150,13 @@ class FedoraVM(basevm.BaseVM): # setup qemu user prompt = " ~]$" - self.console_ssh_init(prompt, self.GUEST_USER, self.GUEST_PASS) + self.console_ssh_init(prompt, self._config["guest_user"], + self._config["guest_pass"]) self.console_wait_send(prompt, "exit\n") # setup root user prompt = " ~]#" - self.console_ssh_init(prompt, "root", self.ROOT_PASS) + self.console_ssh_init(prompt, "root", self._config["root_pass"]) self.console_sshd_config(prompt) # setup virtio-blk #1 (tarfile) diff --git a/tests/vm/freebsd b/tests/vm/freebsd index f87db2b126e..29252fa4a64 100755 --- a/tests/vm/freebsd +++ b/tests/vm/freebsd @@ -113,9 +113,9 @@ class FreeBSDVM(basevm.BaseVM): # post-install configuration self.console_wait("New Password:") - self.console_send("%s\n" % self.ROOT_PASS) + self.console_send("%s\n" % self._config["root_pass"]) self.console_wait("Retype New Password:") - self.console_send("%s\n" % self.ROOT_PASS) + self.console_send("%s\n" % self._config["root_pass"]) self.console_wait_send("Network Configuration", "\n") self.console_wait_send("IPv4", "y") @@ -134,9 +134,9 @@ class FreeBSDVM(basevm.BaseVM): # qemu user self.console_wait_send("Add User Accounts", "y") self.console_wait("Username") - self.console_send("%s\n" % self.GUEST_USER) + self.console_send("%s\n" % self._config["guest_user"]) self.console_wait("Full name") - self.console_send("%s\n" % self.GUEST_USER) + self.console_send("%s\n" % self._config["guest_user"]) self.console_wait_send("Uid", "\n") self.console_wait_send("Login group", "\n") self.console_wait_send("Login group", "\n") @@ -148,9 +148,9 @@ class FreeBSDVM(basevm.BaseVM): self.console_wait_send("Use an empty password", "\n") self.console_wait_send("Use a random password", "\n") self.console_wait("Enter password:") - self.console_send("%s\n" % self.GUEST_PASS) + self.console_send("%s\n" % self._config["guest_pass"]) self.console_wait("Enter password again:") - self.console_send("%s\n" % self.GUEST_PASS) + self.console_send("%s\n" % self._config["guest_pass"]) self.console_wait_send("Lock out", "\n") self.console_wait_send("OK", "yes\n") self.console_wait_send("Add another user", "no\n") @@ -164,12 +164,12 @@ class FreeBSDVM(basevm.BaseVM): # setup qemu user prompt = "$" - self.console_ssh_init(prompt, self.GUEST_USER, self.GUEST_PASS) + self.console_ssh_init(prompt, self._config["guest_user"], self._config["guest_pass"]) self.console_wait_send(prompt, "exit\n") # setup root user prompt = "root@freebsd:~ #" - self.console_ssh_init(prompt, "root", self.ROOT_PASS) + self.console_ssh_init(prompt, "root", self._config["root_pass"]) self.console_sshd_config(prompt) # setup serial console diff --git a/tests/vm/netbsd b/tests/vm/netbsd index cdac502dad8..dc0e45c1d45 100755 --- a/tests/vm/netbsd +++ b/tests/vm/netbsd @@ -120,24 +120,24 @@ class NetBSDVM(basevm.BaseVM): self.console_wait_send("d: Change root password", "d\n") self.console_wait_send("a: Yes", "a\n") self.console_wait("New password:") - self.console_send("%s\n" % self.ROOT_PASS) + self.console_send("%s\n" % self._config["root_pass"]) self.console_wait("New password:") - self.console_send("%s\n" % self.ROOT_PASS) + self.console_send("%s\n" % self._config["root_pass"]) self.console_wait("Retype new password:") - self.console_send("%s\n" % self.ROOT_PASS) + self.console_send("%s\n" % self._config["root_pass"]) self.console_wait_send("o: Add a user", "o\n") self.console_wait("username") - self.console_send("%s\n" % self.GUEST_USER) + self.console_send("%s\n" % self._config["guest_pass"]) self.console_wait("to group wheel") self.console_wait_send("a: Yes", "a\n") self.console_wait_send("a: /bin/sh", "a\n") self.console_wait("New password:") - self.console_send("%s\n" % self.GUEST_PASS) + self.console_send("%s\n" % self._config["guest_pass"]) self.console_wait("New password:") - self.console_send("%s\n" % self.GUEST_PASS) + self.console_send("%s\n" % self._config["guest_pass"]) self.console_wait("Retype new password:") - self.console_send("%s\n" % self.GUEST_PASS) + self.console_send("%s\n" % self._config["guest_pass"]) self.console_wait_send("a: Configure network", "a\n") self.console_wait_send("a: vioif0", "a\n") @@ -170,12 +170,13 @@ class NetBSDVM(basevm.BaseVM): # setup qemu user prompt = "localhost$" - self.console_ssh_init(prompt, self.GUEST_USER, self.GUEST_PASS) + self.console_ssh_init(prompt, self._config["guest_user"], + self._config["guest_pass"]) self.console_wait_send(prompt, "exit\n") # setup root user prompt = "localhost#" - self.console_ssh_init(prompt, "root", self.ROOT_PASS) + self.console_ssh_init(prompt, "root", self._config["root_pass"]) self.console_sshd_config(prompt) # setup virtio-blk #1 (tarfile) diff --git a/tests/vm/openbsd b/tests/vm/openbsd index 13e7f9a6d56..dfe633e4532 100755 --- a/tests/vm/openbsd +++ b/tests/vm/openbsd @@ -98,9 +98,9 @@ class OpenBSDVM(basevm.BaseVM): self.console_wait_send("Which network interface", "done\n") self.console_wait_send("DNS domain name", "localnet\n") self.console_wait("Password for root account") - self.console_send("%s\n" % self.ROOT_PASS) + self.console_send("%s\n" % self._config["root_pass"]) self.console_wait("Password for root account") - self.console_send("%s\n" % self.ROOT_PASS) + self.console_send("%s\n" % self._config["root_pass"]) self.console_wait_send("Start sshd(8)", "yes\n") self.console_wait_send("X Window System", "\n") self.console_wait_send("xenodm", "\n") @@ -108,13 +108,13 @@ class OpenBSDVM(basevm.BaseVM): self.console_wait_send("Which speed", "\n") self.console_wait("Setup a user") - self.console_send("%s\n" % self.GUEST_USER) + self.console_send("%s\n" % self._config["guest_user"]) self.console_wait("Full name") - self.console_send("%s\n" % self.GUEST_USER) + self.console_send("%s\n" % self._config["guest_user"]) self.console_wait("Password") - self.console_send("%s\n" % self.GUEST_PASS) + self.console_send("%s\n" % self._config["guest_pass"]) self.console_wait("Password") - self.console_send("%s\n" % self.GUEST_PASS) + self.console_send("%s\n" % self._config["guest_pass"]) self.console_wait_send("Allow root ssh login", "yes\n") self.console_wait_send("timezone", "UTC\n") @@ -135,12 +135,13 @@ class OpenBSDVM(basevm.BaseVM): # setup qemu user prompt = "$" - self.console_ssh_init(prompt, self.GUEST_USER, self.GUEST_PASS) + self.console_ssh_init(prompt, self._config["guest_user"], + self._config["guest_pass"]) self.console_wait_send(prompt, "exit\n") # setup root user prompt = "openbsd#" - self.console_ssh_init(prompt, "root", self.ROOT_PASS) + self.console_ssh_init(prompt, "root", self._config["root_pass"]) self.console_sshd_config(prompt) # setup virtio-blk #1 (tarfile) From patchwork Wed Jul 1 13:56:24 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Alex_Benn=C3=A9e?= X-Patchwork-Id: 192135 Delivered-To: patch@linaro.org Received: by 2002:a92:d244:0:0:0:0:0 with SMTP id v4csp518038ilg; Wed, 1 Jul 2020 06:58:11 -0700 (PDT) X-Google-Smtp-Source: ABdhPJznxCRZzIXTwQ6tnyKhDOff1lDs+E6F0ODFvsEBLitExBhpZrYsmcLi+iPZp+/JHM+1upoA X-Received: by 2002:a25:d755:: with SMTP id o82mr38877069ybg.166.1593611890956; Wed, 01 Jul 2020 06:58:10 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1593611890; cv=none; d=google.com; s=arc-20160816; b=iQ6wfgSGj/txlIsUdPQzpoFjp2Gf9ZvecOiv4/hVIs7fVlPzpT1FHF2jnp1rpbu0aK lakFGA9sbK4qrrzi+1U9fnT0W520MhKUz7T6wu5rglOiIpI0xxK6Odmz4Vv60+sTjPqA 8CxnjO4qFO3A3Y6h+UBg/Dnh4HihXqcKsX/5KYRoXY6o+4lfUxpbBcJEh4ZomWbM0OEk lXhQ3HGEzR6vh4svEht+07E/XZOE2bJGLipt1D12GxDmUZ7RK0KvQM78z3tTDVEbx2rC eMk9daAcj5yeRfqM2f2rpS9qFjllwgbzAd0FGJklMd1DOwE1+aBm6O6UrZ4S9dKduWJ8 ZbTg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:cc:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=SfCKKjXRpSzktD2zHuCdVYnzBzWod3odSIiX8dUA3RA=; b=uBDXSfAfVcHRcCrAsxxHHikoQRXgEZ49rqjXSCVRTM8W3/OAhRnmQhwCcsFB0v2VNP 4kqWdre6rpLxOdE74XBB44vxd16HPfrZO697Mx62Zqrwz8+pbhaJk1+KuHlVHZTAXNXM k+M/hNCZ7oafbRSWOFcIfhrb6l8vwSrVCEgGtaH3Y4RAo6CrxyjHGcSO3VZgPFnPphwP UrmD91sGg6dsTOYbPbYxHotMY8RP0Fhu1Gof1vHwtnSnJZEe5oNCuAXWB3BYyk43+iMS fJgkGUcxM40FpQyx7Z31ZUGLrAuPN9dk2UtdOK/CnUrkuy/k0DyflRKSJkeLFEywnfS4 JNaA== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=i294gKmZ; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id f20si5962863ybj.55.2020.07.01.06.58.10 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Wed, 01 Jul 2020 06:58:10 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=i294gKmZ; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1]:55310 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jqdFa-0002QO-E6 for patch@linaro.org; Wed, 01 Jul 2020 09:58:10 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:58860) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jqdEW-0002GO-9M for qemu-devel@nongnu.org; Wed, 01 Jul 2020 09:57:04 -0400 Received: from mail-wr1-x429.google.com ([2a00:1450:4864:20::429]:33210) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1jqdEU-0005qf-1O for qemu-devel@nongnu.org; Wed, 01 Jul 2020 09:57:03 -0400 Received: by mail-wr1-x429.google.com with SMTP id f18so15894173wrs.0 for ; Wed, 01 Jul 2020 06:57:01 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=SfCKKjXRpSzktD2zHuCdVYnzBzWod3odSIiX8dUA3RA=; b=i294gKmZN5zM7PdcVVtjoT8BgbgU+sITZj9GRH188Haxc44gPR8swMvV3ZFu37tJf3 rXl8rtKvoi8jpwQyfUMaWx77y57ZGw000LGfUNoyyEIH2B6/fRrJ1jNxklLzKUQWQsju nfm/1IcfX4LjmB3ZRZ+swt24BL2jOzHdjK0oAazcMZmgxRUsqLZOZSre260VIkATgkFl uCUlYDs0gzSBmcEqAUWTqAeEiRrs4JXBx/8yp3Thft46CPHG9WhBoFSLC8TxI1ESOXE6 wFaZOxJWaCUqFd1/bJ6WS/8LkV0Rz+nyxum5q90d4NgjRNlvp38z6DHeKjqjzV/iATO2 PETQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=SfCKKjXRpSzktD2zHuCdVYnzBzWod3odSIiX8dUA3RA=; b=oTVsErJ2X5H9h2MoHhC5hz+WqxJ4vVwdllyO2LVuDxetamDHwlA2mU52fN92Tnb6kn w5wk+5fC0xKh69d8XYro/1otZ4Rv7X9yUZlfPGziIaPfeFlIw09UT75ziv5lUYAqmDiR 2gbYgTnGCStzOpi19L0j5heHxp/DoRRgy759QaF/U2Axwkgu/jH/BxWBYINo8VySw1C8 B7F+EPKgWemDl1Mh21pRwkYlPdPhtOL8yhWtKOId3xG6kofahM8Y63e/iEtrH3OvYkMX Zr7jdkoyM3W52lW7e3jjuvr5AB727LbB8GzhSqtLYkl5YRFJFouCSxCTG7ATU3L9LoV6 8L2A== X-Gm-Message-State: AOAM532XoR0/OEfqSPOYESBNDIP/t1zDDPBNAFwo/+qP5szqNUWhZna6 7oJeijWy6x/TXZHiZZiYBDaEGA== X-Received: by 2002:a5d:6b08:: with SMTP id v8mr28106613wrw.2.1593611820670; Wed, 01 Jul 2020 06:57:00 -0700 (PDT) Received: from zen.linaroharston ([51.148.130.216]) by smtp.gmail.com with ESMTPSA id m10sm7591235wru.4.2020.07.01.06.56.58 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 01 Jul 2020 06:57:00 -0700 (PDT) Received: from zen.lan (localhost [127.0.0.1]) by zen.linaroharston (Postfix) with ESMTP id 120261FF9B; Wed, 1 Jul 2020 14:56:54 +0100 (BST) From: =?utf-8?q?Alex_Benn=C3=A9e?= To: qemu-devel@nongnu.org Subject: [PATCH v4 12/40] python/qemu: Add ConsoleSocket for optional use in QEMUMachine Date: Wed, 1 Jul 2020 14:56:24 +0100 Message-Id: <20200701135652.1366-13-alex.bennee@linaro.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20200701135652.1366-1-alex.bennee@linaro.org> References: <20200701135652.1366-1-alex.bennee@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::429; envelope-from=alex.bennee@linaro.org; helo=mail-wr1-x429.google.com X-detected-operating-system: by eggs.gnu.org: No matching host in p0f cache. That's all we know. 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, URIBL_BLOCKED=0.001 autolearn=_AUTOLEARN X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: fam@euphon.net, berrange@redhat.com, Robert Foley , =?utf-8?q?Alex_Benn=C3=A9e?= , richard.henderson@linaro.org, f4bug@amsat.org, =?utf-8?q?Philippe_Mat?= =?utf-8?q?hieu-Daud=C3=A9?= , cota@braap.org, Cleber Rosa , Peter Puhov , aurelien@aurel32.net, Eduardo Habkost Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: "Qemu-devel" From: Robert Foley We add the ConsoleSocket object, which has a socket interface and which will consume all arriving characters on the socket, placing them into an in memory buffer. This will also provide those chars via recv() as would a regular socket. ConsoleSocket also has the option of dumping the console bytes to a log file. We also give QEMUMachine the option of using ConsoleSocket to drain and to use for logging console to a file. By default QEMUMachine does not use ConsoleSocket. This is added in preparation for use by basevm.py in a later commit. This is a workaround we found was needed for basevm.py since there is a known issue where QEMU will hang waiting for console characters to be consumed. Cc: Eduardo Habkost Cc: Cleber Rosa Signed-off-by: Robert Foley Reviewed-by: Peter Puhov Acked-by: Alex Bennée Tested-by: Philippe Mathieu-Daudé Signed-off-by: Alex Bennée Message-Id: <20200601211421.1277-9-robert.foley@linaro.org> --- python/qemu/console_socket.py | 110 ++++++++++++++++++++++++++++++++++ python/qemu/machine.py | 23 +++++-- 2 files changed, 129 insertions(+), 4 deletions(-) create mode 100644 python/qemu/console_socket.py -- 2.20.1 diff --git a/python/qemu/console_socket.py b/python/qemu/console_socket.py new file mode 100644 index 00000000000..830cb7c6282 --- /dev/null +++ b/python/qemu/console_socket.py @@ -0,0 +1,110 @@ +#!/usr/bin/env python3 +# +# This python module implements a ConsoleSocket object which is +# designed always drain the socket itself, and place +# the bytes into a in memory buffer for later processing. +# +# Optionally a file path can be passed in and we will also +# dump the characters to this file for debug. +# +# Copyright 2020 Linaro +# +# Authors: +# Robert Foley +# +# This code is licensed under the GPL version 2 or later. See +# the COPYING file in the top-level directory. +# +import asyncore +import socket +import threading +import io +import os +import sys +from collections import deque +import time +import traceback + +class ConsoleSocket(asyncore.dispatcher): + + def __init__(self, address, file=None): + self._recv_timeout_sec = 300 + self._buffer = deque() + self._asyncore_thread = None + self._sock = socket.socket(socket.AF_UNIX, socket.SOCK_STREAM) + self._sock.connect(address) + self._logfile = None + if file: + self._logfile = open(file, "w") + asyncore.dispatcher.__init__(self, sock=self._sock) + self._open = True + self._thread_start() + + def _thread_start(self): + """Kick off a thread to wait on the asyncore.loop""" + if self._asyncore_thread is not None: + return + self._asyncore_thread = threading.Thread(target=asyncore.loop, + kwargs={'timeout':1}) + self._asyncore_thread.daemon = True + self._asyncore_thread.start() + + def handle_close(self): + """redirect close to base class""" + # Call the base class close, but not self.close() since + # handle_close() occurs in the context of the thread which + # self.close() attempts to join. + asyncore.dispatcher.close(self) + + def close(self): + """Close the base object and wait for the thread to terminate""" + if self._open: + self._open = False + asyncore.dispatcher.close(self) + if self._asyncore_thread is not None: + thread, self._asyncore_thread = self._asyncore_thread, None + thread.join() + if self._logfile: + self._logfile.close() + self._logfile = None + + def handle_read(self): + """process arriving characters into in memory _buffer""" + try: + data = asyncore.dispatcher.recv(self, 1) + # latin1 is needed since there are some chars + # we are receiving that cannot be encoded to utf-8 + # such as 0xe2, 0x80, 0xA6. + string = data.decode("latin1") + except: + print("Exception seen.") + traceback.print_exc() + return + if self._logfile: + self._logfile.write("{}".format(string)) + self._logfile.flush() + for c in string: + self._buffer.extend(c) + + def recv(self, n=1, sleep_delay_s=0.1): + """Return chars from in memory buffer""" + start_time = time.time() + while len(self._buffer) < n: + time.sleep(sleep_delay_s) + elapsed_sec = time.time() - start_time + if elapsed_sec > self._recv_timeout_sec: + raise socket.timeout + chars = ''.join([self._buffer.popleft() for i in range(n)]) + # We choose to use latin1 to remain consistent with + # handle_read() and give back the same data as the user would + # receive if they were reading directly from the + # socket w/o our intervention. + return chars.encode("latin1") + + def set_blocking(self): + """Maintain compatibility with socket API""" + pass + + def settimeout(self, seconds): + """Set current timeout on recv""" + self._recv_timeout_sec = seconds diff --git a/python/qemu/machine.py b/python/qemu/machine.py index 041c615052e..c25f0b42cf6 100644 --- a/python/qemu/machine.py +++ b/python/qemu/machine.py @@ -26,6 +26,7 @@ import socket import tempfile from typing import Optional, Type from types import TracebackType +from qemu.console_socket import ConsoleSocket from . import qmp @@ -75,7 +76,8 @@ class QEMUMachine: def __init__(self, binary, args=None, wrapper=None, name=None, test_dir="/var/tmp", monitor_address=None, - socket_scm_helper=None, sock_dir=None): + socket_scm_helper=None, sock_dir=None, + drain_console=False, console_log=None): ''' Initialize a QEMUMachine @@ -86,6 +88,9 @@ class QEMUMachine: @param test_dir: where to create socket and log file @param monitor_address: address for QMP monitor @param socket_scm_helper: helper program, required for send_fd_scm() + @param sock_dir: where to create socket (overrides test_dir for sock) + @param console_log: (optional) path to console log file + @param drain_console: (optional) True to drain console socket to buffer @note: Qemu process is not started until launch() is used. ''' if args is None: @@ -122,6 +127,12 @@ class QEMUMachine: self._console_address = None self._console_socket = None self._remove_files = [] + self._console_log_path = console_log + if self._console_log_path: + # In order to log the console, buffering needs to be enabled. + self._drain_console = True + else: + self._drain_console = drain_console def __enter__(self): return self @@ -580,7 +591,11 @@ class QEMUMachine: Returns a socket connected to the console """ if self._console_socket is None: - self._console_socket = socket.socket(socket.AF_UNIX, - socket.SOCK_STREAM) - self._console_socket.connect(self._console_address) + if self._drain_console: + self._console_socket = ConsoleSocket(self._console_address, + file=self._console_log_path) + else: + self._console_socket = socket.socket(socket.AF_UNIX, + socket.SOCK_STREAM) + self._console_socket.connect(self._console_address) return self._console_socket From patchwork Wed Jul 1 13:56:25 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Alex_Benn=C3=A9e?= X-Patchwork-Id: 192169 Delivered-To: patch@linaro.org Received: by 2002:a92:d244:0:0:0:0:0 with SMTP id v4csp537438ilg; Wed, 1 Jul 2020 07:19:05 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyu8SimyI/QG6fXtX8f+aqT89lAX2viBlusvncutoQJkSfodrv7xB2gcp87/0gl+jF+uamt X-Received: by 2002:a25:9706:: with SMTP id d6mr37155916ybo.220.1593613145218; Wed, 01 Jul 2020 07:19:05 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1593613145; cv=none; d=google.com; s=arc-20160816; b=d1PCz9JLi4YizcJADFhxi3/x9TlbySCb8vawGK9FvL1s0jGzL/j+16xN/lpoSNWd7C rXzrQeozdqdm8GvA5IkvzMgJxjqbeXcIaU3EHf3NVikE1kRkQWICKU0umMRqvTUWhqyA DV2GLwKUIMSMSnrez7W2dphURHMFtn+d1hv92ydAQImh9eZyoUa0GG0aJgX5i50KYKEA MyJmkjHr82qFeOY1/PWRBuPTo9LSdNumuoZBJRno+nmyZlG+5szP/iXJXoY9ytSC5DLl KXKaFF1i6/pz1UKDNXjItt4NJAUrB9l2nHio4w4CffCC7CEczScrDpDTpsxFy9gDKrve BmWA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:cc:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=5xSn2L6kzBKcKjTR8zPwxbT757SBhdGuGZ/3k/jBdz8=; b=tF0HBuIcJh4kQnz57i1iWOfXJOZrUuMpr+hN2R8DcLsJJCJ5ti63bhX0Gmzhgc3B1G UMZ6SoWoOd2b5NW3oCZesC6GAZAkbqmOmdmPZX3zp8u4R2J0n+K0mVRn76m4yJAL10ks 9mqfO9Y2/taaig6TSlwPXr02XwWLma0QcboMjlM65WoA+88yYHIU97B5IRkgpjku31tJ dCzIlLIT3jk6gXjrkEiyXV6ZZ3o1Gvk9aM5FLFE1Su0EnoptJle0DqFYdOZz71iMVWoU ihXhViMxIE4rkKy/bvHVNYUTl/8PVAm7CaXYpzwUCHigOCzoKeX/payxJENCBpqwc+eA 6V2g== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=UN8Qvevy; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id t18si5758263ybl.316.2020.07.01.07.19.05 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Wed, 01 Jul 2020 07:19:05 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=UN8Qvevy; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1]:57140 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jqdZo-0005Ko-JY for patch@linaro.org; Wed, 01 Jul 2020 10:19:04 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:35354) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jqdUX-0006b5-Vb for qemu-devel@nongnu.org; Wed, 01 Jul 2020 10:13:39 -0400 Received: from mail-wm1-x342.google.com ([2a00:1450:4864:20::342]:36988) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1jqdUR-0000AA-Os for qemu-devel@nongnu.org; Wed, 01 Jul 2020 10:13:37 -0400 Received: by mail-wm1-x342.google.com with SMTP id o2so23435261wmh.2 for ; Wed, 01 Jul 2020 07:13:31 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=5xSn2L6kzBKcKjTR8zPwxbT757SBhdGuGZ/3k/jBdz8=; b=UN8QvevyH/p/8t8XtM/ztNOtUU3yvM11c97zCjUg/T+qF3R+XahA9xINEahWxGfKTn 2fo/xkoJircuU80TDTxqdTWXroOc84NbdyVU14j1G1T3MjLFw1ksoTxj3C8tmbBElj2T ehlawyCU+18TcyghrtxeRF+S2UVh8gU6xK0rCQw74BHBsGFDJbapPGSOSg16hjdVORzC ZY/aksN6Hto6ZOfTkpSU6sxgD1hRIbCdPe77JoPwDmsutc5PSp2rt2k5SroDVJqNgXxS C+0mA/xIIDBWDBJNedNrJCEihzKh1bz3RXGnRKF9k0cgZ7ZfFtB/Tl/GnCCrF+31x5Vw SkbQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=5xSn2L6kzBKcKjTR8zPwxbT757SBhdGuGZ/3k/jBdz8=; b=TshUlb9H7JI+8SPjqycRUvW4KmN5adW8RjdXomnjRTgBDfz6G0N9TcVyR5Del+kTQ8 CB0Cj0+Scnv+1xh7bqlG/Ip5GMIewr/ZZ6ckERLhKdfEpFNcrUk/R9tKX3HilhQDydz5 id1YUWz8Yjw54gS1lQBPSS0rlU4aDFP/f55vVkRHlrq36vVE0ZYRPRsg1w/B3t0Jmu6r Ei8xDBUeFmvVjoXjo2QPK4+u6ied/EhdqoBOM48J8HBODvOxFSxaqVkwACF2J0B4Gtd6 WnFiamPHTse7EUQR3lMisjdA4AjbTgYsZIctRruvlLmtGTs5HJOfPLMO4BTCUkhOpgVZ 92RA== X-Gm-Message-State: AOAM531mm7nTrZSSCRliCeTov65NBgFkWWI0JpxRW2eS0G9omi/tpXFn vmOKpeWRHLM/ZHgKLgR/i19/5w== X-Received: by 2002:a1c:7306:: with SMTP id d6mr18276656wmb.113.1593612810092; Wed, 01 Jul 2020 07:13:30 -0700 (PDT) Received: from zen.linaroharston ([51.148.130.216]) by smtp.gmail.com with ESMTPSA id v18sm7970236wrv.49.2020.07.01.07.13.27 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 01 Jul 2020 07:13:27 -0700 (PDT) Received: from zen.lan (localhost [127.0.0.1]) by zen.linaroharston (Postfix) with ESMTP id 2861B1FF9C; Wed, 1 Jul 2020 14:56:54 +0100 (BST) From: =?utf-8?q?Alex_Benn=C3=A9e?= To: qemu-devel@nongnu.org Subject: [PATCH v4 13/40] tests/vm: Add workaround to consume console Date: Wed, 1 Jul 2020 14:56:25 +0100 Message-Id: <20200701135652.1366-14-alex.bennee@linaro.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20200701135652.1366-1-alex.bennee@linaro.org> References: <20200701135652.1366-1-alex.bennee@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::342; envelope-from=alex.bennee@linaro.org; helo=mail-wm1-x342.google.com X-detected-operating-system: by eggs.gnu.org: No matching host in p0f cache. That's all we know. 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, URIBL_BLOCKED=0.001 autolearn=_AUTOLEARN X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: fam@euphon.net, berrange@redhat.com, Robert Foley , =?utf-8?q?Alex_Benn=C3=A9e?= , richard.henderson@linaro.org, f4bug@amsat.org, =?utf-8?q?Philippe_Mat?= =?utf-8?q?hieu-Daud=C3=A9?= , cota@braap.org, Peter Puhov , aurelien@aurel32.net Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: "Qemu-devel" From: Robert Foley This adds support to basevm.py so that we always drain the console chars. This makes use of support added in an earlier commit that allows QEMUMachine to use the ConsoleSocket. This is a workaround we found was needed since there is a known issue where QEMU will hang waiting for console characters to be consumed. We also added the option of logging the console to a file. LOG_CONSOLE=1 will now log the output to a file. Signed-off-by: Robert Foley Reviewed-by: Peter Puhov Acked-by: Alex Bennée Signed-off-by: Alex Bennée Message-Id: <20200601211421.1277-10-robert.foley@linaro.org> --- tests/vm/Makefile.include | 4 ++++ tests/vm/basevm.py | 21 +++++++++++++++++++-- 2 files changed, 23 insertions(+), 2 deletions(-) -- 2.20.1 diff --git a/tests/vm/Makefile.include b/tests/vm/Makefile.include index 39f918a430a..f21948c46a5 100644 --- a/tests/vm/Makefile.include +++ b/tests/vm/Makefile.include @@ -49,6 +49,7 @@ endif @echo ' EXTRA_CONFIGURE_OPTS="..."' @echo " J=[0..9]* - Override the -jN parameter for make commands" @echo " DEBUG=1 - Enable verbose output on host and interactive debugging" + @echo " LOG_CONSOLE=1 - Log console to file in: ~/.cache/qemu-vm " @echo " V=1 - Enable verbose ouput on host and guest commands" @echo " QEMU_LOCAL=1 - Use QEMU binary local to this build." @echo " QEMU=/path/to/qemu - Change path to QEMU binary" @@ -75,6 +76,7 @@ $(IMAGES_DIR)/%.img: $(SRC_PATH)/tests/vm/% \ $(if $(GENISOIMAGE),--genisoimage $(GENISOIMAGE)) \ $(if $(QEMU_LOCAL),--build-path $(BUILD_DIR)) \ $(if $(EFI_AARCH64),--efi-aarch64 $(EFI_AARCH64)) \ + $(if $(LOG_CONSOLE),--log-console) \ --image "$@" \ --force \ --build-image $@, \ @@ -91,6 +93,7 @@ vm-build-%: $(IMAGES_DIR)/%.img $(if $(V),--verbose) \ $(if $(QEMU_LOCAL),--build-path $(BUILD_DIR)) \ $(if $(EFI_AARCH64),--efi-aarch64 $(EFI_AARCH64)) \ + $(if $(LOG_CONSOLE),--log-console) \ --image "$<" \ $(if $(BUILD_TARGET),--build-target $(BUILD_TARGET)) \ --snapshot \ @@ -114,6 +117,7 @@ vm-boot-ssh-%: $(IMAGES_DIR)/%.img $(if $(V)$(DEBUG), --debug) \ $(if $(QEMU_LOCAL),--build-path $(BUILD_DIR)) \ $(if $(EFI_AARCH64),--efi-aarch64 $(EFI_AARCH64)) \ + $(if $(LOG_CONSOLE),--log-console) \ --image "$<" \ --interactive \ false, \ diff --git a/tests/vm/basevm.py b/tests/vm/basevm.py index f716798b405..04d083409a5 100644 --- a/tests/vm/basevm.py +++ b/tests/vm/basevm.py @@ -117,6 +117,11 @@ class BaseVM(object): "w").write(self._config['ssh_pub_key']) self.debug = args.debug + self._console_log_path = None + if args.log_console: + self._console_log_path = \ + os.path.join(os.path.expanduser("~/.cache/qemu-vm"), + "{}.install.log".format(self.name)) self._stderr = sys.stderr self._devnull = open(os.devnull, "w") if self.debug: @@ -271,7 +276,13 @@ class BaseVM(object): args += self._data_args + extra_args + self._config['extra_args'] logging.debug("QEMU args: %s", " ".join(args)) qemu_path = get_qemu_path(self.arch, self._build_path) - guest = QEMUMachine(binary=qemu_path, args=args) + + # Since console_log_path is only set when the user provides the + # log_console option, we will set drain_console=True so the + # console is always drained. + guest = QEMUMachine(binary=qemu_path, args=args, + console_log=self._console_log_path, + drain_console=True) guest.set_machine(self._config['machine']) guest.set_console() try: @@ -285,6 +296,8 @@ class BaseVM(object): raise atexit.register(self.shutdown) self._guest = guest + # Init console so we can start consuming the chars. + self.console_init() usernet_info = guest.qmp("human-monitor-command", command_line="info usernet") self.ssh_port = None @@ -296,7 +309,9 @@ class BaseVM(object): raise Exception("Cannot find ssh port from 'info usernet':\n%s" % \ usernet_info) - def console_init(self, timeout = 120): + def console_init(self, timeout = None): + if timeout == None: + timeout = self.socket_timeout vm = self._guest vm.console_socket.settimeout(timeout) self.console_raw_path = os.path.join(vm._temp_dir, @@ -578,6 +593,8 @@ def parse_args(vmcls): parser.add_option("--efi-aarch64", default="/usr/share/qemu-efi-aarch64/QEMU_EFI.fd", help="Path to efi image for aarch64 VMs.") + parser.add_option("--log-console", action="store_true", + help="Log console to file.") parser.disable_interspersed_args() return parser.parse_args() From patchwork Wed Jul 1 13:56:26 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Alex_Benn=C3=A9e?= X-Patchwork-Id: 192161 Delivered-To: patch@linaro.org Received: by 2002:a92:d244:0:0:0:0:0 with SMTP id v4csp533130ilg; Wed, 1 Jul 2020 07:14:08 -0700 (PDT) X-Google-Smtp-Source: ABdhPJz42joxTo869Nvr2TldDytidNaN2GCXZZf3YrjgC5jGIZqAguAJyqN5BYQrA94iIrXPoqyP X-Received: by 2002:a25:d6c1:: with SMTP id n184mr41795279ybg.303.1593612848572; Wed, 01 Jul 2020 07:14:08 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1593612848; cv=none; d=google.com; s=arc-20160816; b=CpcKX/48U73KdHRrBEbSxOQODAvViybDFN26c1Gc7N3d9C2xPRwktOmAfvoPl21gPk MJ6fmcQ7be44IpBF624aJaNTz6qYmjQHziG25MQQxsczDUiCx5tsGBL9ipr/JB+I0Vnz FtAOSToLDUaHzbaAVQNOfba7K3VGJ3DLX3m/xUDGDqa9K3efvUk9owSZQfByRlvzvWT9 jLZ/O8wcwDNp4vWZaNpc1xfjm95yi/8BeYSB9nelB5789JcSWEbKWD7FQ7BEy+XDe0kI MoZL24RCAcg+vRFi8ebYdmkfd8fpCw033oTTcQKvwytbOlSQOES1y/Tx5bnKiwc1zPtQ OSzw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:cc:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=sygc/Hw6fwtICc5dsEJZsfgG0asRPmeTFs6oktvnw3o=; b=i/OOsSWvxFQr1vpRcs0Ap1WR9kKF6VN1+Vcf11I6gnV3lO4HnQ9rm8CRBQlkOBZlCy UJEfOk2pTDn2MuECJ84oGG51HCB8nxtQBsUd7EG3updsvBNI2S6llAPdazKqHA2Pfzh7 wZLR+sfUrr/8K4w/KcbzpXnYbyjr8AEtsU7sOD/+Eoi7hiGAvBVvBIstiC7tr+wQvaPV 9h1DOYnNr428QhIh6agueWmw3fa/IpqVLB2lqP5uf07lSdJsTKpmNIz4jdODVEDpZFcG 92jDU+nRlGTljuOY5R0CuDfGKGE5VY42kfeyIMufvPomzAyYga7QTRPK4w3IUszY0LsZ JShw== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=hEJKumSL; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id m64si5879635ybm.304.2020.07.01.07.14.08 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Wed, 01 Jul 2020 07:14:08 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=hEJKumSL; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1]:38686 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jqdV2-0005zp-0W for patch@linaro.org; Wed, 01 Jul 2020 10:14:08 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:60834) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jqdKs-0004r1-HR for qemu-devel@nongnu.org; Wed, 01 Jul 2020 10:03:38 -0400 Received: from mail-wr1-x441.google.com ([2a00:1450:4864:20::441]:33293) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1jqdKq-0006pU-8k for qemu-devel@nongnu.org; Wed, 01 Jul 2020 10:03:38 -0400 Received: by mail-wr1-x441.google.com with SMTP id f18so15926434wrs.0 for ; Wed, 01 Jul 2020 07:03:35 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=sygc/Hw6fwtICc5dsEJZsfgG0asRPmeTFs6oktvnw3o=; b=hEJKumSL8s1zcrxYe9HpeFavd7BSWgdHT+xUxjaQPDp+YEHfPGS5bTXzUBJ2K1Ai4d kwLS9hGuTxeY9lEdifXJFBK6PSgswQ/AABLcsVwRIAwUlzaw6wRhoX7LNSuR0DDzbJSj YyeDVBeMtqIxYubyoQQDyxmtKdJ2TbU6lzudjWtzG1wJh2OeAXuecIUVfdrcQDTTzPdq uTlfqyMrFM2+nJinEdWkkpIa20wbRu9wNeIm30rqIv9lLpmPd9wPfhRaaRhp/AF4HQXu 9rJLtvBfPY+p0oGr+DZqUcKsNaMx64EMkUNOAtCr2ByKxDVIjSLZeIkIGoWbpT4AiXMs jLRQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=sygc/Hw6fwtICc5dsEJZsfgG0asRPmeTFs6oktvnw3o=; b=SxcZ+rFgTPPDOKgdCPvqR7S4+O8F77UvYXFWF1WUOgkDlBcd1sz7XzX6yPqpM0vDxm HZkB2saadJT22lR/c1av/qjG/GxeD9uOfMgHx/8M1a5kjJjYp72qIFxM6td2BcgcqH/Q OTgPYUUw0aek9kAQuiilBsEdYkYvyZny70qRmLlnYWt2XNcIwLhL7pvYctpKW0gFqY9G VzHuzSzUnNTSVtpp9D9GMgcrD3brDMC2wd+jQOeYIRjm0h+kDJpJP9cwjYTCy1gTzmSQ dqMcwKnO0lbkFfSe4rfksalGLYuB9iV2Dvx/I7ec4zhhpfNYEg0UAH0rUl9o86G2HLcM j4hQ== X-Gm-Message-State: AOAM530Q54Qbw5IWNCToJYja8jJuzr1ye6Q8wXW6S2HL8+CSkLzAc0KG eCorZYxN9/0HXwL7JXQc/pXu5g== X-Received: by 2002:a5d:444e:: with SMTP id x14mr25745822wrr.279.1593612214789; Wed, 01 Jul 2020 07:03:34 -0700 (PDT) Received: from zen.linaroharston ([51.148.130.216]) by smtp.gmail.com with ESMTPSA id g195sm7530342wme.38.2020.07.01.07.03.28 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 01 Jul 2020 07:03:32 -0700 (PDT) Received: from zen.lan (localhost [127.0.0.1]) by zen.linaroharston (Postfix) with ESMTP id 3FA641FF9D; Wed, 1 Jul 2020 14:56:54 +0100 (BST) From: =?utf-8?q?Alex_Benn=C3=A9e?= To: qemu-devel@nongnu.org Subject: [PATCH v4 14/40] tests/vm: switch from optsparse to argparse Date: Wed, 1 Jul 2020 14:56:26 +0100 Message-Id: <20200701135652.1366-15-alex.bennee@linaro.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20200701135652.1366-1-alex.bennee@linaro.org> References: <20200701135652.1366-1-alex.bennee@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::441; envelope-from=alex.bennee@linaro.org; helo=mail-wr1-x441.google.com X-detected-operating-system: by eggs.gnu.org: No matching host in p0f cache. That's all we know. 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, URIBL_BLOCKED=0.001 autolearn=_AUTOLEARN X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: fam@euphon.net, berrange@redhat.com, Robert Foley , =?utf-8?q?Alex_Benn=C3=A9e?= , richard.henderson@linaro.org, f4bug@amsat.org, =?utf-8?q?Philippe_Mat?= =?utf-8?q?hieu-Daud=C3=A9?= , cota@braap.org, aurelien@aurel32.net Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: "Qemu-devel" optparse has been deprecated since version 3.2 and argparse is the blessed replacement. Take the opportunity to enhance our help output showing defaults when called. Signed-off-by: Alex Bennée Reviewed-by: Daniel P. Berrangé Reviewed-by: Robert Foley --- v2 - add explicit parser.add_argument("commands", nargs="*") v4 - fixup call to parse_args in aarch64vm.py --- tests/vm/aarch64vm.py | 2 +- tests/vm/basevm.py | 93 ++++++++++++++++++++++--------------------- 2 files changed, 49 insertions(+), 46 deletions(-) -- 2.20.1 diff --git a/tests/vm/aarch64vm.py b/tests/vm/aarch64vm.py index bb04cb19c91..d70ab843b6b 100644 --- a/tests/vm/aarch64vm.py +++ b/tests/vm/aarch64vm.py @@ -46,7 +46,7 @@ def get_config_defaults(vmcls, default_config): def aarch_get_config_defaults(vmcls): """Set the defaults for current version of QEMU.""" config = CURRENT_CONFIG - args, argv = basevm.parse_args(vmcls) + args = basevm.parse_args(vmcls) qemu_path = basevm.get_qemu_path(vmcls.arch, args.build_path) qemu_version = basevm.get_qemu_version(qemu_path) if qemu_version < QEMU_AARCH64_MIN_VERSION: diff --git a/tests/vm/basevm.py b/tests/vm/basevm.py index 04d083409a5..890bbc5549a 100644 --- a/tests/vm/basevm.py +++ b/tests/vm/basevm.py @@ -23,7 +23,7 @@ from qemu.accel import kvm_available from qemu.machine import QEMUMachine import subprocess import hashlib -import optparse +import argparse import atexit import tempfile import shutil @@ -556,54 +556,57 @@ def parse_args(vmcls): else: return 1 - parser = optparse.OptionParser( - description="VM test utility. Exit codes: " - "0 = success, " - "1 = command line error, " - "2 = environment initialization failed, " - "3 = test command failed") - parser.add_option("--debug", "-D", action="store_true", - help="enable debug output") - parser.add_option("--image", "-i", default="%s.img" % vmcls.name, - help="image file name") - parser.add_option("--force", "-f", action="store_true", - help="force build image even if image exists") - parser.add_option("--jobs", type=int, default=get_default_jobs(), - help="number of virtual CPUs") - parser.add_option("--verbose", "-V", action="store_true", - help="Pass V=1 to builds within the guest") - parser.add_option("--build-image", "-b", action="store_true", - help="build image") - parser.add_option("--build-qemu", - help="build QEMU from source in guest") - parser.add_option("--build-target", - help="QEMU build target", default="check") - parser.add_option("--build-path", default=None, - help="Path of build directory, "\ - "for using build tree QEMU binary. ") - parser.add_option("--interactive", "-I", action="store_true", - help="Interactively run command") - parser.add_option("--snapshot", "-s", action="store_true", - help="run tests with a snapshot") - parser.add_option("--genisoimage", default="genisoimage", - help="iso imaging tool") - parser.add_option("--config", "-c", default=None, - help="Provide config yaml for configuration. "\ - "See config_example.yaml for example.") - parser.add_option("--efi-aarch64", - default="/usr/share/qemu-efi-aarch64/QEMU_EFI.fd", - help="Path to efi image for aarch64 VMs.") - parser.add_option("--log-console", action="store_true", - help="Log console to file.") - parser.disable_interspersed_args() + parser = argparse.ArgumentParser( + formatter_class=argparse.ArgumentDefaultsHelpFormatter, + description="Utility for provisioning VMs and running builds", + epilog="""Remaining arguments are passed to the command. + Exit codes: 0 = success, 1 = command line error, + 2 = environment initialization failed, + 3 = test command failed""") + parser.add_argument("--debug", "-D", action="store_true", + help="enable debug output") + parser.add_argument("--image", "-i", default="%s.img" % vmcls.name, + help="image file name") + parser.add_argument("--force", "-f", action="store_true", + help="force build image even if image exists") + parser.add_argument("--jobs", type=int, default=get_default_jobs(), + help="number of virtual CPUs") + parser.add_argument("--verbose", "-V", action="store_true", + help="Pass V=1 to builds within the guest") + parser.add_argument("--build-image", "-b", action="store_true", + help="build image") + parser.add_argument("--build-qemu", + help="build QEMU from source in guest") + parser.add_argument("--build-target", + help="QEMU build target", default="check") + parser.add_argument("--build-path", default=None, + help="Path of build directory, "\ + "for using build tree QEMU binary. ") + parser.add_argument("--interactive", "-I", action="store_true", + help="Interactively run command") + parser.add_argument("--snapshot", "-s", action="store_true", + help="run tests with a snapshot") + parser.add_argument("--genisoimage", default="genisoimage", + help="iso imaging tool") + parser.add_argument("--config", "-c", default=None, + help="Provide config yaml for configuration. "\ + "See config_example.yaml for example.") + parser.add_argument("--efi-aarch64", + default="/usr/share/qemu-efi-aarch64/QEMU_EFI.fd", + help="Path to efi image for aarch64 VMs.") + parser.add_argument("--log-console", action="store_true", + help="Log console to file.") + parser.add_argument("commands", nargs="*", help="""Remaining + commands after -- are passed to command inside the VM""") + return parser.parse_args() def main(vmcls, config=None): try: if config == None: config = {} - args, argv = parse_args(vmcls) - if not argv and not args.build_qemu and not args.build_image: + args = parse_args(vmcls) + if not args.commands and not args.build_qemu and not args.build_image: print("Nothing to do?") return 1 config = parse_config(config, args) @@ -619,12 +622,12 @@ def main(vmcls, config=None): if args.build_qemu: vm.add_source_dir(args.build_qemu) cmd = [vm.BUILD_SCRIPT.format( - configure_opts = " ".join(argv), + configure_opts = " ".join(args.commands), jobs=int(args.jobs), target=args.build_target, verbose = "V=1" if args.verbose else "")] else: - cmd = argv + cmd = args.commands img = args.image if args.snapshot: img += ",snapshot=on" From patchwork Wed Jul 1 13:56:27 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Alex_Benn=C3=A9e?= X-Patchwork-Id: 192149 Delivered-To: patch@linaro.org Received: by 2002:a92:d244:0:0:0:0:0 with SMTP id v4csp526143ilg; Wed, 1 Jul 2020 07:06:23 -0700 (PDT) X-Google-Smtp-Source: ABdhPJygYnIvkmJ1tonDOJ6ECcdbKfESdL88DHoAf5WFA/1YfuwGdyrESZd80LgJg57fvFqdFQQF X-Received: by 2002:a25:e481:: with SMTP id b123mr38221654ybh.126.1593612383207; Wed, 01 Jul 2020 07:06:23 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1593612383; cv=none; d=google.com; s=arc-20160816; b=X3LU5BdVKvWfwMxsGljhWKXr44k5lgEvkPg++2As34dufMYy4avCGK38hVjYWwpT+N qRVPu1cjun7gc+yToKjzQP4ZT1Ektl2T5eu06yotFBXtBj0cmfxEylG0rwAjRB+bUHwD lm1Geqx0ZzgX7Pm1Omw51EFWtid2iEYRZYy9MzeYfq3RDTWPNvSvIMa5e3zJYMWqRwN2 dgTxSbKgEli/nnwZCtTnJ2qtaF4K97JnrCSsekYxnyHFgP70/RJX18+5VdBPpe3P/FW9 vigDGSJt57OkbMmYfEaGgn85ikqPHZy9QvkI1Jw3Ybo8iCDkigOtErbR0poRGCCENN0Y cAgQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:cc:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=utjQK07eZNS2y1B+oG+Ze8AGzZ6ibCv0Se22YqtS0r0=; b=CeKK8xNOVsxSA0YzqwiPGEYZhxFJuSMeye8r0QCHou/HcdJRcjuxTddPaaiDGL/588 fnTbIKbYcXiLZngDvB1U46b1a36yTq0plYEdVu1cScdLdaKFT7iCDnBurm+kufQhocz2 nODYxu4viPlZLN2jhYZ32Lg2SjvRCiJQHxxDKuMdK2aHjnwMQw2HQ9Xw2f44dJONhX2f M94kWX46XlxXiSmt46Kyw9UtTih25ksgtac18BCyh28Vo8r8HVD3z8jLINE4H60Y5qop +dSgulW3nTLNt3eVdz6K78Vln34w5uyzvDts5759p7CILZvIH8o4BlBMTMuzUp6ADiBW //6Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=Ad46nvnV; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id y16si5883363yby.400.2020.07.01.07.06.23 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Wed, 01 Jul 2020 07:06:23 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=Ad46nvnV; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1]:34546 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jqdNW-0000tS-I4 for patch@linaro.org; Wed, 01 Jul 2020 10:06:22 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:60734) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jqdKl-0004ay-TA for qemu-devel@nongnu.org; Wed, 01 Jul 2020 10:03:31 -0400 Received: from mail-wr1-x442.google.com ([2a00:1450:4864:20::442]:40174) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1jqdKk-0006og-4F for qemu-devel@nongnu.org; Wed, 01 Jul 2020 10:03:31 -0400 Received: by mail-wr1-x442.google.com with SMTP id h5so23977259wrc.7 for ; Wed, 01 Jul 2020 07:03:29 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=utjQK07eZNS2y1B+oG+Ze8AGzZ6ibCv0Se22YqtS0r0=; b=Ad46nvnVhRJa7GOwUF6AnPDsT5GSEkYL0Xv32G6ZbRoqanH2T5w+tMFHjZm24ISEl2 zkD3Nwp5TcS/+d5bK3IPlpGcjW++hW1STGIGqDM1WavtxNrcbCIC/fFi3CcT+S64Ir9x RDk2gL+he4GlclDc9PqsdxJxZYGF7Ztwd598Z5g8Lfs+bwe9hAp+BgvmMavy9iwjq2/Y QYDdsWpNwZvjyuZlKKymW70JIFidsUBXN8y0zBAMzLjkEF1GLGt263qGGqaTfUIgnONu 5mpaM8h5v7yDcC2n3ylirnCjCqMTWW3FjZVvECxHGZ77DSjVrp8u0AthxU0CPasp0cOj ArDQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=utjQK07eZNS2y1B+oG+Ze8AGzZ6ibCv0Se22YqtS0r0=; b=tZa55pEocEWkrb45gemwN/rymCqU4EAfrKAwugQyou6WgmOhX5E7P3bjZr4d0LQD2s aHrnm8RlUs4psmKbret1PkcBUQpT26pc0PHwan78GmHolqCECDOYnUV/OFhyojhOfaKG 2/hHuXjv0uladNatnlRTrRunuZBekJpo5TKuWZs1PnZAU2u6+YwLchwu/o79xzDLI6h1 wpTF4dl8Ox8dWletPMFsTTo339DYUngwL2GGvjOw/9GriY/D/IrxvwYyZ8/CYAbx3TzL lEAXPIv7ZkwiXUuBJiEhzsJp9NwwsYNxAgWK+ghwoQ+TVKwGQNAC9E9uz1Jo/TXlf2nj LX2w== X-Gm-Message-State: AOAM531MjHhoXLv/rZe9wsCRKdJuhU1D4Yr8ncEjxm5PfjGWdIL07VbG OnPsb5lgGgHoDsrVZFWMm3sr2A== X-Received: by 2002:adf:f34e:: with SMTP id e14mr26740295wrp.299.1593612208754; Wed, 01 Jul 2020 07:03:28 -0700 (PDT) Received: from zen.linaroharston ([51.148.130.216]) by smtp.gmail.com with ESMTPSA id u20sm7006588wmc.44.2020.07.01.07.03.26 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 01 Jul 2020 07:03:26 -0700 (PDT) Received: from zen.lan (localhost [127.0.0.1]) by zen.linaroharston (Postfix) with ESMTP id 54CCD1FF9E; Wed, 1 Jul 2020 14:56:54 +0100 (BST) From: =?utf-8?q?Alex_Benn=C3=A9e?= To: qemu-devel@nongnu.org Subject: [PATCH v4 15/40] tests/vm: allow us to take advantage of MTTCG Date: Wed, 1 Jul 2020 14:56:27 +0100 Message-Id: <20200701135652.1366-16-alex.bennee@linaro.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20200701135652.1366-1-alex.bennee@linaro.org> References: <20200701135652.1366-1-alex.bennee@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::442; envelope-from=alex.bennee@linaro.org; helo=mail-wr1-x442.google.com X-detected-operating-system: by eggs.gnu.org: No matching host in p0f cache. That's all we know. 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, URIBL_BLOCKED=0.001 autolearn=_AUTOLEARN X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: fam@euphon.net, berrange@redhat.com, Robert Foley , =?utf-8?q?Alex_Benn=C3=A9e?= , richard.henderson@linaro.org, f4bug@amsat.org, =?utf-8?q?Philippe_Mat?= =?utf-8?q?hieu-Daud=C3=A9?= , cota@braap.org, aurelien@aurel32.net Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: "Qemu-devel" We currently limit TCG guests to -smp 1 but now we have added some aarch64 guests we can do better when running on x86_64 hardware. Raise the limit for TCG guests when it is safe to do so. Signed-off-by: Alex Bennée Reviewed-by: Robert Foley Reviewed-by: Philippe Mathieu-Daudé --- v4 - only attempt compute a bigger default_jobs is multiprocessing.cpu_count > 1 --- tests/vm/basevm.py | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) -- 2.20.1 diff --git a/tests/vm/basevm.py b/tests/vm/basevm.py index 890bbc5549a..21f46d1957d 100644 --- a/tests/vm/basevm.py +++ b/tests/vm/basevm.py @@ -551,8 +551,15 @@ def parse_config(config, args): def parse_args(vmcls): def get_default_jobs(): - if kvm_available(vmcls.arch): - return multiprocessing.cpu_count() // 2 + if multiprocessing.cpu_count() > 1: + if kvm_available(vmcls.arch): + return multiprocessing.cpu_count() // 2 + elif os.uname().machine == "x86_64" and \ + vmcls.arch in ["aarch64", "x86_64", "i386"]: + # MTTCG is available on these arches and we can allow + # more cores. but only up to a reasonable limit. User + # can always override these limits with --jobs. + return min(multiprocessing.cpu_count() // 2, 8) else: return 1 From patchwork Wed Jul 1 13:56:28 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Alex_Benn=C3=A9e?= X-Patchwork-Id: 192154 Delivered-To: patch@linaro.org Received: by 2002:a92:d244:0:0:0:0:0 with SMTP id v4csp529026ilg; Wed, 1 Jul 2020 07:09:34 -0700 (PDT) X-Google-Smtp-Source: ABdhPJz4wFbw49D5GwcMHCWYEZA/Hc26i/BIjrUkLe3Ctu1yxVlBetueNOVhwi2vzBzam3EadYQY X-Received: by 2002:a25:688:: with SMTP id 130mr43164922ybg.466.1593612574474; Wed, 01 Jul 2020 07:09:34 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1593612574; cv=none; d=google.com; s=arc-20160816; b=VNDQ6J2sDm5/1IEOwqi62Zdr3OOFqIeeK000pe/SykYnpAvjKoghkSKslO1aPwBArz LXMozwdDt4KfiEFlMfjLZyQ2R6LpFilJV55cS0YWQiKbVKk648sebHLq9dE7pdm9Cctz yR5f9Z2AU/l2gYo5VnVjspJpFlBvpZFT8Mwfa9ewkESLdQFuCnGwal/9GnqFIPDdh1vK 9R6MO7AF/kIO5EN66uAuYy9tnnSKULcNWMefQF/1HECu7FgOm2jA/Akg2MaH9gZ5IsCB mCWu7YFUj3UKrFrlGgdGeDs5iGCOrYXmWtmiYO7vHz0TwfLiBK1JAbWwBm12lP/897q2 DSlQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:cc:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=Hc/GcVPMTlu7EGTBmWJqWp3KNZYqt74iySDJhQWwxVM=; b=CJmfehodr3BQSTHP3yNhzLVBYWQroDAjYHSbNUrjAX/jdoUe/aMzSflnE4Txg0kWWA vifQ3C36iAc1KOP5a8XUW5v2FvNtg9tDKgz8c3nWOLCqWZefuxjH8jyu71o0vE+w+OyZ HzD6WG5Mx5T7ch7LV72SDikm1eVfe5umKwlWnsJfTdKsqLGHL6tdJWmwt/WuzYFCVu2/ wcvKU4gZmPKnjFnwcia1DBj3j1xntoWFzKi+buZKqZ7Cws+6s2eWBQUiW96CZ4HIgD/H b3DFgx0IgoD6nHl78EhiX/A1jOOAq6kUw1o3s71IuyUPZMxmJCV1CAzJdRkQXi2qqM0b WQ/g== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b="doiSvS/A"; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id y16si5604378ybe.197.2020.07.01.07.09.34 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Wed, 01 Jul 2020 07:09:34 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b="doiSvS/A"; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1]:50028 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jqdQb-0007Ha-Sx for patch@linaro.org; Wed, 01 Jul 2020 10:09:33 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:60800) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jqdKq-0004kG-1O for qemu-devel@nongnu.org; Wed, 01 Jul 2020 10:03:36 -0400 Received: from mail-wr1-x443.google.com ([2a00:1450:4864:20::443]:38633) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1jqdKo-0006pA-6b for qemu-devel@nongnu.org; Wed, 01 Jul 2020 10:03:35 -0400 Received: by mail-wr1-x443.google.com with SMTP id z13so23991212wrw.5 for ; Wed, 01 Jul 2020 07:03:33 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=Hc/GcVPMTlu7EGTBmWJqWp3KNZYqt74iySDJhQWwxVM=; b=doiSvS/AcGDxLuuGZbW4HrBh69t+uEpuunpn0adkYBYU3cuD9QSvswtVFIqEzZQzk8 Wc6dBgSZop6cCVG457kKNNSbKxNSqxM9elxj01O+pWq8RP4ytXRjPlKXxkJ+t3PK+eQs iKSx3Ns9Pr9LoSdJVVe6hg7tQvHiiMI4eIxRPNpADdJ72ZZUMDudyWSO1u0hbWUV46wi 26l0UFlRxpLV8m8aLsDWppbjU/ixyRpIIzdfWbhtmEn4y/JoFtoUmzX4LH/9+iCjVKLj EUhP/Il+urPHW/zZxtjx0AnwMiNprMS+hUNVHgCKTcH+sieORX97OVTOVRiTs8lkuj6i mNPQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=Hc/GcVPMTlu7EGTBmWJqWp3KNZYqt74iySDJhQWwxVM=; b=kUXCvvgTAuw6Bc8yo7/IQsIDZTH9giAojqCm3Bxbv8HHrEZ3NKgVk5MO4X76fIm64f pSS6ExEIyFafqPHd1e84VVwX0q8TlMwTBZZexlG50hWlEZaNddbDNa39+LnpRjaKMBh2 R6NMgPwPDnInp5klpq/rOaxYCkqraTBAkwSV0ZCRnqCSEtwYfp3q5oQ5+hVEpLe5Iv8g YJWzmt89TlcS2kGVoO4OSnBlQjQSoFvK3RjBaObHCEF6GyNTeyvilJ8dunXMQCYNiTZo C82emCySFFhI93Pn+lKJm6uOCArhFtaPxxwoXlMuu4DHGmwfBa+NPOFjFGVLyAckDvV6 RHRQ== X-Gm-Message-State: AOAM5320eK1mL8DaBLPvGKGnZOFAaKUK8AfAlwKNSU6N1d0yctaosxsT Pw65j409ykXQfO7kg+qau8JprA== X-Received: by 2002:adf:e484:: with SMTP id i4mr27695045wrm.246.1593612212715; Wed, 01 Jul 2020 07:03:32 -0700 (PDT) Received: from zen.linaroharston ([51.148.130.216]) by smtp.gmail.com with ESMTPSA id x124sm2330081wmx.16.2020.07.01.07.03.26 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 01 Jul 2020 07:03:26 -0700 (PDT) Received: from zen.lan (localhost [127.0.0.1]) by zen.linaroharston (Postfix) with ESMTP id 6A18D1FF9F; Wed, 1 Jul 2020 14:56:54 +0100 (BST) From: =?utf-8?q?Alex_Benn=C3=A9e?= To: qemu-devel@nongnu.org Subject: [PATCH v4 16/40] tests/docker: check for an parameters not empty string Date: Wed, 1 Jul 2020 14:56:28 +0100 Message-Id: <20200701135652.1366-17-alex.bennee@linaro.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20200701135652.1366-1-alex.bennee@linaro.org> References: <20200701135652.1366-1-alex.bennee@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::443; envelope-from=alex.bennee@linaro.org; helo=mail-wr1-x443.google.com X-detected-operating-system: by eggs.gnu.org: No matching host in p0f cache. That's all we know. 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=_AUTOLEARN X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: fam@euphon.net, Peter Maydell , berrange@redhat.com, =?utf-8?q?Alex_Benn=C3=A9e?= , richard.henderson@linaro.org, f4bug@amsat.org, =?utf-8?q?Philippe_Mat?= =?utf-8?q?hieu-Daud=C3=A9?= , cota@braap.org, aurelien@aurel32.net Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: "Qemu-devel" Reported-by: Philippe Mathieu-Daudé Signed-off-by: Alex Bennée Suggested-by: Peter Maydell Reviewed-by: Philippe Mathieu-Daudé --- v4 - if [ $# == 0 ]; then -> if [ $# = 0 ]; then --- tests/docker/common.rc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) -- 2.20.1 diff --git a/tests/docker/common.rc b/tests/docker/common.rc index 02cd67a8c5e..ebc5b97ecf9 100755 --- a/tests/docker/common.rc +++ b/tests/docker/common.rc @@ -47,7 +47,7 @@ build_qemu() check_qemu() { # default to make check unless the caller specifies - if test -z "$@"; then + if [ $# = 0 ]; then INVOCATION="check" else INVOCATION="$@" From patchwork Wed Jul 1 13:56:29 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Alex_Benn=C3=A9e?= X-Patchwork-Id: 192166 Delivered-To: patch@linaro.org Received: by 2002:a92:d244:0:0:0:0:0 with SMTP id v4csp536460ilg; Wed, 1 Jul 2020 07:17:56 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxsy9JlQsrHy78nfSPasiBTpaHtOS2jHhANsUDk89Jo3rnPnsjq8+8nCILz8tsG56OOz9no X-Received: by 2002:a25:686:: with SMTP id 128mr42303682ybg.284.1593613076862; Wed, 01 Jul 2020 07:17:56 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1593613076; cv=none; d=google.com; s=arc-20160816; b=zrVZAvNUISb8HiVFr2gmbPDcEQ3BHBq12WAwxt4JVlMHhjLAACWdZECWEAgaavBaqp Gb5sOfj5Azng0Oj3kEDxopMAKmeZ+ELC9TLBn4X5J1R2AzowlkQHn06yE66tDqaeTQyG s7pp3otjbsq2QzxTlDlVuah3NPc1Ur2b6JgXJ0XVP+uNkrZWQfblN310kwy4h5/4QKus NvtrdEAkoorICyuHTRq/BVSAY9MPlQVHMFtLrgBDxG3YK9pxmLoT+SCUQAnd4akzNTW4 Zhh9N/N11GjrAvBgaNWGxKK4ifYmSzLsyJwV7MSf6HjWMBpO9i6bWoT7M2JmyUqA0BDy IHsA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:cc:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=FuCHGM7iRPlVOeoJ1tjdyPktkHWpC0K3uPbBotufS80=; b=YslB9/2JK89yGUC9uS5yzSM8BPkmeKmHXCAme6BqBY4fSx9DPVLjW4g0W5k/O9RSsz KuZN0alNHsBuZaXGTYh9iQgjKQu/D+P7NP4pwyrcKWSQbbPOGVQQ5qIUs9Q5/akPOQkC mkAxnO6ynBb8sMjg38rynpnZTfc67VAGGOcH+4vwPwUZGGWixKwE4BBYQ/O5y8F8W1Ay UvgIABdHJywuARaN45LXgTNmggWHeC9AWQVFRaos3AMl6SRLzrvSG5Jv7cPyX+0awI/s fHZ8w2TmEd+9GrTOrS2xYbR/CPWs6r+8FRAZjsbUdfyn1gWuRE4xB/PTh1oBSJ0OxcOI 8JQA== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=MlZqqqm9; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id i192si5765154yba.341.2020.07.01.07.17.56 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Wed, 01 Jul 2020 07:17:56 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=MlZqqqm9; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1]:53610 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jqdYi-0003oo-7i for patch@linaro.org; Wed, 01 Jul 2020 10:17:56 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:32780) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jqdL6-0005Mk-9C for qemu-devel@nongnu.org; Wed, 01 Jul 2020 10:03:52 -0400 Received: from mail-wr1-x42e.google.com ([2a00:1450:4864:20::42e]:40623) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1jqdL3-0006ry-EB for qemu-devel@nongnu.org; Wed, 01 Jul 2020 10:03:51 -0400 Received: by mail-wr1-x42e.google.com with SMTP id h5so23978899wrc.7 for ; Wed, 01 Jul 2020 07:03:48 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=FuCHGM7iRPlVOeoJ1tjdyPktkHWpC0K3uPbBotufS80=; b=MlZqqqm9G6O9sqstXhGYxF/OkJndDqcWI//lBY5GYZ5bDUD88A1bXIMjJHdEhRR/zY tZ6mnZ5GuYKDdQ8wjagb4Gzrr+nV04IckwXIO3KXxKBWlAwlrOEmUW78G0uh8AJfx0cO Wwa7VanNuR7m9tLHV5sLm0mM71pTDdDYtdylD2UuQqra/b2lnTV3pPpQ55+B9SpCD5x4 3hmqwGNYgBHr8nT+7yMfhPB+heRUm9ofDti+z3A6iKDc5ZNMtfz1Co+lAOAobEAWbEYR XM+ImJWQqZITaJ9e3R83KGmgaJ0ME07wjoPou1HHvMKYpym2NUi+Zhp7AyLhP3IbYKn7 gMEA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=FuCHGM7iRPlVOeoJ1tjdyPktkHWpC0K3uPbBotufS80=; b=ah9Er5Q26XEULEvhohNA4ZzHukBi9JiDJdjK+YgvHFYXZnjYgYmMSrxrDIxKAtm2B5 tQ5K0L/OBhm5OEJdhX5flZD5PSAIZOv40egKiZ4Ked9o7V6xAxEHVA9aSCX3dU9txKjR l8C7vpxgrAGnjNKdHezBVCrBCirvOdl2TmbTPP5uHKrMvozc9xpvgIxtGBV3CcSVeqwG cnr96/7qvi7ImEqQ9MFPechrZnS8EmzAF2oVu4rjNEvrLBIU53htBLNxueVx0GjSOPbo 3/h09XzgXi8bfhFuqbtpZ+5eCdKf3CLM7lHxQaXe0iAtYc4OyIj1EbQ+mAcQ/TZInczj TnwQ== X-Gm-Message-State: AOAM530KQ/4VDyqA8D3/Yldq2k16CVnQt6bjO0QbWK3SbmSC4xBcPGcW LIeNuiJbz6/QLoSmK2rDBsvYug== X-Received: by 2002:adf:f504:: with SMTP id q4mr26575847wro.163.1593612227606; Wed, 01 Jul 2020 07:03:47 -0700 (PDT) Received: from zen.linaroharston ([51.148.130.216]) by smtp.gmail.com with ESMTPSA id 65sm7992176wma.48.2020.07.01.07.03.33 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 01 Jul 2020 07:03:41 -0700 (PDT) Received: from zen.lan (localhost [127.0.0.1]) by zen.linaroharston (Postfix) with ESMTP id B06ED1FFA5; Wed, 1 Jul 2020 14:56:54 +0100 (BST) From: =?utf-8?q?Alex_Benn=C3=A9e?= To: qemu-devel@nongnu.org Subject: [PATCH v4 17/40] tests/docker: change tag naming scheme of our images Date: Wed, 1 Jul 2020 14:56:29 +0100 Message-Id: <20200701135652.1366-18-alex.bennee@linaro.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20200701135652.1366-1-alex.bennee@linaro.org> References: <20200701135652.1366-1-alex.bennee@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::42e; envelope-from=alex.bennee@linaro.org; helo=mail-wr1-x42e.google.com X-detected-operating-system: by eggs.gnu.org: No matching host in p0f cache. That's all we know. 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, URIBL_BLOCKED=0.001 autolearn=_AUTOLEARN X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: fam@euphon.net, berrange@redhat.com, =?utf-8?q?Alex_Benn=C3=A9e?= , richard.henderson@linaro.org, f4bug@amsat.org, =?utf-8?q?Philippe_Mat?= =?utf-8?q?hieu-Daud=C3=A9?= , cota@braap.org, aurelien@aurel32.net Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: "Qemu-devel" We've been misusing the tag naming scheme for some time by overloading the post : section with the image type. Really it should be saved for the revision of that particular build. Move the details to the other side so we have: qemu/image-name with the implied :latest version added by the tooling. Suggested-by: Daniel P. Berrangé Signed-off-by: Alex Bennée Reviewed-by: Philippe Mathieu-Daudé --- v2 - fix RUN invocation as well - don't include :latest tag for debian-arm64-cross (implied) v4 - fix up check and compile cases as well - also tweak shippable references --- .shippable.yml | 4 ++-- tests/docker/Makefile.include | 10 +++++----- tests/docker/docker.py | 2 +- tests/docker/dockerfiles/debian-alpha-cross.docker | 2 +- tests/docker/dockerfiles/debian-amd64-cross.docker | 2 +- tests/docker/dockerfiles/debian-amd64.docker | 2 +- tests/docker/dockerfiles/debian-arm64-cross.docker | 2 +- .../docker/dockerfiles/debian-arm64-test-cross.docker | 2 +- tests/docker/dockerfiles/debian-armel-cross.docker | 2 +- tests/docker/dockerfiles/debian-armhf-cross.docker | 2 +- tests/docker/dockerfiles/debian-hppa-cross.docker | 2 +- tests/docker/dockerfiles/debian-m68k-cross.docker | 2 +- tests/docker/dockerfiles/debian-mips-cross.docker | 2 +- tests/docker/dockerfiles/debian-mips64-cross.docker | 2 +- tests/docker/dockerfiles/debian-mips64el-cross.docker | 2 +- tests/docker/dockerfiles/debian-mipsel-cross.docker | 2 +- tests/docker/dockerfiles/debian-powerpc-cross.docker | 2 +- tests/docker/dockerfiles/debian-ppc64-cross.docker | 2 +- tests/docker/dockerfiles/debian-ppc64el-cross.docker | 2 +- tests/docker/dockerfiles/debian-riscv64-cross.docker | 2 +- tests/docker/dockerfiles/debian-s390x-cross.docker | 2 +- tests/docker/dockerfiles/debian-sh4-cross.docker | 2 +- tests/docker/dockerfiles/debian-sparc64-cross.docker | 2 +- tests/docker/dockerfiles/debian-tricore-cross.docker | 2 +- tests/docker/dockerfiles/debian-win32-cross.docker | 2 +- tests/docker/dockerfiles/debian-win64-cross.docker | 2 +- tests/docker/dockerfiles/debian9-mxe.docker | 2 +- tests/tcg/Makefile.qemu | 4 ++-- 28 files changed, 34 insertions(+), 34 deletions(-) -- 2.20.1 diff --git a/.shippable.yml b/.shippable.yml index 2cce7b56890..81905727d14 100644 --- a/.shippable.yml +++ b/.shippable.yml @@ -29,8 +29,8 @@ build: pre_ci: - make docker-image-${IMAGE} V=1 pre_ci_boot: - image_name: qemu - image_tag: ${IMAGE} + image_name: qemu/${IMAGE} + image_tag: latest pull: false options: "-e HOME=/root" ci: diff --git a/tests/docker/Makefile.include b/tests/docker/Makefile.include index 3e3617816ec..e23b4af20ea 100644 --- a/tests/docker/Makefile.include +++ b/tests/docker/Makefile.include @@ -50,12 +50,12 @@ docker-image: ${DOCKER_TARGETS} ifdef SKIP_DOCKER_BUILD docker-image-%: $(DOCKER_FILES_DIR)/%.docker $(call quiet-command, \ - $(DOCKER_SCRIPT) check --quiet qemu:$* $<, \ + $(DOCKER_SCRIPT) check --quiet qemu/$* $<, \ "CHECK", "$*") else docker-image-%: $(DOCKER_FILES_DIR)/%.docker $(call quiet-command,\ - $(DOCKER_SCRIPT) build -t qemu:$* -f $< \ + $(DOCKER_SCRIPT) build -t qemu/$* -f $< \ $(if $V,,--quiet) $(if $(NOCACHE),--no-cache) \ $(if $(NOUSER),,--add-current-user) \ $(if $(EXTRA_FILES),--extra-files $(EXTRA_FILES))\ @@ -75,14 +75,14 @@ docker-binfmt-image-debian-%: $(DOCKER_FILES_DIR)/debian-bootstrap.docker DEB_ARCH=$(DEB_ARCH) \ DEB_TYPE=$(DEB_TYPE) \ $(if $(DEB_URL),DEB_URL=$(DEB_URL),) \ - $(DOCKER_SCRIPT) build qemu:debian-$* $< \ + $(DOCKER_SCRIPT) build qemu/debian-$* $< \ $(if $V,,--quiet) $(if $(NOCACHE),--no-cache) \ $(if $(NOUSER),,--add-current-user) \ $(if $(EXTRA_FILES),--extra-files $(EXTRA_FILES)) \ $(if $(EXECUTABLE),--include-executable=$(EXECUTABLE)), \ "BUILD","binfmt debian-$* (debootstrapped)"), \ $(call quiet-command, \ - $(DOCKER_SCRIPT) check --quiet qemu:debian-$* $< || \ + $(DOCKER_SCRIPT) check --quiet qemu/debian-$* $< || \ { echo "You will need to build $(EXECUTABLE)"; exit 1;},\ "CHECK", "debian-$* exists")) @@ -258,7 +258,7 @@ docker-run: docker-qemu-src docker-run-%: CMD = $(shell echo '$@' | sed -e 's/docker-run-\([^@]*\)@\(.*\)/\1/') docker-run-%: IMAGE = $(shell echo '$@' | sed -e 's/docker-run-\([^@]*\)@\(.*\)/\2/') docker-run-%: - @$(MAKE) docker-run TEST=$(CMD) IMAGE=qemu:$(IMAGE) + @$(MAKE) docker-run TEST=$(CMD) IMAGE=qemu/$(IMAGE) docker-clean: $(call quiet-command, $(DOCKER_SCRIPT) clean) diff --git a/tests/docker/docker.py b/tests/docker/docker.py index e630aae1089..cc6f76caa60 100755 --- a/tests/docker/docker.py +++ b/tests/docker/docker.py @@ -204,7 +204,7 @@ def _dockerfile_preprocess(df): for l in df.splitlines(): if len(l.strip()) == 0 or l.startswith("#"): continue - from_pref = "FROM qemu:" + from_pref = "FROM qemu/" if l.startswith(from_pref): # TODO: Alternatively we could replace this line with "FROM $ID" # where $ID is the image's hex id obtained with diff --git a/tests/docker/dockerfiles/debian-alpha-cross.docker b/tests/docker/dockerfiles/debian-alpha-cross.docker index 74bcabfdb12..10fe30df0dd 100644 --- a/tests/docker/dockerfiles/debian-alpha-cross.docker +++ b/tests/docker/dockerfiles/debian-alpha-cross.docker @@ -3,7 +3,7 @@ # # This docker target builds on the debian Buster base image. # -FROM qemu:debian10 +FROM qemu/debian10 RUN apt update && \ DEBIAN_FRONTEND=noninteractive eatmydata \ diff --git a/tests/docker/dockerfiles/debian-amd64-cross.docker b/tests/docker/dockerfiles/debian-amd64-cross.docker index 5d890419251..870109ef6af 100644 --- a/tests/docker/dockerfiles/debian-amd64-cross.docker +++ b/tests/docker/dockerfiles/debian-amd64-cross.docker @@ -4,7 +4,7 @@ # This docker target is used on non-x86_64 machines which need the # x86_64 cross compilers installed. # -FROM qemu:debian10 +FROM qemu/debian10 MAINTAINER Alex Bennée # Add the foreign architecture we want and install dependencies diff --git a/tests/docker/dockerfiles/debian-amd64.docker b/tests/docker/dockerfiles/debian-amd64.docker index 957f0bc2e79..8fdfd6a6b04 100644 --- a/tests/docker/dockerfiles/debian-amd64.docker +++ b/tests/docker/dockerfiles/debian-amd64.docker @@ -4,7 +4,7 @@ # This docker target builds on the debian Stretch base image. Further # libraries which are not widely available are installed by hand. # -FROM qemu:debian10 +FROM qemu/debian10 MAINTAINER Philippe Mathieu-Daudé RUN apt update && \ diff --git a/tests/docker/dockerfiles/debian-arm64-cross.docker b/tests/docker/dockerfiles/debian-arm64-cross.docker index 09ca0a1ba79..166e24df138 100644 --- a/tests/docker/dockerfiles/debian-arm64-cross.docker +++ b/tests/docker/dockerfiles/debian-arm64-cross.docker @@ -3,7 +3,7 @@ # # This docker target builds on the debian Buster base image. # -FROM qemu:debian10 +FROM qemu/debian10 # Add the foreign architecture we want and install dependencies RUN dpkg --add-architecture arm64 diff --git a/tests/docker/dockerfiles/debian-arm64-test-cross.docker b/tests/docker/dockerfiles/debian-arm64-test-cross.docker index a44e76d9421..53a9012beb8 100644 --- a/tests/docker/dockerfiles/debian-arm64-test-cross.docker +++ b/tests/docker/dockerfiles/debian-arm64-test-cross.docker @@ -3,7 +3,7 @@ # # This docker target builds on the debian Bullseye base image. # -FROM qemu:debian11 +FROM qemu/debian11 # Add the foreign architecture we want and install dependencies RUN dpkg --add-architecture arm64 diff --git a/tests/docker/dockerfiles/debian-armel-cross.docker b/tests/docker/dockerfiles/debian-armel-cross.docker index e3794a61c95..b7b1a3585f8 100644 --- a/tests/docker/dockerfiles/debian-armel-cross.docker +++ b/tests/docker/dockerfiles/debian-armel-cross.docker @@ -3,7 +3,7 @@ # # This docker target builds on the debian Stretch base image. # -FROM qemu:debian10 +FROM qemu/debian10 MAINTAINER Philippe Mathieu-Daudé # Add the foreign architecture we want and install dependencies diff --git a/tests/docker/dockerfiles/debian-armhf-cross.docker b/tests/docker/dockerfiles/debian-armhf-cross.docker index e163b8b9569..25d76188337 100644 --- a/tests/docker/dockerfiles/debian-armhf-cross.docker +++ b/tests/docker/dockerfiles/debian-armhf-cross.docker @@ -3,7 +3,7 @@ # # This docker target builds on the debian Stretch base image. # -FROM qemu:debian10 +FROM qemu/debian10 # Add the foreign architecture we want and install dependencies RUN dpkg --add-architecture armhf diff --git a/tests/docker/dockerfiles/debian-hppa-cross.docker b/tests/docker/dockerfiles/debian-hppa-cross.docker index 5c68b2d3304..3d6c65a3efc 100644 --- a/tests/docker/dockerfiles/debian-hppa-cross.docker +++ b/tests/docker/dockerfiles/debian-hppa-cross.docker @@ -3,7 +3,7 @@ # # This docker target builds on the debian Buster base image. # -FROM qemu:debian10 +FROM qemu/debian10 RUN apt update && \ DEBIAN_FRONTEND=noninteractive eatmydata \ diff --git a/tests/docker/dockerfiles/debian-m68k-cross.docker b/tests/docker/dockerfiles/debian-m68k-cross.docker index 25edc80e9a3..fcb10e35347 100644 --- a/tests/docker/dockerfiles/debian-m68k-cross.docker +++ b/tests/docker/dockerfiles/debian-m68k-cross.docker @@ -3,7 +3,7 @@ # # This docker target builds on the debian Buster base image. # -FROM qemu:debian10 +FROM qemu/debian10 RUN apt update && \ DEBIAN_FRONTEND=noninteractive eatmydata \ diff --git a/tests/docker/dockerfiles/debian-mips-cross.docker b/tests/docker/dockerfiles/debian-mips-cross.docker index 08a8e1c29cc..26c154014db 100644 --- a/tests/docker/dockerfiles/debian-mips-cross.docker +++ b/tests/docker/dockerfiles/debian-mips-cross.docker @@ -3,7 +3,7 @@ # # This docker target builds on the debian Buster base image. # -FROM qemu:debian10 +FROM qemu/debian10 MAINTAINER Philippe Mathieu-Daudé diff --git a/tests/docker/dockerfiles/debian-mips64-cross.docker b/tests/docker/dockerfiles/debian-mips64-cross.docker index 1a79505d696..09c2ba584e5 100644 --- a/tests/docker/dockerfiles/debian-mips64-cross.docker +++ b/tests/docker/dockerfiles/debian-mips64-cross.docker @@ -3,7 +3,7 @@ # # This docker target builds on the debian Buster base image. # -FROM qemu:debian10 +FROM qemu/debian10 RUN apt update && \ DEBIAN_FRONTEND=noninteractive eatmydata \ diff --git a/tests/docker/dockerfiles/debian-mips64el-cross.docker b/tests/docker/dockerfiles/debian-mips64el-cross.docker index 453b53ef72c..c990b683b7a 100644 --- a/tests/docker/dockerfiles/debian-mips64el-cross.docker +++ b/tests/docker/dockerfiles/debian-mips64el-cross.docker @@ -4,7 +4,7 @@ # This docker target builds on the debian Stretch base image. # -FROM qemu:debian10 +FROM qemu/debian10 MAINTAINER Philippe Mathieu-Daudé diff --git a/tests/docker/dockerfiles/debian-mipsel-cross.docker b/tests/docker/dockerfiles/debian-mipsel-cross.docker index 3b6e975c686..0e5dd42d3c4 100644 --- a/tests/docker/dockerfiles/debian-mipsel-cross.docker +++ b/tests/docker/dockerfiles/debian-mipsel-cross.docker @@ -3,7 +3,7 @@ # # This docker target builds on the debian Stretch base image. # -FROM qemu:debian10 +FROM qemu/debian10 MAINTAINER Philippe Mathieu-Daudé diff --git a/tests/docker/dockerfiles/debian-powerpc-cross.docker b/tests/docker/dockerfiles/debian-powerpc-cross.docker index 89dd4fbf870..07e1789650b 100644 --- a/tests/docker/dockerfiles/debian-powerpc-cross.docker +++ b/tests/docker/dockerfiles/debian-powerpc-cross.docker @@ -3,7 +3,7 @@ # # This docker target builds on the debian Buster base image. # -FROM qemu:debian10 +FROM qemu/debian10 RUN apt update && \ DEBIAN_FRONTEND=noninteractive eatmydata \ diff --git a/tests/docker/dockerfiles/debian-ppc64-cross.docker b/tests/docker/dockerfiles/debian-ppc64-cross.docker index 4bf88ab02dd..8efe68874ed 100644 --- a/tests/docker/dockerfiles/debian-ppc64-cross.docker +++ b/tests/docker/dockerfiles/debian-ppc64-cross.docker @@ -2,7 +2,7 @@ # Docker ppc64 cross-compiler target # # This docker target builds on the debian Buster base image. -FROM qemu:debian10 +FROM qemu/debian10 RUN apt update && \ DEBIAN_FRONTEND=noninteractive eatmydata \ diff --git a/tests/docker/dockerfiles/debian-ppc64el-cross.docker b/tests/docker/dockerfiles/debian-ppc64el-cross.docker index cd386f01d93..1146a06be62 100644 --- a/tests/docker/dockerfiles/debian-ppc64el-cross.docker +++ b/tests/docker/dockerfiles/debian-ppc64el-cross.docker @@ -3,7 +3,7 @@ # # This docker target builds on the debian Stretch base image. # -FROM qemu:debian10 +FROM qemu/debian10 # Add the foreign architecture we want and install dependencies RUN dpkg --add-architecture ppc64el && \ diff --git a/tests/docker/dockerfiles/debian-riscv64-cross.docker b/tests/docker/dockerfiles/debian-riscv64-cross.docker index 5e2d6ddb600..2bbff19772a 100644 --- a/tests/docker/dockerfiles/debian-riscv64-cross.docker +++ b/tests/docker/dockerfiles/debian-riscv64-cross.docker @@ -3,7 +3,7 @@ # # This docker target builds on the debian Buster base image. # -FROM qemu:debian10 +FROM qemu/debian10 RUN apt update && \ DEBIAN_FRONTEND=noninteractive eatmydata \ diff --git a/tests/docker/dockerfiles/debian-s390x-cross.docker b/tests/docker/dockerfiles/debian-s390x-cross.docker index 43fe59836f2..9f2ab51eb09 100644 --- a/tests/docker/dockerfiles/debian-s390x-cross.docker +++ b/tests/docker/dockerfiles/debian-s390x-cross.docker @@ -3,7 +3,7 @@ # # This docker target builds on the debian Stretch base image. # -FROM qemu:debian10 +FROM qemu/debian10 # Add the s390x architecture RUN dpkg --add-architecture s390x diff --git a/tests/docker/dockerfiles/debian-sh4-cross.docker b/tests/docker/dockerfiles/debian-sh4-cross.docker index 9d7663764e4..fd3af895759 100644 --- a/tests/docker/dockerfiles/debian-sh4-cross.docker +++ b/tests/docker/dockerfiles/debian-sh4-cross.docker @@ -3,7 +3,7 @@ # # This docker target builds on the debian Buster base image. # -FROM qemu:debian10 +FROM qemu/debian10 RUN apt update && \ DEBIAN_FRONTEND=noninteractive eatmydata \ diff --git a/tests/docker/dockerfiles/debian-sparc64-cross.docker b/tests/docker/dockerfiles/debian-sparc64-cross.docker index 31fd34f120b..f4bb9b561cf 100644 --- a/tests/docker/dockerfiles/debian-sparc64-cross.docker +++ b/tests/docker/dockerfiles/debian-sparc64-cross.docker @@ -3,7 +3,7 @@ # # This docker target builds on the debian Buster base image. # -FROM qemu:debian10 +FROM qemu/debian10 RUN apt update && \ DEBIAN_FRONTEND=noninteractive eatmydata \ diff --git a/tests/docker/dockerfiles/debian-tricore-cross.docker b/tests/docker/dockerfiles/debian-tricore-cross.docker index 4a0f7706a39..769d95c77bb 100644 --- a/tests/docker/dockerfiles/debian-tricore-cross.docker +++ b/tests/docker/dockerfiles/debian-tricore-cross.docker @@ -7,7 +7,7 @@ # # SPDX-License-Identifier: GPL-2.0-or-later # -FROM qemu:debian9 +FROM qemu/debian9 MAINTAINER Philippe Mathieu-Daudé diff --git a/tests/docker/dockerfiles/debian-win32-cross.docker b/tests/docker/dockerfiles/debian-win32-cross.docker index d16d6431bc8..b045e821b91 100644 --- a/tests/docker/dockerfiles/debian-win32-cross.docker +++ b/tests/docker/dockerfiles/debian-win32-cross.docker @@ -3,7 +3,7 @@ # # This docker target builds on the debian Stretch MXE base image. # -FROM qemu:debian9-mxe +FROM qemu/debian9-mxe MAINTAINER Philippe Mathieu-Daudé diff --git a/tests/docker/dockerfiles/debian-win64-cross.docker b/tests/docker/dockerfiles/debian-win64-cross.docker index b0bc960445b..2fc9cfcbc66 100644 --- a/tests/docker/dockerfiles/debian-win64-cross.docker +++ b/tests/docker/dockerfiles/debian-win64-cross.docker @@ -3,7 +3,7 @@ # # This docker target builds on the debian Stretch MXE base image. # -FROM qemu:debian9-mxe +FROM qemu/debian9-mxe MAINTAINER Philippe Mathieu-Daudé diff --git a/tests/docker/dockerfiles/debian9-mxe.docker b/tests/docker/dockerfiles/debian9-mxe.docker index 62ff1cecf2d..ae2c222a6f0 100644 --- a/tests/docker/dockerfiles/debian9-mxe.docker +++ b/tests/docker/dockerfiles/debian9-mxe.docker @@ -3,7 +3,7 @@ # # This docker target builds on the debian Stretch base image. # -FROM qemu:debian9 +FROM qemu/debian9 MAINTAINER Philippe Mathieu-Daudé diff --git a/tests/tcg/Makefile.qemu b/tests/tcg/Makefile.qemu index 9c23aeaa2a6..f8ad4c47be6 100644 --- a/tests/tcg/Makefile.qemu +++ b/tests/tcg/Makefile.qemu @@ -47,7 +47,7 @@ ifneq ($(DOCKER_IMAGE),) DOCKER_COMPILE_CMD="$(DOCKER_SCRIPT) cc \ --cc $(DOCKER_CROSS_CC_GUEST) \ - -i qemu:$(DOCKER_IMAGE) \ + -i qemu/$(DOCKER_IMAGE) \ -s $(SRC_PATH) -- " .PHONY: docker-build-guest-tests @@ -57,7 +57,7 @@ docker-build-guest-tests: docker-image-$(DOCKER_IMAGE) $(MAKE) -f $(TCG_MAKE) TARGET="$(TARGET)" CC=$(DOCKER_COMPILE_CMD) \ SRC_PATH="$(SRC_PATH)" BUILD_STATIC=y \ EXTRA_CFLAGS="$(CROSS_CC_GUEST_CFLAGS)"), \ - "BUILD","$(TARGET) guest-tests with docker qemu:$(DOCKER_IMAGE)") + "BUILD","$(TARGET) guest-tests with docker qemu/$(DOCKER_IMAGE)") GUEST_BUILD=docker-build-guest-tests From patchwork Wed Jul 1 13:56:30 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Alex_Benn=C3=A9e?= X-Patchwork-Id: 192168 Delivered-To: patch@linaro.org Received: by 2002:a92:d244:0:0:0:0:0 with SMTP id v4csp537078ilg; Wed, 1 Jul 2020 07:18:38 -0700 (PDT) X-Google-Smtp-Source: ABdhPJw25eebjDTnmgAAu5WJQez58+p4Bqav7ojAIoxt+WKkeALEy79rpeKZvGCjOp69fknlEiIb X-Received: by 2002:a5b:78b:: with SMTP id b11mr41994054ybq.461.1593613117986; Wed, 01 Jul 2020 07:18:37 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1593613117; cv=none; d=google.com; s=arc-20160816; b=O3sqSF9+hZptRLW9YVkyZgUDn/bm5jcS0Elp8pi5dYSaQru22utqs+2W51HP3hipAs qWwIAWATMsEoomAHF7XywYfwVOD29sIh4z4iMxRdP+i8vXLqS5XMwTzJC41g17jD2Y3l 4YAIMHg3mOdXXvvFP4REWoycRuup3eOXU3yD3wWS1KsXcDw5OXzFNHW63+YY49CKmLR9 trrJd6QmtHijaeeNlMMbsoK1PQ/L5LpQSI6RUFKkuo1WU58z7CrRegUnqodXSCqSKtOQ rR7I0XUPZICDJ6JiGzajfRX7gn8eGAWxjQ+9fxED2Hj2TVUpKk7GqVj0JPr8HN+0bHIa lrUA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:cc:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=/gJeXHauplrna/VI3tbE6Xj0DnjeaDUq+DWasMhuRYI=; b=HeJNAFo5ZbSH5tazdUxn7PANDWt0shuCit3xzrdGZlGIpHxR76hpXYhgAM1jy4UbOt /PR60umRQqqgNzsJ1PnPhK1pmmXkCs1PPv9EiRdXP2DWJdq3ev7Ihjb3wHN7zNtk9DBu RL9d9PiSua/dDiHMOpMtJ0YDiL+Kz5Hxyxd+aGcUB0WEQEo/NKkVyN2q8iQSGCzjxB8j SQOGQHtZqTMD7lUMKl0dHQhRyIP7Mzz3r872XlrjsVA74r20qw8TprISI7bxu+qkUHNT oP5PtBubBKS/CGg/gWHr9tcCxDBjYUe+mC1Ix1vXHhZVt/vR1D4jA5zm+YHnucyTlgA0 QO/w== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=mjXFmiNJ; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id i14si6289039ybk.252.2020.07.01.07.18.37 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Wed, 01 Jul 2020 07:18:37 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=mjXFmiNJ; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1]:55664 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jqdZN-0004fd-FT for patch@linaro.org; Wed, 01 Jul 2020 10:18:37 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:60966) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jqdL2-0005EV-HX for qemu-devel@nongnu.org; Wed, 01 Jul 2020 10:03:48 -0400 Received: from mail-wr1-x444.google.com ([2a00:1450:4864:20::444]:40179) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1jqdL0-0006rc-FP for qemu-devel@nongnu.org; Wed, 01 Jul 2020 10:03:48 -0400 Received: by mail-wr1-x444.google.com with SMTP id h5so23978658wrc.7 for ; Wed, 01 Jul 2020 07:03:46 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=/gJeXHauplrna/VI3tbE6Xj0DnjeaDUq+DWasMhuRYI=; b=mjXFmiNJuIrD339dJL3JR3q+25xfgxvOvhMjzHD8OylTSoNtwpQ3Bp6FJqyN3syuK7 V9HhLGeNRPNBmwiJ3sLOAhwEHetuCMX1LfRuLrAw7RN1m/NcMBLslsp7raydeEpm79bA +AUKpSp07jDAaXiYKphqqJdAndAYF7mT27/h60Bz+4s46XNcc/O5osePuNWQww7IXke9 xcCKEXEuIpPVQJp1xOKf/GJnuOk2aJZi3F6dJTSYHbFlGnFC+Z/q3iCpUcv2yLWW6Td2 gAjePhPN7wRs9TeIIMgTr6YyAgzV/WpeHzb0w0rOghg8XXou3gaFnUjF6dJl0aTax25/ akxQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=/gJeXHauplrna/VI3tbE6Xj0DnjeaDUq+DWasMhuRYI=; b=tfN9z/9J1BYMiYjPyGeslFgtc7GxPQlrQT6NvrFGYSFlyMv7RaQcPzG+UIwituXMJU O2LBJ9d1OedtOkxiqenz5y0V85snVEhRIe5l2DbnJ0vU9kBNsUfv/oACmbKUUSBmDQ5M d9sIXoGxbK0PUzJ2X4kyu1aXe6i874gQONRwPJgZR49IjzY5L2anulfq8WVwKnDrOmZl WfZCQlU7IPpvC8VNz9DupHbPU8bpqLgMEngJNIWNRNTL1zE1yWUKSFX2dcF/Oqsar0U6 qKrshHn4GeV5CZPFcKbTEp1biusGCPn5lNs8A/LFTtwr/n50iul2cFeEkeqMMCSgpJkB 2U0g== X-Gm-Message-State: AOAM531NJckMxSBxTROcIhvKxmp3lkCLSYJBnbrzM0Y3008Ihi6BieAR glIOHNsBImu5QVd/9gL2CmhyKA== X-Received: by 2002:adf:f889:: with SMTP id u9mr29569062wrp.149.1593612225169; Wed, 01 Jul 2020 07:03:45 -0700 (PDT) Received: from zen.linaroharston ([51.148.130.216]) by smtp.gmail.com with ESMTPSA id h14sm7805319wrt.36.2020.07.01.07.03.34 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 01 Jul 2020 07:03:41 -0700 (PDT) Received: from zen.lan (localhost [127.0.0.1]) by zen.linaroharston (Postfix) with ESMTP id C4CC41FFA6; Wed, 1 Jul 2020 14:56:54 +0100 (BST) From: =?utf-8?q?Alex_Benn=C3=A9e?= To: qemu-devel@nongnu.org Subject: [PATCH v4 18/40] .gitignore: un-ignore .gitlab-ci.d Date: Wed, 1 Jul 2020 14:56:30 +0100 Message-Id: <20200701135652.1366-19-alex.bennee@linaro.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20200701135652.1366-1-alex.bennee@linaro.org> References: <20200701135652.1366-1-alex.bennee@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::444; envelope-from=alex.bennee@linaro.org; helo=mail-wr1-x444.google.com X-detected-operating-system: by eggs.gnu.org: No matching host in p0f cache. That's all we know. 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=_AUTOLEARN X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: fam@euphon.net, Thomas Huth , berrange@redhat.com, =?utf-8?q?Alex_Benn=C3=A9e?= , richard.henderson@linaro.org, f4bug@amsat.org, =?utf-8?q?Philippe_Mat?= =?utf-8?q?hieu-Daud=C3=A9?= , cota@braap.org, aurelien@aurel32.net Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: "Qemu-devel" The sooner we deprecate in-tree builds the sooner this mess of regexes can be thrown away. Signed-off-by: Alex Bennée Reviewed-by: Thomas Huth Reviewed-by: Philippe Mathieu-Daudé --- v2 - just use explicit !/.gitlab-ci.d --- .gitignore | 1 + 1 file changed, 1 insertion(+) -- 2.20.1 diff --git a/.gitignore b/.gitignore index 90acb4347d4..2992d15931a 100644 --- a/.gitignore +++ b/.gitignore @@ -93,6 +93,7 @@ *.tp *.vr *.d +!/.gitlab-ci.d !/scripts/qemu-guest-agent/fsfreeze-hook.d *.o .sdk From patchwork Wed Jul 1 13:56:31 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Alex_Benn=C3=A9e?= X-Patchwork-Id: 192147 Delivered-To: patch@linaro.org Received: by 2002:a92:d244:0:0:0:0:0 with SMTP id v4csp525082ilg; Wed, 1 Jul 2020 07:05:22 -0700 (PDT) X-Google-Smtp-Source: ABdhPJw+BQtctUHe7eyeIg1L8NkrxHeqC66PqwZ9WTAfurvBO30E2WlKtTJC2BVygmDUYyxVEQth X-Received: by 2002:a25:be02:: with SMTP id h2mr42913143ybk.315.1593612322525; Wed, 01 Jul 2020 07:05:22 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1593612322; cv=none; d=google.com; s=arc-20160816; b=bNzlJZi1KWI1ztc3+ZQpz/2N3PKYJhwoh3NfzlxTL2a0ewnPGISGKp446QirIp7TnB h4zc17TIxgNVu6dXKdsxc56GmofDYQccsKH+IcivnxAhnqS/GhQ6tzGnkIEPWHzURjxY /Io/A3akYzMexgDR4fGQn9jj62XaYie4cb+CHLBYsJ8EUZ7UIl42+ZP2BXjfKwV9YY9B DoqdvDDRfEG1N41ZxN/CnjNgsGFmTgDnPcLB2aG9w56WnPvCWaZuChzCHEvVRdMoq7tE E4ytmMRSSpprG2bR2U3Rdt9aZMPhOWNa6E6LIpHM26NcO9FpSfiQdvg2DqoR+jmjhrJP aDXg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:cc:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=09WbvjBl4qGw2wSB47ZVCDVMGKqWTzjkB82c4wAU+mc=; b=fXLEF8D+7q48O6npqifWsOMDqI85jCZ/4dtUtNcOCzWCY8ifGzidjnQCR8MDobm3Ca tFyYehK4CkmIUFA2Ju88ndykJfrAIvzLnUX/8wWpku5nWnO2DQ6Bu4RlaIuc6VczKdPn DchJk2qTSmjQWbcDBW4VS0k9uM34U/8BS2aLAUbZVW/CJ/3uqxs6xb2jvlpfybg2V5CJ Z0GLBywhO66c57wt4aNWrsTBZUg6Q3rNi4kykBZ3QNkzaKqfoLgmjDBXaZBLhSn5fFgD aOlD/rx0UBu8viu2CIEklYgwU3JMLHhsRpgri52eEoYo/TT8SxTvzzTpK2cDlCxhweof PR4g== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=ju8BDo3N; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id e187si6335209ybf.249.2020.07.01.07.05.22 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Wed, 01 Jul 2020 07:05:22 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=ju8BDo3N; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1]:55668 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jqdMX-0006Ja-W0 for patch@linaro.org; Wed, 01 Jul 2020 10:05:22 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:58984) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jqdEe-0002Vv-3U for qemu-devel@nongnu.org; Wed, 01 Jul 2020 09:57:12 -0400 Received: from mail-wm1-x32d.google.com ([2a00:1450:4864:20::32d]:38134) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1jqdEb-0005s8-1P for qemu-devel@nongnu.org; Wed, 01 Jul 2020 09:57:11 -0400 Received: by mail-wm1-x32d.google.com with SMTP id f18so23375135wml.3 for ; Wed, 01 Jul 2020 06:57:08 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=09WbvjBl4qGw2wSB47ZVCDVMGKqWTzjkB82c4wAU+mc=; b=ju8BDo3NwSVr5TNwlr3bIE5iIuJiGD1DU6lFRP27OV+UMq/EeHODsa6/LuMMhcc+i9 qjV67Q0UJg+q9oAc6d1QOofLLLh9ik+DTheqk993Spzg7JrWib/iaISr0rRItv9uzCfe w2HEUeSEUIITTreMX5Z3wTXSzNt9XJZsVgzXf8hy9+NFPCpZvk8AjysGIcIuz2lPilJY gPaGVZNBpnDHJp1oHaz5uodLXTEnJGzVY+vbhgKcGCWOgcVuO7qawx/qp3KiyvFuXgaV AfkDynAyuJJlUeejXvq9qyVszIZPaJj1bs9qLFAdHT0XBoU8/GQ+YmWWYamy9bthMfvh HmbA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=09WbvjBl4qGw2wSB47ZVCDVMGKqWTzjkB82c4wAU+mc=; b=klsR4CLy7foHgm5ZOvBzkdrZy9zviF/8NyrXhIlVCnV0w1Lfp7aZuSfmrylepoQK8w Ne5BxMqCJ2lvINZubxWFOMsfCj0NZyAcyg/lloZgx8NJcG8qi0SQgJsTBArPd5iC30dk jZAzufXI+UvKL3dVSIkykx4j9MaH41fA/SXvDfd3NskcyxRyANKauD6L+xRa6C2pKMbJ /Wvs+Cey6tsHBeDpeGj2hjRs5bNdwGbqKXYLRk5r8S5D+x1CVxjvELgD6f5Pff0rPmqt khDKoQaAc35/NdaixAR23nI+w/npda6+OvGURPYn+bgtOjA6X1GUsmffGdQ3sJ/1LBBT DzGQ== X-Gm-Message-State: AOAM532n6zu9YVoChnn4DchsQlflTdb1W5w7FIr7APccm8xhe5PlZ76K oFs/biNEG5mkbCeQAenq060hMA== X-Received: by 2002:a1c:790c:: with SMTP id l12mr26309698wme.50.1593611827633; Wed, 01 Jul 2020 06:57:07 -0700 (PDT) Received: from zen.linaroharston ([51.148.130.216]) by smtp.gmail.com with ESMTPSA id x18sm7365977wrq.13.2020.07.01.06.57.00 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 01 Jul 2020 06:57:02 -0700 (PDT) Received: from zen.lan (localhost [127.0.0.1]) by zen.linaroharston (Postfix) with ESMTP id DC32E1FFA9; Wed, 1 Jul 2020 14:56:54 +0100 (BST) From: =?utf-8?q?Alex_Benn=C3=A9e?= To: qemu-devel@nongnu.org Subject: [PATCH v4 19/40] gitlab-ci: Fix the change rules after moving the YML files Date: Wed, 1 Jul 2020 14:56:31 +0100 Message-Id: <20200701135652.1366-20-alex.bennee@linaro.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20200701135652.1366-1-alex.bennee@linaro.org> References: <20200701135652.1366-1-alex.bennee@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::32d; envelope-from=alex.bennee@linaro.org; helo=mail-wm1-x32d.google.com X-detected-operating-system: by eggs.gnu.org: No matching host in p0f cache. That's all we know. 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=_AUTOLEARN X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: fam@euphon.net, Thomas Huth , berrange@redhat.com, =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= , richard.henderson@linaro.org, f4bug@amsat.org, Laszlo Ersek , =?utf-8?q?Alex_Benn=C3=A9e?= , cota@braap.org, aurelien@aurel32.net Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: "Qemu-devel" From: Thomas Huth The edk2.yml and opensbi.yml files have recently been moved/renamed, but the change has not been reflected in the rules in the YML files yet. Fixes: 922febe2af ("Move edk2 and opensbi YAML files to .gitlab-ci.d folder") Signed-off-by: Thomas Huth Reviewed-by: Philippe Mathieu-Daudé Signed-off-by: Alex Bennée Message-Id: <20200625151627.24986-1-thuth@redhat.com> --- .gitlab-ci.d/edk2.yml | 2 +- .gitlab-ci.d/opensbi.yml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) -- 2.20.1 diff --git a/.gitlab-ci.d/edk2.yml b/.gitlab-ci.d/edk2.yml index 088ba4b43a3..a9990b71475 100644 --- a/.gitlab-ci.d/edk2.yml +++ b/.gitlab-ci.d/edk2.yml @@ -2,7 +2,7 @@ docker-edk2: stage: build rules: # Only run this job when the Dockerfile is modified - changes: - - .gitlab-ci-edk2.yml + - .gitlab-ci.d/edk2.yml - .gitlab-ci.d/edk2/Dockerfile when: always image: docker:19.03.1 diff --git a/.gitlab-ci.d/opensbi.yml b/.gitlab-ci.d/opensbi.yml index dd051c01245..6a1750784ac 100644 --- a/.gitlab-ci.d/opensbi.yml +++ b/.gitlab-ci.d/opensbi.yml @@ -2,7 +2,7 @@ docker-opensbi: stage: build rules: # Only run this job when the Dockerfile is modified - changes: - - .gitlab-ci-opensbi.yml + - .gitlab-ci.d/opensbi.yml - .gitlab-ci.d/opensbi/Dockerfile when: always image: docker:19.03.1 From patchwork Wed Jul 1 13:56:32 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Alex_Benn=C3=A9e?= X-Patchwork-Id: 192148 Delivered-To: patch@linaro.org Received: by 2002:a92:d244:0:0:0:0:0 with SMTP id v4csp525585ilg; Wed, 1 Jul 2020 07:05:51 -0700 (PDT) X-Google-Smtp-Source: ABdhPJws96RKD2b40stNFsJKoKfsMjKPwYrCGqdTDlF59yuW+vhNx1SGuAQN5nRDV/AbVx5/quQ1 X-Received: by 2002:a5b:282:: with SMTP id x2mr41845927ybl.304.1593612351292; Wed, 01 Jul 2020 07:05:51 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1593612351; cv=none; d=google.com; s=arc-20160816; b=eN9H/DdfY80XnAnPTF4I9kz+B6CVHCje6UF2upCS+NN1V6TDLhJVhw7RBN4czyRZ6D KKMi9zJItSICz7a5eYWAPTYpnjfI3pAnTrIDWuN2Vd/m0eroal0Bz5fSAq/EYHHWhDij HCgRT/UWvR38la3xFZGeB+Vzs1OVeUDSLUG3P6fj50FN08YTGrveJAhT5TGBtsDeQd6q UJy9XER0n6jHUUtK81AJMwqOeJkv4qDTw0nwUuMcN/VAWhrYap0h3dwdeAjCz2T2eP68 eBP+/XHDVmz9Im7pj6BFKi6l0vrmq4PYij1667r7wxJMx5fYn9T264FbYjPn2lbSmSMF ddmg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:cc:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=BoQbWA8pgX9GC2xijlmIAV/4o0rgmcM2g2psEePuq2U=; b=TkrHXgUmj/4IRZRo7iPRP1v/yDsAmrI6FbNuhAdCuoVR3APP64srvLQTRC6zDqPO10 2eJrAO/VXOm4Qd8c468aZMFFphPBcwStvu3wxn2Hp8nBfv+67UF0Ijg3ehenThEFqG1+ /DyoFFPG+hIdspmwyauJZ0+2B47+5Yl+OzDUIgk2YHw1m5gCmFRVfMsbfnEuqCoW5DLK 49xsSxVpxCGfPo0aVqIHpk2uIHRW/+uK4RRJVFErGEM4llbYobMnhx3HrI40GxOv6Xmd mlMTlW/HAyegwmh773YWC4KeG2CXrfHztW8s+me9LsszG53nSVq0WrExrCnYsSC0GgLR vuVw== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=F2tvzyJx; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id v137si5567380ybv.363.2020.07.01.07.05.51 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Wed, 01 Jul 2020 07:05:51 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=F2tvzyJx; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1]:60550 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jqdN0-0008NW-Ll for patch@linaro.org; Wed, 01 Jul 2020 10:05:50 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:59084) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jqdEl-0002aL-HX for qemu-devel@nongnu.org; Wed, 01 Jul 2020 09:57:22 -0400 Received: from mail-wr1-x429.google.com ([2a00:1450:4864:20::429]:33982) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1jqdEh-0005tK-Cm for qemu-devel@nongnu.org; Wed, 01 Jul 2020 09:57:19 -0400 Received: by mail-wr1-x429.google.com with SMTP id f7so20948049wrw.1 for ; Wed, 01 Jul 2020 06:57:14 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=BoQbWA8pgX9GC2xijlmIAV/4o0rgmcM2g2psEePuq2U=; b=F2tvzyJxzTOX8RooDOMbR6ll3Sok+dGHUyuqXmS+rFb56WUlYQsvmM/MvY835znBIu TOoUomkchoLwwO8bYwigwd+fm4GgDKD5ULawWnlOcda7Le4VADRc2Nw51zg9m9OAeVg3 bv1bBfZ/nVduT/eYFq8EFPcKxGV3iCjIiKlkov1/eUccBcyZL0rxYBED9DHPYgVrkRnn n8v+mffyQUyLthAkEs/U1dreM/JmiUYWihAEs7CiKjo7ZcfHZm4IbrfjKnKM0XqX7JjK D2jilt9Ox8lkzFtdCxEDCbBqzG3x0yeTimAK4i+tJKsABP3yEZnz4/ri8Y4PbDeVsGjp ssNw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=BoQbWA8pgX9GC2xijlmIAV/4o0rgmcM2g2psEePuq2U=; b=p5CnmqH7PRTuvBqW/R6j8wk7zm7EU+BsbJKEbMQoe8brSUldnEEDECFHhcaY64UQeM C4tQkNS70ADHgEYEzQrapLZhxoPyOrLy1JURNul0KjfmwIybOrtgyuCwMkDxf22yeG9+ 3Bfh84o0kpQCy+LPqJ77G7pd48CN4jVbuiUs75xBfFuFc3I37Z+/PoFO/90+UalyaN+d RypnkmrTc8TBMgNI3Kn+kKUuZjHykCBWG2usAD7DUvsq1XnIbz2vkBqGBZpuQoPhJ/2n wruyZ2DGLqbBdBsGaoxIU3uiXBTxMwaxt9F3eagTfxF1fCoHXBXqcukDOxkbtqA1L2lD 3qSg== X-Gm-Message-State: AOAM532196ZhmoKaxipH2dN3lC5EOuowXfSqE3y1D/S4/4h2L8fGqP67 b3wli2zGo7KMCpU8G5AOlQPNMQ== X-Received: by 2002:adf:de0a:: with SMTP id b10mr26277109wrm.72.1593611834037; Wed, 01 Jul 2020 06:57:14 -0700 (PDT) Received: from zen.linaroharston ([51.148.130.216]) by smtp.gmail.com with ESMTPSA id l18sm7652562wrm.52.2020.07.01.06.57.00 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 01 Jul 2020 06:57:02 -0700 (PDT) Received: from zen.lan (localhost [127.0.0.1]) by zen.linaroharston (Postfix) with ESMTP id 0044E1FF7E; Wed, 1 Jul 2020 14:56:55 +0100 (BST) From: =?utf-8?q?Alex_Benn=C3=A9e?= To: qemu-devel@nongnu.org Subject: [PATCH v4 20/40] gitlab: introduce explicit "container" and "build" stages Date: Wed, 1 Jul 2020 14:56:32 +0100 Message-Id: <20200701135652.1366-21-alex.bennee@linaro.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20200701135652.1366-1-alex.bennee@linaro.org> References: <20200701135652.1366-1-alex.bennee@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::429; envelope-from=alex.bennee@linaro.org; helo=mail-wr1-x429.google.com X-detected-operating-system: by eggs.gnu.org: No matching host in p0f cache. That's all we know. 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=_AUTOLEARN X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: fam@euphon.net, Thomas Huth , berrange@redhat.com, Laszlo Ersek , richard.henderson@linaro.org, f4bug@amsat.org, Wainer dos Santos Moschetta , =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= , =?utf-8?q?Alex_Benn=C3=A9e?= , cota@braap.org, aurelien@aurel32.net Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: "Qemu-devel" From: Daniel P. Berrangé If no stage is listed, jobs get put in an implicit "test" stage. Some jobs which create container images to be used by later stages are currently listed as in a "build" stages. Signed-off-by: Daniel P. Berrangé Acked-by: Laszlo Ersek Signed-off-by: Alex Bennée Reviewed-by: Thomas Huth Reviewed-by: Philippe Mathieu-Daudé Message-Id: <20200622153318.751107-2-berrange@redhat.com> --- .gitlab-ci.d/edk2.yml | 3 ++- .gitlab-ci.d/opensbi.yml | 3 ++- .gitlab-ci.yml | 11 +++++++++++ 3 files changed, 15 insertions(+), 2 deletions(-) -- 2.20.1 diff --git a/.gitlab-ci.d/edk2.yml b/.gitlab-ci.d/edk2.yml index a9990b71475..e1e04524166 100644 --- a/.gitlab-ci.d/edk2.yml +++ b/.gitlab-ci.d/edk2.yml @@ -1,5 +1,5 @@ docker-edk2: - stage: build + stage: containers rules: # Only run this job when the Dockerfile is modified - changes: - .gitlab-ci.d/edk2.yml @@ -24,6 +24,7 @@ docker-edk2: - docker push $IMAGE_TAG build-edk2: + stage: build rules: # Only run this job when ... - changes: # ... roms/edk2/ is modified (submodule updated) - roms/edk2/* diff --git a/.gitlab-ci.d/opensbi.yml b/.gitlab-ci.d/opensbi.yml index 6a1750784ac..62088ec5ec1 100644 --- a/.gitlab-ci.d/opensbi.yml +++ b/.gitlab-ci.d/opensbi.yml @@ -1,5 +1,5 @@ docker-opensbi: - stage: build + stage: containers rules: # Only run this job when the Dockerfile is modified - changes: - .gitlab-ci.d/opensbi.yml @@ -24,6 +24,7 @@ docker-opensbi: - docker push $IMAGE_TAG build-opensbi: + stage: build rules: # Only run this job when ... - changes: # ... roms/opensbi/ is modified (submodule updated) - roms/opensbi/* diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 349c77aa580..9fdc752ea63 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -1,3 +1,7 @@ +stages: + - containers + - build + include: - local: '/.gitlab-ci.d/edk2.yml' - local: '/.gitlab-ci.d/opensbi.yml' @@ -17,6 +21,7 @@ include: - JOBS=$(expr $(nproc) + 1) build-system1: + stage: build image: ubuntu:19.10 <<: *before_script_apt script: @@ -31,6 +36,7 @@ build-system1: - make -j"$JOBS" check build-system2: + stage: build image: fedora:latest <<: *before_script_dnf script: @@ -46,6 +52,7 @@ build-system2: - make -j"$JOBS" check build-disabled: + stage: build image: fedora:latest <<: *before_script_dnf script: @@ -62,6 +69,7 @@ build-disabled: - make -j"$JOBS" check-qtest SPEED=slow build-tcg-disabled: + stage: build image: centos:8 <<: *before_script_dnf script: @@ -82,6 +90,7 @@ build-tcg-disabled: 260 261 262 263 264 270 272 273 277 279 build-user: + stage: build <<: *before_script_apt script: - mkdir build @@ -92,6 +101,7 @@ build-user: - make run-tcg-tests-i386-linux-user run-tcg-tests-x86_64-linux-user build-clang: + stage: build image: fedora:latest <<: *before_script_dnf script: @@ -106,6 +116,7 @@ build-clang: - make -j"$JOBS" check build-tci: + stage: build image: centos:8 <<: *before_script_dnf script: From patchwork Wed Jul 1 13:56:33 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Alex_Benn=C3=A9e?= X-Patchwork-Id: 192153 Delivered-To: patch@linaro.org Received: by 2002:a92:d244:0:0:0:0:0 with SMTP id v4csp528634ilg; Wed, 1 Jul 2020 07:09:05 -0700 (PDT) X-Google-Smtp-Source: ABdhPJy4PMAUuommB3rA+F2TIOet2HeuxB50cnSrzuW+z+37rZUaihDpB40SAnOIpO1tP8VRsRpL X-Received: by 2002:a25:7c45:: with SMTP id x66mr43200295ybc.325.1593612545011; Wed, 01 Jul 2020 07:09:05 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1593612545; cv=none; d=google.com; s=arc-20160816; b=Hzka38pAmE1+JAtZgCOYLxLzrVWdc73Z88TTCGCEDQWpRe4zRibRNA0QXSK/4HKW5X 5mzv2NCwQh3qnPeNWUPWX9BiNSPEQ/lt05EsZi15PwiGovRZgwYM7tsDCfhI1iRhuqY9 XP//KbSO/JMTiXsEGtQpouDNrgnJdsxf2VZIXwXrFlVj2CRaZm/ab5v3lyyog/XZLtzM IwO7FkK3UrkhxdEGZs5U1VwBqB6AlNgLThPvl2jO7DdQDdp8RcXMBu/STbYCcQ5e+/wE itWRpDGrbTkq2Ujs0h6eQ1HfFb8PcQA177hTEb6iLsTmKtsAHHc25c6juNBTGtPgB5Yl DxXQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:cc:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=XtbfSpBB9DtnKKoqK1hU0Y2RrtR1UeM6mQbJKmTSrNs=; b=g7aBotav9j3VP0UCDVkIeeFc5Pgc9KbmbaxTgRZFHbpjTEhNITZub4pcSZOPeEA7HE zQUFLQDjipM7VRs22ZklQq+Llwb9oWySF6P70f/x6KUd9DjLRgDDqLyQd8YNQm8mX4Rk AZPsv+3oGCodL+e9VU61pMly0UErlJY3bDU971pSLhgDpepiclH+PnBOfGNpiaiXHEjV PXSdiibJv6NQajfhVLIUMFgNOyS6ZpN4l+QvpPjwTVHFAAfFUfPH8MLKeMP9BXnfy1dT LgOm0FdpbcWaqmWR2KAmoB/nxvajdZNLiY2g+/AHS5r11uhnUoRdzdm630+KDk5Tkm2q pPWg== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=IdFcX18B; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id a131si1205914ybg.309.2020.07.01.07.09.04 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Wed, 01 Jul 2020 07:09:04 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=IdFcX18B; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1]:44422 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jqdQ8-00050J-CP for patch@linaro.org; Wed, 01 Jul 2020 10:09:04 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:59040) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jqdEh-0002Xn-Kh for qemu-devel@nongnu.org; Wed, 01 Jul 2020 09:57:17 -0400 Received: from mail-wm1-x330.google.com ([2a00:1450:4864:20::330]:39335) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1jqdEe-0005sm-62 for qemu-devel@nongnu.org; Wed, 01 Jul 2020 09:57:15 -0400 Received: by mail-wm1-x330.google.com with SMTP id w3so10905906wmi.4 for ; Wed, 01 Jul 2020 06:57:11 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=XtbfSpBB9DtnKKoqK1hU0Y2RrtR1UeM6mQbJKmTSrNs=; b=IdFcX18BKqKlZRkc7+UIXoRZ+Zm7BZT00PJk5OvQxpHUSuURiZQCv2hlQTUDNcHcGS ynQSnRfAUUUB6WWc0xTCzSmXRgMGxehlXuw1guhlMbcEL9BCqFBb6wYSWEhxepECmdXW Vt5J/Bew/4bdgixynydeIkEnLbCETlauflU+Lxi446lR2cJhGy11uSodydr75ROSVNnl ddQDSnFjdHnHsGzwhxrfMXoiXr87BCJczxRTtlK6mMEMv+inPPNrEcjQbZ8jtYNksPst YNjYUqozwbW58a4Uy7riVwRSLtJcq6Bz76f7faa0GR1h628kdG095NUd/2lfitXVAsfo i55g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=XtbfSpBB9DtnKKoqK1hU0Y2RrtR1UeM6mQbJKmTSrNs=; b=JhQHuu+tREb1BO61sfW2rx0nhvef1iXEpeKr3iSaPy9yc9dkSkqLvbEaAHoncjrabp d8XhPdIwrc91Itg5cnNEMb0uCD2tsIrO7Sns/7zQBGVf+jiKN5vkX29mEdaor/WZWDpU E40cdx1kgl5RROXz5BxvZiI/gslwnG/mVCJxaloDM27M4LqvorAMuqlNFobC1D1RHLtZ tStojHFldmDJ4RLS65p30uHmo+Qdd3uOqxPY66m0lnNDnlfPvvcf17poEI370RAKZfzz wf+aLKcuomwz1AR3y4DQZrkdyGYXqPiC6T3eV4Fgh8JZlDRCbuljvdHSl8AlDxXQsy4I MRWw== X-Gm-Message-State: AOAM5320CxJ9hGPaxOy8Ddd+7qEkd8paM3jbD+lIr7V8nmlaj/5lOIYx HEmRCWzA1tLJacWTL7PnwfRZBQ== X-Received: by 2002:a7b:c84d:: with SMTP id c13mr26769260wml.170.1593611830666; Wed, 01 Jul 2020 06:57:10 -0700 (PDT) Received: from zen.linaroharston ([51.148.130.216]) by smtp.gmail.com with ESMTPSA id f12sm7501283wrw.53.2020.07.01.06.57.00 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 01 Jul 2020 06:57:02 -0700 (PDT) Received: from zen.lan (localhost [127.0.0.1]) by zen.linaroharston (Postfix) with ESMTP id 198061FFAA; Wed, 1 Jul 2020 14:56:55 +0100 (BST) From: =?utf-8?q?Alex_Benn=C3=A9e?= To: qemu-devel@nongnu.org Subject: [PATCH v4 21/40] gitlab: build all container images during CI Date: Wed, 1 Jul 2020 14:56:33 +0100 Message-Id: <20200701135652.1366-22-alex.bennee@linaro.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20200701135652.1366-1-alex.bennee@linaro.org> References: <20200701135652.1366-1-alex.bennee@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::330; envelope-from=alex.bennee@linaro.org; helo=mail-wm1-x330.google.com X-detected-operating-system: by eggs.gnu.org: No matching host in p0f cache. That's all we know. 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=_AUTOLEARN X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: fam@euphon.net, Thomas Huth , berrange@redhat.com, =?utf-8?q?Alex_Benn=C3=A9e?= , richard.henderson@linaro.org, f4bug@amsat.org, Wainer dos Santos Moschetta , =?utf-8?q?Philippe_Mathieu-Daud?= =?utf-8?b?w6k=?= , cota@braap.org, aurelien@aurel32.net Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: "Qemu-devel" From: Daniel P. Berrangé We have a number of container images in tests/docker/dockerfiles that are intended to provide well defined environments for doing test builds. We want our CI system to use these containers too. This introduces builds of all of them as the first stage in the CI, so that the built containers are available for later build jobs. The containers are setup to use the GitLab container registry as the cache, so we only pay the penalty of the full build when the dockerfiles change. The main qemu-project/qemu repo is used as a second cache, so that users forking QEMU will see a fast turnaround time on their CI jobs. Signed-off-by: Daniel P. Berrangé Message-Id: <20200622153318.751107-3-berrange@redhat.com> [AJB: tweak the tag format] Signed-off-by: Alex Bennée Acked-by: Thomas Huth --- v4 - rm leading and trailing ws --- .gitlab-ci.d/containers.yml | 245 ++++++++++++++++++++++++++++++++++++ .gitlab-ci.yml | 3 + 2 files changed, 248 insertions(+) create mode 100644 .gitlab-ci.d/containers.yml -- 2.20.1 diff --git a/.gitlab-ci.d/containers.yml b/.gitlab-ci.d/containers.yml new file mode 100644 index 00000000000..2afd01f1d17 --- /dev/null +++ b/.gitlab-ci.d/containers.yml @@ -0,0 +1,245 @@ +.container_job_template: &container_job_definition + image: docker:stable + stage: containers + services: + - docker:dind + before_script: + - export TAG="$CI_REGISTRY_IMAGE/qemu/$NAME:latest" + - export COMMON_TAG="$CI_REGISTRY/qemu-project/qemu/$NAME:latest" + - docker info + - docker login registry.gitlab.com -u "$CI_REGISTRY_USER" -p "$CI_REGISTRY_PASSWORD" + script: + - docker pull "$TAG" || docker pull "$COMMON_TAG" || true + - sed -i -e "s,FROM qemu/,FROM $CI_REGISTRY_IMAGE/qemu/," tests/docker/dockerfiles/$NAME.docker + - docker build --cache-from "$TAG" --cache-from "$COMMON_TAG" --tag "$TAG" -f "tests/docker/dockerfiles/$NAME.docker" tests/docker/dockerfiles + - docker push "$TAG" + after_script: + - docker logout + +amd64-centos7-container: + <<: *container_job_definition + variables: + NAME: centos7 + +amd64-centos8-container: + <<: *container_job_definition + variables: + NAME: centos8 + +amd64-debian10-container: + <<: *container_job_definition + variables: + NAME: debian10 + +amd64-debian11-container: + <<: *container_job_definition + variables: + NAME: debian11 + +amd64-debian9-container: + <<: *container_job_definition + variables: + NAME: debian9 + +amd64-debian9-mxe-container: + <<: *container_job_definition + stage: containers-layer2 + needs: ['amd64-debian9-container'] + variables: + NAME: debian9-mxe + +alpha-debian-cross-container: + <<: *container_job_definition + stage: containers-layer2 + needs: ['amd64-debian10-container'] + variables: + NAME: debian-alpha-cross + +amd64-debian-cross-container: + <<: *container_job_definition + stage: containers-layer2 + needs: ['amd64-debian10-container'] + variables: + NAME: debian-amd64-cross + +amd64-debian-container: + <<: *container_job_definition + stage: containers-layer2 + needs: ['amd64-debian10-container'] + variables: + NAME: debian-amd64 + +arm64-debian-cross-container: + <<: *container_job_definition + stage: containers-layer2 + needs: ['amd64-debian10-container'] + variables: + NAME: debian-arm64-cross + +arm64-test-debian-cross-container: + <<: *container_job_definition + stage: containers-layer2 + needs: ['amd64-debian11-container'] + variables: + NAME: debian-arm64-test-cross + +armel-debian-cross-container: + <<: *container_job_definition + stage: containers-layer2 + needs: ['amd64-debian10-container'] + variables: + NAME: debian-armel-cross + +armhf-debian-cross-container: + <<: *container_job_definition + stage: containers-layer2 + needs: ['amd64-debian10-container'] + variables: + NAME: debian-armhf-cross + +hppa-debian-cross-container: + <<: *container_job_definition + stage: containers-layer2 + needs: ['amd64-debian10-container'] + variables: + NAME: debian-hppa-cross + +m68k-debian-cross-container: + <<: *container_job_definition + stage: containers-layer2 + needs: ['amd64-debian10-container'] + variables: + NAME: debian-m68k-cross + +mips64-debian-cross-container: + <<: *container_job_definition + stage: containers-layer2 + needs: ['amd64-debian10-container'] + variables: + NAME: debian-mips64-cross + +mips64el-debian-cross-container: + <<: *container_job_definition + stage: containers-layer2 + needs: ['amd64-debian10-container'] + variables: + NAME: debian-mips64el-cross + +mips-debian-cross-container: + <<: *container_job_definition + stage: containers-layer2 + needs: ['amd64-debian10-container'] + variables: + NAME: debian-mips-cross + +mipsel-debian-cross-container: + <<: *container_job_definition + stage: containers-layer2 + needs: ['amd64-debian10-container'] + variables: + NAME: debian-mipsel-cross + +powerpc-debian-cross-container: + <<: *container_job_definition + stage: containers-layer2 + needs: ['amd64-debian10-container'] + variables: + NAME: debian-powerpc-cross + +ppc64-debian-cross-container: + <<: *container_job_definition + stage: containers-layer2 + needs: ['amd64-debian10-container'] + variables: + NAME: debian-ppc64-cross + +ppc64el-debian-cross-container: + <<: *container_job_definition + stage: containers-layer2 + needs: ['amd64-debian10-container'] + variables: + NAME: debian-ppc64el-cross + +riscv64-debian-cross-container: + <<: *container_job_definition + stage: containers-layer2 + needs: ['amd64-debian10-container'] + variables: + NAME: debian-riscv64-cross + +s390x-debian-cross-container: + <<: *container_job_definition + stage: containers-layer2 + needs: ['amd64-debian10-container'] + variables: + NAME: debian-s390x-cross + +sh4-debian-cross-container: + <<: *container_job_definition + stage: containers-layer2 + needs: ['amd64-debian10-container'] + variables: + NAME: debian-sh4-cross + +sparc64-debian-cross-container: + <<: *container_job_definition + stage: containers-layer2 + needs: ['amd64-debian10-container'] + variables: + NAME: debian-sparc64-cross + +tricore-debian-cross-container: + <<: *container_job_definition + stage: containers-layer2 + needs: ['amd64-debian9-container'] + variables: + NAME: debian-tricore-cross + +win32-debian-cross-container: + <<: *container_job_definition + stage: containers-layer3 + needs: ['amd64-debian9-mxe-container'] + variables: + NAME: debian-win32-cross + +win64-debian-cross-container: + <<: *container_job_definition + stage: containers-layer3 + needs: ['amd64-debian9-mxe-container'] + variables: + NAME: debian-win64-cross + +xtensa-debian-cross-container: + <<: *container_job_definition + variables: + NAME: debian-xtensa-cross + +cris-fedora-cross-container: + <<: *container_job_definition + variables: + NAME: fedora-cris-cross + +amd64-fedora-container: + <<: *container_job_definition + variables: + NAME: fedora + +i386-fedora-cross-container: + <<: *container_job_definition + variables: + NAME: fedora-i386-cross + +amd64-ubuntu1804-container: + <<: *container_job_definition + variables: + NAME: ubuntu1804 + +amd64-ubuntu2004-container: + <<: *container_job_definition + variables: + NAME: ubuntu2004 + +amd64-ubuntu-container: + <<: *container_job_definition + variables: + NAME: ubuntu diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 9fdc752ea63..72d688875fd 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -1,10 +1,13 @@ stages: - containers + - containers-layer2 + - containers-layer3 - build include: - local: '/.gitlab-ci.d/edk2.yml' - local: '/.gitlab-ci.d/opensbi.yml' + - local: '/.gitlab-ci.d/containers.yml' .update_apt_template: &before_script_apt before_script: From patchwork Wed Jul 1 13:56:34 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Alex_Benn=C3=A9e?= X-Patchwork-Id: 192155 Delivered-To: patch@linaro.org Received: by 2002:a92:d244:0:0:0:0:0 with SMTP id v4csp529770ilg; Wed, 1 Jul 2020 07:10:20 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwjxwJlnUwsZRuhgtLBdLjK4TGacnvkw8YMX9ZY5Qeawb4E/DHIUYu1n3wtnWy8QmyNg98q X-Received: by 2002:ae9:e8c7:: with SMTP id a190mr25387256qkg.94.1593612620322; Wed, 01 Jul 2020 07:10:20 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1593612620; cv=none; d=google.com; s=arc-20160816; b=MoI2/AfovT3PgZvskvg3KSsZcUlO7cnxU+MqmwuqyQojig89ILlCkfpgFIXwOvvvH1 wBXhdGvw22waO8qc9tfmHkeuWK7AGfZOsAbw/Dk9WUx3TQCYmLOIPjEKl19Amx1e25jr L/w/YJDPhMMpCVqfWzIUIGgblYdCaHskzaipLyebnBrf7NGFn5gBT7D8FjKPxrcj4Qsi uFk2zaSYPT3zJuY2cAIwYjrJevVTNMYmvSXyA7k1f/vI3FPus+93U5auYCHNn4yYw3w+ OAquahpXhyvfAen9ZIUbkP7oLkHmNtNo4IYPTw0dWgPGuwHG7rt/SbFJu1vD6YSmo7/x JZWg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:cc:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=Kb5Xt/DZWMuTCfEQdYSBCmTIyBxrejxoMxcdaJ+ZGQ4=; b=GQooCtIpmKkb2+LnjtyfTWtmQaA2M9t5FVJwxxgwLj0wTvY4Wj7pxNHZ+qx006+RW4 am2DBMYKAutjnhbtzbmqoKVAbxLacOG2DheUrM6PWXOrnwPIM4afHtOvuY/W0ln1Yrb5 VjZYjFVk/Oxx1UZrrWbwFMnU2rhxmkPs8YDJvMA6MSNMELwSW4X0VN+nJkUEunpXmt43 0qiAe08DX1HekuECUaEuuSymNWETC5JGQek06jaDiaJpQsvk2KiN4ehZzTa/a7sqSDAc irQu/iamFUvRfil/yLOPSCp8qFziARo4M78CPGSockFFbe5PnFZWiH3GVkPkndpwgPmn 7apQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=wRPh621d; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id q24si3728772qtp.175.2020.07.01.07.10.20 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Wed, 01 Jul 2020 07:10:20 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=wRPh621d; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1]:52898 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jqdRL-0008W0-O1 for patch@linaro.org; Wed, 01 Jul 2020 10:10:19 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:59120) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jqdEo-0002ae-Pf for qemu-devel@nongnu.org; Wed, 01 Jul 2020 09:57:22 -0400 Received: from mail-wr1-x432.google.com ([2a00:1450:4864:20::432]:37765) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1jqdEf-0005t1-H7 for qemu-devel@nongnu.org; Wed, 01 Jul 2020 09:57:20 -0400 Received: by mail-wr1-x432.google.com with SMTP id a6so23962239wrm.4 for ; Wed, 01 Jul 2020 06:57:12 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=Kb5Xt/DZWMuTCfEQdYSBCmTIyBxrejxoMxcdaJ+ZGQ4=; b=wRPh621dQO+17zfaPmheqmLxotbDMbYOmXo/wV9u3H974kzXildt1BdoTcFOewtVCT Orl3mzwi3Xszc6EW12hp2ThG8ciRcnGYxrgWy0Nlj5Qn2djCZtnB3pKi6jacQr8R0d62 Fd6pfcTqA4OFsjdQUhmOVOgsklQeCLHmK4SHCufuDlq2CXpD5Ex4yxHgTqwBtJRK4hx+ L4zKfLSSRVIQTpH0FKehMZoSATTWJC6vpY18Pu/1IHnrU2zPCaoeuSXPeOcRF3xNWthj hP9dxC4f0AZCs935hpDIZa4iZ9Fw1qwLqTBNeGpemCb0pSNzzl/aUuVNMUym6B14tpYk 6mhg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=Kb5Xt/DZWMuTCfEQdYSBCmTIyBxrejxoMxcdaJ+ZGQ4=; b=g4ShaWyi/gqwwbkOmyV4HHAim5SBkADkQC8IpwLgA2epxdY3KzuJ9XGyRL1Y1c1xZQ yO/LDBLGDW/2pE0gGVsIwqBSb7rkKpSplUrRQ/0mDpRIabH7ivuSXu+/1O0AAZbf66tm IX0ZJwa+NO/4onnmNmOguSDWpJOEgK5kk3cO4mCTOgZJRtrVfVthAEEZBg8MkT8O+BUX zi/s3W8aMk9+j5R8dH/NzWfY0FG0upntV2ww/IXKhYxE4/KH5m7DaKF282ZALPPE1hpp wQ8XQgbwFjSxffUuQ1avwyQb3v4pMpn03/6w1pnY6jfoDqSySfYZkWKMH+R7ClpBIE1D HJmQ== X-Gm-Message-State: AOAM531ePr7NXVu2kt7wfTGwKh14w71eS7spWMzwr7GCDhTph8jGQkig LjWXcf9pyQUqthrnS8Pj9gOd+g== X-Received: by 2002:adf:f14c:: with SMTP id y12mr26463431wro.30.1593611831855; Wed, 01 Jul 2020 06:57:11 -0700 (PDT) Received: from zen.linaroharston ([51.148.130.216]) by smtp.gmail.com with ESMTPSA id r3sm8384735wrg.70.2020.07.01.06.57.00 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 01 Jul 2020 06:57:02 -0700 (PDT) Received: from zen.lan (localhost [127.0.0.1]) by zen.linaroharston (Postfix) with ESMTP id 31CEE1FFAB; Wed, 1 Jul 2020 14:56:55 +0100 (BST) From: =?utf-8?q?Alex_Benn=C3=A9e?= To: qemu-devel@nongnu.org Subject: [PATCH v4 22/40] gitlab: convert jobs to use custom built containers Date: Wed, 1 Jul 2020 14:56:34 +0100 Message-Id: <20200701135652.1366-23-alex.bennee@linaro.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20200701135652.1366-1-alex.bennee@linaro.org> References: <20200701135652.1366-1-alex.bennee@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::432; envelope-from=alex.bennee@linaro.org; helo=mail-wr1-x432.google.com X-detected-operating-system: by eggs.gnu.org: No matching host in p0f cache. That's all we know. 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=_AUTOLEARN X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: fam@euphon.net, Thomas Huth , berrange@redhat.com, =?utf-8?q?Alex_Benn=C3=A9e?= , richard.henderson@linaro.org, f4bug@amsat.org, Wainer dos Santos Moschetta , =?utf-8?q?Philippe_Mathieu-Daud?= =?utf-8?b?w6k=?= , cota@braap.org, aurelien@aurel32.net Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: "Qemu-devel" From: Daniel P. Berrangé Now that we're building standard container images from dockerfiles in tests/docker/dockerfiles, we can convert the build jobs to use them. The key benefit of this is that a contributor can now more easily replicate the CI environment on their local machine. The container images are cached too, so we are not spending time waiting for the apt-get/dnf package installs to complete. Signed-off-by: Daniel P. Berrangé Message-Id: <20200622153318.751107-4-berrange@redhat.com> [AJB: tweak naming convention] Signed-off-by: Alex Bennée Acked-by: Thomas Huth --- .gitlab-ci.yml | 187 +++++++++++++++++++++---------------------------- 1 file changed, 81 insertions(+), 106 deletions(-) -- 2.20.1 diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 72d688875fd..a7abc55a5c6 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -9,133 +9,108 @@ include: - local: '/.gitlab-ci.d/opensbi.yml' - local: '/.gitlab-ci.d/containers.yml' -.update_apt_template: &before_script_apt - before_script: - - apt-get update -qq - - apt-get install -y -qq git gcc libglib2.0-dev libpixman-1-dev make - genisoimage - - JOBS=$(expr $(nproc) + 1) - -.update_dnf_template: &before_script_dnf - before_script: - - dnf update -y - - dnf install -y bzip2 diffutils gcc git genisoimage findutils glib2-devel - make python3 perl-podlators perl-Test-Harness pixman-devel zlib-devel - - JOBS=$(expr $(nproc) + 1) +.native_build_job_template: &native_build_job_definition + stage: build + image: $CI_REGISTRY_IMAGE/qemu/$IMAGE:latest + before_script: + - JOBS=$(expr $(nproc) + 1) + script: + - mkdir build + - cd build + - if test -n "$TARGETS"; + then + ../configure --enable-werror $CONFIGURE_ARGS --target-list="$TARGETS" ; + else + ../configure --enable-werror $CONFIGURE_ARGS ; + fi + - make -j"$JOBS" + - make -j"$JOBS" $MAKE_CHECK_ARGS build-system1: - stage: build - image: ubuntu:19.10 - <<: *before_script_apt - script: - - apt-get install -y -qq libgtk-3-dev libvte-dev nettle-dev libcacard-dev - libusb-dev libvde-dev libspice-protocol-dev libgl1-mesa-dev libvdeplug-dev - - mkdir build - - cd build - - ../configure --enable-werror --target-list="aarch64-softmmu alpha-softmmu - cris-softmmu hppa-softmmu lm32-softmmu moxie-softmmu microblazeel-softmmu - mips64el-softmmu m68k-softmmu ppc-softmmu riscv64-softmmu sparc-softmmu" - - make -j"$JOBS" - - make -j"$JOBS" check + <<: *native_build_job_definition + variables: + IMAGE: ubuntu2004 + TARGETS: aarch64-softmmu alpha-softmmu cris-softmmu hppa-softmmu lm32-softmmu + moxie-softmmu microblazeel-softmmu mips64el-softmmu m68k-softmmu ppc-softmmu + riscv64-softmmu sparc-softmmu + MAKE_CHECK_ARGS: check build-system2: - stage: build - image: fedora:latest - <<: *before_script_dnf - script: - - yum install -y SDL2-devel libgcrypt-devel brlapi-devel libaio-devel - libfdt-devel lzo-devel librdmacm-devel libibverbs-devel libibumad-devel - libzstd-devel - - mkdir build - - cd build - - ../configure --enable-werror --target-list="tricore-softmmu unicore32-softmmu - microblaze-softmmu mips-softmmu riscv32-softmmu s390x-softmmu sh4-softmmu - sparc64-softmmu x86_64-softmmu xtensa-softmmu nios2-softmmu or1k-softmmu" - - make -j"$JOBS" - - make -j"$JOBS" check + <<: *native_build_job_definition + variables: + IMAGE: fedora + TARGETS: tricore-softmmu unicore32-softmmu microblaze-softmmu mips-softmmu + riscv32-softmmu s390x-softmmu sh4-softmmu sparc64-softmmu x86_64-softmmu + xtensa-softmmu nios2-softmmu or1k-softmmu + MAKE_CHECK_ARGS: check build-disabled: - stage: build - image: fedora:latest - <<: *before_script_dnf - script: - - mkdir build - - cd build - - ../configure --enable-werror --disable-rdma --disable-slirp --disable-curl + <<: *native_build_job_definition + variables: + IMAGE: fedora + CONFIGURE_ARGS: --disable-rdma --disable-slirp --disable-curl --disable-capstone --disable-live-block-migration --disable-glusterfs --disable-replication --disable-coroutine-pool --disable-smartcard --disable-guest-agent --disable-curses --disable-libxml2 --disable-tpm --disable-qom-cast-debug --disable-spice --disable-vhost-vsock --disable-vhost-net --disable-vhost-crypto --disable-vhost-user - --target-list="i386-softmmu ppc64-softmmu mips64-softmmu i386-linux-user" - - make -j"$JOBS" - - make -j"$JOBS" check-qtest SPEED=slow + TARGETS: i386-softmmu ppc64-softmmu mips64-softmmu i386-linux-user + MAKE_CHECK_ARGS: check-qtest SPEED=slow build-tcg-disabled: - stage: build - image: centos:8 - <<: *before_script_dnf - script: - - dnf install -y clang gtk3-devel libusbx-devel libgcrypt-devel - - mkdir build - - cd build - - ../configure --cc=clang --enable-werror --disable-tcg --audio-drv-list="" - - make -j"$JOBS" - - make check-unit - - make check-qapi-schema - - cd tests/qemu-iotests/ - - ./check -raw 001 002 003 004 005 008 009 010 011 012 021 025 032 033 048 + <<: *native_build_job_definition + variables: + IMAGE: centos8 + script: + - mkdir build + - cd build + - ../configure --disable-tcg --audio-drv-list="" + - make -j"$JOBS" + - make check-unit + - make check-qapi-schema + - cd tests/qemu-iotests/ + - ./check -raw 001 002 003 004 005 008 009 010 011 012 021 025 032 033 048 052 063 077 086 101 104 106 113 148 150 151 152 157 159 160 163 170 171 183 184 192 194 197 208 215 221 222 226 227 236 253 277 - - ./check -qcow2 028 051 056 057 058 065 067 068 082 085 091 095 096 102 122 + - ./check -qcow2 028 051 056 057 058 065 067 068 082 085 091 095 096 102 122 124 132 139 142 144 145 151 152 155 157 165 194 196 197 200 202 208 209 215 216 218 222 227 234 246 247 248 250 254 255 257 258 260 261 262 263 264 270 272 273 277 279 build-user: - stage: build - <<: *before_script_apt - script: - - mkdir build - - cd build - - ../configure --enable-werror --disable-system --disable-guest-agent - --disable-capstone --disable-slirp --disable-fdt - - make -j"$JOBS" - - make run-tcg-tests-i386-linux-user run-tcg-tests-x86_64-linux-user + <<: *native_build_job_definition + variables: + IMAGE: ubuntu2004 + CONFIGURE_ARGS: --disable-system --disable-guest-agent + --disable-capstone --disable-slirp --disable-fdt + MAKE_CHECK_ARGS: run-tcg-tests-i386-linux-user run-tcg-tests-x86_64-linux-user build-clang: - stage: build - image: fedora:latest - <<: *before_script_dnf - script: - - yum install -y clang SDL2-devel libattr-devel libcap-ng-devel xfsprogs-devel - libiscsi-devel libnfs-devel libseccomp-devel gnutls-devel librbd-devel - - mkdir build - - cd build - - ../configure --cc=clang --cxx=clang++ --enable-werror - --target-list="alpha-softmmu arm-softmmu m68k-softmmu mips64-softmmu - ppc-softmmu s390x-softmmu x86_64-softmmu arm-linux-user" - - make -j"$JOBS" - - make -j"$JOBS" check + <<: *native_build_job_definition + variables: + IMAGE: fedora + CONFIGURE_ARGS: --cc=clang --cxx=clang++ + TARGETS: alpha-softmmu arm-softmmu m68k-softmmu mips64-softmmu + ppc-softmmu s390x-softmmu x86_64-softmmu arm-linux-user + MAKE_CHECK_ARGS: check build-tci: - stage: build - image: centos:8 - <<: *before_script_dnf - script: - - TARGETS="aarch64 alpha arm hppa m68k microblaze moxie ppc64 s390x x86_64" - - mkdir build - - cd build - - ../configure --enable-tcg-interpreter - --target-list="$(for tg in $TARGETS; do echo -n ${tg}'-softmmu '; done)" - - make -j"$JOBS" - - make run-tcg-tests-x86_64-softmmu - - make tests/qtest/boot-serial-test tests/qtest/cdrom-test tests/qtest/pxe-test - - for tg in $TARGETS ; do - export QTEST_QEMU_BINARY="${tg}-softmmu/qemu-system-${tg}" ; - ./tests/qtest/boot-serial-test || exit 1 ; - ./tests/qtest/cdrom-test || exit 1 ; - done - - QTEST_QEMU_BINARY="x86_64-softmmu/qemu-system-x86_64" ./tests/qtest/pxe-test - - QTEST_QEMU_BINARY="s390x-softmmu/qemu-system-s390x" - ./tests/qtest/pxe-test -m slow + <<: *native_build_job_definition + variables: + IMAGE: fedora + script: + - TARGETS="aarch64 alpha arm hppa m68k microblaze moxie ppc64 s390x x86_64" + - mkdir build + - cd build + - ../configure --enable-tcg-interpreter + --target-list="$(for tg in $TARGETS; do echo -n ${tg}'-softmmu '; done)" + - make -j"$JOBS" + - make run-tcg-tests-x86_64-softmmu + - make tests/qtest/boot-serial-test tests/qtest/cdrom-test tests/qtest/pxe-test + - for tg in $TARGETS ; do + export QTEST_QEMU_BINARY="${tg}-softmmu/qemu-system-${tg}" ; + ./tests/qtest/boot-serial-test || exit 1 ; + ./tests/qtest/cdrom-test || exit 1 ; + done + - QTEST_QEMU_BINARY="x86_64-softmmu/qemu-system-x86_64" ./tests/qtest/pxe-test + - QTEST_QEMU_BINARY="s390x-softmmu/qemu-system-s390x" ./tests/qtest/pxe-test -m slow From patchwork Wed Jul 1 13:56:35 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Alex_Benn=C3=A9e?= X-Patchwork-Id: 192159 Delivered-To: patch@linaro.org Received: by 2002:a92:d244:0:0:0:0:0 with SMTP id v4csp532007ilg; Wed, 1 Jul 2020 07:12:49 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyPqahtmJnXPhrjf0aATX321NXIdBaIEE2dzQuCGetrtiNwpfQdVrZ0m+NtiFbDLzyrrfyY X-Received: by 2002:a05:6214:10e5:: with SMTP id q5mr25666058qvt.47.1593612769655; Wed, 01 Jul 2020 07:12:49 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1593612769; cv=none; d=google.com; s=arc-20160816; b=MW3yIGuT+qPKdS1hktcxyak2RPXegF6AFKkkON2OoYr4dg1vSEBrq2bqzrYmKR/7Wg zlwn12L9Zb0fmY6fSSQRY9CreH1U/uOy269xaKY0TaYErq0hlTNTQUA5fsEsjx7QYtsD N+K/yhBCqtutDdbeQWsI2vV4F3tko8pcVSX+5Sm5fs+tn1+SqtAMI4CVAD3RCaEZ1vGs TU45xQMZ9zglSSe3YqmAhLacl4dmjqfeG95U9jZ4UsxzBbg4cbA45bhRwgSKavj9S2Ot Oezx76uVA8AVTmEYBoygVLzJdzBiD/Itc7k5EjJ37NneEefX4rvcIsye3Fd82qm75iBF HUEg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:cc:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=TNPsrLyF7lXSFi67XMppVcIlDb8Jop3OMsLkQ8Zh/L0=; b=OASaq+kSbp1S4v9rZEXSTnYbtef8+PHr45xUWg9gA3BKRRvgiJKINrJbCkYV1I0wY/ TJbsUw1zhnkoqMY0loEEMGrAzuflFs1fdwUC5r4SMpHzilYn5NiN7vL+rZvdz2vTEBdc PZ5O6PzdX7V0aRPSImgA1Y2AQhj5DG4MrwfT+xol+PiP3MLiFDly0NMp+USE8g1a0QJP rgnGl1SHn1+RvOEKm71CrkgLh9mYMLNLg8n58mqQLEvjf7gcyvW7a+/z6ylt3is0sKtb nIiYH6YpaeD/wBjpsTMM637Jgv9EzHJHZdk588B+YpmqGRO4hWhF1YVqc2iPP0mtgHrI 9rNg== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=wxl4gecI; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id l56si4256924qtc.273.2020.07.01.07.12.49 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Wed, 01 Jul 2020 07:12:49 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=wxl4gecI; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1]:33208 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jqdTl-0003k1-3F for patch@linaro.org; Wed, 01 Jul 2020 10:12:49 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:59124) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jqdEo-0002af-Qg for qemu-devel@nongnu.org; Wed, 01 Jul 2020 09:57:22 -0400 Received: from mail-wm1-x343.google.com ([2a00:1450:4864:20::343]:34376) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1jqdEh-0005tA-8q for qemu-devel@nongnu.org; Wed, 01 Jul 2020 09:57:22 -0400 Received: by mail-wm1-x343.google.com with SMTP id g10so6888266wmc.1 for ; Wed, 01 Jul 2020 06:57:13 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=TNPsrLyF7lXSFi67XMppVcIlDb8Jop3OMsLkQ8Zh/L0=; b=wxl4gecImMJT4THqkLYBACUbfKIZwB++ODONQkyqLDLENty9DzcVnMc4zxOo2CCPxn aJc14UHBUYQE8DVUPkzSrcTr2TMvfh+ysCqkBYgVPTthLELR84WzvrKtVWO5pkOE9Vot q8E744gVxYZdKsldP47c8lL5seuP8L7VGJvjzJpf3wrFd0jUK+uacvetIy0ZynmHz8Ie pqEO2UATz9jeUNhAd6GEbkkzdOkpSefXin5r2gne8VJbkuN6Pzn5URNTX6cCBAwnafC3 zF1TSNYiPjsDxhdeCmZf2yNcuIb+nzMmrQqvhW0Zddj/PdO49B8cLi6a5wx8sC0woqMe CdrQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=TNPsrLyF7lXSFi67XMppVcIlDb8Jop3OMsLkQ8Zh/L0=; b=eV46P/iYZ7bdg57MrcnS60zYo6XY96ZEaUwaG/BHWZAOf83wXADzOGqqziFNGGM7X3 bfRtERRgn3x+FWYeeurIrqsAHo2Qj7Ma3MvM6vzcpZafrAnZuDyFMR+jq+eXBaOTC7Jq HIFiVWS0VH+pw10ORT5UiF3FmWaaneY+QXQAMQw3yjVNeoJzyCzpO1P8zRa/+w5/0H1U wqx/M0vuixP6//BzwciYm08HbKkW6fg9ExHHqYzcmUEMcJUpYc44QdHMrwG9XH7olJh7 WMqCGMgWI5WNR3RI2SJ/TE91lBB4LiRlQMezYoQCfg6REMbv/2+w1ew3Wxe0HIgiFSAS xKIQ== X-Gm-Message-State: AOAM5336D8aAL+lfphXslOlv4uVB5p6lw9aA0MZzyTklEEddO3tj3e8W Zy05QmuVpEdKjknqRSH9QWpSfw== X-Received: by 2002:a1c:f616:: with SMTP id w22mr27898939wmc.155.1593611833023; Wed, 01 Jul 2020 06:57:13 -0700 (PDT) Received: from zen.linaroharston ([51.148.130.216]) by smtp.gmail.com with ESMTPSA id 1sm7109422wmf.21.2020.07.01.06.57.00 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 01 Jul 2020 06:57:02 -0700 (PDT) Received: from zen.lan (localhost [127.0.0.1]) by zen.linaroharston (Postfix) with ESMTP id 46B371FFAC; Wed, 1 Jul 2020 14:56:55 +0100 (BST) From: =?utf-8?q?Alex_Benn=C3=A9e?= To: qemu-devel@nongnu.org Subject: [PATCH v4 23/40] gitlab: build containers with buildkit and metadata Date: Wed, 1 Jul 2020 14:56:35 +0100 Message-Id: <20200701135652.1366-24-alex.bennee@linaro.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20200701135652.1366-1-alex.bennee@linaro.org> References: <20200701135652.1366-1-alex.bennee@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::343; envelope-from=alex.bennee@linaro.org; helo=mail-wm1-x343.google.com X-detected-operating-system: by eggs.gnu.org: No matching host in p0f cache. That's all we know. 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=_AUTOLEARN X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: fam@euphon.net, berrange@redhat.com, =?utf-8?q?Alex_Benn=C3=A9e?= , richard.henderson@linaro.org, f4bug@amsat.org, cota@braap.org, aurelien@aurel32.net Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: "Qemu-devel" According to the documentation to be able to use --cache-from for remote registries you need to enable both buildkit and inline the metadata. We want to do this to support pulling from gitlab when users build their local docker images. Signed-off-by: Alex Bennée --- .gitlab-ci.d/containers.yml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) -- 2.20.1 diff --git a/.gitlab-ci.d/containers.yml b/.gitlab-ci.d/containers.yml index 2afd01f1d17..f353359fd8b 100644 --- a/.gitlab-ci.d/containers.yml +++ b/.gitlab-ci.d/containers.yml @@ -11,7 +11,9 @@ script: - docker pull "$TAG" || docker pull "$COMMON_TAG" || true - sed -i -e "s,FROM qemu/,FROM $CI_REGISTRY_IMAGE/qemu/," tests/docker/dockerfiles/$NAME.docker - - docker build --cache-from "$TAG" --cache-from "$COMMON_TAG" --tag "$TAG" -f "tests/docker/dockerfiles/$NAME.docker" tests/docker/dockerfiles + - DOCKER_BUILDKIT=1 docker build --cache-from "$TAG" --cache-from "$COMMON_TAG" --tag "$TAG" + --build-arg BUILDKIT_INLINE_CACHE=1 + -f "tests/docker/dockerfiles/$NAME.docker" tests/docker/dockerfiles - docker push "$TAG" after_script: - docker logout From patchwork Wed Jul 1 13:56:36 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Alex_Benn=C3=A9e?= X-Patchwork-Id: 192150 Delivered-To: patch@linaro.org Received: by 2002:a92:d244:0:0:0:0:0 with SMTP id v4csp526366ilg; Wed, 1 Jul 2020 07:06:39 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwIWRjklqUyEqnU7wXDrvmc2rdE9ymIh19zharIh7bjj9m6co6Jzd1FsOoQl8lEw3SMLn57 X-Received: by 2002:a05:6214:3ec:: with SMTP id cf12mr25706845qvb.251.1593612397566; Wed, 01 Jul 2020 07:06:37 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1593612397; cv=none; d=google.com; s=arc-20160816; b=ZwsgzePVSfIu+x+HeZftEMXSabUqtZvsp7JVdqgm5twmp4TU7BJkLy202PIVOOPVRa ikNa0uEflbtJzYNRJ8VZfSDbpr6//XtqKFnxxwzlbPVySn1cDXa8OzlhGcIOwMe4JbSJ G28J8HAUHFX5kNAfThpd3ho2atwi0uOcUGMvWj2GzYFVQqwIdpduZ4l5eP9vbu/6k+ZB /QcGhFaPQmz6nr3nVqLb5iQYz2lmYjEbnPikdhT5FOMhx2j41Sy5BmSZpAX0LWTFJKGA Fpw6Hi8rcIi6VUjZJukmxY23go4zKmSL3y3b7vLD5xhJulv9w7mMmRQed4vjNS/vCkdO Hm3w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:cc:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=ZQXPMBJFSRwRAMpnVcrqX7aTAD1ChFBfvwEUcI3QHF8=; b=d2haPVAfAGBFKGx9OeFEGjd2VXntzgGJC7c/s7tFOEV2n8nWL2SY5KlBtCaSOnI4Bv ymZMsdS4z7KZumFW9qPgZTe0paRLsoVyQod8NCKtO0LpXm1sIMW6aNilyPEARq3wqUsT YlYJ/NZgwN3IbSYozpeAsHgwaZvuqfM7kefxHTcBytIgq1sZapkta0qvmn6dQ0swhxAP MAn9t3vQ/bdpG2t9BeUpUyiAu+WmqOOhpXJkSVFmeeyaq14PXbkhzJGYA4RMl1u6vWQw qNQQXboLgVZmKfjFuJ5P0ueB09MSCRBXTb4P1jrpb7Wz7VZ3y5aWLVrVkaeWEPZG1ymL T9Ug== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=QV9lfwcP; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id d80si5239192ybh.484.2020.07.01.07.06.37 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Wed, 01 Jul 2020 07:06:37 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=QV9lfwcP; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1]:35892 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jqdNk-0001R2-MH for patch@linaro.org; Wed, 01 Jul 2020 10:06:36 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:59018) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jqdEf-0002Wu-RR for qemu-devel@nongnu.org; Wed, 01 Jul 2020 09:57:15 -0400 Received: from mail-wr1-x443.google.com ([2a00:1450:4864:20::443]:42401) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1jqdEb-0005sN-VL for qemu-devel@nongnu.org; Wed, 01 Jul 2020 09:57:13 -0400 Received: by mail-wr1-x443.google.com with SMTP id o11so23963673wrv.9 for ; Wed, 01 Jul 2020 06:57:09 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=ZQXPMBJFSRwRAMpnVcrqX7aTAD1ChFBfvwEUcI3QHF8=; b=QV9lfwcPg8Ttws8CsGNaD1CPyYpwfk+XUjlDyReZPoF9eZo0F4/F/8DvpURdMKCLci 1rDiqEbCpKFgMKAjfmPCCw/r5SHqeiGbFYWBI03AA3zI4qup9+aabS6qoovj0UChcP0U HCOuWUErC8QxVOWUYXbSXDVKAK1MKg0rQ5SiQ11FB42E3lBfHPP5qJsJwL33K434TFc4 u6ZB6K3WeTmDK+98niCm3P1Usd4Xr6czgUgW5NHrGBs3OPWRXTNQaKcnW44h4J9bMsI6 Lsdbu4+D/qq+jCPGE4PmdCBP35r0oNjHrn69XjLG/BYYyBwQScl8c+rxrbOIIj0AucOk BolQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=ZQXPMBJFSRwRAMpnVcrqX7aTAD1ChFBfvwEUcI3QHF8=; b=exK2T2MdWS6aFBy21shNs5k4lOpcVBAsMoKKdhNxF9a3cj3/5f7B9aOzanPwG/HtWs QIZ92bNIJ3HVyohVrHSbQRWbPiasTJwgV9S4+5l3MmjFlhESWOygmGR42QSdU8k7mOkr aHQFFkfpivQaV7tfQQrcm8UV5pitoRSFTZxGD+53bgjnk+gy+bUkvd9DmzRnVg48oa7M iee8oELghmd4lHgpdnFfoU5roRd5847v5DmorVg8l5K7Jz8lC8umT059ifXVHSxPmkir IhhUdSVV45M2Rpnvt8SyHE4TBN02kMPSpBfP8uMdI5IAqjeFMLJZccGdm/z0OFD37XYP WuIg== X-Gm-Message-State: AOAM530Au7MmRUBIxpcYWsaACh9HeORlW74xHo7+0uGrBvVDacqoUYkS jFGyrIkGEI/e5IvX5LVwUB9Gvw== X-Received: by 2002:adf:f311:: with SMTP id i17mr28013335wro.237.1593611828585; Wed, 01 Jul 2020 06:57:08 -0700 (PDT) Received: from zen.linaroharston ([51.148.130.216]) by smtp.gmail.com with ESMTPSA id n5sm7285076wmi.34.2020.07.01.06.57.00 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 01 Jul 2020 06:57:02 -0700 (PDT) Received: from zen.lan (localhost [127.0.0.1]) by zen.linaroharston (Postfix) with ESMTP id 5CFEB1FFAE; Wed, 1 Jul 2020 14:56:55 +0100 (BST) From: =?utf-8?q?Alex_Benn=C3=A9e?= To: qemu-devel@nongnu.org Subject: [PATCH v4 24/40] tests/docker: add --registry support to tooling Date: Wed, 1 Jul 2020 14:56:36 +0100 Message-Id: <20200701135652.1366-25-alex.bennee@linaro.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20200701135652.1366-1-alex.bennee@linaro.org> References: <20200701135652.1366-1-alex.bennee@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::443; envelope-from=alex.bennee@linaro.org; helo=mail-wr1-x443.google.com X-detected-operating-system: by eggs.gnu.org: No matching host in p0f cache. That's all we know. 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, URIBL_BLOCKED=0.001 autolearn=_AUTOLEARN X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: fam@euphon.net, berrange@redhat.com, =?utf-8?q?Alex_Benn=C3=A9e?= , richard.henderson@linaro.org, f4bug@amsat.org, =?utf-8?q?Philippe_Mat?= =?utf-8?q?hieu-Daud=C3=A9?= , cota@braap.org, aurelien@aurel32.net Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: "Qemu-devel" This allows us to point the tools towards a registry from which they can grab pre-built layers instead of doing everything from scratch each time. To enable this we need to be using the DOCKER_BUILDKIT engine. [AJB: note registry.gitlab.com/stsquad/qemu is for my testing, the final version will see DOCKER_REGISTRY default to registry.gitlab.com/qemu-project/qemu] Signed-off-by: Alex Bennée --- v2 - add a pull stage to pull images from the registry - enable BUILDKIT and BUILDKIT_INLINE_CACHE - don't invoke BUILDKIT on Travis v4 - Don't pass --registry in the NOCACHE case - precalc checksum before doing any replace steps --- tests/docker/Makefile.include | 6 ++++- tests/docker/docker.py | 44 ++++++++++++++++++++++++++++++----- 2 files changed, 43 insertions(+), 7 deletions(-) -- 2.20.1 diff --git a/tests/docker/Makefile.include b/tests/docker/Makefile.include index e23b4af20ea..977d8ff6e40 100644 --- a/tests/docker/Makefile.include +++ b/tests/docker/Makefile.include @@ -13,6 +13,7 @@ DOCKER_IMAGES := $(sort $(notdir $(basename $(wildcard $(DOCKER_FILES_DIR)/*.doc DOCKER_TARGETS := $(patsubst %,docker-image-%,$(DOCKER_IMAGES)) # Use a global constant ccache directory to speed up repetitive builds DOCKER_CCACHE_DIR := $$HOME/.cache/qemu-docker-ccache +DOCKER_REGISTRY := $(if $(REGISTRY),$(REGISTRY),registry.gitlab.com/stsquad/qemu) DOCKER_TESTS := $(notdir $(shell \ find $(SRC_PATH)/tests/docker/ -name 'test-*' -type f)) @@ -56,7 +57,9 @@ else docker-image-%: $(DOCKER_FILES_DIR)/%.docker $(call quiet-command,\ $(DOCKER_SCRIPT) build -t qemu/$* -f $< \ - $(if $V,,--quiet) $(if $(NOCACHE),--no-cache) \ + $(if $V,,--quiet) \ + $(if $(NOCACHE),--no-cache, \ + $(if $(DOCKER_REGISTRY),--registry $(DOCKER_REGISTRY))) \ $(if $(NOUSER),,--add-current-user) \ $(if $(EXTRA_FILES),--extra-files $(EXTRA_FILES))\ $(if $(EXECUTABLE),--include-executable=$(EXECUTABLE)),\ @@ -213,6 +216,7 @@ endif @echo ' Include extra files in image.' @echo ' ENGINE=auto/docker/podman' @echo ' Specify which container engine to run.' + @echo ' REGISTRY=url Cache builds from registry (default:$(DOCKER_REGISTRY))' # This rule if for directly running against an arbitrary docker target. # It is called by the expanded docker targets (e.g. make diff --git a/tests/docker/docker.py b/tests/docker/docker.py index cc6f76caa60..9684f07bdeb 100755 --- a/tests/docker/docker.py +++ b/tests/docker/docker.py @@ -221,6 +221,13 @@ class Docker(object): """ Running Docker commands """ def __init__(self): self._command = _guess_engine_command() + + if "docker" in self._command and "TRAVIS" not in os.environ: + os.environ["DOCKER_BUILDKIT"] = "1" + self._buildkit = True + else: + self._buildkit = False + self._instance = None atexit.register(self._kill_instances) signal.signal(signal.SIGTERM, self._kill_instances) @@ -289,10 +296,24 @@ class Docker(object): return labels.get("com.qemu.dockerfile-checksum", "") def build_image(self, tag, docker_dir, dockerfile, - quiet=True, user=False, argv=None, extra_files_cksum=[]): + quiet=True, user=False, argv=None, registry=None, + extra_files_cksum=[]): if argv is None: argv = [] + # pre-calculate the docker checksum before any + # substitutions we make for caching + checksum = _text_checksum(_dockerfile_preprocess(dockerfile)) + + if registry is not None: + dockerfile = dockerfile.replace("FROM qemu/", + "FROM %s/qemu/" % + (registry)) + # see if we can fetch a cache copy, may fail... + pull_args = ["pull", "%s/%s" % (registry, tag)] + self._do(pull_args, quiet=quiet) + + tmp_df = tempfile.NamedTemporaryFile(mode="w+t", encoding='utf-8', dir=docker_dir, suffix=".docker") @@ -306,15 +327,23 @@ class Docker(object): (uname, uid, uname)) tmp_df.write("\n") - tmp_df.write("LABEL com.qemu.dockerfile-checksum=%s" % - _text_checksum(_dockerfile_preprocess(dockerfile))) + tmp_df.write("LABEL com.qemu.dockerfile-checksum=%s" % (checksum)) for f, c in extra_files_cksum: tmp_df.write("LABEL com.qemu.%s-checksum=%s" % (f, c)) tmp_df.flush() - self._do_check(["build", "-t", tag, "-f", tmp_df.name] + argv + - [docker_dir], + build_args = ["build", "-t", tag, "-f", tmp_df.name] + if self._buildkit: + build_args += ["--build-arg", "BUILDKIT_INLINE_CACHE=1"] + + if registry is not None: + cache = "%s/%s" % (registry, tag) + build_args += ["--cache-from", cache] + build_args += argv + build_args += [docker_dir] + + self._do_check(build_args, quiet=quiet) def update_image(self, tag, tarball, quiet=True): @@ -403,6 +432,8 @@ class BuildCommand(SubCommand): parser.add_argument("--add-current-user", "-u", dest="user", action="store_true", help="Add the current user to image's passwd") + parser.add_argument("--registry", "-r", + help="cache from docker registry") parser.add_argument("-t", dest="tag", help="Image Tag") parser.add_argument("-f", dest="dockerfile", @@ -458,7 +489,8 @@ class BuildCommand(SubCommand): for k, v in os.environ.items() if k.lower() in FILTERED_ENV_NAMES] dkr.build_image(tag, docker_dir, dockerfile, - quiet=args.quiet, user=args.user, argv=argv, + quiet=args.quiet, user=args.user, + argv=argv, registry=args.registry, extra_files_cksum=cksum) rmtree(docker_dir) From patchwork Wed Jul 1 13:56:37 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Alex_Benn=C3=A9e?= X-Patchwork-Id: 192144 Delivered-To: patch@linaro.org Received: by 2002:a92:d244:0:0:0:0:0 with SMTP id v4csp523254ilg; Wed, 1 Jul 2020 07:03:45 -0700 (PDT) X-Google-Smtp-Source: ABdhPJz87jtdl+RLoBoyxOr0A3nmK3Ljl8IJ8Jqf/PQWirgVnkVVnuR+qeRXIpIhyAQdhMDMFpVH X-Received: by 2002:a5b:48f:: with SMTP id n15mr32761176ybp.115.1593612225578; Wed, 01 Jul 2020 07:03:45 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1593612225; cv=none; d=google.com; s=arc-20160816; b=OoXd6bfGtklKlUQXTWtS0sx6WpTVfeGbF41edcgFuB6zPjA4Ag7EIY8ODR5a11RsQD QqMPEL5Xbm/nDw4e7eKq5b3b9HdfiK07wIYNZVRGkUnQASYf51LH/uNZC8hNa6mr9eeW bOcvt0t/aV6QVqsH94u8YJX0B444S91YckroR06FLl6OEK5hrpstsSpz4peI6k3zsP1I AzPwFzW8ifiSKG8ve6ExXgksVX+dVouFbf/yXeFBdpBnePQS/JJxBUSeH7G0nnYbMVVT nCjAmE8oq2WSgCWJwnBqbhDhkkXXPeIh3YDeXiVGaODwU1kSwsZNqhA8NUkkZMcTiHGJ x1zw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:cc:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=L8UfFOdn0PEpfIwJNpttfVutTAGLSZl2+EE67E2O1dE=; b=cdMKU50cG11msfumPrQpr0sl3ZX0cMbH0FIJ0HJp3qAos0toh7w68ownyJZyZ11unP u0J8it2e0atSXnSy2xsT7xxS/VaZENuaQNPB90h8wM9FURFkUYE9gDmtqbvTF3JAYs7q j0jYsRMR3tT7prslvuFd8kQq0FqnjkdudGgOif43Wve578KgNxtZVRARRNnXh3h6OBiE nBKK0hYxGso9jfKeurp96xwIWePRKVAIriFZoVg4F2hNMbuErZSU80/jgLidsKfJwuB+ ZvncLP2Z+oix4UKo/aYOo6LuBsX/GeUBrqLUKZ9EhVRi6oMEdnfnBvTS6CZJyzj9UvhF KwzQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=ECf6hMdn; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id c22si5728564ybf.201.2020.07.01.07.03.45 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Wed, 01 Jul 2020 07:03:45 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=ECf6hMdn; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1]:51720 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jqdKy-0004bI-P0 for patch@linaro.org; Wed, 01 Jul 2020 10:03:44 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:58952) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jqdEc-0002VK-2r for qemu-devel@nongnu.org; Wed, 01 Jul 2020 09:57:11 -0400 Received: from mail-wr1-x432.google.com ([2a00:1450:4864:20::432]:42727) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1jqdEa-0005s0-5V for qemu-devel@nongnu.org; Wed, 01 Jul 2020 09:57:09 -0400 Received: by mail-wr1-x432.google.com with SMTP id o11so23963513wrv.9 for ; Wed, 01 Jul 2020 06:57:07 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=L8UfFOdn0PEpfIwJNpttfVutTAGLSZl2+EE67E2O1dE=; b=ECf6hMdnZSxiSvyASALYKL8QtN0yvYibTwrCRMVphCpoOSQkwGa9xHsW4qZblU4/7e F+jDv4EF+Iqkz3073JBo52kCk+/yxtN2OGc9MvuPA/piZxAsDzdKxbhVAQA45ouCY0FO L4V7mIQl+wl6WCh9peaa6vnG0JzUd8nXJ3czSTUlIJYnKm3nvjd/TkCL6VT5iZw/zJt/ edGIjGIsFBBMlKLDtHPpfsptnhAVWMlT11zWvoRYTc6eih/gj3rbGoO/MkgJSIzE0ffP aeHxSrafSlYIV10eDNsf1ioY1XGOLTlXRL1HpWya1gk6rifZhu9QgBAVlXZK15jsHl1T Hahw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=L8UfFOdn0PEpfIwJNpttfVutTAGLSZl2+EE67E2O1dE=; b=kGjeXGQZAHTF4mvzEeU8WhZVcqgh3oQIHlkiHIGmxOuINK/lRAiLr/v2tcGBJbQqNs tCuHEV+MGq2oxDsnsnLDRIIjLWEeXnEaRGAdju3gILUz+Xc+QMHHhYE9O8ZwVGPM5FFS m4WsuioPePTviawfmmg/YNiZNA/2yK+L6drqUORI27Av3EflnoAP/Uad1KqIJomDEN+r qCF8OUIOqygaZ7AAU8gwmBR2hhjpXufxzg35nXO9yOcDX8wEgaZjre5Xkxc8ncBnc6Xc ZZbQO7Bj5FQMa0/HWMPsJdBVbKoEWTzd3fcb5qJHXQepnucZ3NELzZDzeRRgITlPejHY 7XLQ== X-Gm-Message-State: AOAM5331cwh41Hcl0ECa/YRolVy9CcG9ry8DEgCfTcp8fRft3ZQpAd1h TwhJ630sCApE1mojpe0tyKisTQ== X-Received: by 2002:a5d:43d2:: with SMTP id v18mr26461379wrr.196.1593611826657; Wed, 01 Jul 2020 06:57:06 -0700 (PDT) Received: from zen.linaroharston ([51.148.130.216]) by smtp.gmail.com with ESMTPSA id c65sm7158037wme.8.2020.07.01.06.57.00 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 01 Jul 2020 06:57:02 -0700 (PDT) Received: from zen.lan (localhost [127.0.0.1]) by zen.linaroharston (Postfix) with ESMTP id 73CAF1FFAF; Wed, 1 Jul 2020 14:56:55 +0100 (BST) From: =?utf-8?q?Alex_Benn=C3=A9e?= To: qemu-devel@nongnu.org Subject: [PATCH v4 25/40] tests/docker: add packages needed for check-acceptance Date: Wed, 1 Jul 2020 14:56:37 +0100 Message-Id: <20200701135652.1366-26-alex.bennee@linaro.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20200701135652.1366-1-alex.bennee@linaro.org> References: <20200701135652.1366-1-alex.bennee@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::432; envelope-from=alex.bennee@linaro.org; helo=mail-wr1-x432.google.com X-detected-operating-system: by eggs.gnu.org: No matching host in p0f cache. That's all we know. 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=_AUTOLEARN X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: fam@euphon.net, Thomas Huth , berrange@redhat.com, =?utf-8?q?Alex_Benn=C3=A9e?= , richard.henderson@linaro.org, f4bug@amsat.org, =?utf-8?q?Philippe_Mat?= =?utf-8?q?hieu-Daud=C3=A9?= , cota@braap.org, aurelien@aurel32.net Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: "Qemu-devel" We need additional python packages to run check-acceptance. Add them to the docker images we will be using later. Signed-off-by: Alex Bennée Reviewed-by: Philippe Mathieu-Daudé Reviewed-by: Thomas Huth --- tests/docker/dockerfiles/fedora.docker | 7 +++++++ tests/docker/dockerfiles/ubuntu2004.docker | 10 +++++++++- 2 files changed, 16 insertions(+), 1 deletion(-) -- 2.20.1 diff --git a/tests/docker/dockerfiles/fedora.docker b/tests/docker/dockerfiles/fedora.docker index 798ddd2c3e0..70b6186bd3e 100644 --- a/tests/docker/dockerfiles/fedora.docker +++ b/tests/docker/dockerfiles/fedora.docker @@ -80,7 +80,12 @@ ENV PACKAGES \ pixman-devel \ python3 \ python3-PyYAML \ + python3-numpy \ + python3-opencv \ + python3-pillow \ + python3-pip \ python3-sphinx \ + python3-virtualenv \ rdma-core-devel \ SDL2-devel \ snappy-devel \ @@ -89,6 +94,8 @@ ENV PACKAGES \ systemd-devel \ systemtap-sdt-devel \ tar \ + tesseract \ + tesseract-langpack-eng \ texinfo \ usbredir-devel \ virglrenderer-devel \ diff --git a/tests/docker/dockerfiles/ubuntu2004.docker b/tests/docker/dockerfiles/ubuntu2004.docker index 6050ce7e8a8..f7aac840bf8 100644 --- a/tests/docker/dockerfiles/ubuntu2004.docker +++ b/tests/docker/dockerfiles/ubuntu2004.docker @@ -46,9 +46,17 @@ ENV PACKAGES flex bison \ libxen-dev \ libzstd-dev \ make \ - python3-yaml \ + python3-numpy \ + python3-opencv \ + python3-pil \ + python3-pip \ python3-sphinx \ + python3-venv \ + python3-yaml \ + rpm2cpio \ sparse \ + tesseract-ocr \ + tesseract-ocr-eng \ texinfo \ xfslibs-dev\ vim From patchwork Wed Jul 1 13:56:38 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Alex_Benn=C3=A9e?= X-Patchwork-Id: 192152 Delivered-To: patch@linaro.org Received: by 2002:a92:d244:0:0:0:0:0 with SMTP id v4csp527847ilg; Wed, 1 Jul 2020 07:08:14 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyItQGd8SC7SIbg2mF6boaMMujL45Xn8gk9+KGADCN2S9HF74WghuVg+AklkR4kFdZoQj2k X-Received: by 2002:ac8:6882:: with SMTP id m2mr26542478qtq.231.1593612493936; Wed, 01 Jul 2020 07:08:13 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1593612493; cv=none; d=google.com; s=arc-20160816; b=J9IVI7QMP+WdpYaZHXOtFTlrnPQZswwfTO0/2ZBY31M0ZK5vWYwCEbCECHBybppV3S rReRF3oGg+3g7012IxpeVMYw04VX2kHEfa72tx4wEVrNibctqVJ6mgoLeXmtM7sOCUTh 6CJAuRb6sSuGJC5QG2NBjagiT2VKeGunjip76TkCsftV3y8ktZtaUCYQFtZh75RopGlH DxIXhEBL3x/VDRUFWED1z88vgsGsdl0wsdc7WjP06yYE10tMkrW7r3hsG+npH0OlM9nX Hj/FJclBQ3S1M8l/4qycY8QKz3DOYGZjatysiew0DvC/a3zhcOkIrM7WBUrGjB9DeyJv FWDA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:cc:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=CRf3v0aaaaR+c9GY3Mn+3wHhPs/9iLnwOOfyb/6spX0=; b=A+bW4mVnMEmYoRljnLn+hV+gFswYNZDLwtk9YnvHXEElS4tgBQsS5+vO3W+Y0GWDJJ glc48tm11R0GY5OBm8TcxjnJI1eygH1e5R9mZ2v+JHkWjHt/3L55b55gD1GyFt19ceaD gzL9xlAR7sZHSgRT6RigwCFz5Tgbz0pw6kW8KMjE0ShJFCV7/3olnS0Z9XA2Y8OJrdZz UWgRDBQ0uLuNEYsdW1eWoOjMon0tG1feSrzadfEyN3cgWOIIRqlvlmMU5hZ/3T6VabQ8 ZUB6SpYkMB8BOopdsMWDXRIBVvILH76VkeKaft1/1r4Lcs4i/jIXA5aE47PZbQUHCaTT 0W3Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=MnGkTs62; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id x16si2108411qkm.379.2020.07.01.07.08.13 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Wed, 01 Jul 2020 07:08:13 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=MnGkTs62; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1]:40792 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jqdPJ-0003Tj-AU for patch@linaro.org; Wed, 01 Jul 2020 10:08:13 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:59100) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jqdEl-0002aS-T5 for qemu-devel@nongnu.org; Wed, 01 Jul 2020 09:57:22 -0400 Received: from mail-wr1-x441.google.com ([2a00:1450:4864:20::441]:40068) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1jqdEd-0005sZ-O4 for qemu-devel@nongnu.org; Wed, 01 Jul 2020 09:57:19 -0400 Received: by mail-wr1-x441.google.com with SMTP id h5so23946823wrc.7 for ; Wed, 01 Jul 2020 06:57:10 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=CRf3v0aaaaR+c9GY3Mn+3wHhPs/9iLnwOOfyb/6spX0=; b=MnGkTs62GIjDUDCSW2mDMS1rzy4p/9jBi89tjeATcisAQ1ujXbRPaXrPocKYRXHTVY Lw5kl5QjotHF7SY4l4GhNcJNCYahPie+16tGklWcVZZp+qIXM0YQHpjhWOg2uKXtJYMe Glq3GBO/1g4JRCFxrucaLYqn5/rzbGvfssFwvBrHyeGPdCTyHbLlXD5bXCFSi0wwBIbF MhDojqT8BdQdS9nC6huEZox42yrGyzDOVe+TgiFkFcICMMP+ThzhapXtC3BSCZ1Ry+d3 ZgljM+3LVEWHKBptLTbX9sx+7Zvbjns5Khgo+gslN54VFWJ+Uw7qhfMm41w9sztRfMgB HuTg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=CRf3v0aaaaR+c9GY3Mn+3wHhPs/9iLnwOOfyb/6spX0=; b=H91Gi3qiSk4grg3etdK6K2l7gDyf5rHAwY/Q+vaFywJO8BjDcvsQTXpWlB+vYkCQPS zueD278sJJ1FE6P360STcZdrlZOUIU33UBQcFaaCwdvlLs72+NcauUbIIEoS0Kj+uRPG /gCT8FAVY64ihdATlPUCcWX5BL1N7O+vgIL9RgJTdDSaSf4wGW1yxrfRmeqANDKOLBMx O4jEvrxmIJKX7NeqTzT8Ac0U61MntxGthncs5DvXlu3iHHYl8Ks1nc/UwB1Rt8YQnX1o hVyPATdKGtu8HZBCP8skF4QqrmkUTmwEQvi4nEX9ZkkEI+5Pa73hmOvbTaHs5eDf9Dbg /6BA== X-Gm-Message-State: AOAM531gs4jgBLcYigLKoRl8/jTB5GaVBZnhBeRd/JvqCamoXsEm6M1r 7pTk/KazMAQK4mvlSQbIATYFiw== X-Received: by 2002:adf:f842:: with SMTP id d2mr29114629wrq.55.1593611829478; Wed, 01 Jul 2020 06:57:09 -0700 (PDT) Received: from zen.linaroharston ([51.148.130.216]) by smtp.gmail.com with ESMTPSA id f12sm7656081wrj.48.2020.07.01.06.57.00 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 01 Jul 2020 06:57:02 -0700 (PDT) Received: from zen.lan (localhost [127.0.0.1]) by zen.linaroharston (Postfix) with ESMTP id 88B051FFB1; Wed, 1 Jul 2020 14:56:55 +0100 (BST) From: =?utf-8?q?Alex_Benn=C3=A9e?= To: qemu-devel@nongnu.org Subject: [PATCH v4 26/40] tests/acceptance: skip s390x_ccw_vrtio_tcg on GitLab Date: Wed, 1 Jul 2020 14:56:38 +0100 Message-Id: <20200701135652.1366-27-alex.bennee@linaro.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20200701135652.1366-1-alex.bennee@linaro.org> References: <20200701135652.1366-1-alex.bennee@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::441; envelope-from=alex.bennee@linaro.org; helo=mail-wr1-x441.google.com X-detected-operating-system: by eggs.gnu.org: No matching host in p0f cache. That's all we know. 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=_AUTOLEARN X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: fam@euphon.net, Thomas Huth , berrange@redhat.com, =?utf-8?q?Alex_Benn=C3=A9e?= , Cornelia Huck , richard.henderson@linaro.org, f4bug@amsat.org, Wainer dos Santos Moschetta , =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= , "open list:S390 general arch..." , cota@braap.org, Cleber Rosa , aurelien@aurel32.net Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: "Qemu-devel" Currently the test takes more the 900 seconds on GitLab and then times out. Running on Travis seems to be OK. Signed-off-by: Alex Bennée --- tests/acceptance/boot_linux.py | 2 ++ 1 file changed, 2 insertions(+) -- 2.20.1 diff --git a/tests/acceptance/boot_linux.py b/tests/acceptance/boot_linux.py index 3aa57e88b0b..0055dc7cee7 100644 --- a/tests/acceptance/boot_linux.py +++ b/tests/acceptance/boot_linux.py @@ -20,6 +20,7 @@ from avocado.utils import network from avocado.utils import vmimage from avocado.utils import datadrainer from avocado.utils.path import find_command +from avocado import skipIf ACCEL_NOT_AVAILABLE_FMT = "%s accelerator does not seem to be available" KVM_NOT_AVAILABLE = ACCEL_NOT_AVAILABLE_FMT % "KVM" @@ -220,6 +221,7 @@ class BootLinuxS390X(BootLinux): chksum = '4caaab5a434fd4d1079149a072fdc7891e354f834d355069ca982fdcaf5a122d' + @skipIf(os.getenv('GITLAB_CI'), 'Running on GitLab') def test_s390_ccw_virtio_tcg(self): """ :avocado: tags=machine:s390-ccw-virtio From patchwork Wed Jul 1 13:56:39 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Alex_Benn=C3=A9e?= X-Patchwork-Id: 192157 Delivered-To: patch@linaro.org Received: by 2002:a92:d244:0:0:0:0:0 with SMTP id v4csp531537ilg; Wed, 1 Jul 2020 07:12:16 -0700 (PDT) X-Google-Smtp-Source: ABdhPJy0MTPr94Vkpd4HD8rUEwPl6TCXUkjgoBdoCQKk0Mw2u1qQd3t8JL4bnq35OutvEIXR3DFn X-Received: by 2002:a05:620a:989:: with SMTP id x9mr16520334qkx.66.1593612736738; Wed, 01 Jul 2020 07:12:16 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1593612736; cv=none; d=google.com; s=arc-20160816; b=GVS3wkLsyPXTJ0tMC8UUwdurAJUuuNwI3ec4PoAp0WmcuaGNKAbqM0U19TwL8fNMoX 1+A8JeAbuL3EfIQelZyQfzZVRsILerJp0BkQu5uuS1mj/w0iln1Xp5YNBQBaLyQ1O+ab QpG1eKBezBHOcXR7q3GyLaj+yN0xabaARG8h2KCN5hjDQoKxnn5/MaM7oltwNhC/vsN9 LtViZhDAONhBcwmGZZXvHkc7A4y2XyVmHVXKQHoWMQiyJxygjewwVTP+/NpxQiEsRqYg +pKtI+GPr8/wOFmGZBr3EHp9SmkWJa4ZiqsQsHXfKjuXsjOvOhWxyxi5LyB2I6ZNXUB+ Ffnw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:cc:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=pcMZ/obXnz3i4V6AJOF1d+E1lr/wSxwpDkghVxLQofU=; b=073yQi3hANHvW8K1E9qN+iTf5dWY4TJ9xc4Jn652gYeZYXCU4ve3gsjRUFKjZJ82t1 0XXGPrHA+DP9od3j0xNJgARYZoAqNqqu2UorqBbHIM58tj3RfEHG9xCyHOjrXxynd3iI d3G/pQPTu4uZQ299IP2b3SWwagnaiijV6Z6e9+EKOEdbQfctGN9vJqwRJQDQoDE7z+ya LqJhEEYnD8k2Ryo7gkoPkHU7dsEVHpbGNQI6F0WedHvgbNljyU32RDEgWhSCG07Tilwu tmMV8LTR9hGwD+kRQqytpzWBqtzp3CmMPI2OzHkquRjxOJxk1xPZsmdo0CxwpMF6p3NZ zwSQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=ne7BbYYU; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id v6si4063109qtk.247.2020.07.01.07.12.16 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Wed, 01 Jul 2020 07:12:16 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=ne7BbYYU; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1]:58486 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jqdTE-0002U4-4R for patch@linaro.org; Wed, 01 Jul 2020 10:12:16 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:60816) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jqdKr-0004nU-H5 for qemu-devel@nongnu.org; Wed, 01 Jul 2020 10:03:37 -0400 Received: from mail-wm1-x341.google.com ([2a00:1450:4864:20::341]:37851) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1jqdKl-0006om-Sz for qemu-devel@nongnu.org; Wed, 01 Jul 2020 10:03:37 -0400 Received: by mail-wm1-x341.google.com with SMTP id o2so23396855wmh.2 for ; Wed, 01 Jul 2020 07:03:31 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=pcMZ/obXnz3i4V6AJOF1d+E1lr/wSxwpDkghVxLQofU=; b=ne7BbYYUPGqQ4gOO2pqVyltzSPxSk5g3bbKAs0ix0pW/vg9x0GoLC775o5s61wPYCm 3FnADJ4CIg265fOYvP5XBHO8e1Gp3jh8o59WnhRD5cdatWhd4DOkVuLiL/r+7XuTz00N OVqG2acLbGWq2N9EqTCfkG3Cffr/YcnZHhLZLvrdOSSUWRkG0AsNiQlepRWVhQupEKLs Xf2jwOprYTAyrwF8VTM/+NPmRIiQbliz8wfyjIS5fQn7GeiryTmBt7RxEHOFuJv5Hi+J +PGfnnxQTIsCkqJZdBX2zbWpfi1ySxk01UyjXXSTu6SDtBey5H9BV0FwrdjHR66kACiN Y3zw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=pcMZ/obXnz3i4V6AJOF1d+E1lr/wSxwpDkghVxLQofU=; b=MTLKXQn9ZioXiHPTWao8j3FdFmhQID1hZmfNBbvb9Qc7eQN+7kE5Xq6S/Vg2s6TPfv o/5aEN3GGGic138ZjgSzSHfKc2Wd/FFSfqvaIP+VrQeeU6qtH9wy45V5BD/+6HAbzF9d hJYVqInCEx9ZniU+uK1xfgANmi0CVJBWJsni5SQTtrO/qIu5of7v1gSjpSm7k4Qfco5l fOiAFmds2qJ5hOD3xxD0imx9Hu7OOZFkIpHcmBfx3OIcRcTB1DI5UhyohXPOOAi/dmCD b20EF0NhhTGMWVidQRRwKFz3bEDiwZ2lAxK4Tpo2bWAilVgHR+HVROg2XojHPd7rVgNf QOgw== X-Gm-Message-State: AOAM533k/4tJeSB14vn399P3Wf/Xwh119nuyu2pwgrrZCySwSMNcu1Ed /L9NK/pm4CAPEF/4xp7R8wASWQ== X-Received: by 2002:a1c:6308:: with SMTP id x8mr28001926wmb.92.1593612210468; Wed, 01 Jul 2020 07:03:30 -0700 (PDT) Received: from zen.linaroharston ([51.148.130.216]) by smtp.gmail.com with ESMTPSA id u2sm6878069wml.16.2020.07.01.07.03.26 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 01 Jul 2020 07:03:26 -0700 (PDT) Received: from zen.lan (localhost [127.0.0.1]) by zen.linaroharston (Postfix) with ESMTP id 9FF731FFB3; Wed, 1 Jul 2020 14:56:55 +0100 (BST) From: =?utf-8?q?Alex_Benn=C3=A9e?= To: qemu-devel@nongnu.org Subject: [PATCH v4 27/40] tests/acceptance: fix dtb path for machine_rx_gdbsim Date: Wed, 1 Jul 2020 14:56:39 +0100 Message-Id: <20200701135652.1366-28-alex.bennee@linaro.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20200701135652.1366-1-alex.bennee@linaro.org> References: <20200701135652.1366-1-alex.bennee@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::341; envelope-from=alex.bennee@linaro.org; helo=mail-wm1-x341.google.com X-detected-operating-system: by eggs.gnu.org: No matching host in p0f cache. That's all we know. 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, URIBL_BLOCKED=0.001 autolearn=_AUTOLEARN X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: fam@euphon.net, berrange@redhat.com, Yoshinori Sato , =?utf-8?q?Alex_Benn=C3=A9e?= , richard.henderson@linaro.org, f4bug@amsat.org, Wainer dos Santos Moschetta , =?utf-8?q?Philippe_Mathieu-Daud?= =?utf-8?b?w6k=?= , cota@braap.org, Cleber Rosa , aurelien@aurel32.net Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: "Qemu-devel" The old path doesn't exist but the rx-virt.dtb file has the same checksum so lets use that. Signed-off-by: Alex Bennée --- tests/acceptance/machine_rx_gdbsim.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) -- 2.20.1 Acked-by: Philippe Mathieu-Daudé diff --git a/tests/acceptance/machine_rx_gdbsim.py b/tests/acceptance/machine_rx_gdbsim.py index a44f2c87da0..bff63e421d5 100644 --- a/tests/acceptance/machine_rx_gdbsim.py +++ b/tests/acceptance/machine_rx_gdbsim.py @@ -50,7 +50,7 @@ class RxGdbSimMachine(Test): :avocado: tags=machine:gdbsim-r5f562n7 :avocado: tags=endian:little """ - dtb_url = ('https://acc.dl.osdn.jp/users/23/23887/rx-qemu.dtb') + dtb_url = ('https://acc.dl.osdn.jp/users/23/23887/rx-virt.dtb') dtb_hash = '7b4e4e2c71905da44e86ce47adee2210b026ac18' dtb_path = self.fetch_asset(dtb_url, asset_hash=dtb_hash) kernel_url = ('http://acc.dl.osdn.jp/users/23/23845/zImage') From patchwork Wed Jul 1 13:56:40 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Alex_Benn=C3=A9e?= X-Patchwork-Id: 192165 Delivered-To: patch@linaro.org Received: by 2002:a92:d244:0:0:0:0:0 with SMTP id v4csp534928ilg; Wed, 1 Jul 2020 07:16:11 -0700 (PDT) X-Google-Smtp-Source: ABdhPJy1oswcUSzyCGnthNvNV8V1gbzYyOczTMM/QfcDQSLBZFMUj8kasjkpR6Z45wSiUEwfAsiC X-Received: by 2002:aed:3fac:: with SMTP id s41mr25688703qth.86.1593612971793; Wed, 01 Jul 2020 07:16:11 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1593612971; cv=none; d=google.com; s=arc-20160816; b=hmeeEnmYu4E+Kf3JHHsONwhSX666lJpuyf+YCUZiaRxCvM5fsbRZBKWqRC3jxCQpdB H/mFEO6r3MQCQK9GdDViXOg1xR5+YIvaJKHY1axG3bRXlHvloIkILInLTYmfJT36SBaS jjb4oQKL0j91rUXApKafJbrPOjSDafxb/9jMxDi2ViXcN5LPyM4LIWQZYzM2ahq+bbC3 1WtuWm2mCtPXl+cuq+7l64tEgf7vxlbKkq/mTZ+FAsAOPV3WVlJvNOqSOSySkuNfSu1r 87RcBML+DlLoGTo0Nq1TMwK4fUSAZ0nAz80JW+Fiq3TYXZfJE6doJ/on1XJJEaSBNe2t w41Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:cc:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=1wb2ncrOo7CGsE7dWRGEM3akfUu5tO0R9Fr5WIVAS98=; b=E2V8RUwZF0Cqw0uJI7gtHGWXiN5DEMeOwkXqSi3wxCvX/GkMxzDF/FCms2sLhRYnYp OP2TX3CRI3HBbtOLhWOhCiid1CQinaOX8RoYSOdho/ibh4GxEGpPKC0BMA3JV16YNDZi D+0+9YfEGNSuNJu4Ij7dHwWM1tykIOT6q35wdQXMTii/o/8Nk/XwUpN+y8j0GjlaNM97 W9Uphsw31LIG37URjPRz6GuuqGPjVarR1ky5s3ujhaVe35t22CAgiXMS8Y8UIECUSBUR TCD260kM3YvQkomYUXMeVEea2ig6ZmoC7ly1iNwNNsifWMlNVgwVNEIiMuVbq8tIkdGS Ngrw== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=Nxl6d1ny; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id t12si3786702qvb.116.2020.07.01.07.16.11 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Wed, 01 Jul 2020 07:16:11 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=Nxl6d1ny; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1]:47222 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jqdX1-0001A4-4P for patch@linaro.org; Wed, 01 Jul 2020 10:16:11 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:60946) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jqdL1-0005B7-5J for qemu-devel@nongnu.org; Wed, 01 Jul 2020 10:03:47 -0400 Received: from mail-wr1-x435.google.com ([2a00:1450:4864:20::435]:36493) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1jqdKz-0006r2-8p for qemu-devel@nongnu.org; Wed, 01 Jul 2020 10:03:46 -0400 Received: by mail-wr1-x435.google.com with SMTP id k6so24005188wrn.3 for ; Wed, 01 Jul 2020 07:03:44 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=1wb2ncrOo7CGsE7dWRGEM3akfUu5tO0R9Fr5WIVAS98=; b=Nxl6d1nyOgVwpHdrLCNWKsP8PXAXIFBdgvSu7rQ3azXHfDlLo3j89/DC6/R5v3i00o QAqA2XM7DL9jsa6gzAMipm65qR6WPmnn/t3mqoyFxO6AYt55wSb5VIEkLVmflfSQzBzv C10pJODqSa9oStqUj/K8/Q5Fp8lJ79P+2Bf9okdse/A2ZZVHZUZ6rJDVS/h3yrPNiOUw kiztgE8fS93mmWVUiDznYWPFQJPz8Mp2dc1mGmt+Jh5b1eTSWSWY6llFtH1ujLLanU+W 4SEh8jV8fis5sOLBBKjket5qblmdqqI2qYqtOQvznpLzibiYH5jsOFG17UYQyoSZ+9Lc rVvw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=1wb2ncrOo7CGsE7dWRGEM3akfUu5tO0R9Fr5WIVAS98=; b=i9UrniUg/Xg1zMM/gEjnavBFoxBCgZk4Knytf5PC4i45CabT2TnfohVES2j7gNUo2O 7IZY1HeoTRX8g5lFAjH0/VYPwhBQ2kZY8vlyIgl13EsQHayuWw+rUTkMzbKGVo4dYzA+ Z7MpbFXRiz7NlKy1UvJ3JNf8fyhDlxcp8jjpAtZcJMD6Oj4wBzLxMnUKhpgmIsyu/lQm JAmO8bcu7Tyl2BJ3kjPX2S7dn4wNoygTSbVz+WRZJSXgwZUQIP12yu8k/RcXTdKHxeGN lcRLWYiODhmGGwoqi+pa1dCKmd3lhnUy51FbPXt51l7Ss1KtILLvEwCAsZgQ1v6jtwTG VYgw== X-Gm-Message-State: AOAM5315EsgcOnXupgawGURAGMcL6bBa9HqlhBpfD4bvcH/XIW7DMYml BqpsMjIx94JZ1NbYbxJgnxkYCw== X-Received: by 2002:a05:6000:1283:: with SMTP id f3mr27272527wrx.106.1593612223846; Wed, 01 Jul 2020 07:03:43 -0700 (PDT) Received: from zen.linaroharston ([51.148.130.216]) by smtp.gmail.com with ESMTPSA id l132sm7504530wmf.6.2020.07.01.07.03.33 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 01 Jul 2020 07:03:40 -0700 (PDT) Received: from zen.lan (localhost [127.0.0.1]) by zen.linaroharston (Postfix) with ESMTP id B85A91FFB4; Wed, 1 Jul 2020 14:56:55 +0100 (BST) From: =?utf-8?q?Alex_Benn=C3=A9e?= To: qemu-devel@nongnu.org Subject: [PATCH v4 28/40] tests/acceptance: skip multicore mips_malta tests on GitLab Date: Wed, 1 Jul 2020 14:56:40 +0100 Message-Id: <20200701135652.1366-29-alex.bennee@linaro.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20200701135652.1366-1-alex.bennee@linaro.org> References: <20200701135652.1366-1-alex.bennee@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::435; envelope-from=alex.bennee@linaro.org; helo=mail-wr1-x435.google.com X-detected-operating-system: by eggs.gnu.org: No matching host in p0f cache. That's all we know. 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=_AUTOLEARN X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: fam@euphon.net, Aleksandar Rikalo , berrange@redhat.com, =?utf-8?q?Alex_Benn=C3=A9e?= , richard.henderson@linaro.org, f4bug@amsat.org, Wainer dos Santos Moschetta , =?utf-8?q?Philippe_Mathieu-Daud?= =?utf-8?b?w6k=?= , Aleksandar Markovic , cota@braap.org, Cleber Rosa , aurelien@aurel32.net Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: "Qemu-devel" For some reason these tests fail all the time on GitLab. I can re-create the hang around 3% of the time locally but it doesn't seem to be MTTCG related. For now skipIf on GITLAB_CI. Signed-off-by: Alex Bennée Cc: Aleksandar Markovic --- tests/acceptance/machine_mips_malta.py | 3 +++ 1 file changed, 3 insertions(+) -- 2.20.1 Reviewed-by: Philippe Mathieu-Daudé diff --git a/tests/acceptance/machine_mips_malta.py b/tests/acceptance/machine_mips_malta.py index 92b4f28a112..7c9a4ee4d2d 100644 --- a/tests/acceptance/machine_mips_malta.py +++ b/tests/acceptance/machine_mips_malta.py @@ -15,6 +15,7 @@ from avocado import skipUnless from avocado_qemu import Test from avocado_qemu import wait_for_console_pattern from avocado.utils import archive +from avocado import skipIf NUMPY_AVAILABLE = True @@ -99,6 +100,7 @@ class MaltaMachineFramebuffer(Test): """ self.do_test_i6400_framebuffer_logo(1) + @skipIf(os.getenv('GITLAB_CI'), 'Running on GitLab') def test_mips_malta_i6400_framebuffer_logo_7cores(self): """ :avocado: tags=arch:mips64el @@ -108,6 +110,7 @@ class MaltaMachineFramebuffer(Test): """ self.do_test_i6400_framebuffer_logo(7) + @skipIf(os.getenv('GITLAB_CI'), 'Running on GitLab') def test_mips_malta_i6400_framebuffer_logo_8cores(self): """ :avocado: tags=arch:mips64el From patchwork Wed Jul 1 13:56:41 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Alex_Benn=C3=A9e?= X-Patchwork-Id: 192156 Delivered-To: patch@linaro.org Received: by 2002:a92:d244:0:0:0:0:0 with SMTP id v4csp529934ilg; Wed, 1 Jul 2020 07:10:30 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwVHYsDiF87B991x3+8kIa9C6gY/HuZqq9WoTi2y80w37CRoP+IzffyUitZV8r3C5Kb0HVJ X-Received: by 2002:a25:ce84:: with SMTP id x126mr42123713ybe.15.1593612630156; Wed, 01 Jul 2020 07:10:30 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1593612630; cv=none; d=google.com; s=arc-20160816; b=SHIaMXuKlsypEYjCA90L6OPiwfm5qiKTgUFCeobY2Wx39hPfwwyW/tDnykxexig4kH KDG6typiYSQ1b+ek8L4z1R9tuhT7OaBWQEVPXSlQFpuRenIR643BUCvzDMo09WW56zkO KGd2dOvdGmmVpFmQrP86hVRVqXAqzxgZGkG5E8+vwMLxCqSwGVlA/l2ERxFcpV0T+S+A tNchBH2m4hkfRHS77a5QymIoCkP3N6Bl/VaaT8HLPLDpJEc9SZqVknSpqgueDAbBAZkK g2VBC1ZQqsnpB+TttaIhgx7m3ArCqIX5ux8rkcPy92DwxYG5wGinFvsw6AiQycHVYgG/ Om7A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:cc:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=WZkO+vj6G284wXUPR2Uuf7/6SV8a7gabQd5K0j8iabU=; b=lKm31RX2Bx+iFwnwnKLsvqJGuWiu8ZkRzvRNytT98MBqFdBGgpGujM84gX/XnbXihe N8VnCj818HEpTaZV7tt1l5FxvVwG7es7zKXx0UgX6p12KBIR94WB1bCBK4Wx+DLQ69Q6 l3nZINLaZoeMtHjNSaR/nggNZykZZ8SxotSeZuahLVkrWP9cKXKe/MD31p74tI7/kG9F TWfgkKrhQE8bYtb5ltSsVLmRetCFee6YgM4CV4bcc2zvle+sV6Z1DyM54ANXoxcvwW/o MQxrnMZnqyP8PhIKvipL/KjgdUDDRnZOIyyMs8hZ0gv2GrSwLiItFnqJ5Cse7hVdJ104 iwkg== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=f6SmoSSP; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id p135si5677304yba.192.2020.07.01.07.10.30 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Wed, 01 Jul 2020 07:10:30 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=f6SmoSSP; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1]:51328 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jqdRV-0007oY-KZ for patch@linaro.org; Wed, 01 Jul 2020 10:10:29 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:60906) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jqdKx-00052k-Hc for qemu-devel@nongnu.org; Wed, 01 Jul 2020 10:03:43 -0400 Received: from mail-wr1-x443.google.com ([2a00:1450:4864:20::443]:36791) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1jqdKv-0006qY-NR for qemu-devel@nongnu.org; Wed, 01 Jul 2020 10:03:43 -0400 Received: by mail-wr1-x443.google.com with SMTP id k6so24004882wrn.3 for ; Wed, 01 Jul 2020 07:03:41 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=WZkO+vj6G284wXUPR2Uuf7/6SV8a7gabQd5K0j8iabU=; b=f6SmoSSP/+Plb8g+qJIpf64xBm0FZd6601GR8Lo9mxD+8bM0k0MoP6f0jAovJOvlVQ ek6oqvmA9iLqJkLQkHJHe9ec6LQGC0rxEWG5IneDkMTCjPjqcbEjdT1u42DXe3V6c8iS F9DS4UnlDZLaL/HTedFiOUVvaZin48B4xuoFf0mZmqsqgEVH7Q2mEBsls1KqlGOD/dQC +5+3sQHj+9vxyayGEJMTIZhQVYdRd2bQycldZqqK+MOB+HP1AKcBKIQkYTPZkaNF2VPu Th4N0s+U8cCUxAqW7kpUuxGZBHtzQJFU21b+pAa20wjY2/aKnM0vhBCHwhsUx558X3AO Mcpg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=WZkO+vj6G284wXUPR2Uuf7/6SV8a7gabQd5K0j8iabU=; b=iJbf0navUfixputkkME4D+h7guGvDga9jQNJxcKrPr8HXhDZfVVF1bhOPWnRNpNxhc eGF8kjwMr3YjrmCJ0D5uA71HVe3feRpJEUjWO/176Rv5TKdxSCPfrAGoOfIqeQ0PcAXO FXI5mn1sHgR6dMNUdKKXELOLNSu92gaU6xjs+jR0VkVELGpjQbl4hlSLuw8lsMK7fLtN BP9ty/QEgiNCaEuX2/f3xz8+iIUiu6TgS9g6Zzd15FXFyxPgNzzuarWWDwUNhkrBcRi8 qLqooy5Em+Hrs6AJzwd1LZqj6jz+CfB+6U2DdDXV3vZ+eJkY6aIBBLZswnToAPM8fLcH 5bCg== X-Gm-Message-State: AOAM533MirQveqmg8LjwkKZhrQ2cxBj11zibcUElFvHmkXUZq3g0+e5L AWOcLrXCmMYK4QQufd4eaJAywA== X-Received: by 2002:a5d:4710:: with SMTP id y16mr27846749wrq.189.1593612220396; Wed, 01 Jul 2020 07:03:40 -0700 (PDT) Received: from zen.linaroharston ([51.148.130.216]) by smtp.gmail.com with ESMTPSA id l8sm7567341wrq.15.2020.07.01.07.03.29 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 01 Jul 2020 07:03:33 -0700 (PDT) Received: from zen.lan (localhost [127.0.0.1]) by zen.linaroharston (Postfix) with ESMTP id D00E31FFB5; Wed, 1 Jul 2020 14:56:55 +0100 (BST) From: =?utf-8?q?Alex_Benn=C3=A9e?= To: qemu-devel@nongnu.org Subject: [PATCH v4 29/40] tests/acceptance: skip LinuxInitrd 2gib with v4.16 on GitLab Date: Wed, 1 Jul 2020 14:56:41 +0100 Message-Id: <20200701135652.1366-30-alex.bennee@linaro.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20200701135652.1366-1-alex.bennee@linaro.org> References: <20200701135652.1366-1-alex.bennee@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::443; envelope-from=alex.bennee@linaro.org; helo=mail-wr1-x443.google.com X-detected-operating-system: by eggs.gnu.org: No matching host in p0f cache. That's all we know. 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=_AUTOLEARN X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: fam@euphon.net, berrange@redhat.com, =?utf-8?q?Alex_Benn=C3=A9e?= , richard.henderson@linaro.org, f4bug@amsat.org, Wainer dos Santos Moschetta , =?utf-8?q?Philippe_Mathieu-Daud?= =?utf-8?b?w6k=?= , cota@braap.org, Cleber Rosa , aurelien@aurel32.net Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: "Qemu-devel" This fails on GitLab but not when run locally on the same container image. It's very confusing. Signed-off-by: Alex Bennée --- tests/acceptance/linux_initrd.py | 3 +++ 1 file changed, 3 insertions(+) -- 2.20.1 Acked-by: Philippe Mathieu-Daudé diff --git a/tests/acceptance/linux_initrd.py b/tests/acceptance/linux_initrd.py index a3e54d3fc91..a249e2f14a2 100644 --- a/tests/acceptance/linux_initrd.py +++ b/tests/acceptance/linux_initrd.py @@ -8,10 +8,12 @@ # This work is licensed under the terms of the GNU GPL, version 2 or # later. See the COPYING file in the top-level directory. +import os import logging import tempfile from avocado_qemu import Test +from avocado import skipIf class LinuxInitrd(Test): @@ -51,6 +53,7 @@ class LinuxInitrd(Test): max_size + 1) self.assertRegex(self.vm.get_log(), expected_msg) + @skipIf(os.getenv('GITLAB_CI'), 'Running on GitLab') def test_with_2gib_file_should_work_with_linux_v4_16(self): """ QEMU has supported up to 4 GiB initrd for recent kernel From patchwork Wed Jul 1 13:56:42 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Alex_Benn=C3=A9e?= X-Patchwork-Id: 192171 Delivered-To: patch@linaro.org Received: by 2002:a92:d244:0:0:0:0:0 with SMTP id v4csp540360ilg; Wed, 1 Jul 2020 07:22:23 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwCGYiS+zodsggd7pxzCmX/roQOdZajStJSIQU3cAqSTFektmtMs5icka6DKFcHNP90G4ge X-Received: by 2002:a25:cad0:: with SMTP id a199mr18623728ybg.411.1593613342882; Wed, 01 Jul 2020 07:22:22 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1593613342; cv=none; d=google.com; s=arc-20160816; b=bVpkDocx3SA0LVDipGPNv5xXhV0b9OtBYP832Br2pJV2n0tgdcLwyMugoDg5IEQNwN 81IQczcsrW3Vh9y5HepgfCdAajLFyVqHJ1amk8fN3mpcA7l4n9rNxwRDh7M/lai4Srh6 Ty/m4s7WGjgxoFJTAifW24xN6mxWaFF2xP1oBrpRAXzJxeenSbZJmE9DEA4DODMLiu43 oTP/JJif92qjSK1X64YdUj21oRPnVrF6DDvytWrwExKjlb2EMjyIshAeb+9AA8ZsTzFE lpdhxv4jCrK8PmXjFLv2rz+vAKOv+RMpXUthrrH/T24dwFrGjtbk6jKSAEYeLYllR9MZ 91ZA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:cc:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=t/NgCflCaACrU2hH35R4Vs2GHYuFdBrnkv6dSybnyMQ=; b=Z7lrK1EjKmYVJZ6hobeWxKDtOBm/6h+YoRtgHu8S/5n7s7O3IuiMrnpMvikuF1cGL2 tsj76vN2zptcAs7Dvdpdav6x5INz2fzwxp7wRwsy/4zN+Gekixn/o819kt6CCfM8lIgL rsUh6cjy4Gm7omzqUrPUGNSO54Ch5Y7CQzTDVxGaJXc1v59WBpG063FI/GetTVc6+Gys gdCRTpV4iYCiytkk4L0DheL+bzfidw2ZKyqRl3haFs5xZ8VIF3BSYZ4hi5FzHsJv2nsM 2DNlpdBG4nwkqF/57YgfIihP4OwpbBoUiTlo7uqid9PpfvjzTSzlLlvkBkkUvtKku2nz iI2Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=MSJJw2bL; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id p79si5696731ybg.319.2020.07.01.07.22.22 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Wed, 01 Jul 2020 07:22:22 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=MSJJw2bL; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1]:42314 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jqdd0-0002mM-8h for patch@linaro.org; Wed, 01 Jul 2020 10:22:22 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:35390) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jqdUc-0006fo-WC for qemu-devel@nongnu.org; Wed, 01 Jul 2020 10:13:43 -0400 Received: from mail-wr1-x42d.google.com ([2a00:1450:4864:20::42d]:43463) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1jqdUU-0000AL-49 for qemu-devel@nongnu.org; Wed, 01 Jul 2020 10:13:42 -0400 Received: by mail-wr1-x42d.google.com with SMTP id j4so21585306wrp.10 for ; Wed, 01 Jul 2020 07:13:32 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=t/NgCflCaACrU2hH35R4Vs2GHYuFdBrnkv6dSybnyMQ=; b=MSJJw2bLx/9i7JS5RuFfF0n43/7SO1e6waD5U2tWqIbhrzHFvcOfbIMUzucGK2vPSZ W4/X/OaAfnyI2VDiJbSnycXepzyMODc+mMRoRqM8rntDCmztWTnk1wtpBc9Mzz+dKnSU O3vXQ6Y9/+XJdfsEGfLhbAQI5wT8uGP5NtIKM0LPyZ9SlfDn01jchfB0ntwr0uR1z5Fi aLrpAkNZgneJPRuJwGxk+J9fPVew8a2XJQactegqD2tYObC9E2JdtDdQmbuz0VDnGVCM ED8bO4rHeS7EBpUYS5G9oERr+uP4ir83HawJ0FueGfRlt/PyZPryTByMGuaIdX/wZeY6 /Q+A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=t/NgCflCaACrU2hH35R4Vs2GHYuFdBrnkv6dSybnyMQ=; b=H6qJ/zvioa/rNKnxNaOeDHzKG5CD6pOOp4AsjXruC8TpIhRbsnZfAZzASeGmVyVK1Z IZV5eJpJ1EwBXNMSY1/jP8uMy0HZAe+HX+eLBXoCfdMcf0e+iFKdMkb+5xSE+5VoeO5P GhmGIVUP6NgvR7sr1/a7fwFxZopbUlfuaUGzYT55vCpmvlCc3I+SJFOKn+EeEYM/hE01 G71QjUqUgv7BOCFnU5iZXOmhCdz/IyuqwwCqZF5ewyxSesk/mbVbSqOwJt+w3nRu0Yxq Dy0zds1GPIUmP5bSyESJZg1IhC+lBxX/WtHo2EhdM+DLsLd0Qt30C2YLzFoxbLlR9JoD lTAQ== X-Gm-Message-State: AOAM5313yEah2nMtBed/azNmSMXsaoaowg8UqaWK2V4DRjWwlqC5+AfP FSDmyK32UJAzVxGag87lWDVsOw== X-Received: by 2002:adf:fe46:: with SMTP id m6mr25602424wrs.192.1593612811344; Wed, 01 Jul 2020 07:13:31 -0700 (PDT) Received: from zen.linaroharston ([51.148.130.216]) by smtp.gmail.com with ESMTPSA id 59sm7871261wrj.37.2020.07.01.07.13.27 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 01 Jul 2020 07:13:27 -0700 (PDT) Received: from zen.lan (localhost [127.0.0.1]) by zen.linaroharston (Postfix) with ESMTP id EAACA1FFB7; Wed, 1 Jul 2020 14:56:55 +0100 (BST) From: =?utf-8?q?Alex_Benn=C3=A9e?= To: qemu-devel@nongnu.org Subject: [PATCH v4 30/40] gitlab: add acceptance testing to system builds Date: Wed, 1 Jul 2020 14:56:42 +0100 Message-Id: <20200701135652.1366-31-alex.bennee@linaro.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20200701135652.1366-1-alex.bennee@linaro.org> References: <20200701135652.1366-1-alex.bennee@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::42d; envelope-from=alex.bennee@linaro.org; helo=mail-wr1-x42d.google.com X-detected-operating-system: by eggs.gnu.org: No matching host in p0f cache. That's all we know. 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=_AUTOLEARN X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: fam@euphon.net, Thomas Huth , berrange@redhat.com, =?utf-8?q?Alex_Benn=C3=A9e?= , richard.henderson@linaro.org, f4bug@amsat.org, Wainer dos Santos Moschetta , =?utf-8?q?Philippe_Mathieu-Daud?= =?utf-8?b?w6k=?= , cota@braap.org, aurelien@aurel32.net Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: "Qemu-devel" As part of migrating things from Travis to GitLab add the acceptance tests. To do this: - rename system1 to system-ubuntu-main - rename system2 to system-fedora-misc - split into build/check/acceptance - remove -j from check stages - use artifacts to save build stage - add post acceptance template and use Signed-off-by: Alex Bennée Reviewed-by: Philippe Mathieu-Daudé Message-Id: <20200622143204.12921-16-alex.bennee@linaro.org> --- v2 - updated with danp's docker changes - use needs instead of dependancies - touch all the build files to prevent rebuild v4 - fix misnamed check stage - don't use : in stage names - restore *post_acceptance post_script - don't failfast on GITLAB_CI --- .gitlab-ci.yml | 69 ++++++++++++++++++++++++++++++++++++++++-- .travis.yml | 23 -------------- tests/Makefile.include | 2 +- 3 files changed, 67 insertions(+), 27 deletions(-) -- 2.20.1 diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index a7abc55a5c6..93baf98232d 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -1,8 +1,12 @@ +# Currently we have two build stages after our containers are built: +# - build (for traditional build and test or first stage build) +# - test (for test stages, using build artefacts from a build stage) stages: - containers - containers-layer2 - containers-layer3 - build + - test include: - local: '/.gitlab-ci.d/edk2.yml' @@ -24,26 +28,85 @@ include: ../configure --enable-werror $CONFIGURE_ARGS ; fi - make -j"$JOBS" - - make -j"$JOBS" $MAKE_CHECK_ARGS + - if test -n "$MAKE_CHECK_ARGS"; + then + make $MAKE_CHECK_ARGS ; + fi + +.native_test_job_template: &native_test_job_definition + stage: test + image: $CI_REGISTRY_IMAGE/qemu/$IMAGE:latest + script: + - cd build + - find . -type f -exec touch {} + + - make $MAKE_CHECK_ARGS + +.post_acceptance_template: &post_acceptance + after_script: + - cd build + - python3 -c 'import json; r = json.load(open("tests/results/latest/results.json")); [print(t["logfile"]) for t in r["tests"] if t["status"] not in ("PASS", "SKIP")]' | xargs cat + - du -chs $HOME/avocado/data/cache -build-system1: +build-system-ubuntu-main: <<: *native_build_job_definition variables: IMAGE: ubuntu2004 TARGETS: aarch64-softmmu alpha-softmmu cris-softmmu hppa-softmmu lm32-softmmu moxie-softmmu microblazeel-softmmu mips64el-softmmu m68k-softmmu ppc-softmmu riscv64-softmmu sparc-softmmu + artifacts: + paths: + - build + +check-system-ubuntu-main: + <<: *native_test_job_definition + needs: + - job: build-system-ubuntu-main + artifacts: true + variables: + IMAGE: ubuntu2004 MAKE_CHECK_ARGS: check -build-system2: +acceptance-system-ubuntu-main: + <<: *native_test_job_definition + needs: + - job: build-system-ubuntu-main + artifacts: true + variables: + IMAGE: ubuntu2004 + MAKE_CHECK_ARGS: check-acceptance + <<: *post_acceptance + +build-system-fedora-alt: <<: *native_build_job_definition variables: IMAGE: fedora TARGETS: tricore-softmmu unicore32-softmmu microblaze-softmmu mips-softmmu riscv32-softmmu s390x-softmmu sh4-softmmu sparc64-softmmu x86_64-softmmu xtensa-softmmu nios2-softmmu or1k-softmmu + artifacts: + paths: + - build + +check-system-fedora-alt: + <<: *native_test_job_definition + needs: + - job: build-system-fedora-alt + artifacts: true + variables: + IMAGE: fedora MAKE_CHECK_ARGS: check +acceptance-system-fedora-alt: + <<: *native_test_job_definition + needs: + - job: build-system-fedora-alt + artifacts: true + variables: + IMAGE: fedora + MAKE_CHECK_ARGS: check-acceptance + <<: *post_acceptance + build-disabled: <<: *native_build_job_definition variables: diff --git a/.travis.yml b/.travis.yml index 74158f741b1..c24dfbe377f 100644 --- a/.travis.yml +++ b/.travis.yml @@ -289,29 +289,6 @@ jobs: python: 3.6 - # Acceptance (Functional) tests - - name: "GCC check-acceptance" - dist: bionic - env: - - CONFIG="--enable-tools --target-list=aarch64-softmmu,alpha-softmmu,arm-softmmu,m68k-softmmu,microblaze-softmmu,mips-softmmu,mips64el-softmmu,nios2-softmmu,or1k-softmmu,ppc-softmmu,ppc64-softmmu,s390x-softmmu,sh4-softmmu,sparc-softmmu,x86_64-softmmu,xtensa-softmmu" - - TEST_CMD="make check-acceptance" - - CACHE_NAME="${TRAVIS_BRANCH}-linux-gcc-acceptance" - after_script: - - python3 -c 'import json; r = json.load(open("tests/results/latest/results.json")); [print(t["logfile"]) for t in r["tests"] if t["status"] not in ("PASS", "SKIP")]' | xargs cat - - du -chs $HOME/avocado/data/cache - addons: - apt: - packages: - - python3-pil - - python3-pip - - python3-numpy - - python3-opencv - - python3-venv - - rpm2cpio - - tesseract-ocr - - tesseract-ocr-eng - - # Using newer GCC with sanitizers - name: "GCC9 with sanitizers (softmmu)" addons: diff --git a/tests/Makefile.include b/tests/Makefile.include index 3f4448a20bc..c316e0d6647 100644 --- a/tests/Makefile.include +++ b/tests/Makefile.include @@ -944,7 +944,7 @@ check-acceptance: check-venv $(TESTS_RESULTS_DIR) get-vm-images --show=$(AVOCADO_SHOW) run --job-results-dir=$(TESTS_RESULTS_DIR) \ --filter-by-tags-include-empty --filter-by-tags-include-empty-key \ $(AVOCADO_TAGS) \ - --failfast=on tests/acceptance, \ + $(if $(GITLAB_CI),,--failfast=on) tests/acceptance, \ "AVOCADO", "tests/acceptance") # Consolidated targets From patchwork Wed Jul 1 13:56:43 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Alex_Benn=C3=A9e?= X-Patchwork-Id: 192167 Delivered-To: patch@linaro.org Received: by 2002:a92:d244:0:0:0:0:0 with SMTP id v4csp536716ilg; Wed, 1 Jul 2020 07:18:15 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzAF5p63qnXf1ZCA3h9xAFa3P14UV+tpQYyl30TuUMUvAlrVWrb8aSHO8FxkYMiAZNG2Q51 X-Received: by 2002:a25:b90e:: with SMTP id x14mr43199964ybj.8.1593613094961; Wed, 01 Jul 2020 07:18:14 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1593613094; cv=none; d=google.com; s=arc-20160816; b=Snui7BoH7CSWcE8+tqlBp+CqEygFIpAVC5ZNIQX19ZJCQkC5tEeQwnjaYu4E13Ri2u iuFsOjkF20qR1pRImusolheZfjbsWQzObkOzgQaEl0jyeh67KNdoUHsQ6nxmhiN0/H80 +09oHS7CSOuqA9HwdKjZRceUPwmbkN+7nHk/IVPLe83C5FLfsgVE7B67cEq90CSRgA7i BDsEgdPDTWF2uNXNprWotqzV3W8VB5Z8IGV2cDBDBXXx0fQ157AKdH3m0J0xu+ZpRndq SGL1TJpixgiaWWj5sGKxCULlLGBqq0oVakoWIkuYyAdvbkXLStBYkUbP9tNmgl4c3m/F a8eg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:cc:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=N4xihvXcT2NbzYDWewm5rzgOgSrnKR9VT35cRtylW1A=; b=ZZMwsSlfZ8aM+qawv10LEDLMFz/Y5CjU0YOBHLI76dGWzQdIRj4n5pLTZe4HfiiYW1 fIOzok8rSkfddD/IjINLPCvzblUJGZFMhb/qdd1eOd5Yw36gzQUgWEpKninwYqENfaWk fmC1mSReT61kKVBPPt5KPF7xoq7tKY3NdGzYo5geDMOzRx0uS+CFcZFR2nqUV3pJBsal s9XM4DhWgGWwPWDsY00iX47vmo+iLrp8IjjFjlhD3s/zLdjHXZCpuHPWs2uoysAqG5yq 2JVQPDFzOPATzc0AuozWXVhmkJ/KWLJ2G/m9Wa+8FAgnwxEPPbDGstyf59KppWwoSM+K 2o+Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=Lvnp7rCB; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id h27si6333173ybj.396.2020.07.01.07.18.14 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Wed, 01 Jul 2020 07:18:14 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=Lvnp7rCB; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1]:54404 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jqdZ0-00049d-EJ for patch@linaro.org; Wed, 01 Jul 2020 10:18:14 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:60864) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jqdKu-0004vC-Ch for qemu-devel@nongnu.org; Wed, 01 Jul 2020 10:03:40 -0400 Received: from mail-wr1-x444.google.com ([2a00:1450:4864:20::444]:46564) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1jqdKs-0006pr-I7 for qemu-devel@nongnu.org; Wed, 01 Jul 2020 10:03:40 -0400 Received: by mail-wr1-x444.google.com with SMTP id r12so23922929wrj.13 for ; Wed, 01 Jul 2020 07:03:38 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=N4xihvXcT2NbzYDWewm5rzgOgSrnKR9VT35cRtylW1A=; b=Lvnp7rCBZEi2ZVXPmakSupr3ajkJx4IwkPB3NMdJpvA7i42BUswJd8i4vyaTD/lKNA oWzx/5fSn23i3Mv0DdyOG7y0hF5zmmCcoXn5iIJlFRAjmnNN2Uc570IU1APL31h3eQhz ewtSa/6Is4V6CjlL9kcGcqwlGTJ62mLwGfNkUey/GUeHmN6+fb8A6Zf/UFXNlBKtxBth a5R6q4jjCAdSd1nPMBZvc9RCuiN2nguwgwgnNy7dLa/ngNpOxprEKub4yb+gBnqd5mm7 8EM7UIZyAT7ptN3q9SJ324ZvLyCNOMA0RK2rZPvwYAWBVWrQq+JqwBTCzin8GARLWXjN Kj+A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=N4xihvXcT2NbzYDWewm5rzgOgSrnKR9VT35cRtylW1A=; b=jAGM2IyUbbGVFYjZETJZTgKI3w3MmwcIk8tV7/kLfFADax0OgCWxwkTcLbijBfuhwa VXw/k5sX0wbw3pzbEYlmlV9Udrw3P6FI7YAeWQUTpojlq5I87qywX943KZgma4lcEsvQ nvv2LkV5XbnuHPrMYIlwq10t5jVtEQfUf4+7Qd7RMdRIh46bcOZz26lHVqF6MwCKdhhM dcHUo0vdRPzT8V1Sezg899Sq9OCbo9u0mkH7Od9zdVLRJVRY77apODxAFsq2jk7IDzBW 2A0Brr4odkxMAsWMLuNjoYl/MScKiYtdoz5iNH6FOcuM0MQFsvwJ3uPw+GOmekWdNvKp mb4A== X-Gm-Message-State: AOAM533D+/JV6/U6WTabLGX+NDSGSBv2CMNVm4OAsWrUYjvUNAorXNZw uo/9ffMzwphcMCjTUbBSP/ATGw== X-Received: by 2002:a5d:60d1:: with SMTP id x17mr26690700wrt.293.1593612217099; Wed, 01 Jul 2020 07:03:37 -0700 (PDT) Received: from zen.linaroharston ([51.148.130.216]) by smtp.gmail.com with ESMTPSA id k14sm7323389wrn.76.2020.07.01.07.03.29 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 01 Jul 2020 07:03:33 -0700 (PDT) Received: from zen.lan (localhost [127.0.0.1]) by zen.linaroharston (Postfix) with ESMTP id 0E0D81FFB8; Wed, 1 Jul 2020 14:56:56 +0100 (BST) From: =?utf-8?q?Alex_Benn=C3=A9e?= To: qemu-devel@nongnu.org Subject: [PATCH v4 31/40] tests/tcg: add more default compilers to configure.sh Date: Wed, 1 Jul 2020 14:56:43 +0100 Message-Id: <20200701135652.1366-32-alex.bennee@linaro.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20200701135652.1366-1-alex.bennee@linaro.org> References: <20200701135652.1366-1-alex.bennee@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::444; envelope-from=alex.bennee@linaro.org; helo=mail-wr1-x444.google.com X-detected-operating-system: by eggs.gnu.org: No matching host in p0f cache. That's all we know. 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, URIBL_BLOCKED=0.001 autolearn=_AUTOLEARN X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: fam@euphon.net, berrange@redhat.com, =?utf-8?q?Alex_Benn=C3=A9e?= , richard.henderson@linaro.org, f4bug@amsat.org, cota@braap.org, aurelien@aurel32.net Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: "Qemu-devel" We were missing a bunch of compilers which we could use if they were locally installed. The defaults are based on Debian as they seem to be the best distro for well distributed cross-build compilers. Signed-off-by: Alex Bennée --- tests/tcg/configure.sh | 19 ++++++++++++++----- 1 file changed, 14 insertions(+), 5 deletions(-) -- 2.20.1 diff --git a/tests/tcg/configure.sh b/tests/tcg/configure.sh index 2326f978562..37e49736ca4 100755 --- a/tests/tcg/configure.sh +++ b/tests/tcg/configure.sh @@ -46,20 +46,29 @@ fi : ${cross_cc_aarch64="aarch64-linux-gnu-gcc"} : ${cross_cc_aarch64_be="$cross_cc_aarch64"} : ${cross_cc_cflags_aarch64_be="-mbig-endian"} +: $(cross_cc_alpha="alpha-linux-gnu-gcc") : ${cross_cc_arm="arm-linux-gnueabihf-gcc"} : ${cross_cc_cflags_armeb="-mbig-endian"} +: ${cross_cc_hppa="hppa-linux-gnu-gcc"} : ${cross_cc_i386="i386-pc-linux-gnu-gcc"} : ${cross_cc_cflags_i386="-m32"} -: ${cross_cc_x86_64="x86_64-pc-linux-gnu-gcc"} -: ${cross_cc_cflags_x86_64="-m64"} +: ${cross_cc_m68k="m68k-linux-gnu-gcc"} +: $(cross_cc_mips64el="mips64el-linux-gnuabi64-gcc") +: $(cross_cc_mips64="mips64-linux-gnuabi64-gcc") +: $(cross_cc_mipsel="mipsel-linux-gnu-gcc") +: $(cross_cc_mips="mips-linux-gnu-gcc") : ${cross_cc_ppc="powerpc-linux-gnu-gcc"} : ${cross_cc_cflags_ppc="-m32"} -: ${cross_cc_ppc64="powerpc-linux-gnu-gcc"} -: ${cross_cc_cflags_ppc64="-m64"} +: ${cross_cc_ppc64="powerpc64-linux-gnu-gcc"} : ${cross_cc_ppc64le="powerpc64le-linux-gnu-gcc"} -: ${cross_cc_cflags_s390x="-m64"} +: $(cross_cc_riscv64="riscv64-linux-gnu-gcc") +: ${cross_cc_s390x="s390x-linux-gnu-gcc"} +: $(cross_cc_sh4="sh4-linux-gnu-gcc") : ${cross_cc_cflags_sparc="-m32 -mv8plus -mcpu=ultrasparc"} +: ${cross_cc_sparc64="sparc64-linux-gnu-gcc"} : ${cross_cc_cflags_sparc64="-m64 -mcpu=ultrasparc"} +: ${cross_cc_x86_64="x86_64-pc-linux-gnu-gcc"} +: ${cross_cc_cflags_x86_64="-m64"} for target in $target_list; do arch=${target%%-*} From patchwork Wed Jul 1 13:56:44 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Alex_Benn=C3=A9e?= X-Patchwork-Id: 192172 Delivered-To: patch@linaro.org Received: by 2002:a92:d244:0:0:0:0:0 with SMTP id v4csp545615ilg; Wed, 1 Jul 2020 07:28:51 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzLCCR+QXsckXnhUyOX9HpehuEtwRpRMHjM/77TABAg7GDetCocHIGv/3ViVvny7cRvUgLS X-Received: by 2002:a5b:14a:: with SMTP id c10mr39446440ybp.493.1593613730941; Wed, 01 Jul 2020 07:28:50 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1593613730; cv=none; d=google.com; s=arc-20160816; b=08WpC44/et7p2qYQL40Wp3aXX2lDdz2Z1FGsJ8sgXt56y6j8Wkd4RdoBaJlfb99zAP +YYQ7IsqRqg44KrdMKgyV0UG0s3/ZuDWnQst0OSzmlKn8crH/aoyQ4S8HJGbyOP/81sP VFuCH8x2eSYsFjNuxJnth4o0y4CYlYyws9dJlyKETU7KzUOQG3377jC67dHKjGqVqykf 9qAyKG+P9dj73GSv4imbV0TgRjbkRiuejeAA425s3ZaDGLb9CZWJfQ+/KKErFoiM0PgK 9Nn5tanS6bxmqVig54WrQHJHDfKcJIdiZ7vL0t3tOtcq4fLks2//UKP0zZNbFXHgWABI QDSQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:cc:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=PJhXUCcF3c2PKDCFsCiaqFOmEKen6xlVm+g2tj8AYP8=; b=FH7TVOC0JothWOA9IQ9DHk81PEi23eKUvJu6kkUGlBYSBihil2jfNfhYejFoQvfWJB INg5NazLfpJ6WNSXX+YuiWTc2Z/EgA+rcXVzY0c9FMiM1WgiRNUg6aJy4ukv8qSi7E/x DS+Feqjh62+wdjbStIekRyMjFg5t40u+XTmstgSLb530APKx2K/Ex91Jf/0DcAzQLNPm SWvHMRj9iLbI3TYvH+R25fUfFZrlmzALu/X1FEJqHC+UZrY+sGdePkNIU5m49gxvOD1E iyxuSzd5/tg/70DRQV/UenuLcTPOAKRUNW5tw7eC3XyFmDrsRs1OLixntPc+7IaE1xWZ 1Nyw== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=WlXD7kXT; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id c14si5848520ybs.157.2020.07.01.07.28.50 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Wed, 01 Jul 2020 07:28:50 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=WlXD7kXT; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1]:34658 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jqdjG-00045M-Bj for patch@linaro.org; Wed, 01 Jul 2020 10:28:50 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:35314) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jqdUS-0006ZI-Gz for qemu-devel@nongnu.org; Wed, 01 Jul 2020 10:13:32 -0400 Received: from mail-wm1-x32a.google.com ([2a00:1450:4864:20::32a]:51098) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1jqdUQ-0000A3-Iz for qemu-devel@nongnu.org; Wed, 01 Jul 2020 10:13:32 -0400 Received: by mail-wm1-x32a.google.com with SMTP id l17so22608870wmj.0 for ; Wed, 01 Jul 2020 07:13:30 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=PJhXUCcF3c2PKDCFsCiaqFOmEKen6xlVm+g2tj8AYP8=; b=WlXD7kXTRinT7Nh0YWHeQjdrlpdwKW9wzLMBsuVgwCFPxDtx1THdoOTNvTmAoW+c6m uYX2DworzFB9U7oVOrQ5bZu/kk0jTpqeRG7JBe7DE/knr06Xsrkv2A0L9ScJBO5MlI15 lGSIC6xnmIbMnPU9xnPt75lKLKFq+ZGYKLd70I7hwLVAyrh+ayuuJApL9t1NHDahY86u WS8pRCPL2nweFC9Dudd7htNV63Rqg6Wzi6rBU/KLBJHWDRB4BVH98zbWvpxe2sRUNFq7 iRPw9m9424drJk2mcxRc/Q05+vbJY5uVby4UWKglAzKnmElti4YcRCcLWi5bHCPXqRRj 2mnw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=PJhXUCcF3c2PKDCFsCiaqFOmEKen6xlVm+g2tj8AYP8=; b=Rczy8EKcJWQ3jfdihvPk5Gtwg3/A4CuOu6w7A0dgjH15LnTBOkhiciU2gxmffjh2dQ uodOmVSuRQ+x1whc0FroZykB2RsByh/FsOMERJISiOfqds5mG/Jf/Tjjo2xt8j9OL2Ka mjZ5zwsHdZUCKpgjXakkAN4eLwJbbOdK8R0jxMoncrlTYX5KiVsL5XROz5A1bEDtJL6w hvv+SSb/iQ83hUsqPj53JdOUVjb7rw3MBwdu7b58CbkDADREoqNo+Bs7TkIT2BN/Ustt 06lLygxMNWLMwqxULHUfvaubE0DJMtDhY9+o4KYK5hjTe2x3WSOAC4IdxZdOGoyjfDXQ RrEA== X-Gm-Message-State: AOAM533xafsfMpSs5cu5MysSi8rrItPf/QgDGExFRh+BsAO13vAFs1ag dVVLaKJwpjeQ79zRD1w9R+ynag== X-Received: by 2002:a1c:4408:: with SMTP id r8mr26979777wma.100.1593612808833; Wed, 01 Jul 2020 07:13:28 -0700 (PDT) Received: from zen.linaroharston ([51.148.130.216]) by smtp.gmail.com with ESMTPSA id w2sm7835430wrs.77.2020.07.01.07.13.27 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 01 Jul 2020 07:13:27 -0700 (PDT) Received: from zen.lan (localhost [127.0.0.1]) by zen.linaroharston (Postfix) with ESMTP id 27B561FF8F; Wed, 1 Jul 2020 14:56:56 +0100 (BST) From: =?utf-8?q?Alex_Benn=C3=A9e?= To: qemu-devel@nongnu.org Subject: [PATCH v4 32/40] tests/docker: add a linux-user testing focused image Date: Wed, 1 Jul 2020 14:56:44 +0100 Message-Id: <20200701135652.1366-33-alex.bennee@linaro.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20200701135652.1366-1-alex.bennee@linaro.org> References: <20200701135652.1366-1-alex.bennee@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::32a; envelope-from=alex.bennee@linaro.org; helo=mail-wm1-x32a.google.com X-detected-operating-system: by eggs.gnu.org: No matching host in p0f cache. That's all we know. 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=_AUTOLEARN X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: fam@euphon.net, berrange@redhat.com, =?utf-8?q?Alex_Benn=C3=A9e?= , richard.henderson@linaro.org, f4bug@amsat.org, =?utf-8?q?Philippe_Mat?= =?utf-8?q?hieu-Daud=C3=A9?= , cota@braap.org, aurelien@aurel32.net Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: "Qemu-devel" We happily use all the cross images for both cross-building QEMU as well as building the linux-user tests. However calling docker from within docker seems not to work. As we can build in Debian anyway why not include an image that has all the compilers available for non-docker invocation. Signed-off-by: Alex Bennée Reviewed-by: Philippe Mathieu-Daudé --- .gitlab-ci.d/containers.yml | 7 +++ tests/docker/Makefile.include | 1 + .../dockerfiles/debian-all-test-cross.docker | 53 +++++++++++++++++++ 3 files changed, 61 insertions(+) create mode 100644 tests/docker/dockerfiles/debian-all-test-cross.docker -- 2.20.1 diff --git a/.gitlab-ci.d/containers.yml b/.gitlab-ci.d/containers.yml index f353359fd8b..a7621c4204c 100644 --- a/.gitlab-ci.d/containers.yml +++ b/.gitlab-ci.d/containers.yml @@ -64,6 +64,13 @@ amd64-debian-cross-container: variables: NAME: debian-amd64-cross +amd64-debian-user-cross-container: + <<: *container_job_definition + stage: containers-layer2 + needs: ['amd64-debian10-container'] + variables: + NAME: debian-all-test-cross + amd64-debian-container: <<: *container_job_definition stage: containers-layer2 diff --git a/tests/docker/Makefile.include b/tests/docker/Makefile.include index 977d8ff6e40..8406d039858 100644 --- a/tests/docker/Makefile.include +++ b/tests/docker/Makefile.include @@ -134,6 +134,7 @@ docker-image-travis: NOUSER=1 # Specialist build images, sometimes very limited tools docker-image-debian-tricore-cross: docker-image-debian9 +docker-image-debian-all-test-cross: docker-image-debian10 docker-image-debian-arm64-test-cross: docker-image-debian11 # These images may be good enough for building tests but not for test builds diff --git a/tests/docker/dockerfiles/debian-all-test-cross.docker b/tests/docker/dockerfiles/debian-all-test-cross.docker new file mode 100644 index 00000000000..dedcea58b46 --- /dev/null +++ b/tests/docker/dockerfiles/debian-all-test-cross.docker @@ -0,0 +1,53 @@ +# +# Docker all cross-compiler target (tests only) +# +# While the normal cross builds take care to setup proper multiarch +# build environments which can cross build QEMU this just installs the +# basic compilers for as many targets as possible. We shall use this +# to build and run linux-user tests on GitLab +# +FROM qemu/debian10 + +# What we need to build QEMU itself +RUN apt update && \ + DEBIAN_FRONTEND=noninteractive eatmydata \ + apt build-dep -yy qemu + +# Add the foreign architecture we want and install dependencies +RUN DEBIAN_FRONTEND=noninteractive eatmydata \ + apt install -y --no-install-recommends \ + gcc-aarch64-linux-gnu \ + libc6-dev-arm64-cross \ + gcc-alpha-linux-gnu \ + libc6.1-dev-alpha-cross \ + gcc-arm-linux-gnueabihf \ + libc6-dev-armhf-cross \ + gcc-hppa-linux-gnu \ + libc6-dev-hppa-cross \ + gcc-m68k-linux-gnu \ + libc6-dev-m68k-cross \ + gcc-mips-linux-gnu \ + libc6-dev-mips-cross \ + gcc-mips64-linux-gnuabi64 \ + libc6-dev-mips64-cross \ + gcc-mips64el-linux-gnuabi64 \ + libc6-dev-mips64el-cross \ + gcc-mipsel-linux-gnu \ + libc6-dev-mipsel-cross \ + gcc-powerpc-linux-gnu \ + libc6-dev-powerpc-cross \ + gcc-powerpc64-linux-gnu \ + libc6-dev-ppc64-cross \ + gcc-powerpc64le-linux-gnu \ + libc6-dev-ppc64el-cross \ + gcc-riscv64-linux-gnu \ + libc6-dev-riscv64-cross \ + gcc-s390x-linux-gnu \ + libc6-dev-s390x-cross \ + gcc-sh4-linux-gnu \ + libc6-dev-sh4-cross \ + gcc-sparc64-linux-gnu \ + libc6-dev-sparc64-cross + +ENV QEMU_CONFIGURE_OPTS --disable-system --disable-docs --disable-tools +ENV DEF_TARGET_LIST aarch64-linux-user,alpha-linux-user,arm-linux-user,hppa-linux-user,i386-linux-user,m68k-linux-user,mips-linux-user,mips64-linux-user,mips64el-linux-user,mipsel-linux-user,ppc-linux-user,ppc64-linux-user,ppc64le-linux-user,riscv64-linux-user,s390x-linux-user,sh4-linux-user,sparc64-linux-user From patchwork Wed Jul 1 13:56:45 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Alex_Benn=C3=A9e?= X-Patchwork-Id: 192151 Delivered-To: patch@linaro.org Received: by 2002:a92:d244:0:0:0:0:0 with SMTP id v4csp527634ilg; Wed, 1 Jul 2020 07:08:02 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzgZ9P/BRKsLCFW2o32B+OVgjzDy9iBekTKzTYFKe2P6mIP3KLZCKN2RSV9i2NSXe16z05L X-Received: by 2002:a37:67d7:: with SMTP id b206mr26662746qkc.144.1593612482538; Wed, 01 Jul 2020 07:08:02 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1593612482; cv=none; d=google.com; s=arc-20160816; b=qn6pifkUTATZq0dlxhFD8R5A5zZV6o6k4OUZbykruzL+PDbQhihCwK4Nq2M4Dm5gyO 58Jb3flgo8EHlVoVtgvRfjKFUWx2KoUwSbvHgbBbkdw4wXDUZtq1H9lEZTHeu44y646G yMpLEbwriSHdNjq6w9T0UIwCoCDDWmz+TY7e71iTbtj8hMNgQ+rKLCZkfJgRUuBy0/Mb i2Nkrr4KCHTG2Vvw+N29QXxRGbmTC7hwYhksNRlEfjERrQLNxz8A+LgdJfVQyNLlZAZK ndeWWgQUQYFalcKSgDZQ+f5W1MGn48vi5uTNFt4G0tnnWf2XejT842A4UX8ZVCyJkMV4 zdIw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:cc:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=JbHSSp+OWWoLJx/9MSaLrM42pM2ZJc5nMwUPC3QEVGo=; b=lOeY59yjuYTgxuaIRXnBWSvWlfhZYr+loXo95R5CkNJw/ZcnsTZF3LDJXhbt0KY0hH QUieml9lumQZhfPHBf72h/+CeSMqJm4NyTY+T6GXZTwhQHWiDVarN3pcsxBrFAHmfqnA 4dQx6fdkZLmjDltGPqSvspfjtaLuRimJqfzLC6qzoXPnW+l8c/Z08s7M6cjp4d1K2Gji njKVyziIlZXLyYZYCCF2g1x2Jxx/ZLy1XrlhrAtszSKafz8qyMV5WoUXrFD6vhVG/ilC 6BXrvDzdci78Q3OkZN5YLaM8IWnAZXmOwwCbJvMPDCDPqC2+cwujDTdtaF6Z5bTkYEvL Dp4g== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=tmWLG9Z8; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id h6si3625578qkj.353.2020.07.01.07.08.02 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Wed, 01 Jul 2020 07:08:02 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=tmWLG9Z8; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1]:42894 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jqdP7-0004Lg-3T for patch@linaro.org; Wed, 01 Jul 2020 10:08:02 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:60852) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jqdKt-0004sS-7x for qemu-devel@nongnu.org; Wed, 01 Jul 2020 10:03:39 -0400 Received: from mail-wm1-x343.google.com ([2a00:1450:4864:20::343]:53461) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1jqdKr-0006pi-5g for qemu-devel@nongnu.org; Wed, 01 Jul 2020 10:03:38 -0400 Received: by mail-wm1-x343.google.com with SMTP id j18so22556029wmi.3 for ; Wed, 01 Jul 2020 07:03:36 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=JbHSSp+OWWoLJx/9MSaLrM42pM2ZJc5nMwUPC3QEVGo=; b=tmWLG9Z8Nyx4I30963cbylorfLynCpuEmbskKfJHBstLR7tyDiobK0hzmaonbkljfR TfLmfJyMQ7Ds6eO4E+ae0OO+8xJaHzijIcvU/eN5hQwiC9d/buZjSb7PPqzlXX6fJnMa u7kTntpc8abytSyn1bdvgd8HUPSQmkhaEB/RZSVJ9rWghdPbOjiWnX+s5zk+w1lvLKy6 A8Sx0oua6oTp0bEgv0DO4dhAm19o5EgKkIrPpcZ434l12ZZVeVH+JKGSzoH5HjKIcKwZ dm4PRsdrht4MouRLBSoEEAc0fQzRHJzOoicr7QkSGiubvfWTcO3cWzTreH/i2DG1RgWa o+yQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=JbHSSp+OWWoLJx/9MSaLrM42pM2ZJc5nMwUPC3QEVGo=; b=TNBAHZS1LFjx0bGPeGlmbjijGyanQYCO9phu0UMMAxLej4/KpwQqBtLiLoNKn6ycRU SgO/RXFPuZ1oKP4m0uibtf3On6o+ymdbPesrinU22aPfUdVRoZjpRqe7HS+Z+0QVT2nC j+3SJJmjD9DEpdkS13Dx4akUvTxIv3dwAuzY8MGb8IBIpxgNYDW1MiC8RMMxUYJg5s6x 9oOXh9Tvzn7kA4StRUKHFXYQM/Hiq64UtIKy4Xw7HxBKlQkh/O99VwKxn+9GmQ00sp1I Livp5UdAKkk7nnvEWIg+LaDzSyUWtac6T2rctBaPpHgQ7zdxXJhr9IajvPzUyr7MZnxu Ro5Q== X-Gm-Message-State: AOAM531OuzCNhXB9mRVonXAJ49yxrQE1OrhKOsy4Cc4cCUV0HTYZf0Pe W6S/PZDRJ4c7OTc47tL3qr6P4A== X-Received: by 2002:a1c:6308:: with SMTP id x8mr28002337wmb.92.1593612215706; Wed, 01 Jul 2020 07:03:35 -0700 (PDT) Received: from zen.linaroharston ([51.148.130.216]) by smtp.gmail.com with ESMTPSA id t2sm7243554wma.43.2020.07.01.07.03.28 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 01 Jul 2020 07:03:32 -0700 (PDT) Received: from zen.lan (localhost [127.0.0.1]) by zen.linaroharston (Postfix) with ESMTP id 3EE5B1FFBA; Wed, 1 Jul 2020 14:56:56 +0100 (BST) From: =?utf-8?q?Alex_Benn=C3=A9e?= To: qemu-devel@nongnu.org Subject: [PATCH v4 33/40] linux-user/elfload: use MAP_FIXED_NOREPLACE in pgb_reserved_va Date: Wed, 1 Jul 2020 14:56:45 +0100 Message-Id: <20200701135652.1366-34-alex.bennee@linaro.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20200701135652.1366-1-alex.bennee@linaro.org> References: <20200701135652.1366-1-alex.bennee@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::343; envelope-from=alex.bennee@linaro.org; helo=mail-wm1-x343.google.com X-detected-operating-system: by eggs.gnu.org: No matching host in p0f cache. That's all we know. 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=_AUTOLEARN X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: fam@euphon.net, berrange@redhat.com, =?utf-8?q?Alex_Benn=C3=A9e?= , Riku Voipio , richard.henderson@linaro.org, f4bug@amsat.org, Laurent Vivier , cota@braap.org, aurelien@aurel32.net Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: "Qemu-devel" Given we assert the requested address matches what we asked we should also make that clear in the mmap flags. Otherwise we see failures in the GitLab environment for some currently unknown but allowable reason. We use MAP_FIXED_NOREPLACE if we can so we don't just clobber an existing mapping. Also include the strerror string for a bit more info on failure. Signed-off-by: Alex Bennée --- v4 - use MAP_FIXED_NOREPLACE instead - also dump strerror --- linux-user/elfload.c | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) -- 2.20.1 diff --git a/linux-user/elfload.c b/linux-user/elfload.c index b5cb21384a1..7e7f642332d 100644 --- a/linux-user/elfload.c +++ b/linux-user/elfload.c @@ -2294,7 +2294,7 @@ static void pgb_dynamic(const char *image_name, long align) static void pgb_reserved_va(const char *image_name, abi_ulong guest_loaddr, abi_ulong guest_hiaddr, long align) { - const int flags = MAP_ANONYMOUS | MAP_PRIVATE | MAP_NORESERVE; + int flags = MAP_ANONYMOUS | MAP_PRIVATE | MAP_NORESERVE; void *addr, *test; if (guest_hiaddr > reserved_va) { @@ -2307,15 +2307,19 @@ static void pgb_reserved_va(const char *image_name, abi_ulong guest_loaddr, /* Widen the "image" to the entire reserved address space. */ pgb_static(image_name, 0, reserved_va, align); +#ifdef MAP_FIXED_NOREPLACE + flags |= MAP_FIXED_NOREPLACE; +#endif + /* Reserve the memory on the host. */ assert(guest_base != 0); test = g2h(0); addr = mmap(test, reserved_va, PROT_NONE, flags, -1, 0); if (addr == MAP_FAILED) { error_report("Unable to reserve 0x%lx bytes of virtual address " - "space for use as guest address space (check your " + "space (%s) for use as guest address space (check your " "virtual memory ulimit setting or reserve less " - "using -R option)", reserved_va); + "using -R option)", reserved_va, strerror(errno)); exit(EXIT_FAILURE); } assert(addr == test); From patchwork Wed Jul 1 13:56:46 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Alex_Benn=C3=A9e?= X-Patchwork-Id: 192160 Delivered-To: patch@linaro.org Received: by 2002:a92:d244:0:0:0:0:0 with SMTP id v4csp532845ilg; Wed, 1 Jul 2020 07:13:48 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzvpTCcn/l2KmA+TxK8L6umbukhiCaatbyZNtk4Marj9gZ4mFEGwDpWDEhLzgCLl473tInT X-Received: by 2002:a05:6902:4e9:: with SMTP id w9mr41068347ybs.299.1593612828409; Wed, 01 Jul 2020 07:13:48 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1593612828; cv=none; d=google.com; s=arc-20160816; b=KsoDcphK22C6Ew6JT0f7/ANHZTAZVQZGs/wJkqD6drqxK0ezfek9j0Tlz933dVp+B2 jRgXhhcs4BRl2e9sykEjX5dzdixg+S15Wmwt8srCW+K9MqWY4FoluRAlvollvGzGYlHD Ttvq0TG67/OjTS+fc3hd31Efbx8kqeePqQhFPazhrXxFmvunOcMI3R/h/75pTvRZJa0P Vm2XhO5KrCIhVGFwl7OQHxTCjuPoab7sV3DOMWX/+kJDeL5KW4VFz/dGC1HoTPBqFYsx peHTzfLI5bYMNw02YDee/KEYzt6O5PcLHKI+If3dACTtKOv2Kps0rexE5iiWoHfxLYAt RauQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:cc:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=CVUuhZl1kRpSG6cEgnjsE0COEeahFDnSER/j+eEKc6g=; b=HHbrBWUZxQRnIIBTIS9EKdwJFUfaI3j8jRZ/VGjovo442FoU/xEWF0Swv24dDbXdLZ dn9NH5XT4isG9mHjJWnkZOCGM4Z1IjjO0x11v7QnpDFBBoOSHmBACTy3fBgNCdOqevRr ST3MbbcgWnQgYyLagifJuz0fOzky8XP+NJozSv+nt7yXaFmMkOuTwlZG2yug/yS1vv3z +yKjcBFcru8vuscoIev/tOwrYG44u3o0q9Zf5vtt8XWbpNXcwV0hRGEGfDF08e7+XDY3 jLJisq435Ef85S92dXKPn5Zqe2BIPPdPF4lApAPRTJP1g5BXxNsLDxa7hKbn4F64etii 69jg== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=jCZr9xE9; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id p128si5577042yba.492.2020.07.01.07.13.48 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Wed, 01 Jul 2020 07:13:48 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=jCZr9xE9; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1]:36810 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jqdUg-0005ES-DY for patch@linaro.org; Wed, 01 Jul 2020 10:13:47 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:60730) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jqdKl-0004aB-JI for qemu-devel@nongnu.org; Wed, 01 Jul 2020 10:03:31 -0400 Received: from mail-wm1-x341.google.com ([2a00:1450:4864:20::341]:55343) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1jqdKj-0006oT-8R for qemu-devel@nongnu.org; Wed, 01 Jul 2020 10:03:31 -0400 Received: by mail-wm1-x341.google.com with SMTP id g75so22535589wme.5 for ; Wed, 01 Jul 2020 07:03:28 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=CVUuhZl1kRpSG6cEgnjsE0COEeahFDnSER/j+eEKc6g=; b=jCZr9xE9nR1d3zYqCBJt7t5WSy0BZ0dZCBT96JIZWT6qTeM4q+T6uyBf0cZKxPcI0c 7VHiiVd363KH+6nw58INcwVrt0Ey8i4vDVPQlNAD4bQzS4cBfYyFF1kjVhsUY0Z6k2Xn 1OC05zsHEo1IghT6cP2GENxesfnWtbwjkf2UZtZ4W3Ea1U+2LNvSzzG0rUVeO7g66YPy A6wuZDRHTkkDhnQHbA250JFJpdSgiq/ww9foF1wAuv/VKEoLbv7j3H2FF5KYgmTPkorf OyV/QOluFCT1gfWodnpN7C/AfHUEIxBCag/zxmxDkEliSOrEz1SBHjNAcTBQoy1P3u+M 32lA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=CVUuhZl1kRpSG6cEgnjsE0COEeahFDnSER/j+eEKc6g=; b=PRUppJD3AfOY+ZeTuhsJs+K1iEE0Sera8A+b9Er/TFwuB6Oekk+ivAnzSuGHY7+G4x 8MOr5kyRNRL6SSI9x+8+udR2z5XSqeFnnEmvIUs+KVhS7goS+tJd21iCJyi/TciRgaI+ 2D8bzBSWqMhFjRo6P2gAUcxvmaSJkcj5IFDtFonv442k98YWVq9kqqPbeyEX7eQfEmF4 gZZO4ZN0e4PdxGCXXxg8hakfTWufGDu0Ny2GfwYgoAd6+hTqqlRO4dg2t/aOgIyPpa84 IsgWhsGnl5cMK9gGn7t7VbEFK4JJ8/Xqu53IyzkhLEWfWmO9kfJmMWaZY2vahgO4S0qu 7RrA== X-Gm-Message-State: AOAM531TrLVdHzrkhLsuNfNwiTh4P+h9PvlpQXOZ0Xo+GdDzH7rNYDST B8IEQIxEGT9Ap0U4y9+AcqxkHg== X-Received: by 2002:a1c:48c5:: with SMTP id v188mr25965818wma.58.1593612207587; Wed, 01 Jul 2020 07:03:27 -0700 (PDT) Received: from zen.linaroharston ([51.148.130.216]) by smtp.gmail.com with ESMTPSA id p25sm7001372wmg.39.2020.07.01.07.03.26 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 01 Jul 2020 07:03:26 -0700 (PDT) Received: from zen.lan (localhost [127.0.0.1]) by zen.linaroharston (Postfix) with ESMTP id 54ED41FFBB; Wed, 1 Jul 2020 14:56:56 +0100 (BST) From: =?utf-8?q?Alex_Benn=C3=A9e?= To: qemu-devel@nongnu.org Subject: [PATCH v4 34/40] gitlab: enable check-tcg for linux-user tests Date: Wed, 1 Jul 2020 14:56:46 +0100 Message-Id: <20200701135652.1366-35-alex.bennee@linaro.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20200701135652.1366-1-alex.bennee@linaro.org> References: <20200701135652.1366-1-alex.bennee@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::341; envelope-from=alex.bennee@linaro.org; helo=mail-wm1-x341.google.com X-detected-operating-system: by eggs.gnu.org: No matching host in p0f cache. That's all we know. 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=_AUTOLEARN X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: fam@euphon.net, Thomas Huth , berrange@redhat.com, =?utf-8?q?Alex_Benn=C3=A9e?= , richard.henderson@linaro.org, f4bug@amsat.org, Wainer dos Santos Moschetta , =?utf-8?q?Philippe_Mathieu-Daud?= =?utf-8?b?w6k=?= , cota@braap.org, aurelien@aurel32.net Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: "Qemu-devel" Switch to building in the new debian-all-test-cross image which has most of the cross compilers inline. Signed-off-by: Alex Bennée Reviewed-by: Philippe Mathieu-Daudé Reviewed-by: Thomas Huth --- .gitlab-ci.yml | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) -- 2.20.1 diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 93baf98232d..257947853b7 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -143,10 +143,9 @@ build-tcg-disabled: build-user: <<: *native_build_job_definition variables: - IMAGE: ubuntu2004 - CONFIGURE_ARGS: --disable-system --disable-guest-agent - --disable-capstone --disable-slirp --disable-fdt - MAKE_CHECK_ARGS: run-tcg-tests-i386-linux-user run-tcg-tests-x86_64-linux-user + IMAGE: debian-all-test-cross + CONFIGURE_ARGS: --disable-tools --disable-system + MAKE_CHECK_ARGS: check-tcg build-clang: <<: *native_build_job_definition From patchwork Wed Jul 1 13:56:47 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Alex_Benn=C3=A9e?= X-Patchwork-Id: 192164 Delivered-To: patch@linaro.org Received: by 2002:a92:d244:0:0:0:0:0 with SMTP id v4csp534629ilg; Wed, 1 Jul 2020 07:15:53 -0700 (PDT) X-Google-Smtp-Source: ABdhPJz0gRBZ3LgfU4jLVn5OIUQgMMXE7NNFD2A+ho7r1XYdt5wpnBMnqseW67ywhY2rhoRD6ujm X-Received: by 2002:ac8:429b:: with SMTP id o27mr14835218qtl.124.1593612953776; Wed, 01 Jul 2020 07:15:53 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1593612953; cv=none; d=google.com; s=arc-20160816; b=a5cV689cFW5N6krhpEcQeG/sU7DmvWm+OnVeKVNWem4ZW/3No9XAfZvbqqVfkpWXDU 7I5h+QAbekruLY5odjFeWSXbfNCI4yVKpZ7bC6eB77723yA0aAJrGzIcg1UcOa9PUFPy iNNGZOBJuHcsLKywU0TkxR3nBPbU60TRH/P/yT/0n/MZ7d9+idmxYZ7Ci6iL2jMVKM+I 72X02KHTH/msFEeMVfj2DwkjnwmqYWjCVDEcz3SG6ptkQf7hpCepOZcpoWyEl4kbhtEZ onib5ztD5CP84WkI3GORlcpZVepScBp3fCFEnndB0RI+/69nRiAPbL3rPpRuCa+jFQ9V Fw2A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:cc:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=BKCckCRRRPz6gI/TExKS1YsAaVbiJZyRRuAn4UPdxe8=; b=TVwxJ4mUhc1I7AaNiYwyHKz2NDt6nXUPP+ABwsHbGUTQAZZ7rXuHJEOq/7ZlbayoMn 2rBLa6jF2ZmZh7hzsRC0/buhDZ9vMTcdQvD/vSUOt4t8DfooGkN+AHIxO1XaMxY4NHUH kTII7UEQHSautgHYyP8etmjNgpXyMb2PKmet42P8hbnL+E/RKCU1U9ujxJJio7p4xFeo 6TueSry1VsGJy2wAuRKFR9iDN3yY2hRNpREllhZAbIsgLyhzHyjxWF2O8wqk8JuSkOHk 2qc0jPBvo0Uv9NTGXO76QvDXH8HbjyFP+suJHJSfnFdrAbCMv4wWiNbWAnBus/z7gapL K94g== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=Fm92SJuc; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id f21si3769307qka.377.2020.07.01.07.15.53 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Wed, 01 Jul 2020 07:15:53 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=Fm92SJuc; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1]:45948 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jqdWj-0000Xj-39 for patch@linaro.org; Wed, 01 Jul 2020 10:15:53 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:60796) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jqdKp-0004jp-KU for qemu-devel@nongnu.org; Wed, 01 Jul 2020 10:03:35 -0400 Received: from mail-wr1-x431.google.com ([2a00:1450:4864:20::431]:44174) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1jqdKm-0006p0-VS for qemu-devel@nongnu.org; Wed, 01 Jul 2020 10:03:35 -0400 Received: by mail-wr1-x431.google.com with SMTP id b6so23958435wrs.11 for ; Wed, 01 Jul 2020 07:03:32 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=BKCckCRRRPz6gI/TExKS1YsAaVbiJZyRRuAn4UPdxe8=; b=Fm92SJucfe68NHY/3M2hicaZn+Phdb/ohWjkOKmRut7aahr7HfpO/uEmr+lmRaw1YN xherJkoHDLUmb1X7vAoKI+YBXrWysxkIUet8rQgTxPPQCZIYaLdh4RqZVMHb8ZqHL7av kYuhq8K0m6UV7HTDZRnonr3STBFBe7bFK2ofjclRy12co4hl3XTF8YSK8qxnAvHyAh9r MZJns7goIALIRC2WYAk8MwEk4IuygwjwOx7dIlzawT0kcTTk/ypq5tpVfczBN7HhI3DW IOHxoF+TVTHI7qt+ru8Ml8GvabAt2lCiglyJBzJCnBkxH9l3jcvYLMspC7kxdeqjsOMI Ny6A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=BKCckCRRRPz6gI/TExKS1YsAaVbiJZyRRuAn4UPdxe8=; b=R7ZOS3Vqur/M2Ho0kXLKIhONPwj23aGR/IkwwYZqJNfGfYRqTyw4U683neruQWy+qP u0uljzLVN54msGZf+ob6oaYW/0euNx8OgqkvK2Acx6PdauHreKxFT1eUov2UPSfnwHUs Ddm89Ax8Bt6eUTxc6GWXuIJ6x8kjmbGvWoiMezMdb7tEVJsoVoftWhj+FyF8yLuWnIJV I3811zEexnlYB8MV1T2lPKVJCFbynGPT88PQt19Q4KYn088rITIwugYtIOQv4qYO1O1L /DfQCPKlF3bnvHY55SAjz+VOcQ/I2psDqTnEuIKxEuBtFi7ikHAoruykQTkqbTe4l3GZ fttQ== X-Gm-Message-State: AOAM530wKP1ANtA7ojTdW7PmtvvFt/45JODko5ZCGFErkmSqz7CpATjf RvfqvDCjUy6cpHoTRe4jgNahgA== X-Received: by 2002:a5d:44c7:: with SMTP id z7mr28853627wrr.226.1593612211517; Wed, 01 Jul 2020 07:03:31 -0700 (PDT) Received: from zen.linaroharston ([51.148.130.216]) by smtp.gmail.com with ESMTPSA id d2sm7750124wrs.95.2020.07.01.07.03.26 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 01 Jul 2020 07:03:26 -0700 (PDT) Received: from zen.lan (localhost [127.0.0.1]) by zen.linaroharston (Postfix) with ESMTP id 6CDEC1FFBC; Wed, 1 Jul 2020 14:56:56 +0100 (BST) From: =?utf-8?q?Alex_Benn=C3=A9e?= To: qemu-devel@nongnu.org Subject: [PATCH v4 35/40] gitlab: add avocado asset caching Date: Wed, 1 Jul 2020 14:56:47 +0100 Message-Id: <20200701135652.1366-36-alex.bennee@linaro.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20200701135652.1366-1-alex.bennee@linaro.org> References: <20200701135652.1366-1-alex.bennee@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::431; envelope-from=alex.bennee@linaro.org; helo=mail-wr1-x431.google.com X-detected-operating-system: by eggs.gnu.org: No matching host in p0f cache. That's all we know. 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=_AUTOLEARN X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: fam@euphon.net, Thomas Huth , berrange@redhat.com, =?utf-8?q?Alex_Benn=C3=A9e?= , richard.henderson@linaro.org, f4bug@amsat.org, Wainer dos Santos Moschetta , =?utf-8?q?Philippe_Mathieu-Daud?= =?utf-8?b?w6k=?= , cota@braap.org, aurelien@aurel32.net Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: "Qemu-devel" These can be quite big so lets cache them. I couldn't find any nots on ccache in the gitlab docs so I've just ignored it for now. Signed-off-by: Alex Bennée Reviewed-by: Philippe Mathieu-Daudé Message-Id: <20200622143204.12921-19-alex.bennee@linaro.org> --- .gitlab-ci.yml | 6 ++++++ 1 file changed, 6 insertions(+) -- 2.20.1 diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 257947853b7..13e9531724d 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -8,6 +8,12 @@ stages: - build - test +# We assume GitLab has it's own caching set up for RPM/APT repositories so we +# just take care of avocado assets here. +cache: + paths: + - $HOME/avocado/data/cache + include: - local: '/.gitlab-ci.d/edk2.yml' - local: '/.gitlab-ci.d/opensbi.yml' From patchwork Wed Jul 1 13:56:48 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Alex_Benn=C3=A9e?= X-Patchwork-Id: 192162 Delivered-To: patch@linaro.org Received: by 2002:a92:d244:0:0:0:0:0 with SMTP id v4csp533294ilg; Wed, 1 Jul 2020 07:14:20 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzYnYbYoWPaZFaX/1/NL2Zr0zbGUxLtM7sOP0Gdp/eXBj0hCe3dZqIDny7LPY4xcQXtV5Jv X-Received: by 2002:aed:279d:: with SMTP id a29mr27585788qtd.112.1593612860845; Wed, 01 Jul 2020 07:14:20 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1593612860; cv=none; d=google.com; s=arc-20160816; b=PXiMzAOO2A7G7sm6f7HZicy9ee6BEGMonOoaSDDjbBxZBw1oAi4s94i+9eGEoJGQ6B ZPUlQvLHdsHXfuSNH/rdVzUR717hMZeoIw/sfYNTyfrZMvuvXTlPYk2FE11mEywdJJgh /QiALUsbSSIaE49psBLiMFW18aXSz1Vc47KO7LflNeLEnFgUWMybg1yHjNF2Ph2CDk4i oaS5eTsOiWu7JuWkzEq9wC5gF8Kvnu1Xu/WgpgR61dcxx5DT2K7T1lPUHvOjspHY6fa8 4VoCFJsivt8BRFy7wmlsf5ndnUk9kD0gOP7BIzAJ3luIeoKl/mKHt31mSg2tBuEDIysG ZQTg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:cc:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=bOvcEoh+VzOuY+elSS3lw/PZUPV6sZX2V0ial7PUh0E=; b=Pne/NQ/4ERtVC2xXyOr5TnsoEqA+PbI3PzotBu4Z/Wh2L2yORIg8/cxhp7DEv80qF7 xeQ3vptgJcKkJUiZZRwx8YKMJupnyzy+b5Hufj0ISIJtBGaKTpWC9XFyJslgek14I7vz vEvHVk2pfttpO1a8ak3BGPpWnImXZFvs0B1swiXthhqFCzxgSuL8O5sR9msJb83mnUeC 4YHINzzTQh4y5XroPN08v97OX7/XB4oo0jy3HLQqil4RnlugkGISErXIZzfTlQ44kBwi 4INQAXFSzyKWFnyoV/4tYsh9Nx/Pi+sIK7evj+o92jcK5MRCiIptYpxWpjlaEBXJwemg ScHA== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=JLKoQ3J7; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id z46si3841624qth.380.2020.07.01.07.14.20 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Wed, 01 Jul 2020 07:14:20 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=JLKoQ3J7; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1]:39944 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jqdVE-0006VD-9w for patch@linaro.org; Wed, 01 Jul 2020 10:14:20 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:60980) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jqdL3-0005Gq-JP for qemu-devel@nongnu.org; Wed, 01 Jul 2020 10:03:49 -0400 Received: from mail-wr1-x42c.google.com ([2a00:1450:4864:20::42c]:38324) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1jqdL1-0006rj-PD for qemu-devel@nongnu.org; Wed, 01 Jul 2020 10:03:49 -0400 Received: by mail-wr1-x42c.google.com with SMTP id z13so23992230wrw.5 for ; Wed, 01 Jul 2020 07:03:47 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=bOvcEoh+VzOuY+elSS3lw/PZUPV6sZX2V0ial7PUh0E=; b=JLKoQ3J7EBzWdb5NlzmrWWeO78CTnNVWr4J48TDyFnHQfFxMZA1595KxZQ5TvdYkwe AF5BOrrIKv/AvkujT9R4iglkeSsBtGVDRLN9GG4SBIH2HMXR5q8R5uKyY/yljUWufzM4 KBZgw6lWw43Vjm2TO9fgVjbrHVjfct3DRXIr/WpdIK4RyaGxgaxYva8PIYV1lYwvsYN6 CJZWeVESJQMgNzQXeYZ9Lf2C8pUpMmW5C0iEro0Zk+sieCM5wPh9hHxLfCzOx8ObZxGu CKgt+lU62fcWBwc+/v0jRdAHz/F/krp+L4vNSzx6tZCSi7P+uBeDRv0EbBL5MMhfg0tH 0o6g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=bOvcEoh+VzOuY+elSS3lw/PZUPV6sZX2V0ial7PUh0E=; b=PXmglf1bzT8jATo2Dw69VeNWNatY1m1fm9syP8Qvhaew87Kuuf5UdEv7JQbL5ZipYo JTN8H1L/LZEDYPNGwPDySLICRIkKHYbxVXoN9ywpV1ythwUrY7YOJbYqa+fk8HneM1NT g52Um1dTAXIlrwUQaoK9Y2nB+iHIHKXOduEcol4y/8ejKVAVHyvY2o+GG7foXRZipI6I IDXMuSUahB65zVgPw12XqZtxc5vOZzF1wzcWj3KTtQ/RB0lgJfhmA7KrZiTbiXJRJmKE XFEzYqFIgijMnm1WI+FLpHltOUuTJkavLfYsJD+A5aQzRM2hPTMnueu8MKqiNueNBabc VAzg== X-Gm-Message-State: AOAM530aFn6KNbdqtzUOuFyy5CN7tMxuMq02z1DbGyto0fgGFffPQleG pAyOzdjf4AeL7F0j13tK0z37Yw== X-Received: by 2002:adf:f608:: with SMTP id t8mr27476592wrp.308.1593612226358; Wed, 01 Jul 2020 07:03:46 -0700 (PDT) Received: from zen.linaroharston ([51.148.130.216]) by smtp.gmail.com with ESMTPSA id z132sm7330352wmb.21.2020.07.01.07.03.36 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 01 Jul 2020 07:03:41 -0700 (PDT) Received: from zen.lan (localhost [127.0.0.1]) by zen.linaroharston (Postfix) with ESMTP id 818EC1FFBD; Wed, 1 Jul 2020 14:56:56 +0100 (BST) From: =?utf-8?q?Alex_Benn=C3=A9e?= To: qemu-devel@nongnu.org Subject: [PATCH v4 36/40] gitlab: split build-disabled into two phases Date: Wed, 1 Jul 2020 14:56:48 +0100 Message-Id: <20200701135652.1366-37-alex.bennee@linaro.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20200701135652.1366-1-alex.bennee@linaro.org> References: <20200701135652.1366-1-alex.bennee@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::42c; envelope-from=alex.bennee@linaro.org; helo=mail-wr1-x42c.google.com X-detected-operating-system: by eggs.gnu.org: No matching host in p0f cache. That's all we know. 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=_AUTOLEARN X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: fam@euphon.net, Thomas Huth , berrange@redhat.com, =?utf-8?q?Alex_Benn=C3=A9e?= , richard.henderson@linaro.org, f4bug@amsat.org, Wainer dos Santos Moschetta , =?utf-8?q?Philippe_Mathieu-Daud?= =?utf-8?b?w6k=?= , cota@braap.org, aurelien@aurel32.net Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: "Qemu-devel" As we run check-qtest in "SLOW" mode this can timeout so split into two jobs. Signed-off-by: Alex Bennée Reviewed-by: Philippe Mathieu-Daudé Reviewed-by: Thomas Huth --- v4 - rename :->- --- .gitlab-ci.yml | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) -- 2.20.1 diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 13e9531724d..83e38ea19f3 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -113,7 +113,7 @@ acceptance-system-fedora-alt: MAKE_CHECK_ARGS: check-acceptance <<: *post_acceptance -build-disabled: +build-system-fedora-disabled: <<: *native_build_job_definition variables: IMAGE: fedora @@ -124,6 +124,17 @@ build-disabled: --disable-qom-cast-debug --disable-spice --disable-vhost-vsock --disable-vhost-net --disable-vhost-crypto --disable-vhost-user TARGETS: i386-softmmu ppc64-softmmu mips64-softmmu i386-linux-user + artifacts: + paths: + - build + +qtest-system-fedora-disabled: + <<: *native_test_job_definition + needs: + - job: build-system-fedora-disabled + artifacts: true + variables: + IMAGE: fedora MAKE_CHECK_ARGS: check-qtest SPEED=slow build-tcg-disabled: From patchwork Wed Jul 1 13:56:49 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Alex_Benn=C3=A9e?= X-Patchwork-Id: 192145 Delivered-To: patch@linaro.org Received: by 2002:a92:d244:0:0:0:0:0 with SMTP id v4csp523341ilg; Wed, 1 Jul 2020 07:03:50 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzpHXpwo9DerjME044MCzo6irO7aNbfEjFWh5Usa4ZUC8GGgXuoNEbfr4yWab2OLA+z93yB X-Received: by 2002:a25:b3c9:: with SMTP id x9mr43933833ybf.203.1593612230108; Wed, 01 Jul 2020 07:03:50 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1593612230; cv=none; d=google.com; s=arc-20160816; b=Ar61ChKGNxgxr2OsMAXlv5yJUeZ9edsqHy8H7pdVHJMe1pJbzvvwfn3/dKHbPK9Xk2 nhAcjANECcDnhDVUia+fw4x2dPbq1lUC7CMch9nO1KbWMikfqa3syM1gut4ywvGOPXmA S89+yjBQnb0Qp3cyPhPOWWvgjyG33PvD9Xcm5FIDYBcazxOv5sW46nVLLY7kJGrsvn/A JSLPAygMULJi3UYg+9srqEEqTcnfFb1LhORLoIvQhL96kuHodFMUc0gguxCl0JzBM2PD 5UnNpFCfbvaIvDWC7/GrAGmnyKk2F22pjzLUKDoaEh0YkQuYkISrDxRR9OpG48j8lm+f gBRQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:cc:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=hCA6Fp1zjl/YcdAD2qr1JaESX1/DMtcBS8XPo6xk3BI=; b=TigNNeHjLoujPXDN/SLDfLk0h+Q84ZCuLs0FGs15o4+5Dw2JnwT1Bj2V8j/vUcDbEt lnYqvKJM59r0F1Y6eMNFDX1X6F/1OLvIL4oa0ASgNijp0hvbLh0JoLmru2EciwiCvIGn vKOpYv82utfgbxEW+GxfnM5bOgt1Mq015yW6rHTjrEQIyjRLT7PLLVzMXy47A1ndkijE mmTGfv/yR512JsIu47O1tFzZMsft2PxGuzWQEiEhaknt4/vv89tltPhwW4i+jTWW/EU0 JJve5L7JRUf2DrQKT9fIz2qkJxiOXZ8+BvLnXnvPLgJXjdDvpMpPVwkCdeWDIkBqu6Sh atww== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=evcPGZDx; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id m7si6124008ybo.49.2020.07.01.07.03.50 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Wed, 01 Jul 2020 07:03:50 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=evcPGZDx; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1]:52142 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jqdL3-0004lx-G6 for patch@linaro.org; Wed, 01 Jul 2020 10:03:49 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:59130) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jqdEu-0002cC-Vt for qemu-devel@nongnu.org; Wed, 01 Jul 2020 09:57:29 -0400 Received: from mail-wr1-x443.google.com ([2a00:1450:4864:20::443]:40071) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1jqdEj-0005tW-4e for qemu-devel@nongnu.org; Wed, 01 Jul 2020 09:57:28 -0400 Received: by mail-wr1-x443.google.com with SMTP id h5so23947241wrc.7 for ; Wed, 01 Jul 2020 06:57:16 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=hCA6Fp1zjl/YcdAD2qr1JaESX1/DMtcBS8XPo6xk3BI=; b=evcPGZDx6VcoAplJ+O3WTf/V0gdN7LFhhqY+tWhKnSlyof1wl3pDaslalzqlh2Dtf3 NUPMVrksla/BXss5p/QiJWzXEtzlOS997usukFS6idwW1PXEdmyPgT4c3a7PqDl0bHl/ M01tgp2ktTtRsnjkOIip6Nsm80ZaKTcy+Wzv2ZW8ve4fWbbMMBWqxq6axU7AEsV9SdUg PEoDKzZWFXYOkAa2BjbCAMoCTUm/SKAk2uhIDtP7KXQIg9ZfNOsNKjBJv2d/pIj5mHvQ K+zO0Z+WVPBC/696VzTC0KyCT5CgzKrOO2fJUpeF1b+KUmh9cVkwKtV+GOKuEZxhNQxh cFsw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=hCA6Fp1zjl/YcdAD2qr1JaESX1/DMtcBS8XPo6xk3BI=; b=m2+jBrbvfjpLHDN3h/qqsKqCHUmpYVcacrpLBOCqF8RPqKQxo7rb7q5sjSAFo/Gj4D bWbjVnsHXoYcP4lxcvwjVAOfTs0vVvEjb0GqCedSYUbNY0BEmB6zrH2U+/UQb8jqgfXg qZtKRzGKRCfcQi/6kNhJYCtPukFVI9Jm1GIvtYANQPmksqzYeMiVsKI2gReVuA43tnSs iqlj1GbuDGXhFGaSo/w24m6F5sd0FLtMTMNGfp/m8vMHDRRsH8AqTfI9WoQ8l1PbWSge IspLvILWWbJ/Hb3IHsaeDXjE42cena/cTNIsuSfkdM6IhpWHGeNOJEbBAKgrozggizBC rHUQ== X-Gm-Message-State: AOAM531ZxbbEgWxlYGU5e23TfhHESey+mjW2R4af6ByQgLwBJEpmECbY E6Z9sc12WOBM/JmaZI6xRGNlSw== X-Received: by 2002:adf:8b5a:: with SMTP id v26mr26527074wra.165.1593611835351; Wed, 01 Jul 2020 06:57:15 -0700 (PDT) Received: from zen.linaroharston ([51.148.130.216]) by smtp.gmail.com with ESMTPSA id y20sm7266415wmi.8.2020.07.01.06.57.01 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 01 Jul 2020 06:57:05 -0700 (PDT) Received: from zen.lan (localhost [127.0.0.1]) by zen.linaroharston (Postfix) with ESMTP id 973331FFBE; Wed, 1 Jul 2020 14:56:56 +0100 (BST) From: =?utf-8?q?Alex_Benn=C3=A9e?= To: qemu-devel@nongnu.org Subject: [PATCH v4 37/40] gitlab: limit re-builds of the containers Date: Wed, 1 Jul 2020 14:56:49 +0100 Message-Id: <20200701135652.1366-38-alex.bennee@linaro.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20200701135652.1366-1-alex.bennee@linaro.org> References: <20200701135652.1366-1-alex.bennee@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::443; envelope-from=alex.bennee@linaro.org; helo=mail-wr1-x443.google.com X-detected-operating-system: by eggs.gnu.org: No matching host in p0f cache. That's all we know. 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=_AUTOLEARN X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: fam@euphon.net, berrange@redhat.com, =?utf-8?q?Alex_Benn=C3=A9e?= , richard.henderson@linaro.org, f4bug@amsat.org, =?utf-8?q?Philippe_Mat?= =?utf-8?q?hieu-Daud=C3=A9?= , cota@braap.org, aurelien@aurel32.net Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: "Qemu-devel" Most of the time we are just rebuilding the same things. We can skip this although currently there is no mechanism for picking up new distro releases. Rather than try to be too fine grained allow any change to trigger all the images being rebuilt. Signed-off-by: Alex Bennée Reviewed-by: Philippe Mathieu-Daudé --- v4 - try and include branches - use rules instead --- .gitlab-ci.d/containers.yml | 6 ++++++ 1 file changed, 6 insertions(+) -- 2.20.1 diff --git a/.gitlab-ci.d/containers.yml b/.gitlab-ci.d/containers.yml index a7621c4204c..ea350eacff7 100644 --- a/.gitlab-ci.d/containers.yml +++ b/.gitlab-ci.d/containers.yml @@ -17,6 +17,12 @@ - docker push "$TAG" after_script: - docker logout + rules: + - changes: + - .gitlab-ci.d/containers.yml + - tests/docker/* + - if: '$CI_COMMIT_BRANCH == $CI_DEFAULT_BRANCH' + - if: '$CI_COMMIT_REF_NAME == "testing/next"' amd64-centos7-container: <<: *container_job_definition From patchwork Wed Jul 1 13:56:50 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Alex_Benn=C3=A9e?= X-Patchwork-Id: 192158 Delivered-To: patch@linaro.org Received: by 2002:a92:d244:0:0:0:0:0 with SMTP id v4csp531704ilg; Wed, 1 Jul 2020 07:12:29 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxt4nqJbVcav6sljs3BWrE+5ikaQo+BoJV8us4Z+VD/UXoaR7wn6uHMUoSSUzRbMg+EZBdr X-Received: by 2002:a25:1843:: with SMTP id 64mr38410375yby.89.1593612749706; Wed, 01 Jul 2020 07:12:29 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1593612749; cv=none; d=google.com; s=arc-20160816; b=BajEIBQbQCmJzarorU2Sz9tssutbvFqqmWCvo0/KQwlePp4M5Duv6LxjX2yfNQym7J bPhhnvCf5BHyPdfvnulrI1M6ICRJzcSfgZjBbVdz62wE1v13FNimLZFLVMqsTRo+S/9W dXopiP7zz3FrFrYx8LS3RZ2VhEunB5UhL+xiRYDJXOMOvzWk28jc1HNMJ06oU0JO2s+e SPm+0ZoZYegdiPZl9ISzayN6K8NByHivdDby3PR2kMzb+RCdgyHoudW5OiPaYoviZqqP 6Cg0vCVlFtDmrTB8tr6Pdu2LZoL3VPD7kwAQablz0RwyrSqfSmgB2vZMC1E7jhDn3Q4T SG+w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:cc:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=6WtCLGQRv0MjUdUMAEZUN6efvnmj6vJqFczlhuv8qdY=; b=sjXn3zvx/+1QSSaOs01TLRzRV+VyI3E5aH+b+LarHUOhQwpMEq1MnMGIDDjlgSJa03 CYoXSsABKhF8P2YeNjF53cvePHpPeshEOu0w9BndNQRR7tU7/aSrywoW/KNCfgmQUfaw F+56NuqWpK4nMxDeRMvnEOcN4BrN1EIPSFP9X3/vEGYlUSkAvu+mcAYoA/25TafjHu/I F9vot0Zv+EonfbJzXQJVbBTkJirZYnslmpq7k4lZG80BKECP+CPddJIt4x3PrAffhXdw ZUb48AzsrI8rM71tJ1KeCdGwJj/7cZ5D1HI0MNjFK+AB5YJxFr9VkX/6K9syFut/AkSg tUnw== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=QqQwjLi6; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id v13si5811169ybs.299.2020.07.01.07.12.29 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Wed, 01 Jul 2020 07:12:29 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=QqQwjLi6; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1]:59794 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jqdTR-00032p-4N for patch@linaro.org; Wed, 01 Jul 2020 10:12:29 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:60916) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jqdKy-00056C-Tq for qemu-devel@nongnu.org; Wed, 01 Jul 2020 10:03:44 -0400 Received: from mail-wm1-x343.google.com ([2a00:1450:4864:20::343]:40161) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1jqdKx-0006qf-4V for qemu-devel@nongnu.org; Wed, 01 Jul 2020 10:03:44 -0400 Received: by mail-wm1-x343.google.com with SMTP id f139so23386622wmf.5 for ; Wed, 01 Jul 2020 07:03:42 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=6WtCLGQRv0MjUdUMAEZUN6efvnmj6vJqFczlhuv8qdY=; b=QqQwjLi6YMb46gu33K/TpzYfCNGIN43MXqPRXDIsa6R/ZiLe5p7ZJ/vE/Rg4yh3uVf Cbr2pw1JMakjN0l5veMvTSXzn+ueigEJCXFYJuxCpHVfvVJBTlql2K/MjcPcCVd0XCfT YAmpJ7VzFAwJO+LUR2w9LUeSO1AcuZGrBH33b7AxyyWg7EJ8PYyudr6kponaGkxAsGVX /xhXR8Vz+CUBRDxdTeh+/diUwy82SpCRlZ9ZdRhRHDDLH1Nt32JiYjsksqsSWoUCx55V WBvKSE9OJMANPshS8ZsltJnsXVCwcoSTtIRh2xY96mFDM717lqKc9q2ob1FdNLkVSPlX nU+Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=6WtCLGQRv0MjUdUMAEZUN6efvnmj6vJqFczlhuv8qdY=; b=pdZosqypbE0bWMQ4+bGaCELH+o/+Qsz2T35aw4EQ4cTvizBw+wQV/ZSzq2HbzK6pTq iJV7EdBkDu3ki1t3rr9lUTodvsTL70p8d3V5jF/6MYXDA383x1j+LlkinyNLStVfhZcN fdCGd11dspSxPDvJoy4aU8BtRxS2LasI1Gy/fXI4XP4/QYaskRnpicMisY8UegC3ouae ZkW+2ZhQANvXxuI1qvCxWk5mzzfgFuUfBNi/ck1rQwp2H6eFIbS2S77MS2DuP+kxts2c L5VGFLPTD3d//GfwcCfGj7sAKlRVXtYzr0tW7sHzLvuYEHks879xn+8DroACGbKGsNYv JR4A== X-Gm-Message-State: AOAM531IGyPl7kZ8G58ghPU5u+4/jmN4w9uL7rT+6rsgIL6pOb/EdsgS mcDrW2G+Wv5AQvirPjGUGsqo4Q== X-Received: by 2002:a1c:4408:: with SMTP id r8mr26937260wma.100.1593612221643; Wed, 01 Jul 2020 07:03:41 -0700 (PDT) Received: from zen.linaroharston ([51.148.130.216]) by smtp.gmail.com with ESMTPSA id m4sm7346717wmi.48.2020.07.01.07.03.31 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 01 Jul 2020 07:03:33 -0700 (PDT) Received: from zen.lan (localhost [127.0.0.1]) by zen.linaroharston (Postfix) with ESMTP id ABF9A1FFBF; Wed, 1 Jul 2020 14:56:56 +0100 (BST) From: =?utf-8?q?Alex_Benn=C3=A9e?= To: qemu-devel@nongnu.org Subject: [PATCH v4 38/40] containers.yml: build with docker.py tooling Date: Wed, 1 Jul 2020 14:56:50 +0100 Message-Id: <20200701135652.1366-39-alex.bennee@linaro.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20200701135652.1366-1-alex.bennee@linaro.org> References: <20200701135652.1366-1-alex.bennee@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::343; envelope-from=alex.bennee@linaro.org; helo=mail-wm1-x343.google.com X-detected-operating-system: by eggs.gnu.org: No matching host in p0f cache. That's all we know. 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, URIBL_BLOCKED=0.001 autolearn=_AUTOLEARN X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: fam@euphon.net, berrange@redhat.com, =?utf-8?q?Alex_Benn=C3=A9e?= , richard.henderson@linaro.org, f4bug@amsat.org, cota@braap.org, aurelien@aurel32.net Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: "Qemu-devel" Instead of building the docker files directly use the same docker.py scripting as we do for building locally. This should help ensure we use the exact same steps and allow us to cache properly when building locally. To get this working you have to have a fairly recent docker binary otherwise you will see the error message: => ERROR importing cache manifest from registry.gitlab.... So far docker 19.03.12 works (from the docker apt repos) but 18.09.1, build 4c52b90 which is packaged in Debian Buster fails. Signed-off-by: Alex Bennée --- .gitlab-ci.d/containers.yml | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) -- 2.20.1 diff --git a/.gitlab-ci.d/containers.yml b/.gitlab-ci.d/containers.yml index ea350eacff7..b1e39cfd9ac 100644 --- a/.gitlab-ci.d/containers.yml +++ b/.gitlab-ci.d/containers.yml @@ -6,14 +6,17 @@ before_script: - export TAG="$CI_REGISTRY_IMAGE/qemu/$NAME:latest" - export COMMON_TAG="$CI_REGISTRY/qemu-project/qemu/$NAME:latest" + - apk add python3 - docker info - docker login registry.gitlab.com -u "$CI_REGISTRY_USER" -p "$CI_REGISTRY_PASSWORD" script: + - echo "TAG:$TAG" + - echo "COMMON_TAG:$COMMON_TAG" - docker pull "$TAG" || docker pull "$COMMON_TAG" || true - - sed -i -e "s,FROM qemu/,FROM $CI_REGISTRY_IMAGE/qemu/," tests/docker/dockerfiles/$NAME.docker - - DOCKER_BUILDKIT=1 docker build --cache-from "$TAG" --cache-from "$COMMON_TAG" --tag "$TAG" - --build-arg BUILDKIT_INLINE_CACHE=1 - -f "tests/docker/dockerfiles/$NAME.docker" tests/docker/dockerfiles + - ./tests/docker/docker.py --engine docker build + -t "qemu:$NAME" -f "tests/docker/dockerfiles/$NAME.docker" + -r $CI_REGISTRY_IMAGE + - docker tag "qemu:$NAME" "$TAG" - docker push "$TAG" after_script: - docker logout From patchwork Wed Jul 1 13:56:51 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Alex_Benn=C3=A9e?= X-Patchwork-Id: 192170 Delivered-To: patch@linaro.org Received: by 2002:a92:d244:0:0:0:0:0 with SMTP id v4csp538897ilg; Wed, 1 Jul 2020 07:20:41 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzJnVxIuBK4KPySetbCc4kwa/NefQIurWYcclBMj2ZA2Pa72Hm5IHvQGNGFpNRjDR28tmI/ X-Received: by 2002:a0c:ea26:: with SMTP id t6mr15793504qvp.220.1593613241128; Wed, 01 Jul 2020 07:20:41 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1593613241; cv=none; d=google.com; s=arc-20160816; b=oXYk2eWFltMWIEvkqCKZr95w52WXAH2PoLHcf3b9NncXE18MkO6ia6cCZxiJKgDOU2 EEJ3ZXwrpyQdHu6Xa4XXyl0qoeTYYw7ani4KehpB9kj/FmwAwHb15722ur0/gy/UXuX7 zUR6SeDLC80rSkIIRdcqoeLQdYG23K5QFbLOlTUupcQdcoi3C/8nZLQo+9kCQApm9H38 LC0gb6jUstSYUVAm3UDW/X6hPWDBy6aO0Oz4/xdB2VSyYXP4p9fSScpNr0wNLFevEDV6 Lfw0NPY/QTYB41qW37w4H4Lf0ceWCZarUl6wpvsVXWovtmOq0YsVNobTkLPpxdDfhGsq 1SDQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:cc:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=6iI9/w6QPP17yFAS2LeQCOWZjjok/LI3j4IGGgPNwkk=; b=XKZ3xMEAhQer77B3odq6VFqkquPQvbCnk/HSMYipw57bIYEruHDjO2pLaHXxm6ASyJ HeWmD8Q3KzlCPUmrBCOYTIRy/HJ2H7xN2UIe5xynCVt62gfXJW70c5S7GbTIp2TYfAXA 4rxCKb9jdyvA/CoDQK9f6qYptRSvMHBqCvXwwCNluDH2BHcHzW9aIBRzpURCFfij6d24 l9DRBk6ge0ZXgLb36UoquYrhmZUzHMoKf+UpEgq3bH0P+YjCwPXaNXtUB/NWSGn4eNMG 4xreM2sYmnknIT6yOXG794JMwq5qoEiWBsmBDIuYuZl2R2oqYUfxKBDMTfIfn3hGxCDr LvQg== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=oQrjkOJZ; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id j15si3495004qvp.55.2020.07.01.07.20.41 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Wed, 01 Jul 2020 07:20:41 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=oQrjkOJZ; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1]:34024 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jqdbM-0007U1-GM for patch@linaro.org; Wed, 01 Jul 2020 10:20:40 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:32790) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jqdL6-0005Nw-Qv for qemu-devel@nongnu.org; Wed, 01 Jul 2020 10:03:52 -0400 Received: from mail-wr1-x42b.google.com ([2a00:1450:4864:20::42b]:33272) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1jqdL4-0006s6-LO for qemu-devel@nongnu.org; Wed, 01 Jul 2020 10:03:52 -0400 Received: by mail-wr1-x42b.google.com with SMTP id f18so15927678wrs.0 for ; Wed, 01 Jul 2020 07:03:50 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=6iI9/w6QPP17yFAS2LeQCOWZjjok/LI3j4IGGgPNwkk=; b=oQrjkOJZ5sjTJa4s+xN7BoTtY6doSPVbV6LoG3Sn0CaYY3ZhEGylBntFSml1Q6vWBR O173JsW/NqnAleGq+rG4qnqhp3G1UECM0/MtVbayvof2qaMJHel/MeRE0HQ3MoXE89vi bgXyMtzlI1aDJDmlQGYtZJgaGqI5EUq3zxueaY/EmoeklqCapD6xMMwWBzEsJyDkNLfH oz1Od1l16EHZoyHkX5wFqdpmc8bF7TTueEEdgOkJzR0YskrXsQUIgWJwGc6MF9oVh1kP 9NKc6cYme4ysyeoWBHfT+06yZXv+OsPTeaxXiE+qVedFZ2emJiftQOrSlfUobuApILcV TNqA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=6iI9/w6QPP17yFAS2LeQCOWZjjok/LI3j4IGGgPNwkk=; b=S7r/EmkfWMj1G8t3H1P3lL7pQ7uZjNAZGzVLd/9ATYVsgiDJJF4TqvaRMGQ12pa4Pu dZ97YLekuv/QLzAwSNqn+DBF3lRTRQQL4RPv3fRLSpl0U2yNXqiO1iVXBHzukC0qOZV5 cflz3Ky0OnZ+sjlWHr2b9mC0Q0DZgQpaJtxqM+pjWTqT5xNuLnYQPiLzJW8Ap1UGYsyu zETaZh7C37scEdOjzB/UfZL9s4UlpzSKjMhLF0+0htMiWbRsrlh7E8F1/JvhAgRulFV5 0oINFGRh6u+3AGUpkCxgxkNKny9igo47OGeEN6RTBS8e/a7XDEvTA9efoJxFf8g2zvH7 zjxQ== X-Gm-Message-State: AOAM532B1TcF4U/YXF9GTkvANkcIiq5FZKezrLQwijmOYVXMmBPyjh1i ggbsacgbj1MmyXqLc8rFOTeMDg== X-Received: by 2002:adf:e6c8:: with SMTP id y8mr28673953wrm.40.1593612229115; Wed, 01 Jul 2020 07:03:49 -0700 (PDT) Received: from zen.linaroharston ([51.148.130.216]) by smtp.gmail.com with ESMTPSA id q1sm7406724wro.82.2020.07.01.07.03.34 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 01 Jul 2020 07:03:41 -0700 (PDT) Received: from zen.lan (localhost [127.0.0.1]) by zen.linaroharston (Postfix) with ESMTP id C60E01FFC0; Wed, 1 Jul 2020 14:56:56 +0100 (BST) From: =?utf-8?q?Alex_Benn=C3=A9e?= To: qemu-devel@nongnu.org Subject: [PATCH v4 39/40] testing: add check-build target Date: Wed, 1 Jul 2020 14:56:51 +0100 Message-Id: <20200701135652.1366-40-alex.bennee@linaro.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20200701135652.1366-1-alex.bennee@linaro.org> References: <20200701135652.1366-1-alex.bennee@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::42b; envelope-from=alex.bennee@linaro.org; helo=mail-wr1-x42b.google.com X-detected-operating-system: by eggs.gnu.org: No matching host in p0f cache. That's all we know. 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=_AUTOLEARN X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: fam@euphon.net, Thomas Huth , berrange@redhat.com, =?utf-8?q?Alex_Benn=C3=A9e?= , richard.henderson@linaro.org, f4bug@amsat.org, Wainer dos Santos Moschetta , =?utf-8?q?Philippe_Mathieu-Daud?= =?utf-8?b?w6k=?= , cota@braap.org, aurelien@aurel32.net Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: "Qemu-devel" If we want to continue to split build and check phase it seems like a good idea to allow building of the tests during our multi-threaded build phase. Signed-off-by: Alex Bennée Cc: Daniel P. Berrangé --- .gitlab-ci.yml | 5 ++++- tests/Makefile.include | 17 +++++++++++++---- 2 files changed, 17 insertions(+), 5 deletions(-) -- 2.20.1 Reviewed-by: Philippe Mathieu-Daudé diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 83e38ea19f3..b0e5417146b 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -36,7 +36,7 @@ include: - make -j"$JOBS" - if test -n "$MAKE_CHECK_ARGS"; then - make $MAKE_CHECK_ARGS ; + make -j"$JOBS" $MAKE_CHECK_ARGS ; fi .native_test_job_template: &native_test_job_definition @@ -60,6 +60,7 @@ build-system-ubuntu-main: TARGETS: aarch64-softmmu alpha-softmmu cris-softmmu hppa-softmmu lm32-softmmu moxie-softmmu microblazeel-softmmu mips64el-softmmu m68k-softmmu ppc-softmmu riscv64-softmmu sparc-softmmu + MAKE_CHECK_ARGS: check-build artifacts: paths: - build @@ -90,6 +91,7 @@ build-system-fedora-alt: TARGETS: tricore-softmmu unicore32-softmmu microblaze-softmmu mips-softmmu riscv32-softmmu s390x-softmmu sh4-softmmu sparc64-softmmu x86_64-softmmu xtensa-softmmu nios2-softmmu or1k-softmmu + MAKE_CHECK_ARGS: check-build artifacts: paths: - build @@ -124,6 +126,7 @@ build-system-fedora-disabled: --disable-qom-cast-debug --disable-spice --disable-vhost-vsock --disable-vhost-net --disable-vhost-crypto --disable-vhost-user TARGETS: i386-softmmu ppc64-softmmu mips64-softmmu i386-linux-user + MAKE_CHECK_ARGS: check-build artifacts: paths: - build diff --git a/tests/Makefile.include b/tests/Makefile.include index c316e0d6647..94b1cc8302e 100644 --- a/tests/Makefile.include +++ b/tests/Makefile.include @@ -22,6 +22,8 @@ endif @echo " $(MAKE) check-venv Creates a Python venv for tests" @echo " $(MAKE) check-clean Clean the tests and related data" @echo + @echo "The following are useful for CI builds" + @echo " $(MAKE) check-build Build most test binaris" @echo " $(MAKE) get-vm-images Downloads all images used by acceptance tests, according to configured targets (~350 MB each, 1.5 GB max)" @echo @echo @@ -649,6 +651,10 @@ $(patsubst %, check-qtest-%, $(QTEST_TARGETS)): check-qtest-%: %-softmmu/all $(c QTEST_QEMU_BINARY=$*-softmmu/qemu-system-$* \ QTEST_QEMU_IMG=qemu-img$(EXESUF)) +build-qtest: $(patsubst %, %-softmmu/all, $(QTEST_TARGETS)) $(check-qtest-y) + +build-unit: $(check-unit-y) + check-unit: $(check-unit-y) $(call do_test_human, $^) @@ -680,7 +686,6 @@ check-report.tap: $(patsubst %,check-report-qtest-%.tap, $(QTEST_TARGETS)) check FP_TEST_BIN=$(BUILD_DIR)/tests/fp/fp-test # the build dir is created by configure -.PHONY: $(FP_TEST_BIN) $(FP_TEST_BIN): config-host.h $(test-util-obj-y) $(call quiet-command, \ $(MAKE) $(SUBDIR_MAKEFLAGS) -C $(dir $@) V="$(V)" $(notdir $@), \ @@ -814,9 +819,10 @@ check-softfloat-ops: $(SF_MATH_RULES) .PHONY: check-softfloat ifeq ($(CONFIG_TCG),y) -check-softfloat: check-softfloat-conv check-softfloat-compare check-softfloat-ops +build-softfloat: $(FP_TEST_BIN) +check-softfloat: build-softfloat check-softfloat-conv check-softfloat-compare check-softfloat-ops else -check-softfloat: +build-softfloat check-softfloat: $(call quiet-command, /bin/true, "FLOAT TEST", \ "SKIPPED for non-TCG builds") endif @@ -955,7 +961,8 @@ check-qtest: $(patsubst %,check-qtest-%, $(QTEST_TARGETS)) ifeq ($(CONFIG_TOOLS),y) check-block: $(patsubst %,check-%, $(check-block-y)) endif -check: check-block check-qapi-schema check-unit check-softfloat check-qtest check-decodetree +check-build: build-unit build-softfloat build-qtest + check-clean: rm -rf $(check-unit-y) tests/*.o tests/*/*.o $(QEMU_IOTESTS_HELPERS-y) rm -rf $(sort $(foreach target,$(SYSEMU_TARGET_LIST), $(check-qtest-$(target)-y:%=tests/qtest/%$(EXESUF))) $(check-qtest-generic-y:%=tests/qtest/%$(EXESUF))) @@ -963,6 +970,8 @@ check-clean: rm -f tests/qtest/dbus-vmstate1-gen-timestamp rm -rf $(TESTS_VENV_DIR) $(TESTS_RESULTS_DIR) +check: check-block check-qapi-schema check-unit check-softfloat check-qtest check-decodetree + clean: check-clean # Build the help program automatically From patchwork Wed Jul 1 13:56:52 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Alex_Benn=C3=A9e?= X-Patchwork-Id: 192163 Delivered-To: patch@linaro.org Received: by 2002:a92:d244:0:0:0:0:0 with SMTP id v4csp534485ilg; Wed, 1 Jul 2020 07:15:44 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwkDSZRtRz7X4jisevzAome0Yf9laDTbnjt+Gaf+qGNwdisZ++f2eN6bGfp2wBiUXn9JngZ X-Received: by 2002:a37:b83:: with SMTP id 125mr24386002qkl.96.1593612944715; Wed, 01 Jul 2020 07:15:44 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1593612944; cv=none; d=google.com; s=arc-20160816; b=xa7R1aB8csniGxhgy1JPfIKmohDuBrQ63Ktq9D9EqPXNu3Q5Kii7hM3pDMfyfnIzST ZxdpQ0m/F0lA+Vcyxv+sDcjnUfQaRRWSKEUPjGTMbZ7kpWHUKV0ep3lD5OkZsI183JR9 GAkj56eGKmbK/zvPacNN2l8M7iJmiCFrQT1CfgyUVNmEdueoUopNRHV5AVudM63V9kHq 1a2cuI4O2VYvt0wF3kn5D13FeVTbOO271IuODds2Y/oR9PZEKH485TuIgkZ0Tf2sx9bM C+cDxMx2fJZbq7Gh9xFcp60hFNizXLQk8w0hCurWZunlOnJT2gCvVxKG2sEU4R/N8+5/ LQjw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:cc:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=Z8+7R3MmmcndzfMXwtKjgL5/CCMc+Xc8nupS/X00rus=; b=SSV/i7hqgrXfJhJBrNN9/nkG+jC4eouQYs3HrWHSWfJerSiE+C80c616x6lkLYAUo9 QOuqWuXMQvqLd+vrY9To7YPEdvKfOD/QEPsokFvyimLjHG0v7XOZfG+dprbt5FvyryO3 nyKPt0RVPUEs7kA/91SQAHQ78Tb2vQf4niEuMwGEZpTz9FuGoSrSgI6DnCLo3l3TPCqO tpPwX7c7x7hAO7AWjwQgcCWeFfU8uwgsIqiY9wbybvdEj9HW57IsV6t90sNGOwbzma8A CLFQX1x71uKwS8kZugL5VGjFAYDj8gh3MjweOaPldNGZI0FQQHxVm7+Hva5ZU0zo/tly 7WfA== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=qcjQf1DS; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id k4si3419911qvu.109.2020.07.01.07.15.44 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Wed, 01 Jul 2020 07:15:44 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=qcjQf1DS; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1]:45162 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jqdWW-0000CQ-3o for patch@linaro.org; Wed, 01 Jul 2020 10:15:40 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:60896) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jqdKw-0004zv-Cg for qemu-devel@nongnu.org; Wed, 01 Jul 2020 10:03:42 -0400 Received: from mail-wr1-x42e.google.com ([2a00:1450:4864:20::42e]:39625) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1jqdKu-0006qO-Lf for qemu-devel@nongnu.org; Wed, 01 Jul 2020 10:03:42 -0400 Received: by mail-wr1-x42e.google.com with SMTP id q5so23978914wru.6 for ; Wed, 01 Jul 2020 07:03:40 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=Z8+7R3MmmcndzfMXwtKjgL5/CCMc+Xc8nupS/X00rus=; b=qcjQf1DSHf79VcNlRR59uY0ST5iwrQh3WQ6BFifR02+48pLWqNbg8erPyCVsT/LXlT k37ZGL40+YiMavb3iCMaMvSdZSbRaM1Pfd9hpnbTj5hHvyUZxaiA7cRG/A3Y3AEXR71e e2akNGhBuooZCCe87GhxAleMaa0GBhMb6ITMIdo+Z9zXcLboVWti66+mT4l1K7G+Jsh+ N0ky+g9AlWneZeHzxPs5l09jgG2WEN5ds4LdE4KIJDALsvpePamBPSJA4ppAjD29ZATN FfHyeV42A3JIvPaCnJohPy5aw7U0tBcyLy2oq1yD7dXTiSg+GMUWrTxPu4qTdGMMX/Rt bQmQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=Z8+7R3MmmcndzfMXwtKjgL5/CCMc+Xc8nupS/X00rus=; b=PNzbw7nU3J/a/pdhPlE4jvLji/SRhy43OvFDHgVZnpwQeRMcp/wcYnL8GWWZDVHPzU IK09FLlnlVKnjYy0gP9L64XYIhILOvG0FSBk7hxwQKVz0y/r+9Xfgyf2cGbnpFJqy9cm /27yuatkidVbGvMRnQygqd3ZgPnoCXMSNwrTPDRcocNtKQz3/pxJqCPltl/8Iw1FASBr 4jR44sLEJxkNAckB0jPmCzIS8FZFXOf5ztzgh7SNng1yixpY6Ae3vsEe41v9UepIM5Ki dyo3/0S8+P9JX0H/zHC4/EYS6JC7U2qKQ2dApJASy8dpCgy8m2Cpc0tsf1aS+SUgY12h hfcQ== X-Gm-Message-State: AOAM530UAioYOA3g/5cvi974ReS7twWHglwNzWVe0G2C834Tib/1TlRC a6ClvZwXpxwQFetapZ+HOjV9YXyJFME= X-Received: by 2002:a5d:60d0:: with SMTP id x16mr27639775wrt.5.1593612219261; Wed, 01 Jul 2020 07:03:39 -0700 (PDT) Received: from zen.linaroharston ([51.148.130.216]) by smtp.gmail.com with ESMTPSA id p14sm8261263wrj.14.2020.07.01.07.03.31 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 01 Jul 2020 07:03:33 -0700 (PDT) Received: from zen.lan (localhost [127.0.0.1]) by zen.linaroharston (Postfix) with ESMTP id DBCE31FFC1; Wed, 1 Jul 2020 14:56:56 +0100 (BST) From: =?utf-8?q?Alex_Benn=C3=A9e?= To: qemu-devel@nongnu.org Subject: [PATCH v4 40/40] shippable: pull images from registry instead of building Date: Wed, 1 Jul 2020 14:56:52 +0100 Message-Id: <20200701135652.1366-41-alex.bennee@linaro.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20200701135652.1366-1-alex.bennee@linaro.org> References: <20200701135652.1366-1-alex.bennee@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::42e; envelope-from=alex.bennee@linaro.org; helo=mail-wr1-x42e.google.com X-detected-operating-system: by eggs.gnu.org: No matching host in p0f cache. That's all we know. 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=_AUTOLEARN X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: fam@euphon.net, berrange@redhat.com, =?utf-8?q?Alex_Benn=C3=A9e?= , richard.henderson@linaro.org, f4bug@amsat.org, =?utf-8?q?Philippe_Mat?= =?utf-8?q?hieu-Daud=C3=A9?= , cota@braap.org, aurelien@aurel32.net Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: "Qemu-devel" Now we have a source for registry images pull from there rather than re-building every time on shippable. [AJB: change to upstream when we merge PR] Signed-off-by: Alex Bennée --- .shippable.yml | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) -- 2.20.1 diff --git a/.shippable.yml b/.shippable.yml index 81905727d14..eb8b68610a2 100644 --- a/.shippable.yml +++ b/.shippable.yml @@ -26,12 +26,10 @@ env: - IMAGE=debian-ppc64el-cross TARGET_LIST=ppc64-softmmu,ppc64-linux-user,ppc64abi32-linux-user build: - pre_ci: - - make docker-image-${IMAGE} V=1 pre_ci_boot: - image_name: qemu/${IMAGE} + image_name: registry.gitlab.com/stsquad/qemu/qemu/${IMAGE} image_tag: latest - pull: false + pull: true options: "-e HOME=/root" ci: - unset CC