Received: by 2002:a25:8b12:0:0:0:0:0 with SMTP id i18csp1425842ybl; Fri, 16 Aug 2019 15:03:31 -0700 (PDT) X-Google-Smtp-Source: APXvYqxVkUY7yjAwsZwssO3gcszsQ1iGTG6b4uyajYxZICgh7g4hTiiHXu9nqQrXzda9L0P2Zm2M X-Received: by 2002:aa7:96dc:: with SMTP id h28mr12935196pfq.86.1565993011852; Fri, 16 Aug 2019 15:03:31 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1565993011; cv=none; d=google.com; s=arc-20160816; b=ZtP5/p3DiRXQMm2A4lbGI76d2dtL5ZZnrsS/RVdHzhFpUz9mF6k2JEoORP8+oZFfEK 0PlwuYzWwSaTmSZHEGdpt7U6wl1ViVi/bhgo+PxWINkpsfK5c2hJC5MP1gTWKD64oyh6 Xv4c9orZIQ0UPZPxUneFpKEFiBGOJCTlgFfyCzCid/SDYVMlb+i3EPyLVgO7mWy5fh6V HsgGvZwjtvBDzB81Y8ZTfh4bi5q4p37jHzhcJFVGl4xVaTyjB+svi8HmLg4j4QDmg/a5 RZ4BGnjx9lsX5Js6ISlGh3jTr6IMkN2/bIwNSom14J10q0BUVkPtG8P7Zt6tR4BwtIDu XzRA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:dkim-signature; bh=cIdFGwAFSrX7ZRwqgTTFqmzXANmZBCVeaNYXvQ0ZoyU=; b=tm00TBMr1tGtcuoybdgOCvkl28mxL3ArJZ/jDcPY7+UwINAGMu0ZMYgMhjI3PrE8mU 8OydognNJw2Plo4Zyl8OiAgzPF3+FOa21hfnA+1um9a1g9D9L4kUqqFKPt1yDXtKKLtB B8I/+bVIiQB1RQJFrPE+nwP5LlULUG3m3uwMuvd2oxuE7tN2iBiNUbdaBm6Z/BJIIAMl Wjz4JJVirA83/iFKYTYQ8DgmTlqVKpAK4xB7rI32Yg8wog4DYdpX/fJyhyNLF6P3MLaz V9TCMXg4ySjva0KJ1Za2k9G+V89SoaY9/Ve3vOjSSOZNcAfREzCk+wkpP0cfboavYSAr id1A== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=dUJONrVP; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id br21si3066684pjb.14.2019.08.16.15.03.05; Fri, 16 Aug 2019 15:03:31 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=dUJONrVP; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727772AbfHPWCV (ORCPT + 99 others); Fri, 16 Aug 2019 18:02:21 -0400 Received: from mail-qk1-f193.google.com ([209.85.222.193]:42797 "EHLO mail-qk1-f193.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727696AbfHPWCV (ORCPT ); Fri, 16 Aug 2019 18:02:21 -0400 Received: by mail-qk1-f193.google.com with SMTP id 201so5947533qkm.9 for ; Fri, 16 Aug 2019 15:02:20 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=cIdFGwAFSrX7ZRwqgTTFqmzXANmZBCVeaNYXvQ0ZoyU=; b=dUJONrVPTpPrPScArOmcSXk2K3n6gMPUME0lg/JAo05DH5KjPKEObft+IvMnsF54PC cdlSN+TqqDKcX8H/y0wGj7aYiFj5o+97V7xlnGGJjySN8HgwdAFlhcdn+RzcwrpAj3oE 6f37nXrGs5jWjp2vUtdD8Erckv9FzWgr1b192uQujyK171boGIJ98LdDYXsi+rOSnEwg aNh5aLncqA3uQ4PD29IYKUMqA45Sji2ad3iGhgDEVIKSYSlJD+0sdJUXgbIAWg1XZCdt jmtv16rt6wEphtlRbGW8D5coFLmUKNj0lGwCTQfJ5Qqp9/yXMHi5TIcUF/fOtu8M8JTO bjiQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=cIdFGwAFSrX7ZRwqgTTFqmzXANmZBCVeaNYXvQ0ZoyU=; b=aNvA7KpcnKzpvUiieRBjJ8nH83mR0hezHIPOUxNp+LrZH4+PYe9fxNnnnyDkijODK9 DqLgLKTYHFITF97Gi7H93+rZrj+5xu4CH+Jbx6wMdSmlyTzrS9u0qFI8luEeeE34QVQq gYRVomgNsCSSyw1V1eYcVuRJPa/F/jU2rJpaK0p71zOg/tawkFCkPRZtzayQj5qesbfI YJ9+mKqOWTcFde/sorsUPXk0OZVtCTOIRoRIhpXIN5F+edLiLALc/CIpruT9lDr1GGg4 SPcYvfbYbM59xskd5muLmJno79Q7Ur4ZrVsl9WAcy510FseMYCu4a34vKalOByvbtN/R v+1Q== X-Gm-Message-State: APjAAAWw6fD1N8QGQZtCF10Kjus4N80KKoVdfPGgUM03mOCBugK0DUTW UsWHY9FPeZ47m0MEsjZ5KKTGQ2odYfThXH5mJUaofQ== X-Received: by 2002:a05:620a:5f7:: with SMTP id z23mr10726778qkg.106.1565992939659; Fri, 16 Aug 2019 15:02:19 -0700 (PDT) MIME-Version: 1.0 References: <72bce036fa8cba3db6e5ba82249837ee46e9c077.1564091601.git.amit.kucheria@linaro.org> <20190816213648.GA10244@bogus> In-Reply-To: <20190816213648.GA10244@bogus> From: Amit Kucheria Date: Sat, 17 Aug 2019 03:32:08 +0530 Message-ID: Subject: Re: [PATCH 07/15] dt: thermal: tsens: Document interrupt support in tsens driver To: Rob Herring Cc: Linux Kernel Mailing List , linux-arm-msm , Bjorn Andersson , Eduardo Valentin , Andy Gross , Andy Gross , Daniel Lezcano , Mark Rutland , Zhang Rui , Linux PM list , DTML Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Sat, Aug 17, 2019 at 3:06 AM Rob Herring wrote: > > On Fri, Jul 26, 2019 at 03:48:42AM +0530, Amit Kucheria wrote: > > Define two new required properties to define interrupts and > > interrupt-names for tsens. > > > > Signed-off-by: Amit Kucheria > > --- > > Documentation/devicetree/bindings/thermal/qcom-tsens.txt | 5 +++++ > > 1 file changed, 5 insertions(+) > > > > diff --git a/Documentation/devicetree/bindings/thermal/qcom-tsens.txt b/Documentation/devicetree/bindings/thermal/qcom-tsens.txt > > index 673cc1831ee9..3d3dd5dc6d36 100644 > > --- a/Documentation/devicetree/bindings/thermal/qcom-tsens.txt > > +++ b/Documentation/devicetree/bindings/thermal/qcom-tsens.txt > > @@ -22,6 +22,8 @@ Required properties: > > > > - #thermal-sensor-cells : Should be 1. See ./thermal.txt for a description. > > - #qcom,sensors: Number of sensors in tsens block > > +- interrupts: Interrupts generated from Always-On subsystem (AOSS) > > +- interrupt-names: The name of the interrupt e.g. "tsens0", "tsens1" > > How many interrupts? A name with just indices isn't too useful. Depending on the version of the tsens IP, there can be 1 (upper/lower threshold), 2 (upper/lower + critical threshold) or 3 (upper/lower + critical + zero degree) interrupts. This patch series only introduces support for a single interrupt (upper/lower). I used the names tsens0, tsens1 to encapsulate the controller instance since some SoCs have 1 controller, others have two. So we'll end up with something like the following in DT: tsens0: thermal-sensor@c263000 { compatible = "qcom,sdm845-tsens", "qcom,tsens-v2"; reg = <0 0x0c263000 0 0x1ff>, /* TM */ <0 0x0c222000 0 0x1ff>; /* SROT */ #qcom,sensors = <13>; interrupts = , ; interrupt-names = "tsens0", "tsens0-critical"; #thermal-sensor-cells = <1>; }; tsens1: thermal-sensor@c265000 { compatible = "qcom,sdm845-tsens", "qcom,tsens-v2"; reg = <0 0x0c265000 0 0x1ff>, /* TM */ <0 0x0c223000 0 0x1ff>; /* SROT */ #qcom,sensors = <8>; interrupts = , ; interrupt-names = "tsens1", "tsens1-critical"; #thermal-sensor-cells = <1>; } Does that work? Regards, Amit > > - Refer to Documentation/devicetree/bindings/nvmem/nvmem.txt to know how to specify > > nvmem cells > > > > @@ -40,6 +42,9 @@ tsens0: thermal-sensor@c263000 { > > reg = <0xc263000 0x1ff>, /* TM */ > > <0xc222000 0x1ff>; /* SROT */ > > #qcom,sensors = <13>; > > + interrupts = ; > > + interrupt-names = "tsens0"; > > + > > #thermal-sensor-cells = <1>; > > }; > > > > -- > > 2.17.1 > >