Received: by 2002:a05:7412:f690:b0:e2:908c:2ebd with SMTP id ej16csp236000rdb; Thu, 19 Oct 2023 03:03:11 -0700 (PDT) X-Google-Smtp-Source: AGHT+IGmSz9d9xQyFaFzJwAzipv2IlLkhfWcW9rM70SriVbA1NQkhi2aTpAX5t28RcrlwFIsr7Vn X-Received: by 2002:a05:6a21:18e:b0:154:bfaf:a710 with SMTP id le14-20020a056a21018e00b00154bfafa710mr2196535pzb.41.1697709790776; Thu, 19 Oct 2023 03:03:10 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1697709790; cv=none; d=google.com; s=arc-20160816; b=pKtKEu/HhozaNW5iUxBhTpnulxnIrxd6Bp0c7Wrw9OmnuCJdBBLUoOpRRkzhGBAnt9 53VmC/S8iqsvsD6iCYmeL25CEx9OKS4ZYFvik0B0l/lRJP34FaBEvSU6zIfpGX1rBx6Z EQF4OjvuIsXjvJZmnKlERZLw6yBhffwwbmCT8f1uBhhxbZ2oGNUmcMkbZRZv4YdmX+C3 FjXmCIozetOo71AME0enFE5LE5ugu3naiAV2jifrDOnli7UeMCs+sNhMTEjZtujvnud2 qx+4ly41kQDKo6PGkV+gEWmshSZHvCs3nrnvm9LhZJ1jmbRVOx+3nUlNU6kyK74ZkIkP U5uQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:in-reply-to:from :references:cc:to:content-language:subject:user-agent:mime-version :date:message-id:dkim-signature; bh=i9v+Vy7caFvivgOF/oUuFJCYcoz6P5Q0OzSJeYOGnHY=; fh=DJMVPrO6usvvCyLV/laoOU6FQSpvyda92VOlSSx928c=; b=RlLb70ZPix0Mi6rKHjZIEt5WPJ3wQOzwqLvlcDbhRymoaqyRnSx/V1OyFCTnsgVF6B U775v60OWia6hUUqUELf5hQxSe0wAVod+oIpbfZX925LDih8jhRGg9n7N//cZ6i6CW3z 1+EOsEy1zr1vBFNKwezEfks5Y1zHl31KE+JZcqtSZ+kYI6wZAkVEYP9U82W7WytITXGV Sstbd4Nokr5V08ii+iy7Y+EgvT03IOnRkRiSXIOtcpbgQD8u7DxVyuQoxr6H2/t93vKP FcEjXma5w2pZZ9ffPJZvdIebUn0aOLTvBVbHUCJD8QLuovnwcmQ+EMCCKBJ1FC2oJSrr NpfQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@intel.com header.s=Intel header.b=BTOQSu3n; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.37 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=intel.com Return-Path: Received: from snail.vger.email (snail.vger.email. [23.128.96.37]) by mx.google.com with ESMTPS id z16-20020a656650000000b005ab776a4d4csi3888569pgv.610.2023.10.19.03.03.10 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 19 Oct 2023 03:03:10 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.37 as permitted sender) client-ip=23.128.96.37; Authentication-Results: mx.google.com; dkim=pass header.i=@intel.com header.s=Intel header.b=BTOQSu3n; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.37 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=intel.com Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by snail.vger.email (Postfix) with ESMTP id A538F80EE0F9; Thu, 19 Oct 2023 03:03:08 -0700 (PDT) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.10 at snail.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1345155AbjJSKDH (ORCPT + 99 others); Thu, 19 Oct 2023 06:03:07 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:53268 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1345039AbjJSKDF (ORCPT ); Thu, 19 Oct 2023 06:03:05 -0400 Received: from mgamail.intel.com (mgamail.intel.com [192.55.52.93]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 32519B8 for ; Thu, 19 Oct 2023 03:03:04 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1697709784; x=1729245784; h=message-id:date:mime-version:subject:to:cc:references: from:in-reply-to:content-transfer-encoding; bh=SgyKtQrLkgS4addmbJXnuxPILcTy9f7NSRs4ptqNYWI=; b=BTOQSu3nJW2OSbHU8MuhYgYODX4clJtgLlwEaGgbhwch6gD8zvpF2re2 9nwLI1tWv3ac7GGyDiFsWQJMShkkxY/xTv44Q5FxlT59hA7vUG/StpCbh 8LQ+565BpKddQULjxVwu6Lksl8czYYbwBHBPVU5RvqCD/BAsVzGAj+qbq EnQ6LvbhQf9VDBDVRQd68SaYOoxNy3FEx04dgM0R71v1KRMG3QmGuLU+b GqUsLJA5BePmi5bgbMnySxCfex/OwYuTNn3srl1jAFmnU/K/RLEqZw4e6 hl9/n1yJiXP/+R8YYoftd1AoykwYOpV56Pri9zRF5AgkmRLF28XkgF0aO g==; X-IronPort-AV: E=McAfee;i="6600,9927,10867"; a="383438221" X-IronPort-AV: E=Sophos;i="6.03,236,1694761200"; d="scan'208";a="383438221" Received: from fmsmga007.fm.intel.com ([10.253.24.52]) by fmsmga102.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 19 Oct 2023 03:03:03 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=McAfee;i="6600,9927,10867"; a="760588908" X-IronPort-AV: E=Sophos;i="6.03,236,1694761200"; d="scan'208";a="760588908" Received: from kinstrum-mobl.ger.corp.intel.com (HELO [10.249.254.120]) ([10.249.254.120]) by fmsmga007-auth.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 19 Oct 2023 03:02:58 -0700 Message-ID: Date: Thu, 19 Oct 2023 12:02:55 +0200 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: [PATCH v7 01/13] ASoC: SOF: core: Ensure sof_ops_free() is still called when probe never ran. Content-Language: en-US To: Takashi Iwai Cc: alsa-devel@alsa-project.org, Jaroslav Kysela , Takashi Iwai , Cezary Rojewski , Pierre-Louis Bossart , Liam Girdwood , Peter Ujfalusi , Bard Liao , Ranjani Sridharan , Kai Vehmanen , Mark Brown , Daniel Baluta , linux-kernel@vger.kernel.org, sound-open-firmware@alsa-project.org References: <20231009115437.99976-1-maarten.lankhorst@linux.intel.com> <20231009115437.99976-2-maarten.lankhorst@linux.intel.com> <87il7aopcy.wl-tiwai@suse.de> From: Maarten Lankhorst In-Reply-To: <87il7aopcy.wl-tiwai@suse.de> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-4.3 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_EF,RCVD_IN_DNSWL_MED,SPF_HELO_NONE, SPF_NONE,URIBL_BLOCKED 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 X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (snail.vger.email [0.0.0.0]); Thu, 19 Oct 2023 03:03:08 -0700 (PDT) Hey, Den 2023-10-13 kl. 11:15, skrev Takashi Iwai: > On Mon, 09 Oct 2023 13:54:25 +0200, > Maarten Lankhorst wrote: >> In an effort to not call sof_ops_free twice, we stopped running it when >> probe was aborted. >> >> Check the result of cancel_work_sync to see if this was the case. >> >> Fixes: 31bb7bd9ffee ("ASoC: SOF: core: Only call sof_ops_free() on remove if the probe was successful") >> Cc: Peter Ujfalusi >> Acked-by: Mark Brown > Your Signed-off-by tag is missing. > > Could you resubmit? > > > thanks, > > Takashi I missed this email apparently. Signed-off-by: Maarten Lankhorst Is this enough for the tooling, or do you need an actual resubmit? Cheers, ~Maarten > >> --- >> sound/soc/sof/core.c | 6 +++++- >> 1 file changed, 5 insertions(+), 1 deletion(-) >> >> diff --git a/sound/soc/sof/core.c b/sound/soc/sof/core.c >> index 2d1616b81485c..0938b259f7034 100644 >> --- a/sound/soc/sof/core.c >> +++ b/sound/soc/sof/core.c >> @@ -459,9 +459,10 @@ int snd_sof_device_remove(struct device *dev) >> struct snd_sof_dev *sdev = dev_get_drvdata(dev); >> struct snd_sof_pdata *pdata = sdev->pdata; >> int ret; >> + bool aborted = false; >> >> if (IS_ENABLED(CONFIG_SND_SOC_SOF_PROBE_WORK_QUEUE)) >> - cancel_work_sync(&sdev->probe_work); >> + aborted = cancel_work_sync(&sdev->probe_work); >> >> /* >> * Unregister any registered client device first before IPC and debugfs >> @@ -487,6 +488,9 @@ int snd_sof_device_remove(struct device *dev) >> snd_sof_free_debug(sdev); >> snd_sof_remove(sdev); >> sof_ops_free(sdev); >> + } else if (aborted) { >> + /* probe_work never ran */ >> + sof_ops_free(sdev); >> } >> >> /* release firmware */ >> -- >> 2.39.2 >>