Received: by 2002:ac0:a5a7:0:0:0:0:0 with SMTP id m36-v6csp1201836imm; Wed, 11 Jul 2018 20:01:34 -0700 (PDT) X-Google-Smtp-Source: AAOMgpdlLCc6zq0TXG8jvDIBuOmMLsPMlrdCYnAguHhdvrawAZMpbg0BlQB3ZbIFdB99nmmaTJ8i X-Received: by 2002:a17:902:1703:: with SMTP id i3-v6mr422120pli.263.1531364494596; Wed, 11 Jul 2018 20:01:34 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1531364494; cv=none; d=google.com; s=arc-20160816; b=ILo7ApNP7X/7PJzBfe1LeqnOM8PXJ81NOwibuoAKIQqrkeADngV5Zlg346LULd7Fgm CilMQkY9rVYdNlYRuB8I2vGE0pIQ5eMHqGxQR20RErIPKGFgvbXGTZ27B/Cdq6reGe4p P84JDhos6wbBU/bZXUfA6H7hTfEMw2DlW8HLHrPdqU+zIBQN9Qn5IBN3T6h//mJiS0HL HipD8msMvF/i8xULdU+KYKcwX+OkZ+kTCvVbgVjpjrZULXlrIWvLowIH3yzuaGuOBJHr D1mCgZOXrQjpVBZfoxBYXlAjMsrN+sJrNnfxnbH/37g5PKLWKdg+zRjMzF4KxBCWHec6 QddA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:dkim-signature:arc-authentication-results; bh=s2qgXwJBcwULc0BI0Bi1FAnDb0cW6a+ak7h5AZJe0+A=; b=yKwavj2TfWXfYQAV/7OYuAS5kD+hnFulcabFOcqUPAZEsu8dOWuav/Cph94ualgtPB 9cxu/cyE7Cm8qCDFpNGDrKouI2N8DrSO2lhzuevCkECrsuTh2tyN6HAGwlxSb3kLIQw8 cY9YDhZNzMofsMT0NDwvzenuJionVdGL1ch5dsDLwwhJ7o4EMMKVhEc+Pl7piyUXnQhl 3Pjn8ZkJbs7sSDURtdwol8ezkHd57vT2NTQlP3DbFU936c8lS+krWEYRqbQapyrMTUnf +JzOdDUPTG88l/8bt0dgxBBTQxlbC8JKKdrDtX3E63P95UUGLzSTi5l3s6bKxg7DOkLt ivSw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@chromium.org header.s=google header.b=EnVJO1e3; 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=chromium.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id a17-v6si19285411pgb.369.2018.07.11.20.01.19; Wed, 11 Jul 2018 20:01:34 -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=@chromium.org header.s=google header.b=EnVJO1e3; 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=chromium.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2390566AbeGKV5w (ORCPT + 99 others); Wed, 11 Jul 2018 17:57:52 -0400 Received: from mail-pg1-f196.google.com ([209.85.215.196]:41754 "EHLO mail-pg1-f196.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1733155AbeGKV5w (ORCPT ); Wed, 11 Jul 2018 17:57:52 -0400 Received: by mail-pg1-f196.google.com with SMTP id z8-v6so1794420pgu.8 for ; Wed, 11 Jul 2018 14:51:31 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to:user-agent; bh=s2qgXwJBcwULc0BI0Bi1FAnDb0cW6a+ak7h5AZJe0+A=; b=EnVJO1e3DCF1BwcgZT8vr2mnb2MZ/BaGif5g2cVMxPaSQN81D7fI7vK+oHBKmWyybM bG/xmes1PN7fdNFberEpcUVft7E1Pnbk7qNHvThYgy7HAKQvY7KncoUmUuIjjDHZBFP5 z8ETEZaUX28aUQtaIaI1itEPiQsQOrrrcieAE= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to:user-agent; bh=s2qgXwJBcwULc0BI0Bi1FAnDb0cW6a+ak7h5AZJe0+A=; b=bhfIuZHno72KAGTwe1Bj1b56f45wmj3RikpR45TY9b3lIf9WhyvdlKJ2AyO3R7g5PZ 0yfaXzNxMgVuTYvMFxZTHtWVpXkVwjteFQZxCgmDYoSvVOYBbXL2NVvDLm1b3zEONQfm qsRpjYM291Yv5pCznE2dV0G4qbmuUIrGwi+1o3n1KlBYavBp2v3QUq1NSOss3lW9ZXBZ /WQeiE68KBQAJz0NVm8nZ46hMtgAsxA6Xm2tf8awqV6QWjziig0b0PG1WxwLda12gqud 0mJXDs8hYUpqnYPGuhkG0OmFYOT/yZsue/FqqZT3kxUnB07EoZVq9MEZ/QTxw6qSHRCM dKDQ== X-Gm-Message-State: AOUpUlE4Y+UvaKO87U7B+da/arxsm7FBzALEmBoXlec8AI6i4zXt9pqi NvxDsGiD0QjVRgEH9xZJWSCbZg== X-Received: by 2002:a63:5c10:: with SMTP id q16-v6mr308381pgb.452.1531345891220; Wed, 11 Jul 2018 14:51:31 -0700 (PDT) Received: from localhost ([2620:0:1000:1501:8e2d:4727:1211:622]) by smtp.gmail.com with ESMTPSA id b66-v6sm4372367pgc.15.2018.07.11.14.51.30 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Wed, 11 Jul 2018 14:51:30 -0700 (PDT) Date: Wed, 11 Jul 2018 14:51:29 -0700 From: Matthias Kaehlcke To: Doug Anderson 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 Subject: Re: [PATCH v6 7/7] arm64: dts: sdm845: Add tsens nodes Message-ID: <20180711215129.GT129942@google.com> References: <65c39c405076627bd43ec94c211c6998191b9f16.1531136000.git.amit.kucheria@linaro.org> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.9.2 (2017-12-15) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org 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 ;-)