Received: by 2002:a89:48b:0:b0:1f5:f2ab:c469 with SMTP id a11csp1291729lqd; Thu, 25 Apr 2024 10:54:56 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCUhEyStxIWHfQXNTbRqrQidd/nObGuU10wLQ0RuqZ2z5tkEhggI6sCr35/2PBlg/Ky7+xFa5Af5galsZvFLcvs1GqQ+TG8LmVMWcVX3Pg== X-Google-Smtp-Source: AGHT+IHa7lS4y+ZFF5V/NgRAsDyLA6J/q71JkyNlAq02MDEJk/Pjz51Je78UWnEvMUfwIfWseVsU X-Received: by 2002:a17:90b:3911:b0:2a5:3367:604b with SMTP id ob17-20020a17090b391100b002a53367604bmr695228pjb.19.1714067696480; Thu, 25 Apr 2024 10:54:56 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1714067696; cv=pass; d=google.com; s=arc-20160816; b=0v+3o7wPlZRY58xwX/NulKqAYQ1yfRTfJjEw9VqItR2680/qTxpZOq4NI9Akpl+u/C dpHAfn8y27cgOM+QInWKjSV62X2oVEUFLleUCddb0XeTbfULn66tTyMA7cuw2MYzx5dD HxiCgscAWMHRQGDaoWzVkEcSZUMGCQXw6fVeZVvVx6DJWnpVhKULMzUB8FumK9bbHxlL 7hy182EEf7xyR2UOJeImnb0FTPf/T2R9m4pUz2rvtkbsfabXSfmx+eZOJUSez6cut82V CTB6EAfPgslbw7B4QGMDVrECjTeB4LzU/feJEsPc6f0LGSpVMdI5v7Hs33A7Bfip95Of CYnw== 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:content-language :references:cc:to:subject:user-agent:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:date:message-id:dkim-signature; bh=z1kO/GAocp76n8+huMkaZrDI++s3deccZ1b5L8uylCE=; fh=1n9QfWRtGkTuhhbOVBlxivZiqKXTCZ4PDcbNAA+dqjA=; b=oZbxZdSYlGoQqUdeprTWA8Sq3fAeKWyVwmB7+ocOaZcDVdqqXwtEQ0j7X/TE1qMcnT psdzqAMK/CFmLCuXjDT3jDJdho1WGMWrKXyAmPRVmRzV6t4KOnyYGHz7m1BghH8jCAYb fUfDc4ZNbE8unNmrGAwXXzOIWGrD8/BtdGX96ccsSPaprQDammTnGzhr9UiHkCmI72l6 /Eo9dS5BMRhsc1s+qlLpqHwGONmOUiHIPEqOYbLrso/0CUcQOwiEqAyylxwXs99gth8N 8CUeSaIrgZaa4YflNDVOtxzcDo/zf6azjZTIhClhRaZtxB2pw/gJ2UYuHUkPD81iFlij 42YQ==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@intel.com header.s=Intel header.b=hW2IKNrm; arc=pass (i=1 dkim=pass dkdomain=intel.com dmarc=pass fromdomain=linux.intel.com); spf=pass (google.com: domain of linux-kernel+bounces-158618-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) smtp.mailfrom="linux-kernel+bounces-158618-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=intel.com Return-Path: Received: from sy.mirrors.kernel.org (sy.mirrors.kernel.org. [147.75.48.161]) by mx.google.com with ESMTPS id iq16-20020a17090afb5000b002adedc2eba8si7433036pjb.160.2024.04.25.10.54.55 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 25 Apr 2024 10:54:56 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-158618-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) client-ip=147.75.48.161; Authentication-Results: mx.google.com; dkim=pass header.i=@intel.com header.s=Intel header.b=hW2IKNrm; arc=pass (i=1 dkim=pass dkdomain=intel.com dmarc=pass fromdomain=linux.intel.com); spf=pass (google.com: domain of linux-kernel+bounces-158618-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) smtp.mailfrom="linux-kernel+bounces-158618-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=intel.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 sy.mirrors.kernel.org (Postfix) with ESMTPS id E0A56B24707 for ; Thu, 25 Apr 2024 13:44:39 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 96D91149E0F; Thu, 25 Apr 2024 13:44:16 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=intel.com header.i=@intel.com header.b="hW2IKNrm" Received: from mgamail.intel.com (mgamail.intel.com [192.198.163.18]) (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 AD2CC149DE9; Thu, 25 Apr 2024 13:44:13 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=192.198.163.18 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1714052655; cv=none; b=FKuO+b5T0ikJhYyS0p3SoC6LGOIpH91mIYVTlxbgYkZnseypCG77XmgisEn3oyinuKNj9BtZyDAOpAgUrADh6XqDpWgG6sTY3mFwN9KKOCKThpwc9f0tzrVJvyH10UkvYDLnIlw7KE94N5ZLWxQym9WyY0ZjJbXywNphTeTmaqc= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1714052655; c=relaxed/simple; bh=sevXQPHqwt+0Ww7Ab9Mk8uFLSxt6KOf9Ig3smUYioLc=; h=Message-ID:Date:MIME-Version:Subject:To:Cc:References:From: In-Reply-To:Content-Type; b=YINRKJnckh3veK/aW7alfPojaW50ieI0N0Z4T4I/xaxP/UzlUK9bHNpohnUhB41hHn/3GbNcugEOlUEs9uprc0hNVezCLYlWI44Y3RL6dk8NGDsRkCf6LBX3LZfzYYk9kNKEKtH+KGo8g9cfmMUnkPCkLTgGWT8solKMOjVi2jU= 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=hW2IKNrm; arc=none smtp.client-ip=192.198.163.18 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 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1714052654; x=1745588654; h=message-id:date:mime-version:subject:to:cc:references: from:in-reply-to:content-transfer-encoding; bh=sevXQPHqwt+0Ww7Ab9Mk8uFLSxt6KOf9Ig3smUYioLc=; b=hW2IKNrmAL43jO5tc892Tml9io+6se4xF3gpOR50e3k3wGUukp1CSCJG CcJTK3PtHeKR9PCxqYlp+Pr3WPZSjd7P8tIUx7aR9x9y+5S+GxJ612oee NWnnvVYZwynouoEM0B1PpDNXoM8YvVNLL4PqU0o4lvGoZrNHtOcSGvL2x ePQZITJT/bOcU1IDl6Otnnj4Ygw478fauIb7/sNWV+5sS6NS1NrILSlOI dQK4GtToslDuFczXxjp6hpn57L47EXDINybb5Wo8UNisu3JDo0s55Ja+A wNh1FpBcaPgQPXecxF1ntsoCRjiEeA8kAtqWlatDw0VMITSmDOFsGvxmb Q==; X-CSE-ConnectionGUID: M7HVa8i8QQ6IIdJWx2Asgg== X-CSE-MsgGUID: +LlEjvW1QHS1GFfI7TAIiw== X-IronPort-AV: E=McAfee;i="6600,9927,11054"; a="9587385" X-IronPort-AV: E=Sophos;i="6.07,229,1708416000"; d="scan'208";a="9587385" Received: from orviesa007.jf.intel.com ([10.64.159.147]) by fmvoesa112.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 25 Apr 2024 06:44:13 -0700 X-CSE-ConnectionGUID: 7OVoDDweRre70A69GO9ozQ== X-CSE-MsgGUID: mlJfMqBPSgudVBltKqVGDg== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="6.07,229,1708416000"; d="scan'208";a="25564915" Received: from shivapri-mobl.amr.corp.intel.com (HELO [10.209.176.73]) ([10.209.176.73]) by orviesa007-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 25 Apr 2024 06:44:12 -0700 Message-ID: <59f78ca7-ea09-41d7-9e6e-b0ce1af484e4@linux.intel.com> Date: Thu, 25 Apr 2024 08:43:20 -0500 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: [PATCH v3 2/7] ASoC: codecs: wcd937x: add wcd937x codec driver To: Mohammad Rafi Shaik , Srinivas Kandagatla , Banajit Goswami , Liam Girdwood , Mark Brown , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Jaroslav Kysela , Takashi Iwai Cc: linux-arm-msm@vger.kernel.org, alsa-devel@alsa-project.org, linux-sound@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, quic_rohkumar@quicinc.com, quic_pkumpatl@quicinc.com References: <20240425091857.2161088-1-quic_mohs@quicinc.com> <20240425091857.2161088-3-quic_mohs@quicinc.com> Content-Language: en-US From: Pierre-Louis Bossart In-Reply-To: <20240425091857.2161088-3-quic_mohs@quicinc.com> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit > +struct wcd937x_priv { > + struct sdw_slave *tx_sdw_dev; > + struct sdw_slave *rx_sdw_dev; Does this mean that the codec has 2 SoundWire interfaces? If yes, aren't there merits in splitting the implementation in two separate drivers, one for each interface and probing on the relevant partID? This is how the RT713 was handled. The mic function was exposed as the RT1713. By representing the device as a single entity, things could be fun because the two interfaces are really independent. things like clock stop are handled at the interface level. The code in this driver is difficult to review, for example in the probe you wait for the TX part to complete the enumeration/initialization, but there's nothing mentioned or stated on the RX part, and there's really nothing related to the detection of this device. I don't actually see a sdw_driver at all, it's a platform driver. Would you mind adding a paragraph on how the SoundWire interfaces are handled and how the SoundWire bus is involved if there's no sdw_driver? Thanks!