Received: by 2002:a25:868d:0:0:0:0:0 with SMTP id z13csp247394ybk; Tue, 19 May 2020 21:33:08 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxPVnm0dZtnpmHNzRM+GyosqUIFKfdSbY52NMjPnI6TuEb1qeKltL0qur4jLe5TMEhyccMP X-Received: by 2002:aa7:cac8:: with SMTP id l8mr1693203edt.103.1589949188192; Tue, 19 May 2020 21:33:08 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1589949188; cv=none; d=google.com; s=arc-20160816; b=WPSDSPpqOg/z/vTsUqGi7u+LQ8AZfLN05x4gDa2YLVGUTJPlWNVtnWVLE1aeTr5iNz ZnGCrUnqxj1AUXHKen0pBszKGEGPjexgvgrmsYvcF6i42Qe0/yZvvaJPZNEX1oE7UjTm jq6j8XvEDa/yRWB+Ts2PRwMRmzP7XfZtzP8o+0TSiU0g563pykSi8iaUKMzINPLfyBou 2Jrm5sCOs/3ZYgxoQf7mWoJMDWR8TQ/0GwbFx0pyM0nKAFVp8zWr+01x1G7cAny2PDDK JyBz3KDs2XykoYIjXwta7nY4yfC7SbP95E9iSHeNytHxq3z/MjkCIydrfWWV1aie6bEa rvhQ== 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 :in-reply-to:references:mime-version:dkim-signature; bh=+qZZbuT843G0ykcP4WOBCe4Afr8ELi6EnDD0MmBi+I4=; b=xECQ6omTSH+UKkst8PGIvg4g67ZWh0TsvHTgiZne/BbKq3Ez3yBIj7JEhTTKzK8DxU Hvjwb6MSx2xC+PW4YShpMLedz3wSwY23pZAVpeDX8dQikyrFnMfkrvog7LqfH33iUyfh F/L7vN8nCtobH9zmmzmFB+CnMm6xtL9MYo2N3953dJHUKJqcBtIC52PzXi/6aNZO01z3 Zmo5AHtpmzP31ilFCdnfIEMDgWY+L+DnhY51T7P8rHB99dLjAsTezUibheV4pvdHGO1W 79Pdp/DhAkX74+OUYAbHxj1+S/0WNUCXTbylR+AwkvCOKNxlhtqd0OETqOockLVLgmWe eYdQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@verdurent-com.20150623.gappssmtp.com header.s=20150623 header.b=e4GAUZr0; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id j93si831538edb.327.2020.05.19.21.32.45; Tue, 19 May 2020 21:33:08 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@verdurent-com.20150623.gappssmtp.com header.s=20150623 header.b=e4GAUZr0; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726503AbgETE3E (ORCPT + 99 others); Wed, 20 May 2020 00:29:04 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:47058 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726435AbgETE3D (ORCPT ); Wed, 20 May 2020 00:29:03 -0400 Received: from mail-ua1-x944.google.com (mail-ua1-x944.google.com [IPv6:2607:f8b0:4864:20::944]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 9B5EDC061A0F for ; Tue, 19 May 2020 21:29:02 -0700 (PDT) Received: by mail-ua1-x944.google.com with SMTP id i5so828942uaq.1 for ; Tue, 19 May 2020 21:29:02 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=verdurent-com.20150623.gappssmtp.com; s=20150623; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=+qZZbuT843G0ykcP4WOBCe4Afr8ELi6EnDD0MmBi+I4=; b=e4GAUZr0pYYlAbmqzr5mBscJHnTVsJRtiQmpa37SgUxJp1nut8NqINekK2P+p9iHP8 0O+ePxYtdOc+NKNqX5iCCyYeaMcxzXYdc2rGBUwQmAJNAVZjRTNIGmOFuqSqQBoQdoDc vVkWvI/cl4u/oHEQE2LiLFT1n4xReLm9wvYiSSNEBVZlI84Rp3leRcc/ydVcl6rz8RXQ OHqexNizzlctGtaXQkZY/ODZ46zQbQxP0KN1o8J9TDQ63u0K2uYX4DSyIO/eRfmmMEZ7 xbjGDFDYdO0w/nzf5Axr6TV3MTMVWwXt3bjgcfJfvrV5rYofoDP51e8cLqlekQsJXb3s 8LDw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=+qZZbuT843G0ykcP4WOBCe4Afr8ELi6EnDD0MmBi+I4=; b=ahJgAWwL30004sIuOyZbrbNPoiO9MHFH1kdcvPNvYXhUyBP7t/aXu/IwzCLFPNEyXS XE5IrvdQtLm/Hpt6v/35RX4JMHxxq4Wkv5TBVzg50nG3sVzoT/JGZ5GD1tyiJbYczvWA 4tw27QUpdpwTiCda30aeBPrsKUCmq+Q3EkVs4Cw3uKfwpDF0klWorfeGewKrmBMiP/WH s/dCI+n2OZxCjO/80GSu3puK5KR6FR3GiDhPGYPHnD0Sy2g+dK+HpGv6gIqSZRMQfF04 v7JYioPh/aWArvJmn2DcRxEgv+43ObiUbHDgkE4DfM33nTRvhwSYKFKV/kwqTw83qU3g aOew== X-Gm-Message-State: AOAM533Obuh6lAAcQqFYynXx9/+eP0jIhIzcARst2Esasq0ImikVNmLC aLNfksropLOYWZhPz/Vcg0ZUPfohUwCZa02lJmpYlA== X-Received: by 2002:ab0:30ba:: with SMTP id b26mr2042602uam.77.1589948941382; Tue, 19 May 2020 21:29:01 -0700 (PDT) MIME-Version: 1.0 References: <20200504181616.175477-1-srinivas.pandruvada@linux.intel.com> <20200504181616.175477-4-srinivas.pandruvada@linux.intel.com> <2cd6c73b890b3eab12420adf4ae29101672e6a0b.camel@linux.intel.com> In-Reply-To: <2cd6c73b890b3eab12420adf4ae29101672e6a0b.camel@linux.intel.com> From: Amit Kucheria Date: Wed, 20 May 2020 09:58:18 +0530 Message-ID: Subject: Re: [RFC][PATCH 3/5] thermal: Add support for setting notification thresholds To: Srinivas Pandruvada Cc: Daniel Lezcano , Zhang Rui , LKML , Linux PM list 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 On Tue, May 19, 2020 at 5:10 AM Srinivas Pandruvada wrote: > > On Mon, 2020-05-18 at 18:37 +0200, Daniel Lezcano wrote: > > On 04/05/2020 20:16, Srinivas Pandruvada wrote: > > > Add new attributes in thermal syfs when a thermal drivers provides > > > callbacks for them and CONFIG_THERMAL_USER_EVENT_INTERFACE is > > > defined. > > > > > > These attribute allow user space to stop polling for temperature. > > > > > > These attributes are: > > > - temp_thres_low: Specify a notification temperature for a low > > > temperature threshold event. > > > temp_thres_high: Specify a notification temperature for a high > > > temperature threshold event. > > > temp_thres_hyst: Specify a change in temperature to send > > > notification > > > again. > > > > > > This is implemented by adding additional sysfs attribute group. The > > > changes in this patch are trivial to add new attributes in thermal > > > sysfs as done for other attributes. > > > > Isn't it duplicate with the trip point? > A trip point is where an in-kernel governor takes some action. This is > not same as a notification temperature. For example at trip point > configured by ACPI at 85C, the thermal governor may start aggressive > throttling. > But a user space can set a notification threshold at 80C and start some > active controls like activate some fan to reduce the impact of passive > control on performance. Then what is the use of thermal trip type "ACTIVE" ? > We need a way to distinguish between temperature notification threshold > and actual trip point. Changing a trip point means that user wants > kernel to throttle at temperature.