From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail-wm1-f42.google.com (mail-wm1-f42.google.com [209.85.128.42]) (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 48B913AF645 for ; Mon, 23 Mar 2026 16:06:27 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.128.42 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1774281990; cv=none; b=FWulPBqKpIsF5YYlAgKJ41wop/WQzUOGtpYUWhtUByLSNyBSKocs8wdk9gzqdmpQyMzDPWcZRGFKDfaNrmNw3tZ2YyG/U0uxDzTk6noxTJyj3ng32Gz1PDjVwXXj8uNbuUf5ZssBYIOnFqkBAhweMftrOeP5Hr2c8uxlGbzPiaU= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1774281990; c=relaxed/simple; bh=Z/LmWnslyMEA8KuS1V4Xy1sI8gOsop003nSeTpsLEAs=; h=Message-ID:Subject:From:To:Cc:Date:In-Reply-To:References: Content-Type:MIME-Version; b=VW90ObsGTzZGlhSKyrgNVAQselUi88BlCj3ofEV+Ctmpr2/KUeJXC0cfEJGl1Hh57QAfQS2OjzbQAD3KYexnsmYVd0ZpyMp3AjFhOsN/4VUJpBhQTPYU/xQQty9HSAa6PdjyIJXQmq/6C/5jfWGryTTiR0EZqJjGbgf57Nlf1iU= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com; spf=pass smtp.mailfrom=gmail.com; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b=UkHyyJVk; arc=none smtp.client-ip=209.85.128.42 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.b="UkHyyJVk" Received: by mail-wm1-f42.google.com with SMTP id 5b1f17b1804b1-48538c5956bso40557065e9.0 for ; Mon, 23 Mar 2026 09:06:27 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1774281985; x=1774886785; darn=vger.kernel.org; h=mime-version:user-agent:content-transfer-encoding:references :in-reply-to:date:cc:to:from:subject:message-id:from:to:cc:subject :date:message-id:reply-to; bh=iZ+8+0X30kHk32CK+85EMrU3OFRM220+pzBDKFOaV7I=; b=UkHyyJVkpURCccfu4FgMmG+38Vo9SZf7KCxtdSbAfvboG4SzQAkCPb9dr3PrYINV1o zFH256SA8yYsZ6lD+Pq/nOCsvETvekJq3/WonN68fHaQYjomZ931ZwibpWlh4kPMy0uZ WTPVULbC2/mX8IsumKPD90dQchmq+LIWFnX7W4y30/HHKwKLsKUJcIDqX8BiCDilhbWA k7Tmtp22BeQ1CI05HR8D3sG/4VDQKAcVo+BpgLKDunJSn5cjAicCnBItOQOJPxzfPJHS c7Rrk761SDhBKouRNpRHWoWIjhuSZ/nm28Cq/Hel5RvsY57oy1lvRgq0C72drLLAuDD0 seow== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1774281985; x=1774886785; h=mime-version:user-agent:content-transfer-encoding:references :in-reply-to:date:cc:to:from:subject:message-id:x-gm-gg :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=iZ+8+0X30kHk32CK+85EMrU3OFRM220+pzBDKFOaV7I=; b=Olt/OQbWDVMjeBQcEGRKpcwF6r+PCoyhWyCaYmzQBcamfJKXajgeV9WliMdQGo7CXn LThzERudCnGiwd3kdKnQx/tP+ViWNTgwlMwG2H+2eqQGqK20AP8Q83eQJKVLzY5o96s5 BJsBJz9RNL7LwHtsu+93k7bpohsU54QvkoXEjw1pweszrgTDoSF9EOI7R3A+zdoJ8Awa +Ax6raH6EcSFotUhzbOnhvso85cheBURLFZf/Zy32U+zsvj8ANkvx9/Lp9ZHjv+Y7M5C Ans+j+TPVsCwN8tVTtNfFmkvIgWGlewMDv8DsB/Bs/SSTQqYf0LwtDJYTVSp/U6yhctk fDgA== X-Forwarded-Encrypted: i=1; AJvYcCWCiPcqKnn2IUClQRFl/NNThaFAt7l55QrJBnD/1L5LyQBj1L89N1e0bWoRm62KtjryuPxmpNzwL5g=@vger.kernel.org X-Gm-Message-State: AOJu0Yxe7DKzbAhgoaYOtMCL2FgLT3GbpZN5rJdw3HiZFZ9q97u8QAzN XiWey927L6ZIAmg0q+pgA5C2qX4PpUfu1fKER7/ZqyQsNj2pzDXcJ6Ri X-Gm-Gg: ATEYQzzvKDIpAZyu3wTM0Nu8JEA/aBp7PdplUY/jGHH6dl1zRVTZh0pTFjxLbVlJPPM w75DItmSwmBPUdQ5Zr7CE6KtOGTZc6Mcv6dc1A0nTlak0FYnOCCLqp4zOejgA822nN5fimjYjhq kIDv+76ofR+NoxgsyokhypYEhIqUvZLOoFxKtSS4YcCe4vallfHdAnathOkLJ0nqU1m8BFRi+CK JHW5aRlZVQ/o94Nj/S+Hx8RYGnXS7FdUsaEIVJIWPavf+m5HyHV97qEuf4Z44PdVVqB0WasgGe5 o4/gvs9rOI4uqB1C52H2EkM7eu4JJYatQ2wsYOWNfH5E+a9S5CI5QVOPP/zP+VD1SJJBTg4Grfn WU8/JvNEc91jjekjIKuRPnud1a6ceu9drT2oAeQh/alzpr2hLuBnNdgA1cZty51Rs1OKwxYcw/2 axkdoii9LPJoJP9PsjtfIECZHS1Bw6AR+v7K4+pwrHTA== X-Received: by 2002:a05:600c:6096:b0:47e:e59c:67c5 with SMTP id 5b1f17b1804b1-4870f1fc5e2mr1845745e9.8.1774281985360; Mon, 23 Mar 2026 09:06:25 -0700 (PDT) Received: from [192.168.1.187] ([148.63.225.166]) by smtp.gmail.com with ESMTPSA id 5b1f17b1804b1-486fe6d923fsm469841175e9.1.2026.03.23.09.06.24 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 23 Mar 2026 09:06:25 -0700 (PDT) Message-ID: Subject: Re: [PATCH v7 1/3] dt-bindings: hwmon: Document the LTC4283 Swap Controller From: Nuno =?ISO-8859-1?Q?S=E1?= To: Guenter Roeck , nuno.sa@analog.com Cc: linux-gpio@vger.kernel.org, linux-hwmon@vger.kernel.org, devicetree@vger.kernel.org, linux-doc@vger.kernel.org, Rob Herring , Krzysztof Kozlowski , Conor Dooley , Jonathan Corbet , Shuah Khan , Linus Walleij , Bartosz Golaszewski Date: Mon, 23 Mar 2026 16:07:11 +0000 In-Reply-To: <821aafb4-d1a8-4611-addc-5bff4f1e187e@roeck-us.net> References: <20260314-ltc4283-support-v7-0-1cda48e93802@analog.com> <20260314-ltc4283-support-v7-1-1cda48e93802@analog.com> <77cd7e879a10df791d9d5eb1f16f1654e9904199.camel@gmail.com> <453dbd6c-c68d-4977-8418-a898008b0fe7@roeck-us.net> <63baaa6ea6ce7a8534046fea3d9f14fdb26f87a3.camel@gmail.com> <821aafb4-d1a8-4611-addc-5bff4f1e187e@roeck-us.net> Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable User-Agent: Evolution 3.58.3 Precedence: bulk X-Mailing-List: linux-doc@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 On Mon, 2026-03-23 at 08:27 -0700, Guenter Roeck wrote: > On 3/23/26 08:17, Nuno S=C3=A1 wrote: > > On Mon, 2026-03-23 at 07:33 -0700, Guenter Roeck wrote: > > > [ ...] > > > > > > +=C2=A0 adi,pgio1-func: > > > > > > +=C2=A0=C2=A0=C2=A0 description: Configures the function of the= PGIO1 pin. > > > > > > +=C2=A0=C2=A0=C2=A0 $ref: /schemas/types.yaml#/definitions/stri= ng > > > > > > +=C2=A0=C2=A0=C2=A0 enum: [inverted_power_good, power_good, gpi= o] > > > > > > +=C2=A0=C2=A0=C2=A0 default: inverted_power_good > > > > > > + > > > > > > +=C2=A0 adi,pgio2-func: > > > > > > +=C2=A0=C2=A0=C2=A0 description: Configures the function of the= PGIO2 pin. > > > > > > +=C2=A0=C2=A0=C2=A0 $ref: /schemas/types.yaml#/definitions/stri= ng > > > > > > +=C2=A0=C2=A0=C2=A0 enum: [inverted_power_good, power_good, gpi= o, active_current_limiting] > > > > > > +=C2=A0=C2=A0=C2=A0 default: inverted_power_good > > > > > > + > > > > > > +=C2=A0 adi,pgio3-func: > > > > > > +=C2=A0=C2=A0=C2=A0 description: Configures the function of the= PGIO3 pin. > > > > > > +=C2=A0=C2=A0=C2=A0 $ref: /schemas/types.yaml#/definitions/stri= ng > > > > > > +=C2=A0=C2=A0=C2=A0 enum: [inverted_power_good_input, power_goo= d_input, gpio] > > > > > > +=C2=A0=C2=A0=C2=A0 default: inverted_power_good_input > > > > > > + > > > > > > +=C2=A0 adi,pgio4-func: > > > > > > +=C2=A0=C2=A0=C2=A0 description: Configures the function of the= PGIO4 pin. > > > > > > +=C2=A0=C2=A0=C2=A0 $ref: /schemas/types.yaml#/definitions/stri= ng > > > > > > +=C2=A0=C2=A0=C2=A0 enum: [inverted_external_fault, external_fa= ult, gpio] > > > > > > +=C2=A0=C2=A0=C2=A0 default: inverted_external_fault > > > > > > + > > > > > > +=C2=A0 adi,gpio-on-adio1: > > > > > > +=C2=A0=C2=A0=C2=A0 description: If set, the ADIO1 pin is used = as a GPIO. > > > > > > +=C2=A0=C2=A0=C2=A0 type: boolean > > > > > > + > > > > > > +=C2=A0 adi,gpio-on-adio2: > > > > > > +=C2=A0=C2=A0=C2=A0 description: If set, the ADIO2 pin is used = as a GPIO. > > > > > > +=C2=A0=C2=A0=C2=A0 type: boolean > > > > > > + > > > > > > +=C2=A0 adi,gpio-on-adio3: > > > > > > +=C2=A0=C2=A0=C2=A0 description: If set, the ADIO3 pin is used = as a GPIO. > > > > > > +=C2=A0=C2=A0=C2=A0 type: boolean > > > > > > + > > > > > > +=C2=A0 adi,gpio-on-adio4: > > > > > > +=C2=A0=C2=A0=C2=A0 description: If set, the ADIO4 pin is used = as a GPIO. > > > > > > +=C2=A0=C2=A0=C2=A0 type: boolean > > > > >=20 > > > > > Does this dependency block force a redundant specification of adi= ,pgio4-func? > > > > > The default for adi,pgio4-func is inverted_external_fault, which = means the > > > > > default hardware state already supports external fault features. > > > > > If a device tree legitimately omits adi,pgio4-func to rely on tha= t default, > > > > > will it fail schema validation here since the dependencies keywor= d strictly > > > > > checks for the literal presence of properties without injecting d= efaults? > > > >=20 > > > > Fair point. I guess it will fail but the alternative is to not have= any constrain at all so > > > > maybe worth it to be explicit in here? > > > >=20 > > >=20 > > > I don't claim to understand how to define devicetree properties, but > > >=20 > > > adi,pgio4-func =3D <"gpio"> > > >=20 > > > and > > >=20 > > > adi,gpio-on-adio4; > > >=20 > > > seem to be equivalent to me, and omitting the first property (because > >=20 > > Not exactly. ADIO4 and PGIO4 are different pins and can be both configu= red > > as GPIOs. ADIO is a boolean because they are either monitored by the AD= C (default) > > or configured as GPIOs. PGIOs can have additional configurations and he= nce the > > enum. > >=20 >=20 > Ah, I didn't realize the small "A" vs. "G" difference (and apparently > I don't understand what the AI is complaining about ;-). Sorry for the no= ise. >=20 My understanding about the AI complain is the below dependencies: + adi,external-fault-retry-enable: + - adi,pgio4-func + adi,external-fault-fet-off-enable: + - adi,pgio4-func The default value (omitting the property) is a valid case to use any of the= above two flags but with the above, omitting the property and adding the flag should = result in an error when validating the binding (because of the dependency). That is w= hy I replied with "Fair point. I guess it will fail but the alternative is to not have any co= nstrain at all so maybe worth it to be explicit in here?" - Nuno S=C3=A1