From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (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 337D923DEBA; Tue, 10 Dec 2024 12:05:47 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1733832347; cv=none; b=BlnywGnfbDR+Z6xt84t7T6SOfiG5TpW8wzyZe9U+KTbLnYWnc2efscHC3qRdcRnm3GPTBwmVFtScPtd2RooAUarkG93ztKMVylgmFRbZ0FI87nuWruqy8+862Pk2LFwd5uPIckTFWE+/IqrFQbNBQaKf9oVczqT39MqSwpLQ8Cg= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1733832347; c=relaxed/simple; bh=nBO5Ds3JwYoGI0hwO79o3kkiya7ohUrrfSkZ0bb/Wb4=; h=Message-ID:Date:MIME-Version:Subject:From:To:Cc:References: In-Reply-To:Content-Type; b=VRl/FWEr3DH1LSUH1KLEHMFpjoyuGUDTJq+zhKOhJfbHIkPqJ9zcAm1EkjoqvacV4Z/V004LlAZdzNDAcEiCa0Hh3LUYixWH04r+pWaGSdAzlz7vVAwRgyol0TVYs5RGCexrd+gmMIZp2v1qmpZblmHgPD4tICKMkh9YsAewoM4= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=FluYWaZO; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="FluYWaZO" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 81B12C4CED6; Tue, 10 Dec 2024 12:05:40 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1733832347; bh=nBO5Ds3JwYoGI0hwO79o3kkiya7ohUrrfSkZ0bb/Wb4=; h=Date:Subject:From:To:Cc:References:In-Reply-To:From; b=FluYWaZOcxnf6cXZGyGj8Gml7fo8VPRETZiBZsI5+Agj+Zaq3SZ4FyC0YpaEtVBX5 dslZvImb9rOk6qIbs4ozbhRt5PDoQcCqQAJXiLuo3Qh9Zusq7rKuvv8FDwk15h1Ptv A8xIQWhXGU/LtLLIWXiRjl3o34gS0PE4fnsqDSvPjJU6fzFUzd+SZ/PzaCo5ZMb1hi Qv0KuCg0xl2WpHxe5Tq21Q1NBEuIvK3VDP68l3cET05JhCURdAWtq+vkacSabokTlK ztNlXCBAx+cxpm3env+x2oZWUg1QRSRU2eVD3RQmHzmf8bqjKJCBmrHissS/cwBCEW VnWAP1X+5oMkw== Message-ID: <8b33f935-04a9-48df-8ea1-f6b98efecb9d@kernel.org> Date: Tue, 10 Dec 2024 13:05:38 +0100 Precedence: bulk X-Mailing-List: linux-i2c@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: [PATCH v5 1/4] dt-bindindgs: i2c: qcom,i2c-geni: Document shared flag From: Krzysztof Kozlowski To: Konrad Dybcio , Konrad Dybcio , Mukesh Kumar Savaliya , konrad.dybcio@linaro.org, andersson@kernel.org, andi.shyti@kernel.org, linux-arm-msm@vger.kernel.org, dmaengine@vger.kernel.org, linux-kernel@vger.kernel.org, linux-i2c@vger.kernel.org, conor+dt@kernel.org, agross@kernel.org, devicetree@vger.kernel.org, vkoul@kernel.org, linux@treblig.org, dan.carpenter@linaro.org, Frank.Li@nxp.com, konradybcio@kernel.org, bryan.odonoghue@linaro.org, krzk+dt@kernel.org, robh@kernel.org Cc: quic_vdadhani@quicinc.com References: <20241129144357.2008465-1-quic_msavaliy@quicinc.com> <20241129144357.2008465-2-quic_msavaliy@quicinc.com> <75f2cc08-e3ab-41fb-aa94-22963c4ffd82@quicinc.com> <904ae8ea-d970-4b4b-a30a-cd1b65296a9b@kernel.org> <835ac8c6-3fbb-4a0d-aa07-716d1c8aad7c@gmail.com> Content-Language: en-US Autocrypt: addr=krzk@kernel.org; keydata= xsFNBFVDQq4BEAC6KeLOfFsAvFMBsrCrJ2bCalhPv5+KQF2PS2+iwZI8BpRZoV+Bd5kWvN79 cFgcqTTuNHjAvxtUG8pQgGTHAObYs6xeYJtjUH0ZX6ndJ33FJYf5V3yXqqjcZ30FgHzJCFUu JMp7PSyMPzpUXfU12yfcRYVEMQrmplNZssmYhiTeVicuOOypWugZKVLGNm0IweVCaZ/DJDIH gNbpvVwjcKYrx85m9cBVEBUGaQP6AT7qlVCkrf50v8bofSIyVa2xmubbAwwFA1oxoOusjPIE J3iadrwpFvsZjF5uHAKS+7wHLoW9hVzOnLbX6ajk5Hf8Pb1m+VH/E8bPBNNYKkfTtypTDUCj NYcd27tjnXfG+SDs/EXNUAIRefCyvaRG7oRYF3Ec+2RgQDRnmmjCjoQNbFrJvJkFHlPeHaeS BosGY+XWKydnmsfY7SSnjAzLUGAFhLd/XDVpb1Een2XucPpKvt9ORF+48gy12FA5GduRLhQU vK4tU7ojoem/G23PcowM1CwPurC8sAVsQb9KmwTGh7rVz3ks3w/zfGBy3+WmLg++C2Wct6nM Pd8/6CBVjEWqD06/RjI2AnjIq5fSEH/BIfXXfC68nMp9BZoy3So4ZsbOlBmtAPvMYX6U8VwD TNeBxJu5Ex0Izf1NV9CzC3nNaFUYOY8KfN01X5SExAoVTr09ewARAQABzSVLcnp5c3p0b2Yg S296bG93c2tpIDxrcnprQGtlcm5lbC5vcmc+wsGVBBMBCgA/AhsDBgsJCAcDAgYVCAIJCgsE FgIDAQIeAQIXgBYhBJvQfg4MUfjVlne3VBuTQ307QWKbBQJgPO8PBQkUX63hAAoJEBuTQ307 QWKbBn8P+QFxwl7pDsAKR1InemMAmuykCHl+XgC0LDqrsWhAH5TYe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; charset=UTF-8 Content-Transfer-Encoding: 7bit On 10/12/2024 12:53, Krzysztof Kozlowski wrote: >>>> I'm not sure a single property name+description can fit all possible >>>> cases here. The hardware being "shared" can mean a number of different >>> >>> Existing property does not explain anything more, either. To recap - >>> this block is SE and property is named "se-shared", so basically it is >>> equal to just "shared". "shared" is indeed quite vague, so I was >>> expecting some wider work here. >>> >>> >>>> things, with some blocks having hardware provisions for that, while >>>> others may have totally none and rely on external mechanisms (e.g. >>>> a shared memory buffer) to indicate whether an external entity >>>> manages power to them. >>> >>> We have properties for that too. Qualcomm SoCs need once per year for >>> such shared properties. BAM has two or three. IPA has two. There are >>> probably even more blocks which I don't remember now. >> >> So, the problem is "driver must not toggle GPIO states", because >> "the bus controller must not be muxed away from the endpoint". >> You can come up with a number of similar problems by swapping out >> the quoted text. >> >> We can either describe what the driver must do (A), or what the >> reason for it is (B). >> >> >> If we go with A, we could have a property like: >> >> &i2c1 { >> externally-handled-resources = <(EHR_PINCTRL_STATE | EHR_CLOCK_RATE)> >> }; >> >> which would be a generic list of things that the OS would have to >> tiptoe around, fitting Linux's framework split quite well >> >> >> >> or if we go with B, we could add a property like: >> >> &i2c1 { >> qcom,shared-controller; >> }; >> >> which would hide the implementation details into the driver >> >> I could see both approaches having their place, but in this specific >> instance I think A would be more fitting, as the problem is quite >> simple. > > > The second is fine with me, maybe missing information about "whom" do > you share it with. Or maybe we get to the point that all this is > specific to SoC, thus implied by compatible and we do not need > downstream approach (another discussion in USB pushed by Qcom: I want > one compatible and 1000 properties). > > I really wished Qualcomm start reworking their bindings before they are > being sent upstream to match standard DT guidelines, not downstream > approach. Somehow these hundreds reviews we give could result in new > patches doing things better, not just repeating the same issues. This is BTW v5, with all the same concerns from v1 and still no answers in commit msg about these concerns. Nothing explained in commit msg which hardware needs it or why the same SoC have it once shared, once not (exclusive). Basically there is nothing here corresponding to any real product, so since five versions all this for me is just copy-paste from downstream approach. Best regards, Krzysztof