Received: by 2002:a25:c593:0:0:0:0:0 with SMTP id v141csp515775ybe; Wed, 18 Sep 2019 22:31:00 -0700 (PDT) X-Google-Smtp-Source: APXvYqx6BvLN8H+jYtT0LWJJjOnmIqUkNLQEu5kxN62CbQhYgMjh4qJfrF6CnTaUxFsjB/V34Yjs X-Received: by 2002:a17:906:4b47:: with SMTP id j7mr11297763ejv.63.1568871060759; Wed, 18 Sep 2019 22:31:00 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1568871060; cv=none; d=google.com; s=arc-20160816; b=Y6cYBTnOqwaWRKSXH8w6LNa0uqBue5obCD3dEtN0Xnd570nW8nZTb81EGgdrYZbZKh /arXzOQ19zTz4FV1C/zZbOVolUQsvLPiKRi0S9otb/4u23SOulxAIVnSXpic5RWNmySw AtFGCV2MSnm9VF0Az7NtWuLkwCLlI+1Nyqz+2wApwbSpXFhnF5THJG92zlxxGCPqN/ut Th/yB6xQUturQHYlS0r0I6wBHFIdS1CU4O9Jdn3U8qZ0q/ru76kTxAb2kHcKQFV988z6 sP7HxW61wI3sVjoHQJ2rhxRaLhFv0WJF8oKL8kCrAYP47JAoObPzaFWC5be1f17G2JWy svJA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:message-id:date:subject:cc:to:from :dkim-signature; bh=eMoL+WWX1O3Mr1Rt4D8nfxQ68OPxFI2LpksFdwrwiPI=; b=EWWw9Mj8HdQ/7otQfpd1FRpI+Uii1UhhnvREzbQxqO3zCpN7E3GVfk8QXnYIQmEYIC tX85n+13NAjw8TIo33UXGG608EbQkcOdthmy5px8ait5EAb1+5lOOyxqpX57PXCd4fOi ggURfiFmeZmDZmBr15YPXHf038MsN95fkd6FoxDCe81LRnSGMnz2hs66Cpydd2zt6CRX rZ0FJHvzy6uOyLgdBy1eAT2M8zhoIf+8vPbSq1DDqMCC6G9VPW04l7ABE4mRc64aYA9w nPU2iNsSJhV/29/7rt+9Hw4RbqX5KfOyAltWDyCRvCL9MlSCt8dXw+GH7xWMZ2iuGGfC GxLQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=MdALuVzF; 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 b44si4694577ede.451.2019.09.18.22.30.37; Wed, 18 Sep 2019 22:31:00 -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=MdALuVzF; 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 S2388384AbfISCSd (ORCPT + 99 others); Wed, 18 Sep 2019 22:18:33 -0400 Received: from mail-qt1-f195.google.com ([209.85.160.195]:42853 "EHLO mail-qt1-f195.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2388276AbfISCS1 (ORCPT ); Wed, 18 Sep 2019 22:18:27 -0400 Received: by mail-qt1-f195.google.com with SMTP id g16so2284911qto.9 for ; Wed, 18 Sep 2019 19:18:25 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id; bh=eMoL+WWX1O3Mr1Rt4D8nfxQ68OPxFI2LpksFdwrwiPI=; b=MdALuVzFTvSx2saviYRgBg5S9c2sbaPoLc8vqx13RNuKSCpSSMtjL+s8zbn+SmBzjJ fni31MmFQbdVSlo983Ns41faBRzjgX9RGZrS5d5/023Vq/zxIjZfTBiCgm1i3pHNVA3b Y5kTHkjDXC4nRqC26TNaBT7flijBXYCaiN1+C2nUd0YDwMHhtZ2I/n9i/Xd4nByA7LR7 8viYXIDA6AMurqdW9l26pVxmG7F9Q8rhGsvJiCfk+sJytVX+cXB6NNqXpRPnhxWFG+lf aYCaiklkmcwZAyD0Jzl9Eh+rmWVC0dYTfFN72OaPevO62Caa6F+1/FEL5fqNvWVj8ZRt maAw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id; bh=eMoL+WWX1O3Mr1Rt4D8nfxQ68OPxFI2LpksFdwrwiPI=; b=F+t8MQEXhm2TXP6WG8VCXyXx+FlWyD6cRxHkrUT/yncY1/B+F83yiyBeojcibXB1v7 EQdlypWlTP4DTdwr1ZNZihdpoOxjkg4WHCIbDp5Q1hb1SM1Jhj3duySLpbypGoe1AeC1 TEIsSOR4GHvTJU4PMfZGU94/bR18kYCttwz+5HORTyLGTkPpvyHqKtPL+ccRbzsTrWuD E0Ojg3kJCeze4CNpVAiluuBGyXvIdULY3VwLpuYAaW/ngx3Ibx5LXFM2MenBgbR2HQN3 US4flncDM/kjogoy0nKhHDmafoeWwXXEBcGCFbgD0Sy3m/v3wHuo7tjcw0CwVNGWvMyK 8S9Q== X-Gm-Message-State: APjAAAU+pSAqkgJFmBvJvkJp81onioX3ddUvIbKjrmQUkd7qmNGm1R6M +ftVoOW1ZzhqsNBTU0xerrRldA== X-Received: by 2002:ad4:528b:: with SMTP id v11mr6051296qvr.200.1568859504693; Wed, 18 Sep 2019 19:18:24 -0700 (PDT) Received: from Thara-Work-Ubuntu.fios-router.home (pool-71-255-246-27.washdc.fios.verizon.net. [71.255.246.27]) by smtp.googlemail.com with ESMTPSA id o52sm5261275qtf.56.2019.09.18.19.18.23 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Wed, 18 Sep 2019 19:18:23 -0700 (PDT) From: Thara Gopinath To: rui.zhang@intel.com, edubezval@gmail.com, daniel.lezcano@linaro.org, vincent.guittot@linaro.org, bjorn.andersson@linaro.org, robh+dt@kernel.org Cc: amit.kucheria@verdurent.com, mark.rutland@arm.com, linux-pm@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH 0/4] thermal: Introduce support for monitoring falling temperatures. Date: Wed, 18 Sep 2019 22:18:19 -0400 Message-Id: <1568859503-19725-1-git-send-email-thara.gopinath@linaro.org> X-Mailer: git-send-email 2.1.4 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Thermal framework today supports monitoring for rising temperatures and subsequently initiating cooling action in case of a trip point being crossed. There are scenarios where a SoC needs some warming action to be activated if the temperature falls below a cetain allowable limit. Since warming action can be considered mirror opposite of cooling action, most of the thermal framework can be re-used to achieve this. To enable thermal framework to monitor falling temperature, a new parameter is added to the thermal trip point binding in the device tree to indicate the direction(rising/falling) of temperature monitoring. Thermal DT driver is extended to capture this information from the device tree entries and to reflect it in the thermal framework as a new enum variable in the thermal trip point structure. As an initial attempt, step-wise governor is extended to support bi-directional monitoring of temprature if a trip point is hit, depending on the newly introduced enum variable. Finally thermal sysfs entries are extended to indicate the trip point monitor direction. Patch series introducing various resources that are used as warming devices on Qualcomm sdm845: https://lkml.org/lkml/2019/7/29/749 (already merged) https://lkml.org/lkml/2019/9/10/727 (under review) Thara Gopinath (4): dt-bindings: thermal: Introduce monitor-falling binding to thermal trip point description thermal: Thermal core and sysfs changes needed to support bi-directional monitoring of trip points. thermal: of-thermal: Extend thermal dt driver to support bi-directional monitoring of a thermal trip point. thermal: step_wise: Extend thermal step-wise governor to monitor falling temperature. .../devicetree/bindings/thermal/thermal.txt | 8 +++ drivers/thermal/of-thermal.c | 22 ++++++++ drivers/thermal/step_wise.c | 59 +++++++++++++++------ drivers/thermal/thermal_sysfs.c | 60 ++++++++++++++++++++-- include/linux/thermal.h | 10 ++++ include/uapi/linux/thermal.h | 2 +- 6 files changed, 141 insertions(+), 20 deletions(-) -- 2.1.4