Received: by 2002:a05:6358:e9c4:b0:b2:91dc:71ab with SMTP id hc4csp1623282rwb; Fri, 5 Aug 2022 05:20:51 -0700 (PDT) X-Google-Smtp-Source: AA6agR4y61OcBwH7d7Iupc2ZJB4lp/HjSDmcSNTorHwYQnZUBj8stHOJjFmJVdgSZMXAzTAM+7B/ X-Received: by 2002:a05:6402:1e95:b0:437:ce7f:e17a with SMTP id f21-20020a0564021e9500b00437ce7fe17amr6277689edf.169.1659702051623; Fri, 05 Aug 2022 05:20:51 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1659702051; cv=none; d=google.com; s=arc-20160816; b=Ds/3MCp0JfhXoOhPnHIgSPvw4yHf5wayFJb5oY/0cCTX+9kjoDCG1DcC3nvooBJCk3 98xTevRAgxgiy3YyogqOFBUzvK50dQktGtn0TRShFbY0OitjaBIQz4+k/j4GH/GvTo1u y4X9yMN2sRys6nrQcIiE9Ba7ESaRxCA8ahJR4hfo58lSHXkvD1R59HFbu8HpnKSzJUt1 eU4tXSnkZGwu0pNZE6rWA6WRRFmaMDPTQFbbseeCDKE7LMmg6f1BQ4/cnze4BviNsHVB YXwwcH/qyLHmWaAk2Z4jbLDQFXlie79UInpzJcqM1i7+dhilbRXFmOjHmOC2q3WDHnkL ABpQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from:dkim-signature; bh=jmupmgL/y2HrrDUu//62/jqyRcBAlD1KYeBUZ5VB29Q=; b=a355QjiVrDq1F4XNEi7vODYwEVGJPZ102iOIo/hVNhfTH5e+UugTTWSqQFxrZz6LMb D+fWwib1vZtzeAmEhr7Yd76G4VkWo7+Rvp7ZTF4p2xeFotRnYnNtsRVU2fgSaB0gfiO7 Hon/PrXEp+zQW7j0WoehMNGtCQGvWvv+mAp8H0O2F4OtTlLl22Kchq6g4DgraTXMi6wd dzvU09t1uUgwgdQVgj3FB58xVigpz/h8wACxCaf99FeTbHIZajYJQOPWLSTCSvQXZz+o X1kvHAH1Nbw1A/HoajmI6ufxpdZ5YBQZI9C/xFSCqKNoWK772NELYC0DUCj8nhLnLnRq NRQw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20210112 header.b=b8qEIFbx; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id gs33-20020a1709072d2100b00730a92be805si4092512ejc.148.2022.08.05.05.20.24; Fri, 05 Aug 2022 05:20:51 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20210112 header.b=b8qEIFbx; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S240604AbiHEMEq (ORCPT + 99 others); Fri, 5 Aug 2022 08:04:46 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:45622 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230169AbiHEMEn (ORCPT ); Fri, 5 Aug 2022 08:04:43 -0400 Received: from mail-wm1-x32a.google.com (mail-wm1-x32a.google.com [IPv6:2a00:1450:4864:20::32a]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 5451B140ED; Fri, 5 Aug 2022 05:04:42 -0700 (PDT) Received: by mail-wm1-x32a.google.com with SMTP id n185so1317970wmn.4; Fri, 05 Aug 2022 05:04:42 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:from:to:cc; bh=jmupmgL/y2HrrDUu//62/jqyRcBAlD1KYeBUZ5VB29Q=; b=b8qEIFbxhE6kPRN0WZdb4m+PaZL+4KC/1yg4Gz1Jce1OEuy99CmL5Vr5idAf9saHWg VsETqlLVqRi/tNA2+I79MkFR7H8+WG4DPKeJqZ0FnRNpctc1ZauGLyXzwmscDeA6mtyh txBplgaDJZoVpBgskaKuoCBKug8rJHmh9nv/tE/XH+PnT+6kQ/hIyHQ19uiwK5fKrEEK OkKgBZYACjruR0Wpg/U72t4BJz6Im4q0NOfWhzThXI/R+UHMj5Rw2AI8xGdMoYOWf+XP /6gi4lnAE9eAjE+g6+cas3xASUIIckjfF42pCqLuXb5W4Il+vhXHG4E7ngQcwXC15c2l SRHQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:x-gm-message-state:from:to:cc; bh=jmupmgL/y2HrrDUu//62/jqyRcBAlD1KYeBUZ5VB29Q=; b=8Q4EseuGUMBYQX0mzcWD7CH6OOyKS7Brz2OdFzPRJttfIBIG5LBUcyzqWxGCDMjCvb 3FgxrclHSAp/ldp/LbGTK9uxy5b+4PUO+tA5h+6e0nvMBqMZzJis9zwyKbqV/orNPmYB +7FasIW7AZdMYXIOlAqF3YVTmMZtsIZHieHUqpLA0Ze78rsZCN4fUJCbeIFs6KiD68zA aLLa6SxogojeqyxhAAAUstheHG+pAIj8cb816DBHQJat/xmzBj43Gx7ym7JJAOWjgm7U HBzpFlu80mWtCqewZ/Wk/74Klz/OubjWXWo/LCsaOftJR/nfV/VXvFDMfK2oFjc3ryGT SRtw== X-Gm-Message-State: ACgBeo2RNJgmD0AIs6FK1PGzYAKaFYAvuSjmj0gQSw4WIs8ceSEAUy+u X5Yx0+4MBrRRr3IDX0/DKv8= X-Received: by 2002:a7b:c7cd:0:b0:3a3:8f1:8aeb with SMTP id z13-20020a7bc7cd000000b003a308f18aebmr9227015wmk.90.1659701080818; Fri, 05 Aug 2022 05:04:40 -0700 (PDT) Received: from localhost (cpc154979-craw9-2-0-cust193.16-3.cable.virginm.net. [80.193.200.194]) by smtp.gmail.com with ESMTPSA id m8-20020a7bca48000000b003a3442f1229sm8977412wml.29.2022.08.05.05.04.40 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 05 Aug 2022 05:04:40 -0700 (PDT) From: Colin Ian King To: Jaroslav Kysela , Takashi Iwai , alsa-devel@alsa-project.org Cc: kernel-janitors@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH] ALSA: ice1712: remove redundant assignment to new Date: Fri, 5 Aug 2022 13:04:39 +0100 Message-Id: <20220805120439.2341600-1-colin.i.king@gmail.com> X-Mailer: git-send-email 2.35.3 MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_FROM, RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org The variable new is initialized with a value but it is never read. It is being re-assigned a new value in every case path in the following switch statement. The assignment is redundant and can be removed. Cleans up clang scan build warning: sound/pci/ice1712/quartet.c:569:8: warning: Although the value stored to 'new' is used in the enclosing expression, the value is never actually read from 'new' [deadcode.DeadStores] Signed-off-by: Colin Ian King --- sound/pci/ice1712/quartet.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sound/pci/ice1712/quartet.c b/sound/pci/ice1712/quartet.c index 0dfa093f7dca..20b3e8f94719 100644 --- a/sound/pci/ice1712/quartet.c +++ b/sound/pci/ice1712/quartet.c @@ -566,7 +566,7 @@ static int qtet_ain12_sw_put(struct snd_kcontrol *kcontrol, { struct snd_ice1712 *ice = snd_kcontrol_chip(kcontrol); unsigned int old, new, tmp, masked_old; - old = new = get_scr(ice); + old = get_scr(ice); masked_old = old & (SCR_AIN12_SEL1 | SCR_AIN12_SEL0); tmp = ucontrol->value.integer.value[0]; if (tmp == 2) -- 2.35.3