Received: by 2002:a25:8b12:0:0:0:0:0 with SMTP id i18csp1329698ybl; Thu, 22 Aug 2019 12:46:26 -0700 (PDT) X-Google-Smtp-Source: APXvYqzoSQm22S14HD7aLkg6rbVhRC8Vp2R2RGVbh5pf1wgSH1jZFctnvB3PpOfSLhwigRHCRJiP X-Received: by 2002:a65:690b:: with SMTP id s11mr794085pgq.10.1566503186062; Thu, 22 Aug 2019 12:46:26 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1566503186; cv=none; d=google.com; s=arc-20160816; b=krRQTlvGBpToaUBMst3kGcqxHOTFPH3g6wLGpiawYbjL/0wzM5J06tzm80yX5THVjC Ke9lv6+FQLbM28cwh8I3+fmChBq7ZV/qXGD+s7yrygHG7RaZshmRDrYIeKQ6nZb3gef1 UPQeXGUQMuz7SF+sOyexrZvyTt7cVXi96ZHtoshpq8kX86As8pce0Z6/6DCmSWxiNuId dn/mPggzAskt3XhKh80K+qapwE9vYgQkhXaVatzX1liu1uNQ1KuqD/vvfVsR/raIKDBJ HN+1A9R+uvEC1UCvPtE/0vpom71BwkIz9ycqioVHhgRFu2UVUDBIHnqbLIGQ95BzJDsT iP+g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date; bh=Nm2wePgDMnL5ZVPX9RzKv4BLsy+TeZTuh4csv/pJ07w=; b=d8G5bClj4xwYatCyCcHcw3q71fLFS3MiDqpIb++xWOlBaM+WjlgYTNsk5wQiJx9wzE 5IbMq7sX2cybvS0CPJsgg5oOrTRzLzDHPQtB9FcvRaTZ+GSXs9Iac3jdzjF9AO1bl8gq oJ4/PTPhzlJSDN6pMt8/fU3ifr8stsPoHHILvSVcjA2LLtBYekC5RObMgw04JSVDDpIj H4AljJs3YbT9x7/ch831FzxJlJb2IE7FxUDYwt8zbwhe3TrYkI0EkhKHATPT0w6xLL59 tUa4HnQ77IMi46P1agQkrSbT9fLiDZzyckcDYSTeXLYwP0HvMXMs8o7/FW6NBXzkphFL e/3g== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id 124si214340pgb.11.2019.08.22.12.45.54; Thu, 22 Aug 2019 12:46:26 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2389461AbfHVPLY (ORCPT + 99 others); Thu, 22 Aug 2019 11:11:24 -0400 Received: from mga09.intel.com ([134.134.136.24]:65427 "EHLO mga09.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2387755AbfHVPLY (ORCPT ); Thu, 22 Aug 2019 11:11:24 -0400 X-Amp-Result: UNSCANNABLE X-Amp-File-Uploaded: False Received: from orsmga007.jf.intel.com ([10.7.209.58]) by orsmga102.jf.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 22 Aug 2019 08:11:23 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.64,417,1559545200"; d="scan'208";a="169810435" Received: from gliakhov-mobl2.ger.corp.intel.com (HELO ubuntu) ([10.249.36.176]) by orsmga007.jf.intel.com with ESMTP; 22 Aug 2019 08:11:19 -0700 Date: Thu, 22 Aug 2019 17:11:18 +0200 From: Guennadi Liakhovetski To: Pierre-Louis Bossart Cc: alsa-devel@alsa-project.org, linux-kernel@vger.kernel.org, tiwai@suse.de, broonie@kernel.org, vkoul@kernel.org, gregkh@linuxfoundation.org, jank@cadence.com, srinivas.kandagatla@linaro.org, slawomir.blauciak@intel.com, Bard liao , Rander Wang , Ranjani Sridharan , Liam Girdwood , Jaroslav Kysela , Takashi Iwai , Zhu Yingjiang , YueHaibing , Kai Vehmanen , Arnd Bergmann Subject: Re: [RFC PATCH 4/5] ASoC: SOF: Intel: hda: add SoundWire stream config/free callbacks Message-ID: <20190822151117.GA1200@ubuntu> References: <20190821201720.17768-1-pierre-louis.bossart@linux.intel.com> <20190821201720.17768-5-pierre-louis.bossart@linux.intel.com> <20190822071835.GA30262@ubuntu> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.10.1 (2018-07-13) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, Aug 22, 2019 at 08:53:06AM -0500, Pierre-Louis Bossart wrote: > Thanks for the review Guennadi > > > > +static int sdw_config_stream(void *arg, void *s, void *dai, > > > + void *params, int link_id, int alh_stream_id) > > > > I realise, that these function prototypes aren't being introduced by these > > patches, but just wondering whether such overly generic prototype is really > > a good idea here, whether some of those "void *" pointers could be given > > real types. The first one could be "struct device *" etc. > > In this case the 'arg' parameter is actually a private 'struct snd_sof_dev', > as shown below [1]. We probably want to keep this relatively opaque, this is > a context that doesn't need to be exposed to the SoundWire code. Right, that's why I proposed struct device and not struct snd_sof_dev, to not make it SOF-specific, then sdev could be obtained from dev_get_drvdata(). But yes, that's unrelated to this series. Thanks Guennadi