Received: by 2002:ab2:6991:0:b0:1f7:f6c3:9cb1 with SMTP id v17csp737666lqo; Wed, 8 May 2024 13:17:15 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCVHdzp2fi5fPdWSEco1z9Apf/xpUYAc5BLKU++60pGxVmUjMnV8XkOoJTc9NT4DMpa0Vf7Y3RakScqu1aWSpZBO//RypsWFsplYA+SwuA== X-Google-Smtp-Source: AGHT+IHcCB8Df93AodBlpBKAzWRvie3OZPcFoh70Kcjv9yEpaJLJhuoVwbtGuI3qYxUXI6E4VNb9 X-Received: by 2002:aca:b05:0:b0:3c9:779f:6c5e with SMTP id 5614622812f47-3c985298406mr4147764b6e.4.1715199435143; Wed, 08 May 2024 13:17:15 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1715199435; cv=pass; d=google.com; s=arc-20160816; b=WjJXv5/t3jExBWXmZ5fmBruf7DxdSIcl8SEyzMSMbD+W83SKCvdsFSHRXZt49lrUWZ Fppw7aF2gYo0fgv1fSpDb9+v+KttZV5346IfuXqf/COZBzmAsYd/8jcsd+sBF9Hx941q SJtE5CY5hA84qarK7W2j52dc4LXZY3lpXGKzQuj77iiCe4EF0CBOFDFuqsEQHoVDhvhu EkiVYfNIH20e4nXQBqztzoxxsQcPHXxPMT0ixZwzmCvpdG1HLChnrwMQUKlHgue1EJkC 2edgScMBIQ4NZak3uD0D23qx5ETvdmqFyxL5D63b7ssJc0ezhMlHxKEF1dB1MpIys/tb 5xCQ== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:in-reply-to:from:references:cc:to :content-language:subject:user-agent:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:date:message-id:dkim-signature; bh=/h/CzWxCJAWdECYePSx/kcEaFq6W4rE/eXk8NJV+0HY=; fh=iRZivtppW/TNTAfzyCFB4Ao7jKoLfwnwVSfzppsNZsY=; b=j6rS1WNPhkDSKJaDTutFjh/jCL/UsQlyiI74UE8xsDt//2XU72zms7jgt7ER7cxDNY WFy7sS+sHIlzYEwocVDRgfwHgdWZOjyUz/BDBmE1j+pJXTZX3WG6Wb4+D/6I5ZsdiN+6 wkjv0hHvV9Lm5gkF6y2sH/roY8F+/bWMgdZK89NcV2PCXsF/pDEyEUFTMQ+H2D3pE4QO kKh7pOp00BQ91WN1DYwJyFRrCclfubXu6wbg6M43yjv7SPiZMbAcS8lIPqRcLRyIgNN1 hFSzEut4kipkNd6YbAmpVmvAHeylt6201rdOYVUtHvH2P+si82IGu5LKot2E1gf5ejoz 9bYA==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@quicinc.com header.s=qcppdkim1 header.b=G3CeZyZ4; arc=pass (i=1 spf=pass spfdomain=quicinc.com dkim=pass dkdomain=quicinc.com dmarc=pass fromdomain=quicinc.com); spf=pass (google.com: domain of linux-kernel+bounces-173793-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-173793-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=quicinc.com Return-Path: Received: from ny.mirrors.kernel.org (ny.mirrors.kernel.org. [2604:1380:45d1:ec00::1]) by mx.google.com with ESMTPS id c17-20020ac85a91000000b0043a0f588a2dsi15253903qtc.487.2024.05.08.13.17.14 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 08 May 2024 13:17:15 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-173793-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) client-ip=2604:1380:45d1:ec00::1; Authentication-Results: mx.google.com; dkim=pass header.i=@quicinc.com header.s=qcppdkim1 header.b=G3CeZyZ4; arc=pass (i=1 spf=pass spfdomain=quicinc.com dkim=pass dkdomain=quicinc.com dmarc=pass fromdomain=quicinc.com); spf=pass (google.com: domain of linux-kernel+bounces-173793-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-173793-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=quicinc.com Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ny.mirrors.kernel.org (Postfix) with ESMTPS id D957A1C21060 for ; Wed, 8 May 2024 20:17:14 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id EC1C7130E33; Wed, 8 May 2024 20:17:02 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=quicinc.com header.i=@quicinc.com header.b="G3CeZyZ4" Received: from mx0b-0031df01.pphosted.com (mx0b-0031df01.pphosted.com [205.220.180.131]) (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 A969A130A63; Wed, 8 May 2024 20:17:00 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=205.220.180.131 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1715199422; cv=none; b=ajGpBYv1o62XaWDvovitHCvJ08ZeT8dVioa1lH2u8qcTRMFNGfCCLK3Lr6jFdHFepPWPpI6FCMthHwDkDNBucR53I0TfnMd98lixzpEMc0nCttIPXAO7+eWwDqqc+iTQjKslZ7AkoqDkhacpKLXV5z9gkEfdMNIScmuXiQvkrIA= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1715199422; c=relaxed/simple; bh=U09Rnr9ntnBO7MwvNoJCHqyP9+H/89CU40V7dG6FWYM=; h=Message-ID:Date:MIME-Version:Subject:To:CC:References:From: In-Reply-To:Content-Type; b=dT+VK+sWJvRGD0GJo9mY4tL0TN2L6YPen4AICLvg7hFWcrMw8AOVqwMHkM0My3skr/qKyGCL6XThUbHkOFoucdklrO4OOmsWuIAxVR7C/etilZq5PJv4kkCCnOP3FbSW/3G2e0jEatTe2K51Tn5ZSDMuCiQpD3BAk7BmtsXffWg= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=quicinc.com; spf=pass smtp.mailfrom=quicinc.com; dkim=pass (2048-bit key) header.d=quicinc.com header.i=@quicinc.com header.b=G3CeZyZ4; arc=none smtp.client-ip=205.220.180.131 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=quicinc.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=quicinc.com Received: from pps.filterd (m0279868.ppops.net [127.0.0.1]) by mx0a-0031df01.pphosted.com (8.18.1.2/8.18.1.2) with ESMTP id 448Ae8bk004926; Wed, 8 May 2024 20:16:41 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=quicinc.com; h= message-id:date:mime-version:subject:to:cc:references:from :in-reply-to:content-type:content-transfer-encoding; s= qcppdkim1; bh=/h/CzWxCJAWdECYePSx/kcEaFq6W4rE/eXk8NJV+0HY=; b=G3 CeZyZ4ePRk73R5cwnSmeBM0urCxyVcmWeyXqhE8ksxx8PFJfRosXjZCP+ZyMToPN uNqBaQVN5NKDYn1Dfoxe6mKwRQYhcJit7YwGf0fDPpfUVCAEWutXU2pYwv7fXVo1 GCpYVr/RvAJv72ihoMCpzkzPYc62Z9OHZMoQafRrIv/K40lutuUFCvNN5Ek8cuoW jbTh2fT7eTfHETpiR0Ubw7N9LetZy5ZU4w1/Lnm3GrS9UO13cuTMDMyC+h+5e6uL PwiYxnkOw4+sNSb2BUjPYJazkYjT1xstgNZFALufEONUoZ5sWvfiemtT0iKE8l3w OfadCVyIIsNml6LKrMVQ== Received: from nalasppmta04.qualcomm.com (Global_NAT1.qualcomm.com [129.46.96.20]) by mx0a-0031df01.pphosted.com (PPS) with ESMTPS id 3y07u999yg-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Wed, 08 May 2024 20:16:40 +0000 (GMT) Received: from nalasex01b.na.qualcomm.com (nalasex01b.na.qualcomm.com [10.47.209.197]) by NALASPPMTA04.qualcomm.com (8.17.1.5/8.17.1.5) with ESMTPS id 448KGdbW007663 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Wed, 8 May 2024 20:16:39 GMT Received: from [10.110.126.205] (10.80.80.8) by nalasex01b.na.qualcomm.com (10.47.209.197) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.1544.9; Wed, 8 May 2024 13:16:38 -0700 Message-ID: <106711dc-0250-4d07-254d-2829f89e0a5d@quicinc.com> Date: Wed, 8 May 2024 13:16:38 -0700 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:102.0) Gecko/20100101 Thunderbird/102.15.1 Subject: Re: [PATCH v21 07/39] ASoC: Add SOC USB APIs for adding an USB backend Content-Language: en-US To: Pierre-Louis Bossart , , , , , , , , , , , , , , , , CC: , , , , , , References: <20240507195116.9464-1-quic_wcheng@quicinc.com> <20240507195116.9464-8-quic_wcheng@quicinc.com> <507953f7-c4da-499b-bcd7-76be0e04b766@linux.intel.com> From: Wesley Cheng In-Reply-To: <507953f7-c4da-499b-bcd7-76be0e04b766@linux.intel.com> Content-Type: text/plain; charset="UTF-8"; format=flowed Content-Transfer-Encoding: 7bit X-ClientProxiedBy: nasanex01b.na.qualcomm.com (10.46.141.250) To nalasex01b.na.qualcomm.com (10.47.209.197) X-QCInternal: smtphost X-Proofpoint-Virus-Version: vendor=nai engine=6200 definitions=5800 signatures=585085 X-Proofpoint-GUID: RJxVdkI85z4HvNEsdpbVz7wQbcrOhP3J X-Proofpoint-ORIG-GUID: RJxVdkI85z4HvNEsdpbVz7wQbcrOhP3J X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.293,Aquarius:18.0.1039,Hydra:6.0.650,FMLib:17.11.176.26 definitions=2024-05-08_09,2024-05-08_01,2023-05-22_02 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 clxscore=1015 adultscore=0 spamscore=0 suspectscore=0 mlxlogscore=999 impostorscore=0 mlxscore=0 lowpriorityscore=0 bulkscore=0 malwarescore=0 phishscore=0 priorityscore=1501 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.19.0-2405010000 definitions=main-2405080149 Hi Pierre, On 5/7/2024 1:26 PM, Pierre-Louis Bossart wrote: > >> +const char *snd_soc_usb_get_components_tag(bool playback) >> +{ >> + if (playback) >> + return "usbplaybackoffload: 1"; >> + else >> + return "usbcaptureoffload : 1"; > > why are there different spaces and do we need spaces in the first place? > Will remove these spaces once we clarify if this is still needed. >> +int snd_soc_usb_add_port(struct snd_soc_usb *usb) >> +{ >> + mutex_lock(&ctx_mutex); >> + list_add_tail(&usb->list, &usb_ctx_list); >> + mutex_unlock(&ctx_mutex); >> + >> + return 0; > > make the function return void? > Ack. >> +int snd_soc_usb_remove_port(struct snd_soc_usb *usb) >> +{ >> + struct snd_soc_usb *ctx, *tmp; >> + >> + mutex_lock(&ctx_mutex); >> + list_for_each_entry_safe(ctx, tmp, &usb_ctx_list, list) { >> + if (ctx == usb) { >> + list_del(&ctx->list); >> + break; >> + } >> + } >> + mutex_unlock(&ctx_mutex); >> + >> + return 0; > > make this return void? > > Ack. Thanks Wesley Cheng