From patchwork Fri Mar 1 17:47:28 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Raphael Gallais-Pou X-Patchwork-Id: 208986 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a05:7301:fa17:b0:10a:f01:a869 with SMTP id ju23csp41555dyc; Fri, 1 Mar 2024 09:48:24 -0800 (PST) X-Forwarded-Encrypted: i=3; AJvYcCW5WGO+XVjmJnPoLu9ofXb5//RU40JSbYqMu40RKJZAwPsp24PBunjdYt7PQkIBELWF4XfFuqJYAV4ZanvhFSSJvwVWcg== X-Google-Smtp-Source: AGHT+IFI+qeyZknFz1DKgZ9yvccTl/rn4A41h44o4cmdrP1OTqL/kXGeQ5dZy4rbifvNl1CBXlsu X-Received: by 2002:a05:6402:3410:b0:566:ab94:5b83 with SMTP id k16-20020a056402341000b00566ab945b83mr1996202edc.23.1709315304033; Fri, 01 Mar 2024 09:48:24 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1709315304; cv=pass; d=google.com; s=arc-20160816; b=iY47GnzDs7it90uhjTdkzaNGPyja0mBRPD+zvvKUNz/yxKWqM/xIN3UFZ95PpQtn1Y hA1GYWijwycMdlAnJ8x6OZtEK7tBGsDYnVvLZ4ZZXSiXvftvOmwOuek6msX/tPdBxR5R 2nXM4ApJb0fBxI5l6bxvS2CFTWnSHzN9/hVNOq5/CaU6ufIn+FLVWOLqQWDGw0p2kuPQ f0VdGJRYjgYQFcH9uxj2w3qBXZJeoio6mzfIGUAZmLWvkT00rgc4wcHBIDJfjtyFo8Os 675pQPAexomXAWwPlU2SJIU/AHvNScgPww7RcJiAjoaGd2eSc8YYImDS4fhBlrOHiRq9 U69Q== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:list-unsubscribe:list-subscribe:list-id:precedence :subject:date:from:dkim-signature; bh=3FnpEmiF4nPHhd94SMr00ku6sR56qnzsYgoCp8rfi9I=; fh=yv246u0rkVHqkSm9cACXumms6CotF1rPqSUPyinGUaA=; b=KEu6o0AshxlFo1r7+MWjbOlmFNGa/HxEWzf44ZbY2jyNuRf91Md1D4hAxwOcNbihMk 5CJl2yaskSJHBozqKSXlm2qUYnxyWrcKpoxAjaClRZL3zHVjfngNjbLV7jDAGPbVa0gm rrjrYSJcoVFKTlUnwDIgT5+v6CrTSbYutXqpLbR8CGsBDURYUSAFYqjYPLl2Z0LcDZqk LiOcTzgMJTDXxQvyjmlE4NbC4EJCbcEdyo3131HBWdmtgTtblGvXCkTKWRycUnlWUXN4 okTVTPN41371o5TU0FPUup5A1TTfZqk+fd7Vn29COB568yxbKZ+/XDyNcCo2vYy6b5xk T8Xg==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@gmail.com header.s=20230601 header.b=Lra+oVS+; arc=pass (i=1 spf=pass spfdomain=gmail.com dkim=pass dkdomain=gmail.com dmarc=pass fromdomain=gmail.com); spf=pass (google.com: domain of linux-kernel+bounces-88859-ouuuleilei=gmail.com@vger.kernel.org designates 2604:1380:4601:e00::3 as permitted sender) smtp.mailfrom="linux-kernel+bounces-88859-ouuuleilei=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: from am.mirrors.kernel.org (am.mirrors.kernel.org. [2604:1380:4601:e00::3]) by mx.google.com with ESMTPS id eb10-20020a0564020d0a00b0056529e7d47esi1628052edb.494.2024.03.01.09.48.23 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 01 Mar 2024 09:48:24 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-88859-ouuuleilei=gmail.com@vger.kernel.org designates 2604:1380:4601:e00::3 as permitted sender) client-ip=2604:1380:4601:e00::3; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20230601 header.b=Lra+oVS+; arc=pass (i=1 spf=pass spfdomain=gmail.com dkim=pass dkdomain=gmail.com dmarc=pass fromdomain=gmail.com); spf=pass (google.com: domain of linux-kernel+bounces-88859-ouuuleilei=gmail.com@vger.kernel.org designates 2604:1380:4601:e00::3 as permitted sender) smtp.mailfrom="linux-kernel+bounces-88859-ouuuleilei=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by am.mirrors.kernel.org (Postfix) with ESMTPS id 98A6A1F25C62 for ; Fri, 1 Mar 2024 17:48:23 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 274F937160; Fri, 1 Mar 2024 17:47:39 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="Lra+oVS+" Received: from mail-wm1-f47.google.com (mail-wm1-f47.google.com [209.85.128.47]) (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 52ADC4C99; Fri, 1 Mar 2024 17:47:34 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.128.47 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1709315256; cv=none; b=WeeMUeU/12msabr4Bm/SxC/yqS70Fk8TyMuOysUQ7o5vtI+4TsDnI3Gk7uIt+3uyJoAhlxu6hgvu2tV/E3cKZVA4PpZeAjAtLvYGrfLzT6GJesHojQO/bB2eKoiqv+sd+mzSJWzSDBOEZg7WSV0B0T45lXnfI4S+njhwk6CG+64= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1709315256; c=relaxed/simple; bh=GuG6OcP2Q+V1fhDTC1pxrssX/s5xM4U3zgiW3bxBV9E=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=Tuv1JYBC2TJ4Q6Q4FSXuH1yJkfO11rgaNl2spoXVW5jrUR7pTK9D3unUPAk3BdqNdtZc4GsoQR8fVq3RReDcPzpslvfftNzEcyePkigGS9c0kajSThTqp4Zg99cUqRPyZibi9hpRqeNuB6tdeg37LyPjy3YrzEsyYQ0y4lP2Ylg= 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=Lra+oVS+; arc=none smtp.client-ip=209.85.128.47 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 Received: by mail-wm1-f47.google.com with SMTP id 5b1f17b1804b1-412b83cfac4so16931625e9.0; Fri, 01 Mar 2024 09:47:34 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1709315253; x=1709920053; darn=vger.kernel.org; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:from:to:cc:subject:date:message-id :reply-to; bh=3FnpEmiF4nPHhd94SMr00ku6sR56qnzsYgoCp8rfi9I=; b=Lra+oVS+EO15mvvQPWPiBNURcSGfKX1Qv3+oP1f+9Uv5tnKbJlfjhpLtGCp4khI1aB kTPbWbHqWEZ1uxD22XJ36v6+bWWTqFjaJoN6gPi2xs6+dFg6gOlro9XeYGpGIg81BEoM c0N02shpsKP6ZbcR7pbO/OwTs16teVgqpHekxhHBwLMj/JeiYf68x5C2QX4uAbY0B9bL qcG6Lmp9pxLt3pboMTHHksvJtBgngJ0ddJWn9fATfwShqIW/locu77rU2kHDdc28utpV WIyF3v3ZK0zbMN6ltHeptxQutfg62MyoZdJemCJlenZpbjgzT6pdMZhBxK//lntdzvyY aHmw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1709315253; x=1709920053; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=3FnpEmiF4nPHhd94SMr00ku6sR56qnzsYgoCp8rfi9I=; b=lTz/JPDrsoOPazfmY6e6QYF9s5jLx9yvn/GYWxYmA1JcfUl4K3DA8Qswt3DEDvPrLz jSIjTMFJEUppchmmqVZTG1oKKq3xcsPxVfQw7R4a1pY/apFyZsxsWxNo2Et7eWHMbCS9 GBrJjK0rrHiLByuW1eleAbHPU6jTotAFSbMXRVNVzUWkXiIgF9TWG5PSnYc40qCb8KBW qVJ6AQOcjsiPxpVDIEY+kLqhhEowymqyH5GTBpgso2oqk5q1qEHtuIOg/qZQ4zOeADlC 8q0EONR5/+IvZk9UDk9yqabOB/m1W8ORpFZ6LrDXK/DlfEDyWy9n4/WlSrmQ0dwWiibh naOg== X-Forwarded-Encrypted: i=1; AJvYcCU1KK8TSMeiTdSGjfzwY8lu0eLGppHL6iDGaPSnl2S/CzM5mIRsL5npqMz8Txf90ZSRFtjF2QT7/lBGbprOII6BQsa4Uj6JXR8Kt4bmsUfjVElzt2FMCEVEXHc8siFjDW8W+zIcrDy1BQ== X-Gm-Message-State: AOJu0Yz+RYLrQLtDWSStFEfDdrK8CLJGiV5LUkHjJ1JBW7KLwQNqIdG5 mgnXduRj/1xXGKsK9egbtk2+oGDv8OWKSJTE9knmadABLszk8sOF X-Received: by 2002:a05:6000:12c5:b0:33e:1e0d:658c with SMTP id l5-20020a05600012c500b0033e1e0d658cmr1573306wrx.70.1709315252594; Fri, 01 Mar 2024 09:47:32 -0800 (PST) Received: from localhost ([2001:861:3385:e20:6384:4cf:52c5:3194]) by smtp.gmail.com with ESMTPSA id bu16-20020a056000079000b0033dc3f3d689sm5144705wrb.93.2024.03.01.09.47.32 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 01 Mar 2024 09:47:32 -0800 (PST) From: Raphael Gallais-Pou Date: Fri, 01 Mar 2024 18:47:28 +0100 Subject: [PATCH v2 1/2] dt-bindings: thermal: convert st,stih407-thermal to DT schema Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Message-Id: <20240301-thermal-v2-1-1b32752029ec@gmail.com> References: <20240301-thermal-v2-0-1b32752029ec@gmail.com> In-Reply-To: <20240301-thermal-v2-0-1b32752029ec@gmail.com> To: "Rafael J. Wysocki" , Daniel Lezcano , Zhang Rui , Lukasz Luba , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Patrice Chotard , Lee Jones Cc: linux-pm@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org X-Mailer: b4 0.13.0 X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1792347004579700849 X-GMAIL-MSGID: 1792347004579700849 'st,passive_colling_temp' does not appear in the device-tree, and 'reg' is missing in the device description. Convert st,stih407-thermal binding to DT schema format in order to clean unused 'st,passive_cooling_temp' and add missing 'reg' property. Signed-off-by: Raphael Gallais-Pou --- Changes in v2: - Change commit log to use imperative - Drop description - Drop 'clocks' description - Add 'reg' property - Add '#thermal-sensor-cells' - Make node name generic in example - Fix YAML style --- .../bindings/thermal/st,stih407-thermal.yaml | 56 ++++++++++++++++++++++ .../devicetree/bindings/thermal/st-thermal.txt | 32 ------------- 2 files changed, 56 insertions(+), 32 deletions(-) diff --git a/Documentation/devicetree/bindings/thermal/st,stih407-thermal.yaml b/Documentation/devicetree/bindings/thermal/st,stih407-thermal.yaml new file mode 100644 index 000000000000..68d7dd8b892f --- /dev/null +++ b/Documentation/devicetree/bindings/thermal/st,stih407-thermal.yaml @@ -0,0 +1,56 @@ +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) +%YAML 1.2 +--- +$id: http://devicetree.org/schemas/thermal/st,stih407-thermal.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: STMicroelectronics STi digital thermal sensor (DTS) + +maintainers: + - Patrice Chotard + - Lee Jones + +allOf: + - $ref: thermal-sensor.yaml + +properties: + compatible: + const: st,stih407-thermal + + reg: + maxItems: 1 + + clocks: + maxItems: 1 + + clock-names: + items: + - const: thermal + + interrupts: + description: + For thermal sensors for which no interrupt has been defined, a polling + delay of 1000ms will be used to read the temperature from device. + + '#thermal-sensor-cells': true + +required: + - compatible + - reg + - clocks + - clock-names + +unevaluatedProperties: false + +examples: + - | + #include + temperature-sensor@91a0000 { + compatible = "st,stih407-thermal"; + reg = <0x91a0000 0x28>; + clock-names = "thermal"; + clocks = <&CLK_SYSIN>; + interrupts = ; + #thermal-sensor-cells = <0>; + }; +... diff --git a/Documentation/devicetree/bindings/thermal/st-thermal.txt b/Documentation/devicetree/bindings/thermal/st-thermal.txt deleted file mode 100644 index a2f939137e35..000000000000 --- a/Documentation/devicetree/bindings/thermal/st-thermal.txt +++ /dev/null @@ -1,32 +0,0 @@ -Binding for Thermal Sensor driver for STMicroelectronics STi series of SoCs. - -Required parameters: -------------------- - -compatible : Should be "st,stih407-thermal" - -clock-names : Should be "thermal". - See: Documentation/devicetree/bindings/resource-names.txt -clocks : Phandle of the clock used by the thermal sensor. - See: Documentation/devicetree/bindings/clock/clock-bindings.txt - -Optional parameters: -------------------- - -reg : For non-sysconf based sensors, this should be the physical base - address and length of the sensor's registers. -interrupts : Standard way to define interrupt number. - NB: For thermal sensor's for which no interrupt has been - defined, a polling delay of 1000ms will be used to read the - temperature from device. - -Example: - - temp0@91a0000 { - compatible = "st,stih407-thermal"; - reg = <0x91a0000 0x28>; - clock-names = "thermal"; - clocks = <&CLK_SYSIN>; - interrupts = ; - st,passive_cooling_temp = <110>; - };