From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753600AbcGFLh2 (ORCPT ); Wed, 6 Jul 2016 07:37:28 -0400 Received: from smtpoutz27.laposte.net ([194.117.213.102]:42390 "EHLO smtp.laposte.net" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1753242AbcGFLhY (ORCPT ); Wed, 6 Jul 2016 07:37:24 -0400 Subject: Re: [RFC PATCH v1] irqchip: add support for SMP irq router To: Jason Cooper , Mason References: <577542D1.4070307@laposte.net> <577A5260.3070001@free.fr> <577BA854.6090503@laposte.net> <20160705144151.GE3348@io.lakedaemon.net> <577BCD1D.6060301@free.fr> <20160705161654.GH3348@io.lakedaemon.net> Cc: LKML , Thomas Gleixner , Marc Zyngier From: Sebastian Frias Message-ID: <577CED71.4090406@laposte.net> Date: Wed, 6 Jul 2016 13:37:21 +0200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Thunderbird/38.8.0 MIME-Version: 1.0 In-Reply-To: <20160705161654.GH3348@io.lakedaemon.net> Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: 7bit X-VR-SrcIP: 83.142.147.193 X-VR-FullState: 0 X-VR-Score: -100 X-VR-Cause-1: gggruggvucftvghtrhhoucdtuddrfeeltddrvdeigdefkecutefuodetggdotefrodftvfcurfhrohhf X-VR-Cause-2: ihhlvgemucfntefrqffuvffgnecuuegrihhlohhuthemucehtddtnecusecvtfgvtghiphhivghnthhs X-VR-Cause-3: ucdlqddutddtmdenucfjughrpefuvfhfhffkffgfgggjtgfgsehtjegrtddtfeehnecuhfhrohhmpefu X-VR-Cause-4: vggsrghsthhirghnucfhrhhirghsuceoshhfkeegsehlrghpohhsthgvrdhnvghtqeenucfkphepkeef X-VR-Cause-5: rddugedvrddugeejrdduleefnecurfgrrhgrmhepmhhouggvpehsmhhtphhouhhtpdhhvghloheplgdu X-VR-Cause-6: jedvrddvjedrtddrvddugegnpdhinhgvthepkeefrddugedvrddugeejrdduleefpdhmrghilhhfrhho X-VR-Cause-7: mhepshhfkeegsehlrghpohhsthgvrdhnvghtpdhrtghpthhtohepjhgrshhonheslhgrkhgvuggrvghm X-VR-Cause-8: ohhnrdhnvght X-VR-AvState: No X-VR-State: 0 X-VR-State: 0 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi Jason, On 07/05/2016 06:16 PM, Jason Cooper wrote: >> Come to think of it, I'm not sure the *name* of the file documenting >> a binding is as important to DT maintainers as the compatible string. > > Correct. devicetee compatible strings need to be as specific as > possible. Specific with respect to what thing? To the HW module they are describing (USB, IRQ controller, etc.) or to the chip the HW module it is embedded into? >In a series of compatible IP blocks, the string should refer > to the first version in the series, e.g. sigma,smp8710 for a series of > compatible IP blocks like 8710, 8712, 8715, 8724. If an 8751 came along > with a different register layout or some other incompatibility, then a > new string would be sigma,smp8751. So, > > 8710 uses "sigma,smp8710" > 8712 uses "sigma,smp8710" > 8715 uses "sigma,smp8710" > 8724 uses "sigma,smp8710" > 8751 uses "sigma,smp8751" > 8754 uses "sigma,smp8751" > But this is not consistent with the strings for generic drivers, like "generic-xhci", etc. A SoC is composed of several HW modules, some are shared among different manufacturers (i.e.: "generic-xhci"), and some are shared among different product lines of the same manufacturer (i.e.: "sigma,smp,irqrouter"). And the DT for a given chip should describe the collection of HW modules that make up the SoC, regardless of what chip introduced them or what other chip uses it. Why would that be relevant anyway? By that reasoning, I also think that drivers/net/ethernet/aurora/nb8800.c should have had a string like "aurora,nb8800,sigma" or something, to specify that it is a NB8800 from Aurora integrated in a Sigma platform. That way it can behave as vanilla NB8800 when the string is "aurora,nb8800" and it can adapt its behaviour to Sigma's platform when a different string (like "aurora,nb8800,sigma") is used in the DT. Later if Sigma modified the nb8800 HW, it could be "aurora,nb8800,sigma-v2". The same way, if later Sigma used a different Aurora HW module, the DT would say "aurora,nb2000,sigma" (to signal that another driver is required) Instead, drivers/net/ethernet/aurora/nb8800.c has "sigma,smp8642-ethernet" string, which ties it to a particular chip, and I don't see how does that convey version about the module or other relevant information; Plus it is confusing if the same module is then embedded on a SMP8756 chip. Would you mind explaining how does that contrasts with the logic used by DT naming conventions? Best regards, Sebastian