Received: by 2002:a05:6a10:f347:0:0:0:0 with SMTP id d7csp1878764pxu; Thu, 17 Dec 2020 23:28:35 -0800 (PST) X-Google-Smtp-Source: ABdhPJz6shwcaSFK2QlAYJWr0dVnxi9v1ZC44vnFUZvGL5AnO34cb46SOZq1XP6ARSZuElBjFKbz X-Received: by 2002:a05:6402:1c90:: with SMTP id cy16mr3051235edb.73.1608276514958; Thu, 17 Dec 2020 23:28:34 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1608276514; cv=none; d=google.com; s=arc-20160816; b=VUupUM3k3at1d0CA+/thlHahjddPpm6wcDjLIXnZecmHGnlmHEIoDBcblt2rWWiX95 X96D7SgubXoL/BVzwSGA2Imn368P/N9F3fsKk8G+L1zgFhc6hACVEVUZ1HSqvGd7lFG3 xE26gOdsTCiKwCIr0EQTe58nT/K5N8zws3JByiLe6CrLEjK3i0TbAQWwAs79hEedpAV3 3uNmRpvobRfkbjowjla8IO6hbzWGm+DV38iCMoVszN4rbCHqM/wO9S8eyDW9U68/GTbW wF7HKiw7umG9Y9BLbs8R7szR0MgX9cP7txJd9rU91ckbYXsoWR6dNXK1896SuJRvItaK FxtQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:dkim-signature:date; bh=BZFIkRSlzcBp4QTFYgCVZVXYtFySJDkILRjFWH7iznE=; b=eiyMIPed3QYQ8OP4Y12d74l3eMpB49z3dYDQ8ZRbm5gyxeqOUGIxDsYGkJu7MJRwRP uv6Mf2cG5EqhMvRE3QFQ+L+GFoEZoYPrqgRiAilb/jp2DYD+sY0lXOe6iactdQtunoMP LCdES6E04em9Grd09OhFBv6mi9qTZePCqqoBcUwcZxFys1P8bmqDJEU2Kr9AMSu09nSZ Z7ix+J+MG6y03J67UkPnPfoATbJo07ZeZTdlXLD9ugIkR89Z26JylBvP8jhLPd8ka96i po9R0q2WH1F+y+uWEIMgmvhQBS4GcAEN8FFs3Vn1NGomgEwgxCUPHz3yB+HXKzkRkxG9 D0dg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=p0eV3itq; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id cq20si5721682edb.563.2020.12.17.23.28.12; Thu, 17 Dec 2020 23:28:34 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=p0eV3itq; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1732891AbgLRHLg (ORCPT + 99 others); Fri, 18 Dec 2020 02:11:36 -0500 Received: from mail.kernel.org ([198.145.29.99]:37352 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726520AbgLRHLf (ORCPT ); Fri, 18 Dec 2020 02:11:35 -0500 Date: Fri, 18 Dec 2020 08:10:51 +0100 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1608275455; bh=WoCbTvI1JoQUbfKVXDl1rGZDoThbBAh8ju3cl9AbMs8=; h=From:To:Cc:Subject:References:In-Reply-To:From; b=p0eV3itq7B0JE2tPEfmKLKMQdHJX+EzH3vsTS33F1/pMV7DbYhFzntdD9GS08cocT Zlfyb0i3i0SLP8nMIMMP6g3JPFC2W7UG8B8zCvOStI8a5Bn++07L00/bwHAPfzAsO4 V0+UN2s971KPNO8oivHNaM/wP3eLm4rRUNvj81Lg= From: Greg KH To: Alexandre Belloni Cc: Dan Williams , Pierre-Louis Bossart , alsa-devel@alsa-project.org, Kiran Patil , linux-rdma , Shiraz Saleem , Martin Habets , Liam Girdwood , Ranjani Sridharan , Fred Oh , Mark Brown , Jason Gunthorpe , Dave Ertman , Jakub Kicinski , Netdev , Leon Romanovsky , David Miller , Linux Kernel Mailing List , Parav Pandit Subject: Re: [resend/standalone PATCH v4] Add auxiliary bus support Message-ID: References: <160695681289.505290.8978295443574440604.stgit@dwillia2-desk3.amr.corp.intel.com> <20201217211937.GA3177478@piout.net> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20201217211937.GA3177478@piout.net> Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, Dec 17, 2020 at 10:19:37PM +0100, Alexandre Belloni wrote: > Hello, > > On 05/12/2020 16:51:36+0100, Greg KH wrote: > > > To me, the documentation was written, and reviewed, more from the > > > perspective of "why not open code a custom bus instead". So I can see > > > after the fact how that is a bit too much theory and justification and > > > not enough practical application. Before the fact though this was a > > > bold mechanism to propose and it was not clear that everyone was > > > grokking the "why" and the tradeoffs. > > > > Understood, I guess I read this from the "of course you should do this, > > now how do I use it?" point of view. Which still needs to be addressed > > I feel. > > > > > I also think it was a bit early to identify consistent design patterns > > > across the implementations and codify those. I expect this to evolve > > > convenience macros just like other parts of the driver-core gained > > > over time. Now that it is in though, another pass through the > > > documentation to pull in more examples seems warranted. > > > > A real, working, example would be great to have, so that people can know > > how to use this. Trying to dig through the sound or IB patches to view > > how it is being used is not a trivial thing to do, which is why > > reviewing this took so much work. Having a simple example test module, > > that creates a number of devices on a bus, ideally tied into the ktest > > framework, would be great. I'll attach below a .c file that I used for > > some basic local testing to verify some of this working, but it does not > > implement a aux bus driver, which needs to be also tested. > > > > There is something I don't get from the documentation and it is what is > this introducing that couldn't already be done using platform drivers > and platform devices? Because platform drivers and devices should ONLY be for actual platform devices. Do NOT use that interface to fake up a non-platform device (i.e. something that is NOT connected to a cpu through a memory-mapped or direct-firmware interface). Do not abuse the platform code anymore than it currently is, it's bad enough what has been done to it over time, let's not make it any worse. thanks, greg k-h