From patchwork Mon Aug 9 12:31:36 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Srinivas Kandagatla X-Patchwork-Id: 12426349 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-16.8 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER,INCLUDES_PATCH, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED,USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 8A69CC4338F for ; Mon, 9 Aug 2021 12:32:58 +0000 (UTC) Received: from alsa0.perex.cz (alsa0.perex.cz [77.48.224.243]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id C90DD60F35 for ; Mon, 9 Aug 2021 12:32:56 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.1 mail.kernel.org C90DD60F35 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=linaro.org Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=alsa-project.org Received: from alsa1.perex.cz (alsa1.perex.cz [207.180.221.201]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by alsa0.perex.cz (Postfix) with ESMTPS id AC6391616; Mon, 9 Aug 2021 14:32:04 +0200 (CEST) DKIM-Filter: OpenDKIM Filter v2.11.0 alsa0.perex.cz AC6391616 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=alsa-project.org; s=default; t=1628512374; bh=UqIYI+/WpB8vpmajsMsNj2tzgNmRVCpRxuzElnEH3Nk=; h=From:To:Subject:Date:In-Reply-To:References:Cc:List-Id: List-Unsubscribe:List-Archive:List-Post:List-Help:List-Subscribe: From; b=JJ0TcjNBXv4fs14ROc8xU767X5gZKSpLYeY3DUVV8a9EtkOXbaboHxqNYCeqHfpV9 8SnNYgNzzo9JgF12nM1Ch5iZIqV/M+5abJnGd2PVo+S/TbLeiwA8W8yG0P30hUfsP9 pHcAqGenDCB5Z7aArSsUXN7AYM8O9Ag3o1kD8UZM= Received: from alsa1.perex.cz (localhost.localdomain [127.0.0.1]) by alsa1.perex.cz (Postfix) with ESMTP id 37D64F80105; Mon, 9 Aug 2021 14:32:04 +0200 (CEST) Received: by alsa1.perex.cz (Postfix, from userid 50401) id 91C73F804AE; Mon, 9 Aug 2021 14:32:01 +0200 (CEST) Received: from mail-wr1-x42b.google.com (mail-wr1-x42b.google.com [IPv6:2a00:1450:4864:20::42b]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by alsa1.perex.cz (Postfix) with ESMTPS id AB4EFF800CB for ; Mon, 9 Aug 2021 14:31:53 +0200 (CEST) DKIM-Filter: OpenDKIM Filter v2.11.0 alsa1.perex.cz AB4EFF800CB Authentication-Results: alsa1.perex.cz; dkim=pass (2048-bit key) header.d=linaro.org header.i=@linaro.org header.b="TYuC62Jh" Received: by mail-wr1-x42b.google.com with SMTP id b11so5053041wrx.6 for ; Mon, 09 Aug 2021 05:31:53 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=ZKxim9glF2Pix1TZX/SYGDBRE7+YwjotanL1KNZXsdQ=; b=TYuC62Jh8eFdZMbUsv4rGO508rQbR1YCfDc5MbOorLYbt8FA/66mO2Tcg7Yi94zRUi mYzef4aoOSkoAZyHQckJS/OPuJ/7KF2JvbhlpKZ5FuL1/EbTzDWeZNM31xN8lh9SEQMS 9Mr6IDHsmccn0qv3JKbIUSVrMCIwqqm1pYGz/hlPmk4Rcns6EgXqtHW8iXdtAZDej0do ViesldXEEX7N/OHOLwSoWpp0Ab9c4LUBtlRrp7U0lkpEMPdT5kSotpyVT7vvWDFMmFNK TTbbBEgphMsquJFuaA7qklkQClBW2gl8Lw0uWYYt78AUjuNi14OqElu3hFs9CSPxCqfF cTKA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=ZKxim9glF2Pix1TZX/SYGDBRE7+YwjotanL1KNZXsdQ=; b=SFmatJM7ZOTNNwH//fZ07/EDa+mGpHr9l01FsDZiA3irRuZbdubbREoivPu8st73fK UhkT08WSbyKwgjSifCzcWVPL3Rxbfefn2noLCcjzdPdLSpKbIabXC966CijJqwoxR3lx U5Lf/4vnIANj1n7ag6qwoL0ZqW0rYLG12JqH9068tl6hN6uT/aUmTVEZvUUs5EdmMhAf WWnI/kRJWhxBNoZqlf3aqOFqKx8sQqBd50qWh8N/hqSl50jmcTkxFssidVMACyqBaH1d vPNqRUIGAtsMEN6N7RrtxCSG+4zsl/jSyjUsh2HYK9YbOlyE+VQgebvDYLF8uil1oSi6 i9Jw== X-Gm-Message-State: AOAM532EN/KctzyoEMyEov6pvAsbuGCddYCsxKg8kQA8SW/udOFOgZnM gxfvB1dFm6nVo14/kc65eNMZAA== X-Google-Smtp-Source: ABdhPJwJyoOBTP0fsNQzeKuLps0saSz1ly0/E7TfoFgS8hiqbxkUxbr3KiTjFFfNWykYNvbwHckfNQ== X-Received: by 2002:a05:6000:1366:: with SMTP id q6mr24588422wrz.60.1628512312871; Mon, 09 Aug 2021 05:31:52 -0700 (PDT) Received: from srini-hackbox.lan (cpc86377-aztw32-2-0-cust226.18-1.cable.virginm.net. [92.233.226.227]) by smtp.gmail.com with ESMTPSA id g12sm19369193wri.49.2021.08.09.05.31.51 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 09 Aug 2021 05:31:52 -0700 (PDT) From: Srinivas Kandagatla To: broonie@kernel.org Subject: [PATCH 1/2] ASoC: qdsp6: q6asm: fix cppcheck warnings for unnecessary initialization Date: Mon, 9 Aug 2021 13:31:36 +0100 Message-Id: <20210809123137.14456-2-srinivas.kandagatla@linaro.org> X-Mailer: git-send-email 2.21.0 In-Reply-To: <20210809123137.14456-1-srinivas.kandagatla@linaro.org> References: <20210809123137.14456-1-srinivas.kandagatla@linaro.org> MIME-Version: 1.0 Cc: alsa-devel@alsa-project.org, bgoswami@codeaurora.org, tiwai@suse.de, lgirdwood@gmail.com X-BeenThere: alsa-devel@alsa-project.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: "Alsa-devel mailing list for ALSA developers - http://www.alsa-project.org" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: alsa-devel-bounces@alsa-project.org Sender: "Alsa-devel" cppcheck reports below warning. q6asm.c:1631: (style) Variable 'port' is reassigned a value before the old one has been used. This is due to unnecessary initialization of variable port, which is now removed as part of this patch. Signed-off-by: Srinivas Kandagatla --- sound/soc/qcom/qdsp6/q6asm.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sound/soc/qcom/qdsp6/q6asm.c b/sound/soc/qcom/qdsp6/q6asm.c index 36bf8bd4edd7..9251d8548965 100644 --- a/sound/soc/qcom/qdsp6/q6asm.c +++ b/sound/soc/qcom/qdsp6/q6asm.c @@ -1624,7 +1624,7 @@ EXPORT_SYMBOL_GPL(q6asm_write_async); static void q6asm_reset_buf_state(struct audio_client *ac) { - struct audio_port_data *port = NULL; + struct audio_port_data *port; unsigned long flags; spin_lock_irqsave(&ac->lock, flags);