Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752366AbdLEGtv (ORCPT ); Tue, 5 Dec 2017 01:49:51 -0500 Received: from mail-wm0-f48.google.com ([74.125.82.48]:36984 "EHLO mail-wm0-f48.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751416AbdLEGts (ORCPT ); Tue, 5 Dec 2017 01:49:48 -0500 X-Google-Smtp-Source: AGs4zMZ5EgA+fARz7vLDBNFZsMeuBtJnK4Gtts4T3qUCjyhm8QJaR0txLK29RSBvdAukWjRauz9vyw== Subject: Re: [PATCH V2] thermal/drivers/hisi: Switch to interrupt mode To: Eduardo Valentin Cc: Leo Yan , rui.zhang@intel.com, jean.wangtao@linaro.org, Keerthy , "open list:THERMAL" , open list References: <1bfd974e-3dc1-e99b-d0dd-50102cee762d@ti.com> <1506575625-20388-1-git-send-email-daniel.lezcano@linaro.org> <20170928065752.GA31697@leoy-linaro> <20170928073220.GF2196@mai> <20171205020031.GA4949@localhost.localdomain> From: Daniel Lezcano Message-ID: Date: Tue, 5 Dec 2017 07:49:45 +0100 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.4.0 MIME-Version: 1.0 In-Reply-To: <20171205020031.GA4949@localhost.localdomain> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1610 Lines: 45 On 05/12/2017 03:00, Eduardo Valentin wrote: > Hello, > > On Thu, Sep 28, 2017 at 09:32:20AM +0200, Daniel Lezcano wrote: >> On Thu, Sep 28, 2017 at 02:57:52PM +0800, Leo Yan wrote: >>> Hi Daniel, >>> >>> On Thu, Sep 28, 2017 at 07:13:44AM +0200, Daniel Lezcano wrote: >>>> At this moment, we have both the interrupt setup and the polling enabled. The >>>> interrupt does nothing more than forcing an update while the temperature is >>>> polled every second. >>>> >>>> We can do much better than that, threshold is set to 65C in the DT and the >>>> passive cooling device enters in the dance when 75C is reached. We need to >>>> sample the temperature at 65C in order to let the IPA gather enough values for >>>> the PID computation. If the SoC is running at a temperature below 65C, we will >>>> be constantly polling for nothing. >>>> >>>> This patch disables the sensor when the temperature is below 65C and enables it >>>> when passing the threshold. It results the thermal sensor driver will have no >>>> activity most of the time. >>>> >>>> Cc: Keerthy >>>> Cc: Leo Yang >>> >>> s/Yang/Yan :) Have tested this patch on Hikey at my side: >> >> Oops sorry :) >> >>> Reviewed-by: Leo Yan >>> Tested-by: Leo Yan >> > > Is this still needed after the latest rework done? No longer needed. -- Linaro.org │ Open source software for ARM SoCs Follow Linaro: Facebook | Twitter | Blog