From patchwork Tue Sep 10 22:15:39 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Pierrick Bouvier X-Patchwork-Id: 827047 Delivered-To: patch@linaro.org Received: by 2002:adf:ab1c:0:b0:367:895a:4699 with SMTP id q28csp528793wrc; Tue, 10 Sep 2024 15:17:30 -0700 (PDT) X-Forwarded-Encrypted: i=2; AJvYcCV89CdgPkU9h3UTkZg86lFg0QWl3uWIrTHG7oyXd5PkzH6fDNtEmz+EmLmapD3GtGTEzhyX4g==@linaro.org X-Google-Smtp-Source: AGHT+IFl3LxdQFyCrI/gsZqSOIlgru8v2y5lTiqWTtPFveaoOMBo5fgRKQZT4hOqr633JBSPJPDk X-Received: by 2002:a05:622a:4e8a:b0:458:1957:b925 with SMTP id d75a77b69052e-4581957c29cmr200783911cf.8.1726006650730; Tue, 10 Sep 2024 15:17:30 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1726006650; cv=none; d=google.com; s=arc-20240605; b=IuJC+dXskbK2YKqjpIclG9cA1fZqnyCZIoNozQI3TmiisURUMImR/kTzUvhL89pY+O DPa1OuZcX31YT2wh7UaRdEQl7jo/rr2/xo9UjzMKY85zJJdcDw15wID0G+bVBhok3L4n E9jMcxJ8f9ZSjJKpJfI1IwYGt/YMS66gkNZA/zPqiEYSjb9NP8QIoxwPvglYGVchC3w9 g3rbwYRbFq2UBwPtQs1CaKTWMPNhmYHqj6Iqp/zdrpdw5TY6ttzK9Fj4NxaH30kDWdHb FvYOrs8N6dhsDYDmdtOholbuj2Q8pm/DJqMxdvwnw+Nzjs78DFuFI0v5sTHLqNegU8dD QsJg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20240605; h=sender:errors-to: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:cc:to :from:dkim-signature; bh=5e7jM2SGiugZIDj7hvcHvckpF7J0ao6gx5zsDNU5OmE=; fh=ynTlK/oH/ur5RqvPhczOwhj4YatH1hTHyPq9uMdf314=; b=Yb+XkmivBRKORmZhZShvGztqLotXnyhUkwFr/exlsjBQ3VWzYp62bVbQN6u0FypzgI W7Gvb0d3sPDkALq1kVxgs8BDViiyUxG7UzkATsvN20ZZTIuDFbTiNroWeqFZXeZ4Fa8F DVCI8/vlsxkb2fOdTp1UTS6l6OTsq2kaEWUZdIhyVg4SSnuZ3ILukQg57X67iwRkvGl+ Ab+Tp8DCbnU7gAD6Y+6ArPrDzzpt8YNbNu4Se3NPqTB+z10q2iKMydMUNS3uR140TYiV 38aWYotb704Pkn90xivx5igaY3RzA1wTzFZNiP8DoUErCZ3qRhcm32P7akc30+NuUTbu awTg==; dara=google.com ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=wduGhNEU; 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=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org; dara=neutral header.i=@linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id d75a77b69052e-4583129c06asi59021441cf.98.2024.09.10.15.17.30 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Tue, 10 Sep 2024 15:17: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=pass header.i=@linaro.org header.s=google header.b=wduGhNEU; 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=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org; dara=neutral header.i=@linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1so9Ak-0002of-13; Tue, 10 Sep 2024 18:17:18 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1so9AB-0008Cl-Qc for qemu-devel@nongnu.org; Tue, 10 Sep 2024 18:16:45 -0400 Received: from mail-pf1-x42b.google.com ([2607:f8b0:4864:20::42b]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1so9A8-0006eB-Aw for qemu-devel@nongnu.org; Tue, 10 Sep 2024 18:16:43 -0400 Received: by mail-pf1-x42b.google.com with SMTP id d2e1a72fcca58-717914d6c95so3988211b3a.0 for ; Tue, 10 Sep 2024 15:16:39 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1726006599; x=1726611399; darn=nongnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=5e7jM2SGiugZIDj7hvcHvckpF7J0ao6gx5zsDNU5OmE=; b=wduGhNEUW654bI5J5WjytgxOJ/DUmkzd1a4bCa6xp5jIMaPPS8DwZ+5ytCc1YCeifk SMZjcVeENF3XDQZRjYoZpkeRZ2w3cZKwzn7ugVLPq3l5u2eC07t9hYVnIJ1ikHhzGQPF lZVUVydpCFasXRtu4BCzVDLZeAgwXAHoEFsNzgsbSbPxfX1qLwwOnrYEuTWJwoe5u6Zc lvH70jsqI9CECxc7udypkPjn/gxZbIGs6iYwATxXds8WG+GTfYL8tq3CAULQzs2tkExB olF3LCQWTNQkzWIxTbPOBp5DZyvgu99bTjcqbWHCo11De2GcKRy3Nf+zcnv44AKvBc1K cJeA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1726006599; x=1726611399; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=5e7jM2SGiugZIDj7hvcHvckpF7J0ao6gx5zsDNU5OmE=; b=VkOG6hH+9q+5h/kj+aFNWvxkj+J57jpKgUmK/uVzN9jckivHlx5qW1PRtBiG5lo4JT R6/cVthPhEWMszw6JwckX2fPO5hglooZvcP8YKMRxMYkJ968sxWNAlRfEh/y9ER+D/xn v6qZEthK9dRQYEwA9Gbz8Wuo8Vv1jKLjkO/h2sc2Z+MQZtX6RM2yhc10t2tv9I7iwrIu EqRQ6u2l9ChSbMHKYCJPG39qXbEcXAI94jVZT5/Hznu2BZIs/6o0pMa6P32lbsTfU0YE rSqjTWhHFWcrXCMlgAdBWw/WQz0AauN0/FqZ38oxKWl4eVb3Q6nWj4krKVuJ//m9Uhv4 i6GA== X-Gm-Message-State: AOJu0YxRoNQVwAyuHI3EmJM83M6zaFdxnZ+oiRI6ScvbiC0BTEgpDTOL UYEvdvmurIsuM3cIEzwI+6s9qfxoWXpeHTjx4GVR24hTcoB5Pkf5s6clKhFDQd6g4ARKNJ+CkMG ADiFuSeTe X-Received: by 2002:a05:6a20:289e:b0:1cf:4348:d5c8 with SMTP id adf61e73a8af0-1cf5e157922mr2270616637.39.1726006598631; Tue, 10 Sep 2024 15:16:38 -0700 (PDT) Received: from linaro.vn.shawcable.net ([2604:3d08:9384:1d00::9633]) by smtp.gmail.com with ESMTPSA id d2e1a72fcca58-71909003d0esm1884055b3a.93.2024.09.10.15.16.36 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 10 Sep 2024 15:16:38 -0700 (PDT) From: Pierrick Bouvier To: qemu-devel@nongnu.org Cc: Zhao Liu , "Richard W.M. Jones" , Joel Stanley , Kevin Wolf , Paolo Bonzini , qemu-arm@nongnu.org, Corey Minyard , Eric Farman , Thomas Huth , Keith Busch , WANG Xuerui , Hyman Huang , Stefan Berger , Michael Rolnik , Alistair Francis , =?utf-8?q?Marc-Andr=C3=A9_Lure?= =?utf-8?q?au?= , Markus Armbruster , Sriram Yagnaraman , Palmer Dabbelt , qemu-riscv@nongnu.org, Ani Sinha , Halil Pasic , Jesper Devantier , Laurent Vivier , Peter Maydell , Igor Mammedov , kvm@vger.kernel.org, =?utf-8?q?Alex_Be?= =?utf-8?q?nn=C3=A9e?= , Richard Henderson , Fam Zheng , qemu-s390x@nongnu.org, Hanna Reitz , Nicholas Piggin , Eduardo Habkost , Laurent Vivier , Rob Herring , Marcel Apfelbaum , qemu-block@nongnu.org, "Maciej S. Szmigiero" , qemu-ppc@nongnu.org, Daniel Henrique Barboza , Christian Borntraeger , Harsh Prateek Bora , =?utf-8?q?Philippe_Mathieu-Daud?= =?utf-8?q?=C3=A9?= , Nina Schoetterl-Glausch , "Michael S. Tsirkin" , Fabiano Rosas , Helge Deller , Dmitry Fleytman , Daniel Henrique Barboza , Akihiko Odaki , Marcelo Tosatti , David Gibson , Aurelien Jarno , Liu Zhiwei , Yanan Wang , Peter Xu , Bin Meng , Weiwei Li , Klaus Jensen , Jean-Christophe Dubois , Jason Wang , Pierrick Bouvier Subject: [PATCH 12/39] tests/qtest: replace assert(0) with g_assert_not_reached() Date: Tue, 10 Sep 2024 15:15:39 -0700 Message-Id: <20240910221606.1817478-13-pierrick.bouvier@linaro.org> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20240910221606.1817478-1-pierrick.bouvier@linaro.org> References: <20240910221606.1817478-1-pierrick.bouvier@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::42b; envelope-from=pierrick.bouvier@linaro.org; helo=mail-pf1-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 autolearn=unavailable autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org Signed-off-by: Pierrick Bouvier Reviewed-by: Richard Henderson Reviewed-by: Thomas Huth --- tests/qtest/ipmi-bt-test.c | 2 +- tests/qtest/ipmi-kcs-test.c | 4 ++-- tests/qtest/rtl8139-test.c | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/tests/qtest/ipmi-bt-test.c b/tests/qtest/ipmi-bt-test.c index 383239bcd48..13f7c841f59 100644 --- a/tests/qtest/ipmi-bt-test.c +++ b/tests/qtest/ipmi-bt-test.c @@ -251,7 +251,7 @@ static void emu_msg_handler(void) msg[msg_len++] = 0xa0; write_emu_msg(msg, msg_len); } else { - g_assert(0); + g_assert_not_reached(); } } diff --git a/tests/qtest/ipmi-kcs-test.c b/tests/qtest/ipmi-kcs-test.c index afc24dd3e46..3186c6ad64b 100644 --- a/tests/qtest/ipmi-kcs-test.c +++ b/tests/qtest/ipmi-kcs-test.c @@ -145,7 +145,7 @@ static void kcs_cmd(uint8_t *cmd, unsigned int cmd_len, break; default: - g_assert(0); + g_assert_not_reached(); } *rsp_len = j; } @@ -184,7 +184,7 @@ static void kcs_abort(uint8_t *cmd, unsigned int cmd_len, break; default: - g_assert(0); + g_assert_not_reached(); } /* Start the abort here */ diff --git a/tests/qtest/rtl8139-test.c b/tests/qtest/rtl8139-test.c index eedf90f65af..55f671f2f59 100644 --- a/tests/qtest/rtl8139-test.c +++ b/tests/qtest/rtl8139-test.c @@ -65,7 +65,7 @@ PORT(IntrMask, w, 0x3c) PORT(IntrStatus, w, 0x3E) PORT(TimerInt, l, 0x54) -#define fatal(...) do { g_test_message(__VA_ARGS__); g_assert(0); } while (0) +#define fatal(...) do { g_test_message(__VA_ARGS__); g_assert_not_reached(); } while (0) static void test_timer(void) {