From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail-oo1-f45.google.com (mail-oo1-f45.google.com [209.85.161.45]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 36ED529D272 for ; Sun, 17 Aug 2025 16:51:25 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.161.45 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1755449488; cv=none; b=KHUSXvLxY4pfa5FhKJijt4kCD8WKQME8w7j6TjMujnlqlrOKYJ7D2/dTIyL+LLdU1JWT/usx8XGZuqF3x2UT0YaHhpfhk0PPwPter5eVcGsKv9LMaBwK9dYdpQguGYNSYKFkeQ8gJ0+wVszLd+aR32oGsoyyMlcIhQs1mTqBWnA= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1755449488; c=relaxed/simple; bh=mg9G1GrczvFU5RkdMi7X+2IDftbj0oeSDe+aPw5yECo=; h=Message-ID:Date:MIME-Version:Subject:To:References:From: In-Reply-To:Content-Type; b=rOkE3TD389f3zmqQrGmRljlArZFQshaU4qBj+tGHyWFgzjtpiTTZGIQxWOodxUB7Gfkijt/5c5ifB25VHTNJY7jvctbMZCWBKHHj5DKuiy1aRahDU4+Qf94GjRggMRGURwJ3vXH5TQ/6FW1au1xZFmZGGxCrgtWMo1m7GeYtsQ0= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=baylibre.com; spf=pass smtp.mailfrom=baylibre.com; dkim=pass (2048-bit key) header.d=baylibre-com.20230601.gappssmtp.com header.i=@baylibre-com.20230601.gappssmtp.com header.b=EPiyHYJA; arc=none smtp.client-ip=209.85.161.45 Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=baylibre.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=baylibre.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=baylibre-com.20230601.gappssmtp.com header.i=@baylibre-com.20230601.gappssmtp.com header.b="EPiyHYJA" Received: by mail-oo1-f45.google.com with SMTP id 006d021491bc7-61bd4e14054so1626718eaf.2 for ; Sun, 17 Aug 2025 09:51:25 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=baylibre-com.20230601.gappssmtp.com; s=20230601; t=1755449485; x=1756054285; darn=vger.kernel.org; h=content-transfer-encoding:in-reply-to:from:content-language :references:to:subject:user-agent:mime-version:date:message-id:from :to:cc:subject:date:message-id:reply-to; bh=XOShuqoDRF3qNIrD82l+4By1/XWbaXr8sdy7PQ1Fw2E=; b=EPiyHYJAdc4q4zs5Cpr/ujY7QAwZqeojGZk721sUIZRT/SKmGLDKXyZNRBoDF1Tf0/ n10TL/9En11MhQnUT9lUHojjMcJQKRS4ie/4qnyZhHXyJUA4v2ckP5KkpXGdsKfjf8U0 Vw0G4Pb/DHH/Q8jBKhXXGyUZ/5Dg042O0snwsORrzCh+m2BlBk0t9pkKYvCgsK3nw81h DsKPBYblwEUgySmEIQedZ7avCZZ4SLxBQDCtEL3A9JGjlUwZWMvzZaP261WdMOV03Aij ukt/XjUvBhFdhP+woJNej6gKM6FPwSyHqC5zKeU8iRcxFDv/rZHCjt9/TPxinz41MdLw QGsA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1755449485; x=1756054285; h=content-transfer-encoding:in-reply-to:from:content-language :references:to:subject:user-agent:mime-version:date:message-id :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=XOShuqoDRF3qNIrD82l+4By1/XWbaXr8sdy7PQ1Fw2E=; b=H5NPnDZRJant9xijs/spfsiHRfmkaj0ce7WnP/KpmsAEEKqWttyqARzmQb0nYjD7OA FDJ2QjmmdNRJmfO1HhwOtzzVWVN8xmCQoRwjVRkk2gH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fa44:2318 with SMTP id 006d021491bc7-61bfa443307mr1755652eaf.0.1755449485031; Sun, 17 Aug 2025 09:51:25 -0700 (PDT) Received: from ?IPV6:2600:8803:e7e4:1d00:7648:43db:38fd:de4a? ([2600:8803:e7e4:1d00:7648:43db:38fd:de4a]) by smtp.gmail.com with ESMTPSA id 006d021491bc7-61bebf8d16dsm671683eaf.1.2025.08.17.09.51.23 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Sun, 17 Aug 2025 09:51:24 -0700 (PDT) Message-ID: <8e228d2d-d22f-4092-8c6d-94ce989b4a84@baylibre.com> Date: Sun, 17 Aug 2025 11:51:22 -0500 Precedence: bulk X-Mailing-List: devicetree@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: [PATCH 1/5] dt-bindings: iio: mcp9600: Add compatible for microchip,mcp9601 To: Jonathan Cameron , Ben Collins , =?UTF-8?Q?Nuno_S=C3=A1?= , Andy Shevchenko , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Andrew Hepp , linux-iio@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org References: <20250815164627.22002-1-bcollins@watter.com> <20250815164627.22002-2-bcollins@watter.com> <20250816105825.35e69652@jic23-huawei> <66063382-78c6-4d93-be25-46e972e390f4@baylibre.com> <2025081711-coral-aardwark-9f061b@boujee-and-buff> Content-Language: en-US From: David Lechner In-Reply-To: <2025081711-coral-aardwark-9f061b@boujee-and-buff> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit On 8/17/25 11:37 AM, Ben Collins wrote: > On Sat, Aug 16, 2025 at 01:55:31PM -0500, David Lechner wrote: >> On 8/16/25 4:58 AM, Jonathan Cameron wrote: >>> On Fri, 15 Aug 2025 16:46:03 +0000 >>> Ben Collins wrote: >>> >>>> The mcp9600 driver supports the mcp9601 chip, but complains about not >>>> recognizing the device id on probe. A separate patch... >>>> >>>> iio: mcp9600: Recognize chip id for mcp9601 >>>> >>>> ...addresses this. This patch updates the dt-bindings for this chip to >>>> reflect the change to allow explicitly setting microchip,mcp9601 as >>>> the expected chip type. >>>> >>>> The mcp9601 also supports features not found on the mcp9600, so this >>>> will also allow the driver to differentiate the support of these >>>> features. >>> >>> If it's additional features only then you can still use a fallback >>> compatible. Intent being that a new DT vs old kernel still 'works'. >>> >>> Then for the driver on new kernels we match on the new compatible and >>> support those new features. Old kernel users get to keep the ID >>> mismatch warning - they can upgrade if they want that to go away ;) >>> >>> Krzysztof raised the same point on v2 but I'm not seeing it addressed >>> in that discussion. >> >> One could make the argument that these are not entirely fallback >> compatible since bit 4 of the STATUS register has a different >> meaning depending on if the chip is MCP9601/L01/RL01 or not. > > There are some nuances to this register between the two, but it can be > used generically as "not in range" for both. > > My understanding from the docs is if VSENSE is connected on mcp9601, > then it is explicitly open-circuit detection vs. short-circuit, which > is bit 5. > >> Interestingly, the existing bindings include interrupts for >> open circuit and short circuit alert pins. But these pins >> also only exist on MCP9601/L01/RL01. If we decide these aren't >> fallback compatible, then those properties should have the >> proper constraints added as well. > > In my v4 patch, I'm going to remove the short/open circuit interrupts > since they are not implemented, yet. Don't remove them from the devicetree bindings. Even if the Linux driver doesn't use it, the bindings should be as complete as possible. https://docs.kernel.org/devicetree/bindings/writing-bindings.html > > I have VSENSE wired on my board so I can work on those interrupts and > register support in a later patch series. >