From mboxrd@z Thu Jan 1 00:00:00 1970 Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.remote-ip=100.103.45.18 ARC-Seal: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=none; t=1796092911; b=casGY74oGQXwD2q8awuZhZK3HxhUcjHDEKrJJGWii5PUBhSuzEtjPgCXMOJo4BbXVUGH QMn0AJKket6CE9z4+yY0BS4c/tGDDpK8E9VFN6okw47lyPYD1dDxO9FVvdjlTRG42StEt npb4C1fWYiheTG06jCNai0B5IqZ1R8+2H+5q3zSTqFaiBwIpa0Rb88iw567N4BrKkiChj Wu0BCb9WioVAnrpEbrZfIRKUToMlom26NAAlnAebHLSEQX4gwscGgnWxnW6Gotu7ZGBqL LfQ3RuCREEgpEwHS+C2oyb3foZwcVtnjdh0pm2WfpMt0j6Ejp57jQ8vSbRy4ARj0iow== ARC-Message-Signature: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; c=relaxed/relaxed; t=1796092911; h=Received:DKIM-Signature:Date:From:To:Cc:Subject:Message-ID: References:MIME-Version:Content-Type:Content-Disposition:In-Reply-To; bh=0MiUq+UbYs6mnPFNUAmBCeCX8YKC26RsuAvEdqXS52k=; b=ghgHNxUFFeHHSTXSURhJLydm/+Gv1cJNcsthCbXzXHMpap9XjgbnEM7p5NyzE958APsr 1ZT92GBA2hTf3n/BRxC9yn1aReHl5WR1M/cj8+a2gAdpD8KIM7VJq2KMieAcCpzthtX5C 7FPBM4yc0/AIXeH54gDESgjwi+hPzwEZQh8jSUmezBRwagwDswtIEY/T9LKaWtrTfnEC9 v7emzTg2+Cg4vBR0zfMRgoJXLVTg2nN4QqRNrCbxj3RCY/1E4I3/o5+0xm/okYoTp9MQ3 SM3BhIeCRcn9mhYGtd9ZwGoaCNeHyqRNFdSvY0TyJPOkhit2X5i07bfnt3W4nthQKDQ== ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dkim=pass header.d=kernel.org header.i=@kernel.org header.a=rsa-sha256 header.s=k20260515 header.b=DbWZcQrM; arc=none smtp.remote-ip=100.103.45.18 Received: from smtp.kernel.org (quasi.space.kernel.org [100.103.45.18]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (prime256v1)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id DCF58606A31A; Tue, 1 Dec 2026 02:41:51 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.a=rsa-sha256 header.s=k20260515 header.b=DbWZcQrM Received: by smtp.kernel.org (Postfix) with ESMTPSA id E17E31F000C1; Tue, 1 Dec 2026 02:41:50 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=kernel.org; s=k20260515; t=1796092911; bh=0MiUq+UbYs6mnPFNUAmBCeCX8YKC26RsuAvEdqXS52k=; h=Date:From:To:Cc:Subject:References:In-Reply-To; b=DbWZcQrM5zVsIAhx/j6n4LHZ2dNpfi3FPNxxThQITSCIDntPqTfcGyEd8Wqx7D/rv shIB3ZMihFAH1DA5EXLWa2eAl5NX/p0+EkT6WzE+4disQlwMICnsleC9Cq90/FVY00 eM5soUZIjojVNiWREtr4EgRqK9EaPyyWibn0fES/PQJj/X9yRwR2jMad9sMFWCOqp1 bEOw8J1ONjKMlHKJXWYop5M0eNCy7dpAZJSSk1EazwpZSxe23RH1eBDFjhghK1Tc7A 4RS7+d8+lKUqBYv86MEWb6CnGPPiExxvGch6KypMYQX0LW3mWYMSoBfWOVAQtFEWD2 Yf9JmnNR2jJuQ== Date: Mon, 30 Nov 2026 20:41:49 -0600 From: Rob Herring To: Akshay Gupta Cc: linux-hwmon@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-doc@vger.kernel.org, linux@roeck-us.net, krzk+dt@kernel.org, conor+dt@kernel.org, corbet@lwn.net, skhan@linuxfoundation.org, rdunlap@infradead.org, arnd@arndb.de, gregkh@linuxfoundation.org, naveenkrishna.chatradhi@amd.com, Anand.Umarji@amd.com, Prathima Lk Subject: Re: [PATCH v1 2/4] dt-bindings: hwmon: add DIMM thermal sensor properties Message-ID: <20261201024149.GA3978064-robh@kernel.org> References: <20261116120228.865196-1-Akshay.Gupta@amd.com> <20261116120228.865196-3-Akshay.Gupta@amd.com> X-Mailing-List: devicetree@vger.kernel.org List-Id: List-Post: List-Help: List-Subscribe: List-Unsubscribe: List-Owner: Precedence: list MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20261116120228.865196-3-Akshay.Gupta@amd.com> On Mon, Nov 16, 2026 at 05:32:26PM +0530, Akshay Gupta wrote: > From: Prathima Lk > > The SB-RMI mailbox also reports the temperature of the TS0/TS1 thermal > sensors on each DIMM (command 0x48, Mode 1 DIMM_ADDRESS). Boards differ > in how many DIMMs are fitted per memory channel and which sensors are > populated, so describe both in the binding. > > Add two optional properties: > > - amd,dpc: uint8, DIMMs per channel, 1 or 2 (default 1). > > - amd,dimm-ids: uint8 array of 1 to 32 unique Mode 1 DIMM_ADDRESS > values, one per sensor to report. Encoding: bit[7]=1 (Mode 1), > bit[6] sensor (0=TS0, 1=TS1), bit[5] reserved, bit[4] DIMM slot, > bit[3:0] memory channel. When absent, the TS0 and TS1 sensors of > all 16 DIMMs are reported. All this is defined in the diff itself. No need to put in the commit msg too. > > The allowed amd,dimm-ids values depend on amd,dpc: with one DIMM per > channel 0x80-0x8f and 0xc0-0xcf; with two, 0x80-0x87, 0x90-0x97, > 0xc0-0xc7 and 0xd0-0xd7. This rejects the reserved bit, a slot bit > without a second DIMM, and channels above 7 with two DIMMs per channel. > > Also mention the DIMM sensors in the title and description and extend > the example. > > Signed-off-by: Prathima Lk > Signed-off-by: Akshay Gupta > --- > .../devicetree/bindings/hwmon/amd,sbrmi.yaml | 59 +++++++++++++++++-- > 1 file changed, 55 insertions(+), 4 deletions(-) > > diff --git a/Documentation/devicetree/bindings/hwmon/amd,sbrmi.yaml b/Documentation/devicetree/bindings/hwmon/amd,sbrmi.yaml > index 353d81d89bf5..f08b62133996 100644 > --- a/Documentation/devicetree/bindings/hwmon/amd,sbrmi.yaml > +++ b/Documentation/devicetree/bindings/hwmon/amd,sbrmi.yaml > @@ -4,9 +4,7 @@ > $id: http://devicetree.org/schemas/hwmon/amd,sbrmi.yaml# > $schema: http://devicetree.org/meta-schemas/core.yaml# > > -title: > > - Sideband Remote Management Interface (SB-RMI) compliant > - AMD SoC power device. > +title: AMD SoC SB-RMI power and DIMM thermal sensor > > maintainers: > - Akshay Gupta > @@ -16,7 +14,8 @@ description: | > interface that reports AMD SoC's Power (normalized Power) using, > Mailbox Service Request and resembles a typical 8-pin remote power > sensor's I2C interface to BMC. The power attributes in hwmon > - reports power in microwatts. > + reports power in microwatts. The same mailbox also reports the > + temperature of the TS0/TS1 thermal sensors on each populated DIMM. > > properties: > compatible: > @@ -33,10 +32,60 @@ properties: > \[open source SoC register reference\] > https://www.amd.com/en/support/tech-docs?keyword=55898 > > + amd,dpc: amd,dimms-per-chan > + $ref: /schemas/types.yaml#/definitions/uint8 > + enum: [1, 2] > + default: 1 > + description: > + DIMMs per channel (dimms-per-channel), the number of DIMM slots per > + memory channel. You've said the same thing 3 times. > + > + amd,dimm-ids: > + $ref: /schemas/types.yaml#/definitions/uint8-array > + minItems: 1 > + maxItems: 32 > + uniqueItems: true > + description: | > + Mode 1 SB-RMI DIMM_ADDRESS of each DIMM thermal sensor to report. > + Encoding: bit[7]=1 (Mode 1), bit[6] sensor (0=TS0, 1=TS1), bit[5] > + reserved, bit[4] DIMM slot, bit[3:0] memory channel ID. With one DIMM > + per channel bit[4] is 0; with two, the memory channel ID is 0-7. > + When absent, the TS0 and TS1 sensors of all 16 DIMMs are reported. > + > required: > - compatible > - reg > > +allOf: > + - if: > + required: > + - amd,dpc > + properties: > + amd,dpc: > + const: 2 > + then: > + properties: > + amd,dimm-ids: > + items: > + anyOf: oneOf An entry can't be more than 1 number. > + - minimum: 0x80 > + maximum: 0x87 > + - minimum: 0x90 > + maximum: 0x97 > + - minimum: 0xc0 > + maximum: 0xc7 > + - minimum: 0xd0 > + maximum: 0xd7 > + else: > + properties: > + amd,dimm-ids: > + items: > + anyOf: oneOf > + - minimum: 0x80 > + maximum: 0x8f > + - minimum: 0xc0 > + maximum: 0xcf > + > additionalProperties: false > > examples: > @@ -48,6 +97,8 @@ examples: > sbrmi@3c { > compatible = "amd,sbrmi"; > reg = <0x3c>; > + /* TS0 sensors of the DIMMs on memory channels 0-7 */ > + amd,dimm-ids = /bits/ 8 <0x80 0x81 0x82 0x83 0x84 0x85 0x86 0x87>; > }; > }; > ... > -- > 2.34.1 >