Received: by 2002:a05:6a10:9848:0:0:0:0 with SMTP id x8csp1480925pxf; Fri, 12 Mar 2021 10:26:20 -0800 (PST) X-Google-Smtp-Source: ABdhPJydZVg7aRvGH9/ePRqi5CLlMS4WvD3JZtzY8BvAnX8M6fYCWs/1Fo8GhpzWM9woxQHqrl0T X-Received: by 2002:aa7:d503:: with SMTP id y3mr15671337edq.142.1615573579805; Fri, 12 Mar 2021 10:26:19 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1615573579; cv=none; d=google.com; s=arc-20160816; b=0WPUXs2mT4qoQ1sotECukvYOtc5WYHNYlMr7/okLNd7jr/s3Omu1cD/k4rPlu0NeFV Qm6GX2666GYcnp4H1zThABHuRpr233+d7rc05oTkSm4+3lvfWZJXKzQk8XfesPfCayGQ B3pbx3Q5pURlihDrMK8P/3g5kDaXi5aVlVaPsfamy1/nCxQxQ2hz0T1xr89b/FehKkcO 1rNf3p6V/EVk+vucSDSoHNPtv6A2TVwyuNotcv93fhAeX/gKGE2qpln4CuxoKYkkLnT5 +Oa0UOssGU8UvFKPzLJ8HCFls11knDlFWR+VJA93/yRondXJeEj6CiHBdPr26+r4ri8+ UBnQ== 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 :references:in-reply-to:message-id:date:subject:cc:to:from :ironport-sdr:ironport-sdr; bh=cciJVApGunpjWezKUJxC7dL3GOyD5DE4jt7Y+cYA4Gw=; b=muMW9WMCV1oIf3ASg0j9sD4ZNaZX2WyVU/+cmNDLd6slVEAf57860nZxJDrc1fW8Uj LPrvnRG9KSWOf4lVz1OzdKCG4xjT8Zr7uHjEYHJLwubdxt2Unc4Xkd5ftKHfIHapt08g cO0y4EbP1VitdifPyt70HyYgG3e3Q3SSzHM7BP3YsaiZczuVyzywAIJUnDwfpHLlO7Ug xitgQO1rwzBYSQ99my+j13p4bQiX51+7/1GuMTseETg0AQYTk0DukOogHEjdZ34hwBxR wwnvbGmZ9KgmTB+4R4xdQUYiWo2NfjaQkfqGUaAQEdF5IEOzkjEIxxw+I8LRr4lu0PPA F6Dw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id c20si4719396ejk.730.2021.03.12.10.25.56; Fri, 12 Mar 2021 10:26:19 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233681AbhCLSYf (ORCPT + 99 others); Fri, 12 Mar 2021 13:24:35 -0500 Received: from mga07.intel.com ([134.134.136.100]:4255 "EHLO mga07.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233193AbhCLSX5 (ORCPT ); Fri, 12 Mar 2021 13:23:57 -0500 IronPort-SDR: O3Q37hxT2H23KeOxGi+g2QWk/vV+4w7DUbr30dtbsLQesvBBmaGRIJRrm6jurZCH3woS3CtzUe sSoTEALtUgAA== X-IronPort-AV: E=McAfee;i="6000,8403,9921"; a="252888966" X-IronPort-AV: E=Sophos;i="5.81,244,1610438400"; d="scan'208";a="252888966" Received: from fmsmga007.fm.intel.com ([10.253.24.52]) by orsmga105.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 12 Mar 2021 10:23:56 -0800 IronPort-SDR: 6SOIPlZAxWJEsjsdY7SvKERcoUUu+c1aFiJMLRhHzkT1oGWK5AFgx60v0aiyrBWPOQYChhjLuT NROlmJZ+GTLQ== X-IronPort-AV: E=Sophos;i="5.81,244,1610438400"; d="scan'208";a="377792084" Received: from amiteshs-mobl.amr.corp.intel.com (HELO pbossart-mobl3.intel.com) ([10.212.37.30]) by fmsmga007-auth.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 12 Mar 2021 10:23:55 -0800 From: Pierre-Louis Bossart To: alsa-devel@alsa-project.org Cc: tiwai@suse.de, broonie@kernel.org, linux-kernel@vger.kernel.org, Pierre-Louis Bossart , Steven Eckhoff , Liam Girdwood , Jaroslav Kysela , Takashi Iwai Subject: [PATCH 23/23] ASoC: tscs454: remove useless test on PLL disable Date: Fri, 12 Mar 2021 12:22:46 -0600 Message-Id: <20210312182246.5153-24-pierre-louis.bossart@linux.intel.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20210312182246.5153-1-pierre-louis.bossart@linux.intel.com> References: <20210312182246.5153-1-pierre-louis.bossart@linux.intel.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org cppcheck warning: sound/soc/codecs/tscs454.c:730:37: style: Same value in both branches of ternary operator. [duplicateValueTernary] val = pll1 ? FV_PLL1CLKEN_DISABLE : FV_PLL2CLKEN_DISABLE; ^ Signed-off-by: Pierre-Louis Bossart --- sound/soc/codecs/tscs454.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/sound/soc/codecs/tscs454.c b/sound/soc/codecs/tscs454.c index 1bafc9d1101c..43220bb36701 100644 --- a/sound/soc/codecs/tscs454.c +++ b/sound/soc/codecs/tscs454.c @@ -727,7 +727,12 @@ static int pll_power_event(struct snd_soc_dapm_widget *w, if (enable) val = pll1 ? FV_PLL1CLKEN_ENABLE : FV_PLL2CLKEN_ENABLE; else - val = pll1 ? FV_PLL1CLKEN_DISABLE : FV_PLL2CLKEN_DISABLE; + /* + * FV_PLL1CLKEN_DISABLE and FV_PLL2CLKEN_DISABLE are + * identical zero vzalues, there is no need to test + * the PLL index + */ + val = FV_PLL1CLKEN_DISABLE; ret = snd_soc_component_update_bits(component, R_PLLCTL, msk, val); if (ret < 0) { -- 2.25.1