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 440627262E; Tue, 30 Dec 2025 13:54:18 +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=1767102859; cv=none; b=p6GKhyvDkDJVrrbRyFn7UIo1vznDNp2D470IYw8EWr81O3KghLg62W8T7oSf513NWpsx9EtXSRL91Imove3lPv1518bcq4GwwJsQ8cab+bdvCgq1jjwhVd51D+z8Uy+vTx5S1s43ohHUb/e9FpWPkxr6ciwZc50o8684m4owuIU= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1767102859; c=relaxed/simple; bh=5lMqJZwb4hgYOByED8z0hZEet9gjORTV1yz896z2ftk=; h=Message-ID:Date:MIME-Version:Subject:To:Cc:References:From: In-Reply-To:Content-Type; b=dDf0eamEnw9XhnmIn9mmEquQ1m8J4NEzljN8Xi3Kcb6jmRgUZhd+7eXFUGw6Wx+yKB5hedGL4y77dlkLNLk+y+V8rrvWbYYGmbd4GLUsK8plEwGWZzsiZql1fz7s50s/1xVU8ka70HD037xZnKfmFPcumOFn+AdAkuIFiPwOQ0w= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=jJhlOldH; 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="jJhlOldH" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 1DEEEC4CEFB; Tue, 30 Dec 2025 13:54:15 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1767102858; bh=5lMqJZwb4hgYOByED8z0hZEet9gjORTV1yz896z2ftk=; h=Date:Subject:To:Cc:References:From:In-Reply-To:From; b=jJhlOldHcuIN0nef9IO/i4twvy7tnxnz4bJjugDFrHqp+KfqbCytlgiNyhe5EKzw9 RQPxQvGINXBUuvCj+n6gUP+/CKbgQui911OkDqkBKf56qAdtjAPuTgIzqdECW+dMpi nVtO72co2Wbh40RpsLijVLxgxVSHPl5IQys4qs6wmRWoFBAdOmt7A3h6wDE5Nia4jL dza6lYZjyisXkoPoxncqBU3U4asD5lKVr+YnCrKvydm1hKyVrSXKD3bCQdbd12rrZd WuoRyW/uY/6jNt+m9QP5AQB1pdnzRQgu1D61MEcFx8byThpR1OMmeE1bt7JVBO/GTf cWHAWU+NWkgDg== Message-ID: <41447e2e-52af-4fe0-8204-7ee7f43841c6@kernel.org> Date: Tue, 30 Dec 2025 14:54:14 +0100 Precedence: bulk X-Mailing-List: linux-media@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: [PATCH v3 1/4] media: i2c: ov9282: Fix reset-gpio logical state To: Loic Poulain , Sakari Ailus , krzk+dt@kernel.org Cc: andersson@kernel.org, konradybcio@kernel.org, dave.stevenson@raspberrypi.com, robh@kernel.org, conor+dt@kernel.org, mchehab@kernel.org, linux-arm-msm@vger.kernel.org, devicetree@vger.kernel.org, linux-media@vger.kernel.org, laurent.pinchart@ideasonboard.com References: <20251114133822.434171-1-loic.poulain@oss.qualcomm.com> <20251114133822.434171-2-loic.poulain@oss.qualcomm.com> From: Krzysztof Kozlowski Content-Language: en-US Autocrypt: addr=krzk@kernel.org; keydata= xsFNBFVDQq4BEAC6KeLOfFsAvFMBsrCrJ2bCalhPv5+KQF2PS2+iwZI8BpRZoV+Bd5kWvN79 cFgcqTTuNHjAvxtUG8pQgGTHAObYs6xeYJtjUH0ZX6ndJ33FJYf5V3yXqqj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8BBgBCgAmAhsMFiEEm9B+DgxR+NWWd7dUG5NDfTtB YpsFAmgXUF8FCRaWWyoACgkQG5NDfTtBYptO0w//dlXJs5/42hAXKsk+PDg3wyEFb4NpyA1v qmx7SfAzk9Hf6lWwU1O6AbqNMbh6PjEwadKUk1m04S7EjdQLsj/MBSgoQtCT3MDmWUUtHZd5 RYIPnPq3WVB47GtuO6/u375tsxhtf7vt95QSYJwCB+ZUgo4T+FV4hquZ4AsRkbgavtIzQisg Dgv76tnEv3YHV8Jn9mi/Bu0FURF+5kpdMfgo1sq6RXNQ//TVf8yFgRtTUdXxW/qHjlYURrm2 H4kutobVEIxiyu6m05q3e9eZB/TaMMNVORx+1kM3j7f0rwtEYUFzY1ygQfpcMDPl7pRYoJjB dSsm0ZuzDaCwaxg2t8hqQJBzJCezTOIkjHUsWAK+tEbU4Z4SnNpCyM3fBqsgYdJxjyC/tWVT AQ18NRLtPw7tK1rdcwCl0GFQHwSwk5pDpz1NH40e6lU+NcXSeiqkDDRkHlftKPV/dV+lQXiu jWt87ecuHlpL3uuQ0ZZNWqHgZoQLXoqC2ZV5KrtKWb/jyiFX/sxSrodALf0zf+tfHv0FZWT2 zHjUqd0t4njD/UOsuIMOQn4Ig0SdivYPfZukb5cdasKJukG1NOpbW7yRNivaCnfZz6dTawXw XRIV/KDsHQiyVxKvN73bThKhONkcX2LWuD928tAR6XMM2G5ovxLe09vuOzzfTWQDsm++9UKF a/A= In-Reply-To: Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit On 15/12/2025 11:19, Loic Poulain wrote: > On Mon, Dec 15, 2025 at 10:40 AM Sakari Ailus > wrote: >> >> Hi Loic, >> >> On Mon, Dec 15, 2025 at 10:35:15AM +0100, Loic Poulain wrote: >>> Hi Sakari, >>> >>> On Mon, Nov 17, 2025 at 6:30 PM Sakari Ailus >>> wrote: >>>> >>>> Hi Loic, >>>> >>>> On Fri, Nov 14, 2025 at 02:38:19PM +0100, Loic Poulain wrote: >>>>> Ensure reset state is low in the power-on state and high in the >>>>> power-off state (assert reset). Note that the polarity is abstracted >>>>> by the GPIO subsystem, so the logic level reflects the intended reset >>>>> behavior. >>>> >>>> That's an interesting approach to fix DTS gone systematically wrong. >>>> >>>> I was thinking of the drivers that have this issue, too, but I would have >>>> introduced a new GPIO under a different name (many sensors use "enable", >>>> too). Any thoughts? >>> >>> Apologies for missing your point earlier. We can’t really name it >>> enable, as it performs the opposite function and that would be >>> confusing in the device tree description. A property like reset2 would >>> be more accurate, but I suspect such a binding wouldn’t be acceptable >>> from a device tree/bindings perspective. >> >> Many sensor datasheets document a pin called "xshutdown" or alike. That's >> not exactly "reset" or "enable" but it can be mapped to either and this can >> be seen in the existing bindings. The polarity is effectively the opposite, >> yes, but does that matter? > > I assume naming a pin 'xshutdown' or 'xreset' indicates that its > polarity is inverted at the driver level, the driver interprets the > shutdown or reset function as being active when the logical level is 0 > (low), as they actually incorrectly do for the 'reset' gpio. > > From the driver’s perspective, this naming convention is acceptable; > however, it causes the devicetree description to slightly diverge from > the datasheet and leaves the reset property effectively inverted (and > therefore incorrect). > > Honestly, in this specific case, the simplest solution would be to fix > the driver, since there is currently no upstream devicetree using this > sensor. That would technically break backward compatibility for any > out-of-tree DTS (if they exist), but those would have been incorrect > in the first place. > > But yes, this seems like a good opportunity to discuss and define a > more general approach that can be applied to other drivers with > similar polarity or naming issues. > > Krzysztof, any thoughts? You need to first CC me. You sent it to the special bulk email address... Anyway, please be specific about the question. I responded to earlier message that your claims in your comment in this patch are clearly wrong, but what it is surprising me, it's second approach this month people completely ignore existing and new DTS. Other was MT7530 where author also claim all is fine, but actually both old and new DTS were broken. Same here. Best regards, Krzysztof