Received: by 2002:ac0:a5a7:0:0:0:0:0 with SMTP id m36-v6csp1202054imm; Wed, 11 Jul 2018 20:01:52 -0700 (PDT) X-Google-Smtp-Source: AAOMgpeUDE8YV6yF0EIyNgqAbVcgmo+otVjHR0AsEVFni7ckxKRo5oa9PBjLQenX2fyq5Vt3714+ X-Received: by 2002:a65:5288:: with SMTP id y8-v6mr440358pgp.284.1531364512046; Wed, 11 Jul 2018 20:01:52 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1531364512; cv=none; d=google.com; s=arc-20160816; b=S4sbDzqUWi1FwHgP0f/LtVX7LC2WBakiczGPGqRqKvvI28avv0ReT0lCP7QsPfMhqC N/g0qxXsNlyTWX8WMtsf0huwpYxw63/KTSGvyD/vN2giRYZVFl7i89gsUwFbqf+YpeVi TF5a0yYw4aNVWTyz0er1bx0JhUQg3idIkf0cIsxgiRVatC0CmiUx4+AP+dJl6rPLvYJn /lP59jFVD1W6EbgI8yBPG4ZEahpSDQl5JWPg94OAGn3QQKe9v+VE0zajA8Ilz666egAP R4myGSTZhYF62hSbwPTXFAIih3PEpgdn9kTCAiOGQ/DkS8ChseXETnxMjYrX6YORok97 Lc/A== 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 :references:in-reply-to:mime-version:dkim-signature:dkim-signature :arc-authentication-results; bh=5k/k+uPKwa9Palxh0LzQfvkzZ+n3MsPFuH6dwwTGtFw=; b=JOzjdN5E8UFPlMj+yujaRRJGP/KUKfyLb5Wsj937GaLLy4ULnda9+8q1Rqdn70AuPn Xrx9fL+5rWcWk+0KKUHJGeT0TBkoqjsGyN2nAxMToPOCpYPN2NMz3IfDgs/rBkmKM7HU PcFNi41ORDCT6wm3rZvp/wUJiF0KbQVtGLd7+w/63mEAi1M1q8z5VixGd+gc18+Sg/VD Ug6lMQ+UThekO9Kqm+VC5R8LzkRNjGuLmDhCwKFBFsy5LmTGvYTGYWn76WxBt2s7KWxF ZQPdmWVvAVCPGdhnTTsNRrOc3L/YA4cePO8GKk/WRRwRjhr1+txniZnE0QhXJpSB7J8i zRWQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@google.com header.s=20161025 header.b=XY89ZD2o; dkim=fail header.i=@chromium.org header.s=google header.b=HKbr3KXO; 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=fail (p=NONE sp=NONE dis=NONE) header.from=chromium.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id g7-v6si20277444plt.149.2018.07.11.20.01.36; Wed, 11 Jul 2018 20:01:52 -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=fail header.i=@google.com header.s=20161025 header.b=XY89ZD2o; dkim=fail header.i=@chromium.org header.s=google header.b=HKbr3KXO; 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=fail (p=NONE sp=NONE dis=NONE) header.from=chromium.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2389312AbeGKWHV (ORCPT + 99 others); Wed, 11 Jul 2018 18:07:21 -0400 Received: from mail-vk0-f65.google.com ([209.85.213.65]:44726 "EHLO mail-vk0-f65.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2387457AbeGKWHU (ORCPT ); Wed, 11 Jul 2018 18:07:20 -0400 Received: by mail-vk0-f65.google.com with SMTP id 125-v6so15275514vke.11 for ; Wed, 11 Jul 2018 15:00:57 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20161025; h=mime-version:sender:in-reply-to:references:from:date:message-id :subject:to:cc; bh=5k/k+uPKwa9Palxh0LzQfvkzZ+n3MsPFuH6dwwTGtFw=; b=XY89ZD2obVOEaFkS6X9moL061+LkTeIBesfSpmWv00Ya0unEHgFfNnKipOut4VIou2 OHmMV3vvqOZzO1s/6OL3ODgAXezTGeRAg6OrccJseJmpoL9hwAyhnk1uDIJtyZtiAcdi 9IQvIq/01y+11NMkkPTYGZdkW/n3NaJLmStD2n/bk+v9Yr6mgii0QJngctDuWu1zepSg iZsSbBlrcghTGaRdM7c+mXpdKDjwDKIVB8aFmYcxZvHHGoe+o2pY6RiMjYsELT4YhISg xh6eGP+c3LF5nAbbn4GJ6dhUqnlCcDbjwuVEIZmNWbWSy/HT0StmiFdnhc+nE273nNYg yyUg== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; h=mime-version:sender:in-reply-to:references:from:date:message-id :subject:to:cc; bh=5k/k+uPKwa9Palxh0LzQfvkzZ+n3MsPFuH6dwwTGtFw=; b=HKbr3KXO1xntrsMSMvUNNkQa568tGEmJRCrjLt7weAmwRS9AsN7smRhe19awGLaGUc +za1z2g3baKWSGu/ZqqXvH14CAYd5nXBwciISEqLQ2cP2XaSrremo76A84c9vtjr3Ccv jvKvyjDyuA9ynKVgOzhVArjPmbQftoP2dM9Mc= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:sender:in-reply-to:references:from :date:message-id:subject:to:cc; bh=5k/k+uPKwa9Palxh0LzQfvkzZ+n3MsPFuH6dwwTGtFw=; b=rnsENJz/q5JJKONGmbbubfokDPPdGA/YE7kw/WlTXOsSVyL9DIKXVsHpbO54ZJ9ymU P86BYUGuKf3qIZy1jxc0h2hdbRvVHDj+IVtmwtY8OdP57vZxCTcZ7OFBFSLtluDRmM6w p72F9ksKg35d1rIcMjGOcvkNhFO9CukPpQK26zHnvmSA0j+Kv5lChlC29ww1prLq7/0h STfRtW7s3OnzyIksEpySua3+QPFucNRdWYed+ma7+GYxD8u/+GPzUnw3MNKMi8Wzd7e1 BvM5TSPMI5IBFPhrMq1+Wg+WhYBklskmIimRDVBejXDFUH03PZsAdTrDFYX3QYv406+c jUkA== X-Gm-Message-State: AOUpUlEPaB22ZN1cpIV8XePTr5+Fk5fhdBt+gbs3Vo8TUf+2ZjOHZ+C4 zz7IEBTYiS9U5pT9yE5hJhGmL2Gz02VoNv1/ADVeOQ== X-Received: by 2002:a1f:c014:: with SMTP id q20-v6mr276665vkf.144.1531346456488; Wed, 11 Jul 2018 15:00:56 -0700 (PDT) MIME-Version: 1.0 Received: by 2002:a1f:9495:0:0:0:0:0 with HTTP; Wed, 11 Jul 2018 15:00:55 -0700 (PDT) In-Reply-To: <20180711215129.GT129942@google.com> References: <65c39c405076627bd43ec94c211c6998191b9f16.1531136000.git.amit.kucheria@linaro.org> <20180711215129.GT129942@google.com> From: Doug Anderson Date: Wed, 11 Jul 2018 15:00:55 -0700 X-Google-Sender-Auth: yHGzjhP7j5I82uF1VPnxrC42L3A Message-ID: Subject: Re: [PATCH v6 7/7] arm64: dts: sdm845: Add tsens nodes To: Matthias Kaehlcke Cc: Amit Kucheria , LKML , Rajendra Nayak , linux-arm-msm , Bjorn Andersson , Eduardo Valentin , smohanad@codeaurora.org, Vivek Gautam , Andy Gross , David Brown , Rob Herring , Mark Rutland , Catalin Marinas , Will Deacon , "open list:ARM/QUALCOMM SUPPORT" , devicetree@vger.kernel.org, Linux ARM 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 Hi Matthias, On Wed, Jul 11, 2018 at 2:51 PM, Matthias Kaehlcke wrote: > On Wed, Jul 11, 2018 at 11:44:13AM -0700, Doug Anderson wrote: >> Hi, >> >> On Mon, Jul 9, 2018 at 4:43 AM, Amit Kucheria wrote: >> > SDM845 has two tsens blocks, one with 13 sensors and the other with 8 >> > sensors. It uses version 2 of the TSENS IP, so use the fallback property to >> > allow more common code. >> > >> > Signed-off-by: Amit Kucheria >> > --- >> > arch/arm64/boot/dts/qcom/sdm845.dtsi | 16 ++++++++++++++++ >> > 1 file changed, 16 insertions(+) >> > >> > diff --git a/arch/arm64/boot/dts/qcom/sdm845.dtsi b/arch/arm64/boot/dts/qcom/sdm845.dtsi >> > index cdaabeb..ba2899c 100644 >> > --- a/arch/arm64/boot/dts/qcom/sdm845.dtsi >> > +++ b/arch/arm64/boot/dts/qcom/sdm845.dtsi >> > @@ -221,6 +221,22 @@ >> > #interrupt-cells = <2>; >> > }; >> > >> > + tsens0: tsens@c263000 { >> >> As per my comments in the bindings, nit that this should probably be >> "thermal-sensor" not "tsens", AKA: >> >> tsens0: thermal-sensor@c263000 { >> >> > + compatible = "qcom,sdm845-tsens", "qcom,tsens-v2"; >> > + reg = <0xc263000 0x1ff>, /* TM */ >> > + <0xc222000 0x1ff>; /* SROT */ >> > + #qcom,sensors = <13>; >> >> As per my comment in the bindings and the code, I'm confused about the >> whole "#qcom,sensors" bit. It's not documented and doesn't seem >> hooked up in the code either. >> >> ...but if people have tested this, perhaps I'm confused. How can >> things work if num_sensors is 0??? > > The mystery is resolved by: > > commit 6d7c70d1cd6526dc79e3d3b3faae1c40c1681168 > Author: Bjorn Andersson > Date: Mon May 7 16:53:39 2018 -0700 > > thermal: qcom: tsens: Allow number of sensors to come from DT > > For platforms that has multiple copies of the TSENS hardware block it's > necessary to be able to specify the number of sensors per block in DeviceTree. > > Signed-off-by: Bjorn Andersson > Reviewed-by: Amit Kucheria > Reviewed-by: Rob Herring > Signed-off-by: Eduardo Valentin > > > I bumped into this during testing ;-) Ah, now it makes sense to me! Serves me right for assuming it would be in the same series and not checking if it was something that had already landed. Thanks. Please ignore the parts of my comments related to the "#qcom,sensors" property. I guess Rob must have thought that the "#" in the name was fine and he's the one in charge not me. -Doug