Received: by 2002:ab2:6a05:0:b0:1f8:1780:a4ed with SMTP id w5csp1901194lqo; Mon, 13 May 2024 01:36:56 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCV0Mrh9NWc+BdgB3sn1SJM337E961oKHHVjwQOe0FlAxWWS4hYHdJ1zRB9KswMaqWz8gMGHesAxhoUbjT/L2E5ZFolbeNtA13uieJZhvg== X-Google-Smtp-Source: AGHT+IGuetQTullhBLMnD4tsUC8mtOjIVsjCjm7hDbIEVcCt3hBn+2WHJMNB+VB42Af3AfE/udSh X-Received: by 2002:a9d:77d1:0:b0:6ee:360e:e11d with SMTP id 46e09a7af769-6f0e92c0d00mr9597525a34.35.1715589415969; Mon, 13 May 2024 01:36:55 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1715589415; cv=pass; d=google.com; s=arc-20160816; b=DekRPIUXYS3iCmRRHYbeCOALBebdqzoAAAUmLlAq6NqT9jhBTK6McVrfq50dtZtgpf CycjMbxpCI0samrIUDAyMwaR5U6zpSRIzfTi8/S3TbS9kuwWp9WdbiEz/Y5dN/OpNOdQ FvqCFNcNkdA+eeow1yzvvwJH8kjJiiS3NqAR+vjaTVDX5t7Ccu39V3A2WFEhdOwFEOSl 8pARvczQNLGdzUss+beeNZNx43AqgYe2jAZlLnT/ONW8vFWyj2dTZjm/oI5/Q4/etxW0 PXuMyg0noMPjSdtCOq7RfIlHKIO/DUg6usiFfj2a5vwhWw/5YKnHQ7GxQ16ESfSioVVj M8Xw== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:message-id:date:subject:cc:to :from:dkim-signature; bh=hiJdAG0IiOqJzfvr5ICD+P1L13jouUZ1sJj6ghGQ+Sw=; fh=et0fAP0abu7sjGSrQYZxTvZ0yBrXVZRmfpuUg3SjIm8=; b=dUS0uQJGSLKeqOswpJJPPuOjJbCtqH2BScqAW/ajs/24J5Em7sZ1Mw0C+baTxoE9DL IaaKl63nqJVaPmvOiKbcigtzl0w7m+ahzeesOXE7uqvRPn+KyX0nm3uiZq+2WQ9cCYnZ QTiqWvNtaqsyuq5MtkNhCsb5eEMkN8G37K+Ti09lg+vBB7krY/Oev8JIFi3OcBn7R/od 9+yyPvZ56qvpK/vpGK/P0AyoBpwCa+I3qZ0O1aV8O7KMOl/EkQy/micOK5HpFXXdBaMt S1jFGL5uI65/P2O9at/vLD2RBcpPLdVFUPFQpCCLl1lXXlYrnqC2CdZ3lViXVPvPdIOj sB/Q==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@yandex.ru header.s=mail header.b=IvXICKXz; arc=pass (i=1 spf=pass spfdomain=yandex.ru dkim=pass dkdomain=yandex.ru dmarc=pass fromdomain=yandex.ru); spf=pass (google.com: domain of linux-wireless+bounces-7578-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:40f1:3f00::1 as permitted sender) smtp.mailfrom="linux-wireless+bounces-7578-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=yandex.ru Return-Path: Received: from sy.mirrors.kernel.org (sy.mirrors.kernel.org. [2604:1380:40f1:3f00::1]) by mx.google.com with ESMTPS id 41be03b00d2f7-63411902ea1si8056297a12.601.2024.05.13.01.36.55 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 13 May 2024 01:36:55 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-wireless+bounces-7578-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:40f1:3f00::1 as permitted sender) client-ip=2604:1380:40f1:3f00::1; Authentication-Results: mx.google.com; dkim=pass header.i=@yandex.ru header.s=mail header.b=IvXICKXz; arc=pass (i=1 spf=pass spfdomain=yandex.ru dkim=pass dkdomain=yandex.ru dmarc=pass fromdomain=yandex.ru); spf=pass (google.com: domain of linux-wireless+bounces-7578-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:40f1:3f00::1 as permitted sender) smtp.mailfrom="linux-wireless+bounces-7578-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=yandex.ru Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sy.mirrors.kernel.org (Postfix) with ESMTPS id DB1ECB21488 for ; Mon, 13 May 2024 08:36:42 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id BB1A2147C89; Mon, 13 May 2024 08:36:31 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=yandex.ru header.i=@yandex.ru header.b="IvXICKXz" X-Original-To: linux-wireless@vger.kernel.org Received: from forward100b.mail.yandex.net (forward100b.mail.yandex.net [178.154.239.147]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id B7E3B1474BF for ; Mon, 13 May 2024 08:36:26 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=178.154.239.147 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1715589391; cv=none; b=FPR9v2YB3AcKA/+XmnA2+m9Iah158XrMuPq1FJylndYIHnVGvivgnVq16IV9L73okFfs8XNi++faz5f2pXpLVU483/3T3eq0dZmBPDToTeTDLBotQm/4maBRWHUUbSuQhUgcHh0gaqmyi8e2nyZoxhjG0PeBefrfM3DQu08SEz4= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1715589391; c=relaxed/simple; bh=t7PMDf2rrvX6tfQNxWNnMVy4qxBUKQAMFLifA7YdZuw=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version; b=nqkfj+5MY6GWWUPvBipL7mwbVMDkReDBiQH7dgaL7OfT42pE66oDt1EJoaFI9iQ6Zqhl/X1bgg929zQ503WjrCuuz8LbVvPEB7Z/Ga1bb28HUAPlM5os15GmgDzHT2YE67ZQiaQR3M390qWJ2WFFqd+YQaE9UrsVt3GJcTAzVqk= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=yandex.ru; spf=pass smtp.mailfrom=yandex.ru; dkim=pass (1024-bit key) header.d=yandex.ru header.i=@yandex.ru header.b=IvXICKXz; arc=none smtp.client-ip=178.154.239.147 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=yandex.ru Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=yandex.ru Received: from mail-nwsmtp-smtp-production-main-31.sas.yp-c.yandex.net (mail-nwsmtp-smtp-production-main-31.sas.yp-c.yandex.net [IPv6:2a02:6b8:c08:de2c:0:640:e39b:0]) by forward100b.mail.yandex.net (Yandex) with ESMTPS id 163AA60B42; Mon, 13 May 2024 11:36:19 +0300 (MSK) Received: by mail-nwsmtp-smtp-production-main-31.sas.yp-c.yandex.net (smtp/Yandex) with ESMTPSA id HaZQu3Ho9qM0-8Jzux3U1; Mon, 13 May 2024 11:36:18 +0300 X-Yandex-Fwd: 1 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yandex.ru; s=mail; t=1715589378; bh=hiJdAG0IiOqJzfvr5ICD+P1L13jouUZ1sJj6ghGQ+Sw=; h=Message-ID:Date:Cc:Subject:To:From; b=IvXICKXzZsHICeftrEAKYm06U+ldpYf/W0W2Dq/WWAolK3Qcj1uWze9m1puAg/6ku G4nuFf/lVoPO9lzz8Z1MDm+TcUcptMguRDK7MUiDtv7ii5Cr0eyHnbTnjeXd8YDVSX 2/lbZQVTVAhzdMhnnT6QwmIG15iyor81tr3a6A34= Authentication-Results: mail-nwsmtp-smtp-production-main-31.sas.yp-c.yandex.net; dkim=pass header.i=@yandex.ru From: Dmitry Antipov To: Miri Korenblit Cc: Kalle Valo , linux-wireless@vger.kernel.org, lvc-project@linuxtesting.org, Dmitry Antipov Subject: [PATCH] wifi: iwlwifi: fw: remove dead branch in iwl_acpi_get_wgds_table() Date: Mon, 13 May 2024 11:36:11 +0300 Message-ID: <20240513083611.49064-1-dmantipov@yandex.ru> X-Mailer: git-send-email 2.45.0 Precedence: bulk X-Mailing-List: linux-wireless@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Since the first loop in iwl_acpi_get_wgds_table() always terminates with 'idx == ARRAY_SIZE(rev_data)' unless one of goto branches is taken, remove unreachable code. Compile tested only. Found by Linux Verification Center (linuxtesting.org) with SVACE. Signed-off-by: Dmitry Antipov --- drivers/net/wireless/intel/iwlwifi/fw/acpi.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/drivers/net/wireless/intel/iwlwifi/fw/acpi.c b/drivers/net/wireless/intel/iwlwifi/fw/acpi.c index fa339791223b..7fb3cd06edbb 100644 --- a/drivers/net/wireless/intel/iwlwifi/fw/acpi.c +++ b/drivers/net/wireless/intel/iwlwifi/fw/acpi.c @@ -745,10 +745,7 @@ int iwl_acpi_get_wgds_table(struct iwl_fw_runtime *fwrt) } } - if (idx < ARRAY_SIZE(rev_data)) - ret = PTR_ERR(wifi_pkg); - else - ret = -ENOENT; + ret = -ENOENT; goto out_free; read_table: -- 2.45.0