Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id EAFA2C19F2A for ; Thu, 11 Aug 2022 11:59:28 +0000 (UTC) Received: from localhost ([::1]:35902 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1oM6qV-0004Qa-Te for qemu-devel@archiver.kernel.org; Thu, 11 Aug 2022 07:59:27 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:55308) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1oM6mf-0000Rb-3D for qemu-devel@nongnu.org; Thu, 11 Aug 2022 07:55:29 -0400 Received: from smtpout2.mo529.mail-out.ovh.net ([79.137.123.220]:47741) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1oM6md-0005WM-7m for qemu-devel@nongnu.org; Thu, 11 Aug 2022 07:55:28 -0400 Received: from mxplan5.mail.ovh.net (unknown [10.109.138.129]) by mo529.mail-out.ovh.net (Postfix) with ESMTPS id EB0EB11DE86F0; Thu, 11 Aug 2022 13:55:22 +0200 (CEST) Received: from kaod.org (37.59.142.103) by DAG4EX2.mxp5.local (172.16.2.32) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.9; Thu, 11 Aug 2022 13:55:22 +0200 Authentication-Results: garm.ovh; auth=pass (GARM-103G00512e61c34-2d58-4592-9b14-8d1d82405f74, B18B381393FCCA734C2622819310E7EBE9D8D149) smtp.auth=clg@kaod.org X-OVh-ClientIp: 90.89.155.17 Message-ID: Date: Thu, 11 Aug 2022 13:55:21 +0200 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:91.0) Gecko/20100101 Thunderbird/91.12.0 Subject: Re: [RFC PATCH] tests/avocado: apply a band aid to aspeed-evb login Content-Language: en-US To: =?UTF-8?Q?Alex_Benn=c3=a9e?= , CC: John Snow , Cleber Rosa , =?UTF-8?Q?Philippe_Mathieu-Daud=c3=a9?= , Wainer dos Santos Moschetta , Beraldo Leal References: <20220811114315.3065951-1-alex.bennee@linaro.org> From: =?UTF-8?Q?C=c3=a9dric_Le_Goater?= In-Reply-To: <20220811114315.3065951-1-alex.bennee@linaro.org> Content-Type: text/plain; charset="UTF-8"; format=flowed Content-Transfer-Encoding: 8bit X-Originating-IP: [37.59.142.103] X-ClientProxiedBy: DAG2EX2.mxp5.local (172.16.2.12) To DAG4EX2.mxp5.local (172.16.2.32) X-Ovh-Tracer-GUID: f517cc22-2bb5-45a7-87e0-1c6ae965044d X-Ovh-Tracer-Id: 17161529332691536745 X-VR-SPAMSTATE: OK X-VR-SPAMSCORE: -100 X-VR-SPAMCAUSE: gggruggvucftvghtrhhoucdtuddrgedvfedrvdeggedggeejucetufdoteggodetrfdotffvucfrrhhofhhilhgvmecuqfggjfdpvefjgfevmfevgfenuceurghilhhouhhtmecuhedttdenucesvcftvggtihhpihgvnhhtshculddquddttddmnecujfgurhepkfffgggfuffvvehfhfgjtgfgihesthekredttdefjeenucfhrhhomhepveorughrihgtpgfnvggpifhorghtvghruceotghlgheskhgrohgurdhorhhgqeenucggtffrrghtthgvrhhnpeekteejtdelkeejvdevffduhfetteelieefgeefffeugffhfeekheffueefledujeenucfkpheptddrtddrtddrtddpfeejrdehledrudegvddruddtfeenucevlhhushhtvghrufhiiigvpedtnecurfgrrhgrmhepmhhouggvpehsmhhtphhouhhtpdhhvghlohepmhigphhlrghnhedrmhgrihhlrdhovhhhrdhnvghtpdhinhgvtheptddrtddrtddrtddpmhgrihhlfhhrohhmpegtlhhgsehkrghougdrohhrghdpnhgspghrtghpthhtohepuddprhgtphhtthhopegslhgvrghlsehrvgguhhgrthdrtghomhdpoffvtefjohhsthepmhhohedvle Received-SPF: pass client-ip=79.137.123.220; envelope-from=clg@kaod.org; helo=smtpout2.mo529.mail-out.ovh.net X-Spam_score_int: -18 X-Spam_score: -1.9 X-Spam_bar: - X-Spam_report: (-1.9 / 5.0 requ) BAYES_00=-1.9, NICE_REPLY_A=-0.001, 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+qemu-devel=archiver.kernel.org@nongnu.org Sender: "Qemu-devel" On 8/11/22 13:43, Alex Bennée wrote: > 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ée > Cc: Cédric Le Goater > Cc: John Snow May be you should also add the missing timeout setting ? Anyhow, Reviewed-by: Cédric Le Goater Thanks, C. > --- > tests/avocado/machine_aspeed.py | 2 ++ > 1 file changed, 2 insertions(+) > > 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 ' + cpu_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) >