From nobody Sun May 5 01:46:01 2024 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass(p=none dis=none) header.from=linaro.org ARC-Seal: i=1; a=rsa-sha256; t=1660652981; cv=none; d=zohomail.com; s=zohoarc; b=DTgXjq7qQNhNMU3AuS9UG/CeFViKGzeO2dpjM9IPDIXjB59kocmwlBEL7Us2yszpH41Dq5FP7OHDX7w6MTh9Z3RK9rS6/vqh3L7G7l+JBrkdweYm0VpSpvfU+tHN1kmJihyPbfIY55+0hDlLxLPQYna1InCCqLzKjia/P/gA/jU= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1660652981; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To; bh=bwzqfA6o9KxVQ+yh1ggjjAyIYRr9k3xUnAlnxn391Io=; b=S4WXeiYuqFL1uCV77OEI08EMS+3CbO6ZTXagIxZ/AkeUQxcJEz7xG30Vz9H6eQMt9MvBMnswSnu5Xi+OYcI9GGyLe1C8U/8XE0GdT3C1h42TMypG1BGoyyrcjQgkg6k6jgTYG8VPRltNcNJnSVIoE5y3063s4bSra6eBlSDUxx4= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass header.from= (p=none dis=none) Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1660652981176775.3102790160011; Tue, 16 Aug 2022 05:29:41 -0700 (PDT) Received: from localhost ([::1]:53230 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1oNvhU-00086a-70 for importer@patchew.org; Tue, 16 Aug 2022 08:29:40 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:51820) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1oNveP-0004gh-9U for qemu-devel@nongnu.org; Tue, 16 Aug 2022 08:26:29 -0400 Received: from mail-wr1-x42b.google.com ([2a00:1450:4864:20::42b]:37703) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1oNveM-0001ja-UC for qemu-devel@nongnu.org; Tue, 16 Aug 2022 08:26:28 -0400 Received: by mail-wr1-x42b.google.com with SMTP id n7so1232389wrv.4 for ; Tue, 16 Aug 2022 05:26:26 -0700 (PDT) Received: from zen.linaroharston ([185.81.254.11]) by smtp.gmail.com with ESMTPSA id g7-20020a05600c4ec700b003a3170a7af9sm13186389wmq.4.2022.08.16.05.26.22 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 16 Aug 2022 05:26:22 -0700 (PDT) Received: from zen.lan (localhost [127.0.0.1]) by zen.linaroharston (Postfix) with ESMTP id DD7B31FFB8; Tue, 16 Aug 2022 13:26:21 +0100 (BST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc; bh=bwzqfA6o9KxVQ+yh1ggjjAyIYRr9k3xUnAlnxn391Io=; b=hVupO/BbnR/puOKWMrDR9gWDlqWO6mB2t0k8CKg6WP7+HdJLhi2hbELMWX4mUJ7q8E LiNnr3lCif/t6rN2cwewWOkT2AjDR0vFhIqWnXEt5TZxE2psqsYobOEGRZPVBKP/+OB1 XVmUCzF9PCJnRPCrr9DoHydLELmouwWnm/PeE1LHKyVzy7W1fgukuHuq5oBdgYNuh1jD OSuFyxekd/Wj2HavLX+PiKf67jYUAitK1sim+QwVFhFy+hlKIJTHiPpOsA/RsWPdflXv KH2mUlwxsTFVsxlKpuKir/HRShEcsN/qse/fZrtFI52vGCSaMvISQkuyu+yapZo5c5oH Kd8Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc; bh=bwzqfA6o9KxVQ+yh1ggjjAyIYRr9k3xUnAlnxn391Io=; b=PMR4isStjWHfzw4GEfwlXMmOm/+5IfmQ6gM01iwGLhaGClYJxp9B0QK92HB3Mz6JoZ ngGMNVmX1lpMIxHaK9b4DWgUh0BXSQ/L/EsOismKK60yOjYB9wID3Ob/qHoav1pCY56r w/Nt8ud7gXGcDvK9DdAwhI0N1asH4cGkZC7ll42mwpdNM62iioDhHViF74gTLTz1eKfU P9Blb/3pgTwKWh0Zhtd1Ca3v3NoynZv4Cxr4uT+coo/r0Xf8D8QteBsBmF1wh/XOKthN TV5Ooh37FqH+sUDFRhduQyP5eMo5F3yzxgWs8VkTRTczf/lVyFJVwoMTfknKInb6g06l y7Gw== X-Gm-Message-State: ACgBeo327BrkVuImsQL3LOVz1blMQkaKnmCR010v4m5LVsjLU5u6r1mh lxP2lcVoqJhldF5uCunyTcRtvw== X-Google-Smtp-Source: AA6agR7mOxPAmib3eQoY4/e9/CGYGKUVheW6GTO1WrbdfIq2mQ3b9EvP+WG0VrZky8rBTBhTn5Ad0w== X-Received: by 2002:a05:6000:170b:b0:220:6535:26d8 with SMTP id n11-20020a056000170b00b00220653526d8mr12127609wrc.577.1660652785563; Tue, 16 Aug 2022 05:26:25 -0700 (PDT) From: =?UTF-8?q?Alex=20Benn=C3=A9e?= To: peter.maydell@linaro.org, richard.henderson@linaro.org Cc: qemu-devel@nongnu.org, =?UTF-8?q?Alex=20Benn=C3=A9e?= , Laurent Vivier Subject: [PULL 1/3] linux-user: un-parent OBJECT(cpu) when closing thread Date: Tue, 16 Aug 2022 13:26:19 +0100 Message-Id: <20220816122621.2066292-2-alex.bennee@linaro.org> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20220816122621.2066292-1-alex.bennee@linaro.org> References: <20220816122621.2066292-1-alex.bennee@linaro.org> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=2a00:1450:4864:20::42b; envelope-from=alex.bennee@linaro.org; helo=mail-wr1-x42b.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" X-ZohoMail-DKIM: pass (identity @linaro.org) X-ZM-MESSAGEID: 1660652981725100001 While forcing the CPU to unrealize by hand does trigger the clean-up code we never fully free resources because refcount never reaches zero. This is because QOM automatically added objects without an explicit parent to /unattached/, incrementing the refcount. Instead of manually triggering unrealization just unparent the object and let the device machinery deal with that for us. Resolves: https://gitlab.com/qemu-project/qemu/-/issues/866 Signed-off-by: Alex Benn=C3=A9e Reviewed-by: Laurent Vivier Message-Id: <20220811151413.3350684-2-alex.bennee@linaro.org> diff --git a/linux-user/syscall.c b/linux-user/syscall.c index f409121202..bfdd60136b 100644 --- a/linux-user/syscall.c +++ b/linux-user/syscall.c @@ -8594,7 +8594,13 @@ static abi_long do_syscall1(CPUArchState *cpu_env, i= nt num, abi_long arg1, if (CPU_NEXT(first_cpu)) { TaskState *ts =3D cpu->opaque; =20 - object_property_set_bool(OBJECT(cpu), "realized", false, NULL); + if (ts->child_tidptr) { + put_user_u32(0, ts->child_tidptr); + do_sys_futex(g2h(cpu, ts->child_tidptr), + FUTEX_WAKE, INT_MAX, NULL, NULL, 0); + } + + object_unparent(OBJECT(cpu)); object_unref(OBJECT(cpu)); /* * At this point the CPU should be unrealized and removed @@ -8604,11 +8610,6 @@ static abi_long do_syscall1(CPUArchState *cpu_env, i= nt num, abi_long arg1, =20 pthread_mutex_unlock(&clone_lock); =20 - if (ts->child_tidptr) { - put_user_u32(0, ts->child_tidptr); - do_sys_futex(g2h(cpu, ts->child_tidptr), - FUTEX_WAKE, INT_MAX, NULL, NULL, 0); - } thread_cpu =3D NULL; g_free(ts); rcu_unregister_thread(); --=20 2.30.2 From nobody Sun May 5 01:46:01 2024 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass(p=none dis=none) header.from=linaro.org ARC-Seal: i=1; a=rsa-sha256; t=1660652941; cv=none; d=zohomail.com; s=zohoarc; b=LRXO2pfoLCNIc0upQDzcC06nm98GSReuprN1ItYa54cb12vSjSycuNFHanXUFnrsLYB77cRQX4agxb+SFKZPsR/Jxn/wt1Q6UxBUHitZfLn11zD5+cEixwte72TWcKnZjCb6JC85a4zRRTIPskOKQLXUmKv2BHQ0CSGUojqE9z0= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1660652941; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To; bh=lcoW7Lzpi1sLzNSIYAaJ/EO/qi9Z5QpCbFBSmRllJwE=; b=f7y1NNLfo5pnNsePLP6xD29qK3ZQmQitGQ7ssWqSLt5xWHxbvr+mxDhRlt/svgVaDZTNPu6YveY2FB85f3WehVeHaCzIPLrrBpb1G68uGXva8h7n/PhCjdeKwR++hHmYUL1s1qn2Cl7izwqxNcA3fEqTnbgx2m42ey8Zx3JtCLo= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass header.from= (p=none dis=none) Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1660652941573502.3645899840235; Tue, 16 Aug 2022 05:29:01 -0700 (PDT) Received: from localhost ([::1]:47218 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1oNvgo-0006o4-0K for importer@patchew.org; Tue, 16 Aug 2022 08:28:58 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:51786) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1oNveN-0004dL-TT for qemu-devel@nongnu.org; Tue, 16 Aug 2022 08:26:27 -0400 Received: from mail-wm1-x32c.google.com ([2a00:1450:4864:20::32c]:50764) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1oNveM-0001jO-0v for qemu-devel@nongnu.org; Tue, 16 Aug 2022 08:26:27 -0400 Received: by mail-wm1-x32c.google.com with SMTP id j26so2921314wms.0 for ; Tue, 16 Aug 2022 05:26:25 -0700 (PDT) Received: from zen.linaroharston ([185.81.254.11]) by smtp.gmail.com with ESMTPSA id m8-20020a05600c4f4800b003a603f96db7sm3640742wmq.36.2022.08.16.05.26.22 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 16 Aug 2022 05:26:22 -0700 (PDT) Received: from zen.lan (localhost [127.0.0.1]) by zen.linaroharston (Postfix) with ESMTP id 00E531FFBA; Tue, 16 Aug 2022 13:26:22 +0100 (BST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc; bh=lcoW7Lzpi1sLzNSIYAaJ/EO/qi9Z5QpCbFBSmRllJwE=; b=YzxllfUqpgE6pDtlwGbkji85vJjbK3adYD81KbyQq8vDyHjj2ZCvR7VE/59qHOUpVz FYlzBLGZfs9/Dpox1a89gjjOsoGHXcp96yogZRuM4Wx4BpapRWV10rLum6T9OoWrBBgA 5U4xazV++38jrNuixxQhwRRyLm/hz+JXCmvkjzIkGRI4ANosOVysn0xEERuvPPmuGkhp dd6GvnDZEWFHibC7ubps3k2ewAHWm5ZluZSNdwZjXVPKQaNuEDaUDfDM+olRuKAluwBn h0FKW7Y5vbkwDpxcNS39/cg/jrA/1BomQogxyMiPcpLEGPWHQcEgYkQSVL6gqMp0wcmy 37GQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc; bh=lcoW7Lzpi1sLzNSIYAaJ/EO/qi9Z5QpCbFBSmRllJwE=; b=sJ9mfpyYJ5hqzM/zz+sYiZxPrXZsZa74d6KRJX4xbUW5FF4tMLqdKC1bVzBxjMV2Lc 2fuBIe+EgAtRakqJOl1fP1wcuPoK+le0iNmf638KGEiPTaOkaZFBbO2snn9Tg9xzTi4h aVHKAji+HNEtOxcONxr0sXSV38G3glpbHy4HMz+Nu+tr9sM7+7lk9Q3Wq5j5ZGZDy49h R+9zza3dgDOpdAJCom0U6xE68PlArrJO90zpqlI6zFf1oxHeeCmw8ClWEeUjvJVD7bYk 15tC2YDtDg0F7kgK6feUGo+BNU/g4ew0NFQG7GZyu3+u5bm1zXQsR63/e3UXk7PUjq3Y zKdg== X-Gm-Message-State: ACgBeo3BrFz0JfEdeOsa4QCu7YtoZxf2HEQPCi821pnugnBeFdYHk/58 +MmZdP4cnry6Yhs6TOsDAVb6Vg== X-Google-Smtp-Source: AA6agR6WeeYp3s8dZTumzCkb7IfjhhK/G7NvEP8BkbAbr5fOoFwaeO3sWBHYFHmyjYXE1jXO9yTA3A== X-Received: by 2002:a05:600c:1551:b0:3a5:e40b:1477 with SMTP id f17-20020a05600c155100b003a5e40b1477mr8332317wmg.16.1660652784523; Tue, 16 Aug 2022 05:26:24 -0700 (PDT) From: =?UTF-8?q?Alex=20Benn=C3=A9e?= To: peter.maydell@linaro.org, richard.henderson@linaro.org Cc: qemu-devel@nongnu.org, =?UTF-8?q?Alex=20Benn=C3=A9e?= , =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= , Cleber Rosa , Wainer dos Santos Moschetta , Beraldo Leal Subject: [PULL 2/3] tests/avocado: add timeout to the aspeed tests Date: Tue, 16 Aug 2022 13:26:20 +0100 Message-Id: <20220816122621.2066292-3-alex.bennee@linaro.org> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20220816122621.2066292-1-alex.bennee@linaro.org> References: <20220816122621.2066292-1-alex.bennee@linaro.org> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=2a00:1450:4864:20::32c; envelope-from=alex.bennee@linaro.org; helo=mail-wm1-x32c.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" X-ZohoMail-DKIM: pass (identity @linaro.org) X-ZM-MESSAGEID: 1660652944250100001 On some systems the test can hang. At least defining a timeout stops it from hanging forever. Signed-off-by: Alex Benn=C3=A9e Reviewed-by: Philippe Mathieu-Daud=C3=A9 Message-Id: <20220811151413.3350684-7-alex.bennee@linaro.org> diff --git a/tests/avocado/machine_aspeed.py b/tests/avocado/machine_aspeed= .py index b4e35a3d07..c54da0fd8f 100644 --- a/tests/avocado/machine_aspeed.py +++ b/tests/avocado/machine_aspeed.py @@ -40,6 +40,8 @@ def test_ast1030_zephyros(self): =20 class AST2x00Machine(QemuSystemTest): =20 + timeout =3D 90 + def wait_for_console_pattern(self, success_message, vm=3DNone): wait_for_console_pattern(self, success_message, failure_message=3D'Kernel panic - not syn= cing', --=20 2.30.2 From nobody Sun May 5 01:46:01 2024 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass(p=none dis=none) header.from=linaro.org ARC-Seal: i=1; a=rsa-sha256; t=1660653302; cv=none; d=zohomail.com; s=zohoarc; b=CpfviWcNBC9ki/ZvgOggCL+dzfw5gkCsxDf8QkOwqMGar2CMAjy9kTlb6SdLIP30FHAgcS096ZPLhOE7ZZK4PHB200XglFZlcM8Bjo48FTJCEaG32D729of85l9RenJfiFiPf3q7hNd0RKo6bFW3TagP2PsxOWy6W2Pwn2ee838= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1660653302; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To; bh=Qx6wBS0awIg5wJT+Q1AQmTWd+527vRCxS4thMsgW8xg=; b=KSLkdR99hEUiXd7bVG7y9wYFDAqvWfsFpVjLqQ+9yZbCHw3A9YbQvewWrRXDSE3qD6zsZzcQhulMonl+meAmjFKdDWRHVmXgqNl2wfH+dmBGtNJvpfts8IDTdb2h+qQQwrp+CJ54VlxFPdImAQIIPeKXUCc+HKYBWzHwNO8HwOo= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass header.from= (p=none dis=none) Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1660653302262686.7809139154408; Tue, 16 Aug 2022 05:35:02 -0700 (PDT) Received: from localhost ([::1]:32962 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1oNvmd-0002Hf-Mx for importer@patchew.org; Tue, 16 Aug 2022 08:34:59 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:51854) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1oNveQ-0004jj-HD for qemu-devel@nongnu.org; Tue, 16 Aug 2022 08:26:30 -0400 Received: from mail-wr1-x42c.google.com ([2a00:1450:4864:20::42c]:33348) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1oNveO-0001js-6q for qemu-devel@nongnu.org; Tue, 16 Aug 2022 08:26:30 -0400 Received: by mail-wr1-x42c.google.com with SMTP id v3so12474233wrp.0 for ; Tue, 16 Aug 2022 05:26:27 -0700 (PDT) Received: from zen.linaroharston ([185.81.254.11]) by smtp.gmail.com with ESMTPSA id h3-20020a05600c2ca300b003a5ea1cc63csm9238720wmc.39.2022.08.16.05.26.22 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 16 Aug 2022 05:26:23 -0700 (PDT) Received: from zen.lan (localhost [127.0.0.1]) by zen.linaroharston (Postfix) with ESMTP id 182771FFBB; Tue, 16 Aug 2022 13:26:22 +0100 (BST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc; bh=Qx6wBS0awIg5wJT+Q1AQmTWd+527vRCxS4thMsgW8xg=; b=pti8qqDLiXclsQN0cICI/ZjmG95UnefekqiwFqmNALMjvvdcRY1P+04BKSO/VFRhqx ZgM3h9RoiLikS9l2RljNWHV7kZHSSd1R/YSoiU7SSYdUGR8tridjr17jFaQDjUF0tBgf Mqjx+ACPzmPphN0uxI1Y/XIJQsTirCBRWkr0htRP67AEvfH8yxJZyGThx7SqW6JMxFzE xVSnqiPTG5QbkqWzVSaCUFmJRZ1DYCyRmjiOfxN4TNIgYmG/JJjenWCZtWEGdVE9BPo3 HfBxc3OwUK+Q6JBJjevs21SRVrAcH+5ggF+w9n4+tKsglcAurMzKpvX4OxLadzaj7UrC 178w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc; bh=Qx6wBS0awIg5wJT+Q1AQmTWd+527vRCxS4thMsgW8xg=; b=t6dFufj6kVcMPWwvKC2H0BjFoD/rDX5LCTbYKaFprWCaFb3o3h5zEaYNmy39kOevSx fFJEzxiWW4ZS6SQVguIKi2PmW4gjpbW+BSVwf4XdJO/muYaSQMmx2sIMYD8JFtPYW8VY b0YxlgR3Mv1acrjByf/IoF70Z1SSLlNd1Iq6FG0MkAz72HYO2Brxk1mzCwLbSIHqtciC ZuPX/SCZ8vGOSBRpddW8CXZ9+kIvced8b90rV8eU+f/TsLsH0s0S60je2fTsrEYxq9uq rEL8mqxIRFgqOJuZk3xGnMXRp77hra05EaMaeqItXQH1HmWdUKF1lBZ558lEJVpQXTJE bVOg== X-Gm-Message-State: ACgBeo0zTWajdeB31+dwW7clpl5ErKzmRh7s5zGce/iENo2cW6uTfZYM MdTgE+kq6rKoWVAVdv1QOPCfkA== X-Google-Smtp-Source: AA6agR7hbJukTquDxJP/c+s5y430UEbOj4ZmjOhCLW4G3NldGObpb8i7g9JDYcjS1auSY7WZ2idcYg== X-Received: by 2002:a5d:6f17:0:b0:225:325:59cd with SMTP id ay23-20020a5d6f17000000b00225032559cdmr5813768wrb.83.1660652786746; Tue, 16 Aug 2022 05:26:26 -0700 (PDT) From: =?UTF-8?q?Alex=20Benn=C3=A9e?= To: peter.maydell@linaro.org, richard.henderson@linaro.org Cc: qemu-devel@nongnu.org, =?UTF-8?q?Alex=20Benn=C3=A9e?= , =?UTF-8?q?C=C3=A9dric=20Le=20Goater?= , John Snow , Cleber Rosa , =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= , Wainer dos Santos Moschetta , Beraldo Leal Subject: [PULL 3/3] tests/avocado: apply a band aid to aspeed-evb login Date: Tue, 16 Aug 2022 13:26:21 +0100 Message-Id: <20220816122621.2066292-4-alex.bennee@linaro.org> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20220816122621.2066292-1-alex.bennee@linaro.org> References: <20220816122621.2066292-1-alex.bennee@linaro.org> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=2a00:1450:4864:20::42c; envelope-from=alex.bennee@linaro.org; helo=mail-wr1-x42c.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" X-ZohoMail-DKIM: pass (identity @linaro.org) X-ZM-MESSAGEID: 1660653303184100001 This is really a limitation of the underlying console code which doesn't allow us to detect the login: and following "#" prompts because it reads input line wise. By adding a small delay we ensure that the login prompt has appeared so we don't accidentally spaff the shell commands to a confused getty in the guest. Signed-off-by: Alex Benn=C3=A9e Reviewed-by: C=C3=A9dric Le Goater Acked-by: John Snow Message-Id: <20220811151413.3350684-8-alex.bennee@linaro.org> diff --git a/tests/avocado/machine_aspeed.py b/tests/avocado/machine_aspeed= .py index c54da0fd8f..65d38f4efa 100644 --- a/tests/avocado/machine_aspeed.py +++ b/tests/avocado/machine_aspeed.py @@ -101,7 +101,9 @@ def do_test_arm_aspeed_buidroot_start(self, image, cpu_= id): self.wait_for_console_pattern('Starting kernel ...') self.wait_for_console_pattern('Booting Linux on physical CPU ' + c= pu_id) self.wait_for_console_pattern('lease of 10.0.2.15') + # the line before login: self.wait_for_console_pattern('Aspeed EVB') + time.sleep(0.1) exec_command(self, 'root') time.sleep(0.1) =20 --=20 2.30.2