Received: by 2002:a05:7412:8d10:b0:f3:1519:9f41 with SMTP id bj16csp4915971rdb; Tue, 12 Dec 2023 13:02:55 -0800 (PST) X-Google-Smtp-Source: AGHT+IEomdmjdvPTcIhAcgcWRr5YqH9CK+DmhcNGF2qSG+5FQYvFCu1si629fGWrghJV4snGctYa X-Received: by 2002:a17:902:b683:b0:1d0:8303:216 with SMTP id c3-20020a170902b68300b001d083030216mr3490690pls.95.1702414975612; Tue, 12 Dec 2023 13:02:55 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1702414975; cv=none; d=google.com; s=arc-20160816; b=dP7s/qAzWz9MR4UjNUpUpM7x6SIL9LL3BnSn7PeAC6S3BnpsyyimjGa2KZyGzFZPac mJtk/KivuF3mqcFEeckS1WYWvv/kqw3sjLI4hsHR2qN+Czu6WtTIOwPODSpWiQww0/eE EICe+zLIxmWMpsMCGjyE0/cADJfmTfVZOq30+6kYOcyBWfgTtnKy4QtB0UnWhuBXKsn8 h/95nZ9LFBNcCMWzBEw8iZ3zSi8a18jCro4EPz0SpFS25dNN9ry+d3DVssC6UFSZZeGT O8f3ZWS9mhtmtaMLlu1fCyF4RUDiSm7VhPjyq89cL+5GV/ybse+G4C9gKna8Z3TOSkBp ox5w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:in-reply-to:from :references:cc:to:content-language:subject:user-agent:mime-version :date:message-id:dkim-signature; bh=fP3PBbkg+dGDRbq07rpkl3oLoeUyahhiYf75aZTkbF0=; fh=sK4Tc0dqW1+VfldxJe0fJiJm4djpTXt4/3mAd9SgNU8=; b=IT3BQVhcXDrvgnzMySSza6e3j83P8mJ5JhOEbzaaFkDeZEheCWBzb3RNgcJqUMElpi OrcwzGPgjOLrfw3a1YeekpPoj1xE6JYX3TRW+aznWqH+oKerPy6/vd6CpqV4gv8Mbcgk FNeP1JmfSdUJE126FttUuG0UwHPtgCC387vse7Qe7dI6k7SKva8xoPW1YheuPjXM8dhv TOC0GHeszIFLcFUj1DHfNrKCQ+9tRyltAmO8ulGUt5Cqse1SueYQaF0rKRsCzIVJ/zvH VL7/htuD+My1wQc7EwwXUbw4WeLN56yKZyf48uFYFGP+yi5SmNxJx/BOQc4sonoHgdPK eH/w== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=J0zWqfWH; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.35 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 groat.vger.email (groat.vger.email. [23.128.96.35]) by mx.google.com with ESMTPS id q14-20020a170902dace00b001cfcd2e1294si8622686plx.241.2023.12.12.13.02.55 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 12 Dec 2023 13:02:55 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.35 as permitted sender) client-ip=23.128.96.35; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=J0zWqfWH; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.35 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by groat.vger.email (Postfix) with ESMTP id BDCBB8075B04; Tue, 12 Dec 2023 13:02:52 -0800 (PST) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.11 at groat.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1377447AbjLLVCc (ORCPT + 99 others); Tue, 12 Dec 2023 16:02:32 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:58618 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1377304AbjLLVCb (ORCPT ); Tue, 12 Dec 2023 16:02:31 -0500 Received: from mail-wr1-x430.google.com (mail-wr1-x430.google.com [IPv6:2a00:1450:4864:20::430]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id B20539B for ; Tue, 12 Dec 2023 13:02:36 -0800 (PST) Received: by mail-wr1-x430.google.com with SMTP id ffacd0b85a97d-3363880e9f3so48545f8f.3 for ; Tue, 12 Dec 2023 13:02:36 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1702414955; x=1703019755; darn=vger.kernel.org; h=content-transfer-encoding:in-reply-to:from:references:cc:to :content-language:subject:user-agent:mime-version:date:message-id :from:to:cc:subject:date:message-id:reply-to; bh=fP3PBbkg+dGDRbq07rpkl3oLoeUyahhiYf75aZTkbF0=; b=J0zWqfWHzdG+QeTl4U+QZKt5y8Efwcr4V31Lrl3e2GJf9dHb9GaTPdMyz9JWAq6VFf qwjugv9cp6cXnOKMsJX4dkdYNwVtyK3ihlzxWykY+6lv6lX0XKlUcaoc4LQhxOk03BSE Z2lq3HU73JzInRDo6yWRUEOzljFsx8PuopvbtC5DJL9L/BZNYSCx9zeMcOeWeHcIyCIJ RUHOSlo9YUfIiee931XMpbikEp5vt0vESB+XgtxVNRJDmWW4G5rrBkErAcjZO2btQqE0 tm2DiZrPWCTb17j9l1YEpMknlNafOFe5rbY3r5fpnwEfqpC2oXfgwlyOUHI5NnQcZHSM CliQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1702414955; x=1703019755; h=content-transfer-encoding:in-reply-to:from:references:cc:to :content-language:subject:user-agent:mime-version:date:message-id :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=fP3PBbkg+dGDRbq07rpkl3oLoeUyahhiYf75aZTkbF0=; b=qhFowRlE7ojdmY6ey5ejTG3KZQPwPV7wrRTMhtpzuzOk8AA31vDjmnwindc0MAf4Hx Es3K1D8RkwnseIr6H+f2rKljmAOMNL0UAPXbPW0KywfyOYrPuk48wLQCWeOvE8r+Zn+q Jgi8JvWuF8woFO3MDEJGkVQhUKZ6jTlPbm44Oy1B8clJoJmNpXjvjIMJ5dHy6U0cgjCZ UR2HRre22VnnVVEqY02TqpTDvwGNr57+i1KojKIYqu02ilGWdDb/Gs1/4K+plp2gZBb4 Ri77Q7uNfebSWr8zvziP7YvMA/gxIKx/F3omFqnS4jxCx61L5ngFVkWsUDJfSngBgiLq nbGA== X-Gm-Message-State: AOJu0YzPuepaFYp2dhjL+i/D8TN2yGx4MQxGBJduWnBaJdRLE2VAYD2D YJVcqZwyYQzNBysEeBNgM50lCg== X-Received: by 2002:adf:e34a:0:b0:332:de0f:d7be with SMTP id n10-20020adfe34a000000b00332de0fd7bemr3284238wrj.18.1702414955022; Tue, 12 Dec 2023 13:02:35 -0800 (PST) Received: from ?IPV6:2a05:6e02:1041:c10:c49e:e1a5:3210:b8c0? ([2a05:6e02:1041:c10:c49e:e1a5:3210:b8c0]) by smtp.googlemail.com with ESMTPSA id n4-20020a5d6b84000000b0033634aef014sm1746153wrx.104.2023.12.12.13.02.34 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Tue, 12 Dec 2023 13:02:34 -0800 (PST) Message-ID: <1e2b5100-f40d-47f2-880b-121704c0c8e2@linaro.org> Date: Tue, 12 Dec 2023 22:02:33 +0100 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: [PATCH v1] thermal: trip: Send trip change notifications on all trip updates Content-Language: en-US To: "Rafael J. Wysocki" Cc: "Rafael J. Wysocki" , Linux PM , Srinivas Pandruvada , Zhang Rui , Linux ACPI , LKML , Lukasz Luba References: <5737811.DvuYhMxLoT@kreacher> From: Daniel Lezcano In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-0.9 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on groat.vger.email Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (groat.vger.email [0.0.0.0]); Tue, 12 Dec 2023 13:02:52 -0800 (PST) On 12/12/2023 20:04, Rafael J. Wysocki wrote: > On Wed, Dec 6, 2023 at 5:01 PM Rafael J. Wysocki wrote: >> >> Hi Daniel, >> >> On Wed, Dec 6, 2023 at 3:38 PM Daniel Lezcano wrote: >>> >>> >>> Hi Rafael, >>> >>> On 05/12/2023 20:18, Rafael J. Wysocki wrote: >>>> From: Rafael J. Wysocki >>>> >>>> The _store callbacks of the trip point temperature and hysteresis sysfs >>>> attributes invoke thermal_notify_tz_trip_change() to send a notification >>>> regarding the trip point change, but when trip points are updated by the >>>> platform firmware, trip point change notifications are not sent. >>>> >>>> To make the behavior after a trip point change more consistent, >>>> modify all of the 3 places where trip point temperature is updated >>>> to use a new function called thermal_zone_set_trip_temp() for this >>>> purpose and make that function call thermal_notify_tz_trip_change(). >>>> >>>> Note that trip point hysteresis can only be updated via sysfs and >>>> trip_point_hyst_store() calls thermal_notify_tz_trip_change() already, >>>> so this code path need not be changed. >>> >>> Why the ACPI driver is not calling thermal_zone_device_update() after >>> changing the trip point like the other drivers? >> >> It calls that function, but because it may update multiple trips in >> one go, it does that after all of the updates are done, via >> acpi_thermal_check_fn(). >> >>> It would make sense to have the thermal framework to be notified about >>> this change and check if there is a trip violation, no ? >> >> It is notified as noted above, but not synchronously. > > I believe that the question above has been answered, so are there any > other comments or concerns regarding this patch? No, it is fine. Thanks for the clarification Acked-by: Daniel Lezcano -- Linaro.org │ Open source software for ARM SoCs Follow Linaro: Facebook | Twitter | Blog