From patchwork Thu Sep 19 04:46:34 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Pierrick Bouvier X-Patchwork-Id: 829573 Delivered-To: patch@linaro.org Received: by 2002:adf:ebcc:0:b0:367:895a:4699 with SMTP id v12csp154618wrn; Wed, 18 Sep 2024 21:51:23 -0700 (PDT) X-Forwarded-Encrypted: i=2; AJvYcCUszLYIPtDHs6nhZ37ZhHTOts9JPaiJ2sjPFCEoNcCVTgwiT9ap2f7juaT+0aJzfvnAXB/IBQ==@linaro.org X-Google-Smtp-Source: AGHT+IEW1K4dz692/iLC8rffIRD4xgOnwdT9XFMhXG8QPr5vE8jp8Q8kPvyI0x2t98iAtiv6FSVj X-Received: by 2002:a05:620a:4086:b0:7a9:c160:c80b with SMTP id af79cd13be357-7a9e5ee70f9mr4403202285a.8.1726721483580; Wed, 18 Sep 2024 21:51:23 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1726721483; cv=none; d=google.com; s=arc-20240605; b=LaLMM5KDR0E3L48ZpQ9xodMfbEtxRDxwKWN/bewTmnA3U9hzrMndF4P0q7kQu5BX57 GE33N5yWfsb1F5n+xA4jzep4GDdLAk/1dhhUuvtGjkXOnCVYrlFkrGq5gsoVSUWvQVEF sg9jaamt4ypPJY/rzfvV4fnq0EmjSdbf6MthPalVxkKa5J9RXFg5aK7RmQ5oE9uQC9ea 0tm6X9QDPgaG489547RQg9hhOTHFsY6c5l8HBQTZKtP2j5JpV9gMHExX6XHjBEURhZ8d ATIGyoDcxpYSxN1HuGKmPwyksze+SpsFKN5d2LjLTQrZKqHG34Kj3bEiHyYGYsj6rnx6 PiVA== 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=aVLlQ1azCZTPpBP5TtwQ0P5RnlTFYhwK6Tm+S/9eUGE=; fh=5sUwfmYRlCXWUAcYTQtsUKL3/h5U38RKAKIQYZIY6/E=; b=YgFAFOQVm6GRtx4e499NgTZLG+Y1bfo7+UE6ZA3Do/0iLWTd1LbQ7zTi7a+yLZwfMz VxBaF0Z9kA9FwRLCUlcy9p+AeQAehen7yQO8A+/KcaYVvkU3gxqXbdLvjZtiRwGdE9HV wUYKn2xDuG/+KqRaZxApxoG5PRKyPJcBjz2MnU+sev2yjmgZX5grFscvt2UInkQ3pd5L lgMwldovBh8+9Eqw434amh+3HHU5zC8gNSRm59kawgz3tVV479+ujBmOkKIdd8DTnCWH rS2L+y4AAEAhq3g4/3Oc6XjsqeF8mFbmFHJ4PkJpAnAa+5SqV3m9i5wwP3PvjkgQLplN +IEA==; dara=google.com ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=sZmZYMIE; 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 af79cd13be357-7acb08e273fsi101964385a.394.2024.09.18.21.51.23 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Wed, 18 Sep 2024 21:51: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=pass header.i=@linaro.org header.s=google header.b=sZmZYMIE; 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 1sr958-0003JY-3i; Thu, 19 Sep 2024 00:47:54 -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 1sr951-0002kf-Dp for qemu-devel@nongnu.org; Thu, 19 Sep 2024 00:47:47 -0400 Received: from mail-pf1-x42e.google.com ([2607:f8b0:4864:20::42e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1sr94v-0007UT-A1 for qemu-devel@nongnu.org; Thu, 19 Sep 2024 00:47:47 -0400 Received: by mail-pf1-x42e.google.com with SMTP id d2e1a72fcca58-7191df6b5f5so286980b3a.0 for ; Wed, 18 Sep 2024 21:47:40 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1726721260; x=1727326060; 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=aVLlQ1azCZTPpBP5TtwQ0P5RnlTFYhwK6Tm+S/9eUGE=; b=sZmZYMIEwzYkertdAhYCDFEI09bhwEWFdDjoyMnuwtc5Az44Yg7DIb4zk3jCTmPQ4G 93aTV14n+0dsWonbG5Ai/ygmW6Nt5cLjyoxH2Dw9LQnnZVtN32clgWHxlY9htoFGThki eOOmfAKE5xswVgHGztQTAf8DiyDZsjTqXiCHUBpKC4UZSaQ46S8QZxtMDx3T6uS+704K ZKCZ6nPhqyqrEmNgAq3lrQAYjRzMYFcI9Ko35NUsmqcu5opXXDDyCjuPXehahmxMk/QH yeW608UmoTuOGnauIFsSxy7z7/O1+vRd3QVSzgyioKFX/C8kxQFUO7ivN/OX+HwUj2DN 8k4w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1726721260; x=1727326060; 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=aVLlQ1azCZTPpBP5TtwQ0P5RnlTFYhwK6Tm+S/9eUGE=; b=qh9uTjphlKrmTsrQxgaVjsEhkZ+ozDkgBxJKz/onksmseEc1vUtD20WhHDm3bvaOhC n5Me5v/H93a+NaHIEkqRf0vTWAZRh+BOZnQ+yA001/KFrwK5ufFkSCGPpvYTmP9wz+o2 0FGmX/39U9Ca0yFJ9W/zoWw5FF5jg4VXfrY8poYQRfmGH6WLB6aGzNUnlIk+tAGQoNjq oCxdDL7JrHm32MJ4UiP20al+nrby3IkEClthrBM7FX4BlFqlS4Pk3W1e4PLOkDLCM2cM U2wdtuJVAUnOMYmhzJNn5ER3bJArSFRCu8JU+HclyRhVsx22FFoqdZ93QLQkvm2J11s0 0HnQ== X-Gm-Message-State: AOJu0YxyCMnvt0ZbtHFiMkU3r48kNytX4TzNAw9rYBdi90v3FSquSdMZ vFoLX38a8QHIWXKXA+o7rxFaqHPEwIAlMIHz0IsofBBrTO+j0DK1sjY7mgrgpZHJvkHRG0U6Fyv i0xYzFQ== X-Received: by 2002:a05:6a20:cd0e:b0:1cf:476f:2d10 with SMTP id adf61e73a8af0-1cf76239c98mr35848879637.49.1726721259880; Wed, 18 Sep 2024 21:47:39 -0700 (PDT) Received: from linaro.. (216-180-64-156.dyn.novuscom.net. [216.180.64.156]) by smtp.gmail.com with ESMTPSA id d2e1a72fcca58-71944bc279csm7478601b3a.188.2024.09.18.21.47.37 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 18 Sep 2024 21:47:39 -0700 (PDT) From: Pierrick Bouvier To: qemu-devel@nongnu.org Cc: Palmer Dabbelt , Alistair Francis , Hyman Huang , Halil Pasic , kvm@vger.kernel.org, Bin Meng , Peter Xu , Liu Zhiwei , David Gibson , Daniel Henrique Barboza , qemu-s390x@nongnu.org, Dmitry Fleytman , Hanna Reitz , Klaus Jensen , Corey Minyard , Laurent Vivier , WANG Xuerui , Thomas Huth , Rob Herring , Eduardo Habkost , Nicholas Piggin , "Michael S. Tsirkin" , Harsh Prateek Bora , "Maciej S. Szmigiero" , Ani Sinha , Stefan Berger , Fam Zheng , Laurent Vivier , Paolo Bonzini , =?utf-8?q?Daniel_P=2E_Berrang=C3=A9?= , Richard Henderson , =?utf-8?q?Philippe_Mathie?= =?utf-8?q?u-Daud=C3=A9?= , Keith Busch , Jean-Christophe Dubois , qemu-riscv@nongnu.org, Igor Mammedov , Akihiko Odaki , Sriram Yagnaraman , Jason Wang , Eric Farman , "Richard W.M. Jones" , =?utf-8?q?Marc-Andr=C3=A9_Lureau?= , Nina Schoetterl-Glausch , Aurelien Jarno , Markus Armbruster , =?utf-8?q?Alex_Benn=C3=A9e?= , Fabiano Rosas , Marcel Apfelbaum , qemu-arm@nongnu.org, Christian Borntraeger , qemu-ppc@nongnu.org, Zhao Liu , Daniel Henrique Barboza , qemu-block@nongnu.org, Joel Stanley , Weiwei Li , Kevin Wolf , Helge Deller , Yanan Wang , Michael Rolnik , Jesper Devantier , Marcelo Tosatti , Peter Maydell , Pierrick Bouvier Subject: [PATCH v3 27/34] hw/net: remove return after g_assert_not_reached() Date: Wed, 18 Sep 2024 21:46:34 -0700 Message-Id: <20240919044641.386068-28-pierrick.bouvier@linaro.org> X-Mailer: git-send-email 2.39.5 In-Reply-To: <20240919044641.386068-1-pierrick.bouvier@linaro.org> References: <20240919044641.386068-1-pierrick.bouvier@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::42e; envelope-from=pierrick.bouvier@linaro.org; helo=mail-pf1-x42e.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=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 This patch is part of a series that moves towards a consistent use of g_assert_not_reached() rather than an ad hoc mix of different assertion mechanisms. Reviewed-by: Richard Henderson Signed-off-by: Pierrick Bouvier --- hw/net/e1000e_core.c | 2 -- hw/net/igb_core.c | 2 -- hw/net/vmxnet3.c | 1 - 3 files changed, 5 deletions(-) diff --git a/hw/net/e1000e_core.c b/hw/net/e1000e_core.c index 248381f9766..2e4c50ddbaf 100644 --- a/hw/net/e1000e_core.c +++ b/hw/net/e1000e_core.c @@ -562,7 +562,6 @@ e1000e_rss_calc_hash(E1000ECore *core, break; default: g_assert_not_reached(); - return 0; } return net_rx_pkt_calc_rss_hash(pkt, type, (uint8_t *) &core->mac[RSSRK]); @@ -841,7 +840,6 @@ e1000e_ring_free_descr_num(E1000ECore *core, const E1000ERingInfo *r) } g_assert_not_reached(); - return 0; } static inline bool diff --git a/hw/net/igb_core.c b/hw/net/igb_core.c index 6be61407715..5dffa12c64b 100644 --- a/hw/net/igb_core.c +++ b/hw/net/igb_core.c @@ -398,7 +398,6 @@ igb_rss_calc_hash(IGBCore *core, struct NetRxPkt *pkt, E1000E_RSSInfo *info) break; default: g_assert_not_reached(); - return 0; } return net_rx_pkt_calc_rss_hash(pkt, type, (uint8_t *) &core->mac[RSSRK]); @@ -747,7 +746,6 @@ igb_ring_free_descr_num(IGBCore *core, const E1000ERingInfo *r) } g_assert_not_reached(); - return 0; } static inline bool diff --git a/hw/net/vmxnet3.c b/hw/net/vmxnet3.c index bb8583c7aba..8aa8c462283 100644 --- a/hw/net/vmxnet3.c +++ b/hw/net/vmxnet3.c @@ -456,7 +456,6 @@ vmxnet3_setup_tx_offloads(VMXNET3State *s) default: g_assert_not_reached(); - return false; } return true;