Received: by 2002:a05:6358:a55:b0:ec:fcf4:3ecf with SMTP id 21csp703784rwb; Fri, 13 Jan 2023 03:14:18 -0800 (PST) X-Google-Smtp-Source: AMrXdXuLe0K51qlGhJYIH9hDbXCzg/QSvM52mbVGSRX3EHiuwnuhc8+nGY6TB7cA+oCwoS/JxtPm X-Received: by 2002:a17:902:eb4b:b0:194:623e:f401 with SMTP id i11-20020a170902eb4b00b00194623ef401mr5054883pli.8.1673608457978; Fri, 13 Jan 2023 03:14:17 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1673608457; cv=none; d=google.com; s=arc-20160816; b=kk6RS0PoWL7ydBo8yA04RmvwudC7km2fcDs1xD6aefrvUCfjlmtuj782fxw5Gt2Jou ZmClBAYHXNpJXykobzT4EbT1NuT9FqL94pOpnvF2mE2AMF0u9GVFLjkTN6HccZSnuFla 4n0pUNTuaO/7u/VIkosSSim6FqoL1AMqrsS6RdM/mLLzZotg3ebC4qilAexgSo4cX3BT SIx11WZPL6d2f9D0g1Z/Jxqn2Xo3fROH7McOoZLCI3xf0W6wStDFORaFtpUrl+VIR6NT /qTwP076agAF02KdFjPicGQ65LQUyXhDpsQUz+u7atJ4IAR/NDj2wNVuuiqDNcyWsT7T HnPQ== 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=XC089RbzIWG/G+D3fxDE+8JK2pHHFQ8zOqK0gr9iK6o=; b=VIcadVB+N6xSn0WC8lAoUIyjhfXHSDTKizyTUWS0RjzdHfJzJ4PJmHMmEGwBqAymfv QhGWAFYDPjo3q3XaTmvQX9ljjszMSG+jGVKwq7qR4t8R+YWBJh6Z4zc0AUlwAYTxbX1z wuoBHzDDpyzx2sZMnTinVyjqlc8KQDOuR3x9bE+EhN/lYsyF1Jk5+ddb7neU2Snh3NeS JEugzIa+wMO63vtK9kgD5hIUGzmOvm0rt9BP96ECMfRPYe9S4pQ/NJbKvDfQaCbIZ1sl 0Uzdq/xoQzN1WwTApbie06kc9pwYgEiqXQ2YknBy3nXDAyeJR6EGiL/x1tnrEa3dvL+2 lOQg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@intel.com header.s=Intel header.b=jlUoylVA; 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=NONE dis=NONE) header.from=intel.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id w9-20020a170902904900b001932b1fb0cbsi14481369plz.435.2023.01.13.03.14.11; Fri, 13 Jan 2023 03:14:17 -0800 (PST) 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=@intel.com header.s=Intel header.b=jlUoylVA; 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=NONE dis=NONE) header.from=intel.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S240996AbjAMKXa (ORCPT + 51 others); Fri, 13 Jan 2023 05:23:30 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:57848 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S241024AbjAMKW7 (ORCPT ); Fri, 13 Jan 2023 05:22:59 -0500 Received: from mga14.intel.com (mga14.intel.com [192.55.52.115]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id C25BE1788F for ; Fri, 13 Jan 2023 02:22:46 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1673605366; x=1705141366; h=message-id:date:mime-version:subject:to:cc:references: from:in-reply-to:content-transfer-encoding; bh=CDcpGc14MxwljMRrNGGaJzjMrvUpcw8OYXg9rqQznUQ=; b=jlUoylVARX8BXNVQfSrQBU9qkKD6NzTVLKuZwVhDCzLdhj9Bk9xkhDWE 8GzM/75eI1ET83xYDp5L9iFaXHbu8EZlmAtvSQeSRp+zCzTQfi44q1Dal O4HwExhxFEkPJ68dT+zg6UV9uU8MK7INI+UZowLD+J+CHrDW4mLP27Ztl qEmSR1w8wf5p08B14zYMDP94fBj0oTVJ+4fTAPHI7iO20l2Cfdy4jErvE /1ijIz3jJ5uHQO2QNWQ6xNnl9G1gfPCpKeRqOnuB8YEP+Diuw3uAktMft iTvK1i0rquBUSff9X4k5eKhavEuTRo9TGxvCwvUqq+X66yj3/RNy6GKkD Q==; X-IronPort-AV: E=McAfee;i="6500,9779,10588"; a="324024194" X-IronPort-AV: E=Sophos;i="5.97,213,1669104000"; d="scan'208";a="324024194" Received: from fmsmga008.fm.intel.com ([10.253.24.58]) by fmsmga103.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 13 Jan 2023 02:22:34 -0800 X-IronPort-AV: E=McAfee;i="6500,9779,10588"; a="721473464" X-IronPort-AV: E=Sophos;i="5.97,213,1669104000"; d="scan'208";a="721473464" Received: from aslawinx-mobl.ger.corp.intel.com (HELO [10.99.16.144]) ([10.99.16.144]) by fmsmga008-auth.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 13 Jan 2023 02:22:32 -0800 Message-ID: Date: Fri, 13 Jan 2023 11:22:30 +0100 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:102.0) Gecko/20100101 Thunderbird/102.6.1 Subject: Re: [PATCH 1/5] soundwire: stream: uniquify dev_err() logs Content-Language: en-US To: Bard Liao , alsa-devel@alsa-project.org, vkoul@kernel.org Cc: pierre-louis.bossart@linux.intel.com, vinod.koul@linaro.org, bard.liao@intel.com, linux-kernel@vger.kernel.org References: <20230113093532.3872113-1-yung-chuan.liao@linux.intel.com> <20230113093532.3872113-2-yung-chuan.liao@linux.intel.com> From: =?UTF-8?Q?Amadeusz_S=c5=82awi=c5=84ski?= In-Reply-To: <20230113093532.3872113-2-yung-chuan.liao@linux.intel.com> 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,NICE_REPLY_A,RCVD_IN_DNSWL_MED, SPF_HELO_NONE,SPF_NONE 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 On 1/13/2023 10:35 AM, Bard Liao wrote: > From: Pierre-Louis Bossart > > There are a couple of duplicate logs which makes harder than needed to > follow the error flows. Add __func__ or make the log unique. > > Signed-off-by: Pierre-Louis Bossart > Reviewed-by: Ranjani Sridharan > Signed-off-by: Bard Liao > --- > drivers/soundwire/stream.c | 14 ++++++++------ > 1 file changed, 8 insertions(+), 6 deletions(-) > > diff --git a/drivers/soundwire/stream.c b/drivers/soundwire/stream.c > index df3b36670df4..e0eae0b98267 100644 > --- a/drivers/soundwire/stream.c > +++ b/drivers/soundwire/stream.c > @@ -1389,7 +1389,7 @@ static int _sdw_prepare_stream(struct sdw_stream_runtime *stream, > > ret = do_bank_switch(stream); > if (ret < 0) { > - dev_err(bus->dev, "Bank switch failed: %d\n", ret); > + dev_err(bus->dev, "do_bank_switch failed: %d\n", ret); > goto restore_params; > } This one seems bit unrelated to the change and makes error message inconsistent with: https://git.kernel.org/pub/scm/linux/kernel/git/vkoul/soundwire.git/tree/drivers/soundwire/stream.c?h=next&id=545c365185a47672b1d5cc13c84057a1e874993c#n1498 and https://git.kernel.org/pub/scm/linux/kernel/git/vkoul/soundwire.git/tree/drivers/soundwire/stream.c?h=next&id=545c365185a47672b1d5cc13c84057a1e874993c#n1575 which actually brings me to another suggestion, can this error message perhaps be just moved into do_bank_switch() function itself, instead of being duplicated multiple times or alternatively just also prefix all of them with function name?