From mboxrd@z Thu Jan 1 00:00:00 1970 Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.remote-ip=209.85.167.52 ARC-Seal: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=none; t=1796363547; b=217PWEPRy9EMBaV+FXLWE+HLlsVl39jbfpuHY0vD2QXqbWIAWxAK+ZJZ+lugVs7vf+Au LWHXW9EHmun/8pztsArT5R9zcZVsywIszBtsLir+KQDV/qDf4U/8gq5tnYnQtPljpgnvC BhhgAHp1AwbB3/PqixfbHMRob6RZ3ualvRDv2Wyl2UlhNqFTp+MT8oVCLLkRu+eSW4JEu 0EPEcE2jRuD4dTDqyur92wsdE0hs2DEjq+yE4TrfsmOcwuVKg66bzhkce0l3T5noyRiQ2 bOKfaNOpjOk9W8FSsqhRz/SjzHss1mE5gOMiytUPKw1jgcp6TOVLPeZ9Eva5VnRcZPw== ARC-Message-Signature: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; c=relaxed/relaxed; t=1796363547; h=DMARC-Filter:Received:DKIM-Signature:X-Google-DKIM-Signature: X-Forwarded-Encrypted:X-Gm-Message-State:X-Gm-Gg:X-Received:Received: Message-ID:Date:MIME-Version:User-Agent:Subject:To:Cc:References: Content-Language:From:In-Reply-To:Content-Type: Content-Transfer-Encoding; bh=3NY+mUktI2CFMFV+M1VPOT4Pb3KyGcxUxP8Hj79Om+8=; b=hCcoDlRTsngOkV0CITt5NpE281yPOeTiPN7QaEVM6ho3Wz0dIRCdQI5M/NjNikxOiB44 mBVOIYSnMmNW0EKFXlkDwOpW8IOlqacfOUYIw5wXexB2Rsqo4UAHtnQrnntK30zaxQe4j N2wXRG+bj9D9vJL58GH40aIPg01s2xZ64gNM+4irtAo1qhfXPGOG/VhwN4qFS4jkGmE2f 4LqQ+wTIj6AXRQUCQqazOWMqB4XhOFMcEqcavCHFkMkWeuaw6jwYLcBJ1HnITj73hrVd8 lP1AqKhgVX01qTich4PG/I9q5YvJ1XczA1n7A1oYAUuqGY4IsIJy6pfVQJCsyGf1kLQ== ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass header.from=gmail.com; spf=pass smtp.mailfrom=gmail.com; dkim=pass header.d=gmail.com header.i=@gmail.com header.a=rsa-sha256 header.s=20260707 header.b=n4KjIg9l; arc=none smtp.remote-ip=209.85.167.52 Received: from mail-lf1-f52.google.com (mail-lf1-f52.google.com [209.85.167.52]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature ECDSA (prime256v1) server-digest SHA256) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 17AAD606A322 for ; Fri, 4 Dec 2026 05:52:26 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.2 smtp.subspace.kernel.org 17AAD606A322 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmail.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.a=rsa-sha256 header.s=20260707 header.b=n4KjIg9l Received: by mail-lf1-f52.google.com with SMTP id 2adb3069b0e04-5c14f3dab0cso313428e87.1 for ; Thu, 03 Dec 2026 21:52:26 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20260707; t=1796363545; x=1796968345; darn=vger.kernel.org; h=content-transfer-encoding:content-type:in-reply-to:from :content-language:references:cc:to:subject:user-agent:mime-version :date:message-id:from:to:cc:subject:date:message-id:reply-to :content-type; bh=3NY+mUktI2CFMFV+M1VPOT4Pb3KyGcxUxP8Hj79Om+8=; b=n4KjIg9l9bEbE0TJFcDoVvq4IYyVvyOBjw+GpD/REzYuBf37kpVl/7sXj/YSj+09p8 PjTT7RZvkiItNI/Unfj0hkpVfAOudw3TbvoOdrK+jQ7B/jHVXKVwkEI+/XqGkpzJScw6 cBRa7V1/bD6mTbeUy2sgnNJgZXLNKAnMAg4s2hD9B4Mveeq/2VKDRNPfL6yykjxaGQ4a 2bSG05C4e76JYkL0nkmvO6GhdnmXnjNPwvMCszV+eEHoCuz3Xys7VuZD1Uh5v7VvfHuF v3LTnoigQPhJFyz3LFFI5wFGUL5azTNlzrZAZlY40BtX/+VgNqDYX4EVvJjM04qqeq2K OWfQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20260707; t=1796363545; x=1796968345; h=content-transfer-encoding:content-type:in-reply-to:from :content-language:references:cc:to:subject:user-agent:mime-version :date:message-id:x-gm-gg:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to:content-type; bh=3NY+mUktI2CFMFV+M1VPOT4Pb3KyGcxUxP8Hj79Om+8=; b=wO8y9mXUiFI/kp6SatIaH/VyZDUf6IRueFQrpMbWTPBfwIrrOFIzIxy4sJ4lIHkMiB Oko7zUkpVuqcAToT703YSmk0ZnecIPgWfUbz/4i6AqatuGm3YNMXQMARf4h5Y5urAf5e SlC1CIr3w7c/HhzplE2osHC3M4/mgGbwYMKv9ag1mu0rU050/HAsotgbpJY3505rZP6P NoknH3ykg5xRIVRRJZLGB1TFP2FQ9Kh0rCkV3n0yDb6LQdpVDq8crmsjKlNrRFzZjyAa 99NT6NyGX7sKqpMfKvnRjMAHOVjmCvMgw4BxOWyqYjWqY/hBg3pwa4i/r+Pgy1fFqLac kAaA== X-Forwarded-Encrypted: i=1; AL+hErHtzUZIbunbAQPTgCnZvC0yltYzFGu8Z9MQmG8AxgMTIU/5GDnXDwvJvQc8coN+SP/+Ulz9XTsEPIizYUk=@vger.kernel.org X-Gm-Message-State: APuU4Z/ajsixp7DMG9tPVIJwZu7TUnfICiKtst+z9hLS6PSIJf8tnbdq WkeLXblQnHZvniE4aLk5YN2hqKvI9tSiDoqo0f6fRU1hQvroKCOjwRG9 X-Gm-Gg: AZFdTZeF+tmnrStM52eaejP78ukRXn3f91M49B+wdEjdxr7kBjs5yhW0ulmHBU4wKeR zvAMkGKihDp5xzXcEn6UkdfEQO/1Z+EIJVAzAOFxK18lzs/1b1gJ6YW0qNb8QBhKpTwtjsdn1u4 Hxo66YCjxyUhp5fwYfmwd1tisSor+bvGm/tKYBpqNstPLw4ERQH0LD5FEDMWTEwN1VzyavI85sM 8GoB/W1VqP+Hh5VgJw9LdIsEDjdbC7gSUgoy0Ln/3Qe8XCNku7Iazhnwg9YTMf4AhaM48XoXUrz Nw/CZin6Tt7gEkR/mGjQoVYBnG7TY9byMTmv+EPUfM0geC/DopkwC6hUJHdL1lE8xk/OB0pQXg7 Gjj8XOBSW+sOiRVUvdFAJrQrour3Z3N4W5pgesqb6WlA1NKJtklEcujNCxoyra1u9zyBdhedBMM JEscDuHGYmgWfzXbrDd/lpFwpSM8S9gRemK73QHhVGV0pn0Xi9dT36LG0Vlhp8hPmsDsbKra+6y j23UzD6tSXcIen0VAaXrlcC/p7AH2jvJwibvKtiwb6Gj3ia2v9ILnzYNUGNkpt9KTT1HrbeJK9y gWMyMzMmqA/291T+ct+6P0ZPcw2z6/qkNxpUrT1KYleDwgzurpOw30LzJtJk3r0A1FRXTNfq2rr gREMGxdG7 X-Received: by 2002:a05:6512:a86:b0:5c3:5bd9:4b8a with SMTP id 2adb3069b0e04-5c3861a9f2amr187830e87.39.1796363545088; Thu, 03 Dec 2026 21:52:25 -0800 (PST) Received: from ?IPV6:2a10:a5c0:800d:dd00:8fdf:935a:2c85:d703? ([2a10:a5c0:800d:dd00:8fdf:935a:2c85:d703]) by smtp.gmail.com with ESMTPSA id 38308e7fff4ca-3b00378ebc6sm4119511fa.14.2026.12.03.21.52.21 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Thu, 03 Dec 2026 21:52:23 -0800 (PST) Message-ID: <25fbd4d2-1629-4eee-b398-5122bb3ac08a@gmail.com> Date: Fri, 4 Dec 2026 07:52:21 +0200 X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Post: List-Help: List-Subscribe: List-Unsubscribe: List-Owner: Precedence: list MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: [PATCH 2/4] dt-bindings: iio: dac: Add ROHM BD7971x To: Conor Dooley Cc: Conor Dooley , Matti Vaittinen , Matti Vaittinen , Jonathan Cameron , David Lechner , =?UTF-8?Q?Nuno_S=C3=A1?= , Andy Shevchenko , Rob Herring , Krzysztof Kozlowski , Conor Dooley , linux-iio@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org References: <003d2b6ccbf816cee396698808555a62cb3068bc.1796049052.git.mazziesaccount@gmail.com> <20261202-stingy-hungry-8fe162c0d9d4@spud> <5d4fa0ce-3804-438e-ae07-8418ad00256f@gmail.com> <20261203-splotchy-factor-bbd31ec6fd3b@wendy> <20261203-nephew-sliceable-d4971671b194@spud> Content-Language: en-US, en-AU, en-GB, en-BW From: Matti Vaittinen In-Reply-To: <20261203-nephew-sliceable-d4971671b194@spud> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit On 03/12/2026 18:36, Conor Dooley wrote: > On Thu, Dec 03, 2026 at 02:10:12PM +0200, Matti Vaittinen wrote: >> On 03/12/2026 10:35, Conor Dooley wrote: >>> On Thu, Dec 03, 2026 at 08:54:56AM +0200, Matti Vaittinen wrote: >>>> On 02/12/2026 20:05, Conor Dooley wrote: >>>>> On Wed, Dec 02, 2026 at 03:38:53PM +0200, Matti Vaittinen wrote: >>>>>> From: Matti Vaittinen >>>>>> >>>>>> The ROHM BD7971[0-3] are very similar to the ROHM BD7970[0-3]. Main >>>>>> difference is the amount of bits in the DAC word, BD7970x having 8-bit >>>>>> DAC and BD7971x having 10-bit DAC. >>>>> >>>>> From the driver there's more differences than this, and that's what >>>>> justifies the devices not being comatible with one another. >>>> >>>> Thanks for the review (once again) Conor! >>>> >>>> I think the compatibility breaking changes are actually resulting from the >>>> DAC-word size change. The bd7970x (previous, 8-bit DAC IC family) >>>> SPI-protocol had only 8 bits reserved for the DAC-word. The SPI command was >>>> placed in the 4 bits directly after the 8 DAC bits. Hence, the 10-bit DAC >>>> word we have on BD7971x family, required SPI protocol to be changed. >>>> Furthermore, the size of the DAC-word needs any ways to be visible to the >>>> users so they can use the full range. Hence, the DAC-word change from 8-bit >>>> to 10-bit really broke the compatibility. >>>> >>>> But yes, from the driver side the changes look following: The SPI command >>>> was moved to the first 4 bits of the transfer, DAC word was increased to >>>> 10-bits and it was also moved 2 bits left, while remaining last 2 bits are >>>> now required to be zero. >>>> >>>> I can mention above to clarify things if you feel it is important, but this >>>> really was required (well, DAC word shifting and zeroing the last 2 bits was >>>> not) because the DAC size changed. Hence, from hardware description point of >>>> view, the DAC change was the big thing. >>> >>> I believe you that the lack of fallbacks is a requirement, don't worry >>> about that. I think we've crossed wires though - the 8/10-bit thing is >>> already explained and it wasn't that I was looking for a note on. It's >>> the lack of compatibility between all of the new devices that you're >>> adding in this patch I was talking about. >>> I presume the answer is going to be channel count/capability related. >> >> Hmm.. After re-reading the patch, the patch itself has this information: >> >> ... >> >>>>>> description: | >>>>>> - The ROHM BD7970[0,1,2,3] are 8-bit DACs. The BD79700 has 2 channels, >>>>>> - BD79701 3 channels, BD79702 4 channels and BD79703 has 6 channels. >>>>>> - Datasheets for BD79702 and BD79703 can be found from >>>>>> - https://fscdn.rohm.com/en/products/databook/datasheet/ic/data_converter/dac/bd79702fv-lb_bd79703fv-lb-e.pdf >>>>>> - and for the BD79700 and the BD79701 from >>>>>> - https://fscdn.rohm.com/en/products/databook/datasheet/ic/data_converter/dac/bd79700fvm-lb_bd79701fvm-lb-e.pdf >>>>>> + The ROHM BD7970[0-3] are 8-bit DACs and BD7971[0-3] are 10-bit DACs. The >>>>>> + BD797x0 has 2 channels, BD797x1 3 channels, BD797x2 4 channels and BD797x3 >>>>>> + has 6 channels. >> You would like this to be explicitly stated said in the commit message too? > > Yes, I would like it spelt out. Often channel differences don't produce > incompatibility because it's taken care of by channel@### subnodes. In > this patch, the diff doesn't cover the whole binding so I can't tell by > looking at this that this is the incompatibility. Ok. > Notes about the sources of incompatibility is one of my person crusades, > because checking that wastes a lot of time on trivial patches, that > could otherwise be entirely reviewed from my mailer without checking the > other patches in the series mid-reply. Thanks for explaining the background! I never thought this from this point of view :) I see the importance now! Yours, -- Matti -- Matti Vaittinen Linux kernel developer at ROHM Semiconductor Oulu Finland ~~ When things go utterly wrong vim users can always type :help! ~~