Received: by 2002:a05:6358:3188:b0:123:57c1:9b43 with SMTP id q8csp5159977rwd; Mon, 12 Jun 2023 00:25:00 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ7Pctsv3GHtAHTmyG3kVUt3Y3/tMNajAsshfef90+Ua+eiY/gWl1mhKBRDINHnJcpPl35Q/ X-Received: by 2002:a17:902:900b:b0:1b1:787d:1e47 with SMTP id a11-20020a170902900b00b001b1787d1e47mr5041860plp.41.1686554700095; Mon, 12 Jun 2023 00:25:00 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1686554700; cv=none; d=google.com; s=arc-20160816; b=GJRm/eiGLOuUIvSNxdbvb+eefA+1wcPwfLzLHAAWl0Uud1Hu3vJpehVrihWUfSmtXK 9UcHbat53jKoAodkpA7w0fEK75d3DTupVMXcoDZk3BTEhhEXJWHIbUZDtfWlbB9k9fTc W2qCwfsG0yniAJYGbOJ4z5kl59U2aPogguTO9hiKaYubXH4dGnSk7giHzBCrPW4sxHUg 50zVfpFfRJtDby6/e+ZMAUHM/Bnai0dV2GqAIEmsnY4egV41nBYs1VoeJZmOFm/oiu3v D6h/poM/g943r+mBj3S15SB1kkUmjxhtArQlzZfZfLbRxQDqImlAXgPUj0CYu6AyQ/aQ lXnA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:dkim-signature :from; bh=5WdmsNcfnfJhZlcRD/AABB3BQ/Q/V4x0NfhKyYWvdOs=; b=qNeb8yHM/qiTxP4Bjhveb9pZj2E4aihjI2Hf8hTTP6lYqNQN06h40B/wvIFvFGdnjf XTsVyCzL17VSHqzs88MYQgxNtKnaL1TPuGKP6wDlEAsTo/QNOFyXaaVdJHxJ2z9V2n82 911zvVq5t/4CHD/WNdgzngvGajh3GyE2cq/+jC8WThnB4LFRkSHeRga7dVVw5zmYZ8fR CNp5qdkUq4CTdDzPGkBuYIuydMKXSpXlLfHbsi4iKSs98H4BWdS7Xyup8lh2Tc2R9kNZ uFMe4wKUlU8+zRy5oh0vjqZj7waZzBjy/dMm0nNDET+hQmL1VmvktCgVJV28sM8LkjdW /lzg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@puri.sm header.s=comms header.b=pZrs4NYH; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=puri.sm Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id q11-20020a170902bd8b00b001ae141947acsi2427086pls.183.2023.06.12.00.24.34; Mon, 12 Jun 2023 00:25:00 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@puri.sm header.s=comms header.b=pZrs4NYH; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=puri.sm Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233872AbjFLHJZ (ORCPT + 99 others); Mon, 12 Jun 2023 03:09:25 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:37676 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231424AbjFLHJX (ORCPT ); Mon, 12 Jun 2023 03:09:23 -0400 Received: from comms.puri.sm (comms.puri.sm [159.203.221.185]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 9D7E21988; Mon, 12 Jun 2023 00:04:22 -0700 (PDT) Received: from localhost (localhost [127.0.0.1]) by comms.puri.sm (Postfix) with ESMTP id 9B0CCEBEE9; Sun, 11 Jun 2023 23:23:49 -0700 (PDT) Received: from comms.puri.sm ([127.0.0.1]) by localhost (comms.puri.sm [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id qNkXHMKsc_bt; Sun, 11 Jun 2023 23:23:48 -0700 (PDT) From: Sebastian Krzyszkowiak DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=puri.sm; s=comms; t=1686551028; bh=5WdmsNcfnfJhZlcRD/AABB3BQ/Q/V4x0NfhKyYWvdOs=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=pZrs4NYHksUe2cl7XbAEerstNlOYmsYefC5/fD5zoqRbR5YTSTOPQb4SSt5JWlgZn RKnkF8zjiqAoCCRdI9H7mcpjQ67pxAwOi8UZggmmlkohain1f6AZeqN3Zzi1ei6yJ9 LSEN6hIbSE6w4/VPZaGwU287566rR4cluYqFehVMle/t71wBYGKOhXb39hWDOxoSou flLO37GBD8ue+lVNW2c8rv6ivngWKbabIKDAbg8fPYI35uIUem6giHmW1HP76k2ROh +sUAHrPNZ2O9Ocz9v23sV0P54buaOQ+F6z4PdynRIMZwzX7DPG8Us9EjlRmGHSZ+ZN YAy9yhATC+4/Q== To: Peng Fan , "Peng Fan (OSS)" , "rafael@kernel.org" , "shawnguo@kernel.org" , "s.hauer@pengutronix.de" , Daniel Lezcano Cc: "amitk@kernel.org" , "rui.zhang@intel.com" , "andrew.smirnov@gmail.com" , "linux-pm@vger.kernel.org" , "linux-kernel@vger.kernel.org" , "kernel@pengutronix.de" , "festevam@gmail.com" , dl-linux-imx , "linux-arm-kernel@lists.infradead.org" , Alice Guo Subject: Re: [PATCH 2/3] thermal: qoriq_thermal: only enable supported sensors Date: Mon, 12 Jun 2023 08:23:34 +0200 Message-ID: <23120696.6Emhk5qWAg@pliszka> In-Reply-To: <507b5daa-73e7-8d21-4f73-c56f88c6bf77@linaro.org> References: <20230516083746.63436-1-peng.fan@oss.nxp.com> <1966575.usQuhbGJ8B@pliszka> <507b5daa-73e7-8d21-4f73-c56f88c6bf77@linaro.org> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="UTF-8" Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On =C5=9Broda, 7 czerwca 2023 21:10:18 CEST Daniel Lezcano wrote: > On 07/06/2023 19:42, Sebastian Krzyszkowiak wrote: >=20 > [ ... ] >=20 > >> Hence, the thermal_zone_device_register_with_trips() is not called, the > >> thermal zone is not created neither updated. > >=20 > > Again - that's not the case the check is there for. It's there for zones > > that do exist and that do get registered, because REGS_TMR only gets set > > *after* all the zones are already registered (the driver as it is right > > now does not know which sites it should enable before registering the > > zones). Because of that, the first value a zone gets after being > > registered is always bogus, because no monitoring site has been enabled > > yet at all. >=20 > Ok, I misunderstood. I thought that was for failing registered thermal zo= ne. >=20 > Would enabling the site in ops->change_mode do the trick ? Haven't tested, but from a quick glance at the core I believe it should! Peng, would you like to try that approach out and update this patch? Thanks, Sebastian