From patchwork Tue Apr 2 14:59:56 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Pierre-Louis Bossart X-Patchwork-Id: 13614270 Received: from mgamail.intel.com (mgamail.intel.com [192.198.163.15]) (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 A9DDE138A for ; Tue, 2 Apr 2024 15:00:14 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=192.198.163.15 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1712070016; cv=none; b=XatEn4CAD+h3gCR23NH9X3AdBEJAvCHPNc4PM6vBdF2oVIwCF07FK1+G3uQuoCz1GND0P5G8x8fWnn5E/WVdd6c2gv4hujKmgWb90qep67da6D6LPhT6x0TQqU4BtR1FQrRbBH4uejuvaudktOEebu/um9DzqnDrJ+GGUe/BVwo= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1712070016; c=relaxed/simple; bh=Z+Ybbt9Fy1SY0EwppncHnxJ8noudvlaEyZRsTHXtmrc=; h=From:To:Cc:Subject:Date:Message-Id:In-Reply-To:References: MIME-Version; b=u/VoP+WqAhm61/vQJvq2YA9LIDOsYuOUbog7eD/JxSi+50KYgtFUSjOXOEbMPlIOPOBIrUHGL+6zQQ8ExkeaVT3HkIlbUEXGxB0cGphF/sVlkZLRrELU2v5LbaPRSg/4MfhEqMPXbxXTmjir/uqZheW7e706vmlNlDntlcgjFJw= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linux.intel.com; spf=none smtp.mailfrom=linux.intel.com; dkim=pass (2048-bit key) header.d=intel.com header.i=@intel.com header.b=LzQx2ESG; arc=none smtp.client-ip=192.198.163.15 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linux.intel.com Authentication-Results: smtp.subspace.kernel.org; spf=none smtp.mailfrom=linux.intel.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=intel.com header.i=@intel.com header.b="LzQx2ESG" DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1712070014; x=1743606014; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=Z+Ybbt9Fy1SY0EwppncHnxJ8noudvlaEyZRsTHXtmrc=; b=LzQx2ESG0ZpAdRE2lgbY5ohcwXDCFUfK3KRRu+5jY+4v8BPa6raQJ0J0 zyyv1nIG+REJ1a9DoG4cVZts8tVMu8YI/fDTdXfoHpS4V3fM+GDyjHmdF HeQwD8nGZi62uzFFtucpejoGp4OBqz1GOyJeB0V4q2w5Don9hvOC+V4dV DOtEuku5MFMiLSSAcT8j0WVOFiYhyWIwmNSyD5J5MkOJKaWvl4cpXFJXG ddRxjcdYaaC0gQ+AL9374szTaACsso5WS9DvN2ETY+GLotdKhydP3ol3y yvaTLusmJi+qzWEz2d9A/20/uCG9n4RHL3DA/OWuPRkGhbEq6SpsTpQXu Q==; X-CSE-ConnectionGUID: 2IB60xpIQJOeud6UbvtmTQ== X-CSE-MsgGUID: dp2W+6EpSrWZ6LCPG0pQrg== X-IronPort-AV: E=McAfee;i="6600,9927,11032"; a="7433821" X-IronPort-AV: E=Sophos;i="6.07,175,1708416000"; d="scan'208";a="7433821" Received: from fmviesa003.fm.intel.com ([10.60.135.143]) by fmvoesa109.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 02 Apr 2024 08:00:12 -0700 X-CSE-ConnectionGUID: TvxuCwT4SmegYy/4R03HAg== X-CSE-MsgGUID: A4QkwMyIS4q/i3CB+PNzew== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="6.07,175,1708416000"; d="scan'208";a="22558027" Received: from skhare-mobl5.amr.corp.intel.com (HELO pbossart-mobl6.intel.com) ([10.212.8.83]) by fmviesa003-auth.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 02 Apr 2024 08:00:12 -0700 From: Pierre-Louis Bossart To: linux-sound@vger.kernel.org Cc: alsa-devel@alsa-project.org, tiwai@suse.de, broonie@kernel.org, Yong Zhi , Ranjani Sridharan , Bard Liao , Pierre-Louis Bossart Subject: [PATCH 1/4] ASoC: SOF: ipc4-loader: save FW version info to debugfs Date: Tue, 2 Apr 2024 09:59:56 -0500 Message-Id: <20240402145959.172619-2-pierre-louis.bossart@linux.intel.com> X-Mailer: git-send-email 2.40.1 In-Reply-To: <20240402145959.172619-1-pierre-louis.bossart@linux.intel.com> References: <20240402145959.172619-1-pierre-louis.bossart@linux.intel.com> Precedence: bulk X-Mailing-List: linux-sound@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 From: Yong Zhi To check loaded FW version: $ hexdump -C /sys/kernel/debug/sof/fw_version 00000000 02 00 07 00 63 00 01 00 00 00 00 00 00 00 00 00 |....c...........| Reviewed-by: Ranjani Sridharan Reviewed-by: Bard Liao Signed-off-by: Yong Zhi Signed-off-by: Pierre-Louis Bossart --- sound/soc/sof/ipc4-loader.c | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/sound/soc/sof/ipc4-loader.c b/sound/soc/sof/ipc4-loader.c index c79479afa8d0..641c4f24cca9 100644 --- a/sound/soc/sof/ipc4-loader.c +++ b/sound/soc/sof/ipc4-loader.c @@ -80,6 +80,14 @@ static ssize_t sof_ipc4_fw_parse_ext_man(struct snd_sof_dev *sdev, dev_dbg(sdev->dev, "Header length: %u, module count: %u\n", fw_header->len, fw_header->num_module_entries); + /* copy the fw_version of basefw into debugfs at first boot */ + if (fw == sdev->basefw.fw) { + sdev->fw_version.major = fw_header->major_version; + sdev->fw_version.minor = fw_header->minor_version; + sdev->fw_version.micro = fw_header->hotfix_version; + sdev->fw_version.build = fw_header->build_version; + } + fw_lib->modules = devm_kmalloc_array(sdev->dev, fw_header->num_module_entries, sizeof(*fw_module), GFP_KERNEL); if (!fw_lib->modules) From patchwork Tue Apr 2 14:59:57 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Pierre-Louis Bossart X-Patchwork-Id: 13614271 Received: from mgamail.intel.com (mgamail.intel.com [192.198.163.15]) (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 120C412B16E for ; Tue, 2 Apr 2024 15:00:16 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=192.198.163.15 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1712070017; cv=none; b=p3XQ57uXaQMxeNbMJTH403mkJvvsP+spZMP6cjRbJ0N+fXYsMAv92po5+Q7pU5bHwuA/tgorfrUVopA0yYN1JIFc8T97otbdsRb8/mKLfYZivOHuntG3oSaZCXYwE1mPFhP5piAz4G5pUiiJ58iV0hvZd5+2/vMgsUyGWe26iUo= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1712070017; c=relaxed/simple; bh=KEiSZsipQm/e3f21LS8Ya39Ul+7YeHp7MqC0Uee8uzY=; h=From:To:Cc:Subject:Date:Message-Id:In-Reply-To:References: MIME-Version; b=DQ5+kLmLEJBkNPWAkwsq4k9CuzxiXhCOhJ6vzFY5R43QHmirb+1lEq3ch3KfM0ZxZcTeEjtexRHABQAkzMqaAB5cQVgWrcueb0iXJV0sM/o/Ldcj4/FFKIGYhENhYvbdjAa+/05QIA4kuN4ZCoTeBDmAN5LocwJ45k1V5RjNKkw= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linux.intel.com; spf=none smtp.mailfrom=linux.intel.com; dkim=pass (2048-bit key) header.d=intel.com header.i=@intel.com header.b=iZDMDZrS; arc=none smtp.client-ip=192.198.163.15 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linux.intel.com Authentication-Results: smtp.subspace.kernel.org; spf=none smtp.mailfrom=linux.intel.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=intel.com header.i=@intel.com header.b="iZDMDZrS" DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1712070015; x=1743606015; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=KEiSZsipQm/e3f21LS8Ya39Ul+7YeHp7MqC0Uee8uzY=; b=iZDMDZrStqEQpwzQF+m1PQVuGz95mSTANS+cebGYnpUtCcLXRcaA3Kzl XUXbNO8RcEs5T8w17AcMfBMNHrooqgfGhdhORPVSduewVErNd3fL0emSD TX4cWw6dvr6ZVhC6ClZ2j/06ZqUAAxN+/dCrzaMPRieTecgPF49elUYY2 L9R0HbU+q30x9unFjbteP/rGV+aD5ixW5OWCG7lKN7F0beoR1LoCj1Wyg gzHy34Pjl6CbeHCNUEf8Irhc/dCkgYiSWptTHa0Vd5kANe6+EjlHosDkt rEZwD4RnJhf4EEsuUoi+NB9vNmrDZT82r+74ggyVUwu4o0IQp2mcn+8Kb Q==; X-CSE-ConnectionGUID: VDntlRm0RfuMoSiCXTtI/w== X-CSE-MsgGUID: oREYGsc+RXi+jBXIYEIalQ== X-IronPort-AV: E=McAfee;i="6600,9927,11032"; a="7433825" X-IronPort-AV: E=Sophos;i="6.07,175,1708416000"; d="scan'208";a="7433825" Received: from fmviesa003.fm.intel.com ([10.60.135.143]) by fmvoesa109.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 02 Apr 2024 08:00:12 -0700 X-CSE-ConnectionGUID: j7c6EjLCQ2G1F8K60/gzEg== X-CSE-MsgGUID: LyJ8yZEbR/ujCc/5/Oj1YQ== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="6.07,175,1708416000"; d="scan'208";a="22558028" Received: from skhare-mobl5.amr.corp.intel.com (HELO pbossart-mobl6.intel.com) ([10.212.8.83]) by fmviesa003-auth.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 02 Apr 2024 08:00:13 -0700 From: Pierre-Louis Bossart To: linux-sound@vger.kernel.org Cc: alsa-devel@alsa-project.org, tiwai@suse.de, broonie@kernel.org, Pierre-Louis Bossart , Bard Liao Subject: [PATCH 2/4] ASoC: SOF: amd: acp-loader: abort firmware download on write error Date: Tue, 2 Apr 2024 09:59:57 -0500 Message-Id: <20240402145959.172619-3-pierre-louis.bossart@linux.intel.com> X-Mailer: git-send-email 2.40.1 In-Reply-To: <20240402145959.172619-1-pierre-louis.bossart@linux.intel.com> References: <20240402145959.172619-1-pierre-louis.bossart@linux.intel.com> Precedence: bulk X-Mailing-List: linux-sound@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 cppcheck reports this issue: sound/soc/sof/amd/acp-loader.c:299:6: style: Variable 'ret' is reassigned a value before the old one has been used. [redundantAssignment] ret = request_firmware(&adata->fw_dbin, fw_filename, sdev->dev); ^ sound/soc/sof/amd/acp-loader.c:289:6: note: ret is assigned ret = snd_sof_dsp_block_write(sdev, SOF_FW_BLK_TYPE_IRAM, 0, ^ sound/soc/sof/amd/acp-loader.c:299:6: note: ret is overwritten ret = request_firmware(&adata->fw_dbin, fw_filename, sdev->dev); ^ This behavior is probably unintentional, there's no reason to return an error for the DRAM but not the IRAM. Signed-off-by: Pierre-Louis Bossart Reviewed-by: Bard Liao --- sound/soc/sof/amd/acp-loader.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/sound/soc/sof/amd/acp-loader.c b/sound/soc/sof/amd/acp-loader.c index aad904839b81..2d5e58846499 100644 --- a/sound/soc/sof/amd/acp-loader.c +++ b/sound/soc/sof/amd/acp-loader.c @@ -289,6 +289,8 @@ int acp_sof_load_signed_firmware(struct snd_sof_dev *sdev) ret = snd_sof_dsp_block_write(sdev, SOF_FW_BLK_TYPE_IRAM, 0, (void *)sdev->basefw.fw->data, sdev->basefw.fw->size); + if (ret < 0) + return ret; fw_filename = kasprintf(GFP_KERNEL, "%s/%s", plat_data->fw_filename_prefix, From patchwork Tue Apr 2 14:59:58 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Pierre-Louis Bossart X-Patchwork-Id: 13614273 Received: from mgamail.intel.com (mgamail.intel.com [192.198.163.15]) (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 84AC812BEB8 for ; Tue, 2 Apr 2024 15:00:16 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=192.198.163.15 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1712070018; cv=none; b=leE7h/nShyM77Mejf0XIZ1kNiWznLJFECE5VshvbaTl+Kpu3gXbtA8rbkZIGZL4RzHKyn2oKtAqo1fWwWKzTe/jmcjF81gO1+A8bbb5bk51Lrs5N/3bNaXULGy7jPccSWJG8cAT5bmoRcqybF/6Op6pJAwmP5ry7/tzGWHmPkmM= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1712070018; c=relaxed/simple; bh=7SUUzrMM9vVUTGjyOMCz5njlZv6H/FWKf1uf9PfnM48=; h=From:To:Cc:Subject:Date:Message-Id:In-Reply-To:References: MIME-Version; b=WM7+NsCAc/wH8l4PT/yra60d5BuqlDxPWHEA6obEp5AC29ICKhlo5Kr/hCRzzyNvSVJ7qiuI2jhWnaXAxbETu1CoWiXZVEypa1/7/p7kQ101IndfbABoYnt3PHyNIi+KvOqre/D4m4Y8InfNTW7x7lsYS+e8SA8TDEVy6GbBtd4= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linux.intel.com; spf=none smtp.mailfrom=linux.intel.com; dkim=pass (2048-bit key) header.d=intel.com header.i=@intel.com header.b=hV3idLRw; arc=none smtp.client-ip=192.198.163.15 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linux.intel.com Authentication-Results: smtp.subspace.kernel.org; spf=none smtp.mailfrom=linux.intel.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=intel.com header.i=@intel.com header.b="hV3idLRw" DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1712070015; x=1743606015; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=7SUUzrMM9vVUTGjyOMCz5njlZv6H/FWKf1uf9PfnM48=; b=hV3idLRwnUyvVkf8mhI9ctb2Dwhwhq5zuhtJwuyx4GuKAxh9h9xdZeo9 6YY0el/azEypv4lPcGgx258+r6oukpelz6F3FLVFhIRN7GBxjT43HVqYz TiqJDpx1P5lJclB+xu22x8DQh7si6oM5JoF2YUomzJZgEpdbctBwVucCf jo7DtfKHCt2qiGdWtxA6vsprzEpqcYeCXa+da3L1nDjtSUVeuAcC8+vs7 QFNQN0gptWmi6nRZVzOthaMX7xbkQmP/B9z26Z5FvW1Z6WlGbJcidqSNY 33mTReLi/QhoihBzrnX9Tzi0vanPH3wOCdpbVCm/HZTDT6gdPv5eA3c8H A==; X-CSE-ConnectionGUID: /cDsgz7AQue3zPlsyFi5zQ== X-CSE-MsgGUID: /PjG4sk4QUKEmLhuWaUNUQ== X-IronPort-AV: E=McAfee;i="6600,9927,11032"; a="7433830" X-IronPort-AV: E=Sophos;i="6.07,175,1708416000"; d="scan'208";a="7433830" Received: from fmviesa003.fm.intel.com ([10.60.135.143]) by fmvoesa109.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 02 Apr 2024 08:00:13 -0700 X-CSE-ConnectionGUID: 6QlY+RSbSYimAso6nlNcmQ== X-CSE-MsgGUID: KsKYp1ZhRAqBurZSVlwiDA== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="6.07,175,1708416000"; d="scan'208";a="22558029" Received: from skhare-mobl5.amr.corp.intel.com (HELO pbossart-mobl6.intel.com) ([10.212.8.83]) by fmviesa003-auth.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 02 Apr 2024 08:00:13 -0700 From: Pierre-Louis Bossart To: linux-sound@vger.kernel.org Cc: alsa-devel@alsa-project.org, tiwai@suse.de, broonie@kernel.org, Pierre-Louis Bossart , Bard Liao Subject: [PATCH 3/4] ASoC: SOF: ipc4-priv: align prototype and function declaration Date: Tue, 2 Apr 2024 09:59:58 -0500 Message-Id: <20240402145959.172619-4-pierre-louis.bossart@linux.intel.com> X-Mailer: git-send-email 2.40.1 In-Reply-To: <20240402145959.172619-1-pierre-louis.bossart@linux.intel.com> References: <20240402145959.172619-1-pierre-louis.bossart@linux.intel.com> Precedence: bulk X-Mailing-List: linux-sound@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Somehow instance_id and id were mixed. Align on instance_id for consistency. Signed-off-by: Pierre-Louis Bossart Reviewed-by: Bard Liao --- sound/soc/sof/ipc4-priv.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sound/soc/sof/ipc4-priv.h b/sound/soc/sof/ipc4-priv.h index afed618a15f0..e157ab80a103 100644 --- a/sound/soc/sof/ipc4-priv.h +++ b/sound/soc/sof/ipc4-priv.h @@ -98,7 +98,7 @@ extern const struct sof_ipc_tplg_control_ops tplg_ipc4_control_ops; extern const struct sof_ipc_pcm_ops ipc4_pcm_ops; extern const struct sof_ipc_fw_tracing_ops ipc4_mtrace_ops; -int sof_ipc4_set_pipeline_state(struct snd_sof_dev *sdev, u32 id, u32 state); +int sof_ipc4_set_pipeline_state(struct snd_sof_dev *sdev, u32 instance_id, u32 state); int sof_ipc4_mtrace_update_pos(struct snd_sof_dev *sdev, int core); int sof_ipc4_query_fw_configuration(struct snd_sof_dev *sdev); From patchwork Tue Apr 2 14:59:59 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Pierre-Louis Bossart X-Patchwork-Id: 13614272 Received: from mgamail.intel.com (mgamail.intel.com [192.198.163.15]) (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 59E6412BEA1 for ; Tue, 2 Apr 2024 15:00:16 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=192.198.163.15 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1712070017; cv=none; b=qpw5+oswm5z2lBYKqOMUXrFa7s5aZkfGyJr+kjeWR/KdNVJrcT93QGSH+hJDrYGjNq/7fFJ7/rnckU598eXkCkJs7vCLPPhCrPxSGWBOCqp/KgL3MUjujTywciqQ2aQXjGj0OtopUH4/oTeFARanc3C0xn4rQbNihBZzfIk9YJY= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1712070017; c=relaxed/simple; bh=XC/KIBuVWENi+nZcHSHtH5poqdXkQwX6utx5Af8jDo4=; h=From:To:Cc:Subject:Date:Message-Id:In-Reply-To:References: MIME-Version; b=jJbmhSEHp0xM+leAJqzjAzmDOvgCX96Rwy3JUU8RjpwWIf/IXBFXaj8gfIPQtFlFzWUTaInvSxHd2GHzQiQEpLl0xB/dZMeM0AMFxhA8AX0p4DPrYt1yoSxFLetV8QWeEcE2ozTaefl1r7Gr6XQ/x02HpzC0NfbXyaVVTQE8W+o= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linux.intel.com; spf=none smtp.mailfrom=linux.intel.com; dkim=pass (2048-bit key) header.d=intel.com header.i=@intel.com header.b=imlkZ8Wz; arc=none smtp.client-ip=192.198.163.15 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linux.intel.com Authentication-Results: smtp.subspace.kernel.org; spf=none smtp.mailfrom=linux.intel.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=intel.com header.i=@intel.com header.b="imlkZ8Wz" DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1712070015; x=1743606015; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=XC/KIBuVWENi+nZcHSHtH5poqdXkQwX6utx5Af8jDo4=; b=imlkZ8WzQEuoV9+FrraBwkaXhXedqEJaQCt7O9v3zpKUHHJPQI5m3Vnd fANjkc4boiNumz79vv3RB6w7Fk0tvqQrKcvuFGPAZ3zOmYBUyHboQuQcQ jUEc0bZsOsDDCqnvpIWN9lSrvXZFFWMSj+KwIt3oYu2Gi5KIRpRqcFCMX Ybq8ULzTusobKsU3DZJrXl9rBXmwTnt78NKUfAbC2jq/0ti+MM/v8Nh4y CkrmeRicdHpsaAOc9vHa/vJGtSeaJOD3erIn2N0UvRL64a9KQZZNiSA2u vjbga47BFTG8WWqRFfHDXtysHWr4eY0v10m13DV67cDuk2keGsoKOLgHY A==; X-CSE-ConnectionGUID: BCY1pxFZRA+64x6Pds4nHw== X-CSE-MsgGUID: FHYu+KBdSvCw0axwnGMTGg== X-IronPort-AV: E=McAfee;i="6600,9927,11032"; a="7433834" X-IronPort-AV: E=Sophos;i="6.07,175,1708416000"; d="scan'208";a="7433834" Received: from fmviesa003.fm.intel.com ([10.60.135.143]) by fmvoesa109.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 02 Apr 2024 08:00:13 -0700 X-CSE-ConnectionGUID: 7E16P8RbQUSCSgoWUteSSw== X-CSE-MsgGUID: GOPdG6s1RlyM+OvXzqjG8g== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="6.07,175,1708416000"; d="scan'208";a="22558031" Received: from skhare-mobl5.amr.corp.intel.com (HELO pbossart-mobl6.intel.com) ([10.212.8.83]) by fmviesa003-auth.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 02 Apr 2024 08:00:14 -0700 From: Pierre-Louis Bossart To: linux-sound@vger.kernel.org Cc: alsa-devel@alsa-project.org, tiwai@suse.de, broonie@kernel.org, Pierre-Louis Bossart , Bard Liao Subject: [PATCH 4/4] ASoC: SOF: ipc4-topology: remove shadowed variable Date: Tue, 2 Apr 2024 09:59:59 -0500 Message-Id: <20240402145959.172619-5-pierre-louis.bossart@linux.intel.com> X-Mailer: git-send-email 2.40.1 In-Reply-To: <20240402145959.172619-1-pierre-louis.bossart@linux.intel.com> References: <20240402145959.172619-1-pierre-louis.bossart@linux.intel.com> Precedence: bulk X-Mailing-List: linux-sound@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Cppcheck reports this: sound/soc/sof/ipc4-topology.c:569:23: style: Local variable 'sdev' shadows outer variable [shadowVariable] struct snd_sof_dev *sdev = snd_soc_component_get_drvdata(scomp); ^ sound/soc/sof/ipc4-topology.c:512:22: note: Shadowed declaration struct snd_sof_dev *sdev = snd_soc_component_get_drvdata(scomp); ^ sound/soc/sof/ipc4-topology.c:569:23: note: Shadow variable struct snd_sof_dev *sdev = snd_soc_component_get_drvdata(scomp); ^ Remove shadowed variable. Signed-off-by: Pierre-Louis Bossart Reviewed-by: Bard Liao --- sound/soc/sof/ipc4-topology.c | 1 - 1 file changed, 1 deletion(-) diff --git a/sound/soc/sof/ipc4-topology.c b/sound/soc/sof/ipc4-topology.c index 5cca05842126..427f186ddc11 100644 --- a/sound/soc/sof/ipc4-topology.c +++ b/sound/soc/sof/ipc4-topology.c @@ -586,7 +586,6 @@ static int sof_ipc4_widget_setup_comp_dai(struct snd_sof_widget *swidget) switch (ipc4_copier->dai_type) { case SOF_DAI_INTEL_ALH: { - struct snd_sof_dev *sdev = snd_soc_component_get_drvdata(scomp); struct sof_ipc4_alh_configuration_blob *blob; struct snd_soc_dapm_path *p; struct snd_sof_widget *w;