Received: by 2002:a05:7412:d1aa:b0:fc:a2b0:25d7 with SMTP id ba42csp625461rdb; Mon, 29 Jan 2024 12:46:08 -0800 (PST) X-Google-Smtp-Source: AGHT+IFIb9R6OkIA1DLpaZZIgx13Wlxv09Dg0nTX3D72mBovTsFJi2i4gm9KCRsSkMUp45vXGzVh X-Received: by 2002:ad4:5cc1:0:b0:684:1482:b846 with SMTP id iu1-20020ad45cc1000000b006841482b846mr6931267qvb.58.1706561168612; Mon, 29 Jan 2024 12:46:08 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1706561168; cv=pass; d=google.com; s=arc-20160816; b=vPkDnkIfKRAPDBEqE9HAjFfeDuo8/TuSpf45RHadP6xCOhiU56B3P7mCw6VGPcEg8D ryk2tyLsm/SBSvSVZCjeY1+0cytbwUuaQ8m8Lko3EggLZkdyh50eQokrA1RfigdUHZf5 v2fqsH1F3JTNJAXwkzSW6j+yyOeFtf8RsVHgJqHLKBARovQ1WbJgLQiEIzKkoko8HSru 1urDr0+Ha64GDgZ/zoczgZiqhAf9fsMI8NGo/U74n4NjCZSQWKbnUE+N/nOAi6Gf87tv Yehim4ZjBheIfDHzvso83q5sCFve0Mqs5JtynPqkwFkwJVR4TmXi8bpCoieT1TWRxzAo K7oA== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:list-unsubscribe:list-subscribe :list-id:precedence; bh=xvTbQy9VMHt6fnQCY3TVYNEIJh4tIcaNRd3FXe7uHFs=; fh=Bj3gvkiSIzaFt6Jjy5UtjbhtqhOgRGI6E8cFTQKRgIo=; b=pFjPljN41oS+Py7q4S0Jb2/4M/UJFVzveha1CoO/L8wbMBPZnZbsjiuwMQq96KuZjN HB6g6KkAQwnyrp8mKpFU17kkMFFY4AuzCvKLufA3/Im6s3SR0JRW8FheSp5KZv0N7mUC 8YrqURk+UP8h9xB+CXtX7i0NgAQOhVyfmcaQbrAzSc2y9tLRBr8N0U3/MEWJ9hEiwdzD WnRXg7LIb0bILHlltn61mfHuPuJwW7EkXdWAqRAzJZtIQy66c++5qDBNnK2Jb8syBOAJ t12WMKON4PwmXbKyQbK0mkpjnqaoVC8j6BUyJj2+IDK79ZrJRumlwvdj54Wa66u3Uaf2 OoeA== ARC-Authentication-Results: i=2; mx.google.com; arc=pass (i=1 spf=pass spfdomain=gmail.com); spf=pass (google.com: domain of linux-kernel+bounces-43484-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-43484-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from ny.mirrors.kernel.org (ny.mirrors.kernel.org. [2604:1380:45d1:ec00::1]) by mx.google.com with ESMTPS id e25-20020a05620a209900b00783e13a074csi6542518qka.0.2024.01.29.12.46.08 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 29 Jan 2024 12:46:08 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-43484-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) client-ip=2604:1380:45d1:ec00::1; Authentication-Results: mx.google.com; arc=pass (i=1 spf=pass spfdomain=gmail.com); spf=pass (google.com: domain of linux-kernel+bounces-43484-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-43484-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ny.mirrors.kernel.org (Postfix) with ESMTPS id D63D61C24DDA for ; Mon, 29 Jan 2024 20:45:34 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 5B061156967; Mon, 29 Jan 2024 20:45:26 +0000 (UTC) Received: from mail-oo1-f44.google.com (mail-oo1-f44.google.com [209.85.161.44]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 635E37602C; Mon, 29 Jan 2024 20:45:23 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.161.44 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1706561125; cv=none; b=bXAsDBSWKYh0wPnnRWKbX9pQYR8N500GA5QMzkGtq70AD59Qxo0gzrL5v4xswFW8bZDMPENV3WoiDV+ZNyr7pSTH45CZyrTX3RiIupyKQmJHPhVmmM1/c7//uKwkrK8FiYtW1r8PP7hzwfZuq5ChRX9koTrntpDn/COiUZmEd0g= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1706561125; c=relaxed/simple; bh=wH59XtXAzJJua0WPMURILT065bEyBsmYhcbPLahSQXo=; h=MIME-Version:References:In-Reply-To:From:Date:Message-ID:Subject: To:Cc:Content-Type; b=TJ54WTWYPAxk9qmmERjv7HMOKewj9A8r2+2ssKmywzXvZ7w/2bgYYOfAgvrf8Vr7pUEs5Q1ExZrlqLHGdL908URbLRW2HtbnA9adygdb0ondKdGLwjmVeTDBN1e9/gOuzHHfXjqOVqw3GrmGRY7vqc8a4M0VNl/6Lrzogqp/PmQ= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=fail (p=none dis=none) header.from=kernel.org; spf=pass smtp.mailfrom=gmail.com; arc=none smtp.client-ip=209.85.161.44 Authentication-Results: smtp.subspace.kernel.org; dmarc=fail (p=none dis=none) header.from=kernel.org Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmail.com Received: by mail-oo1-f44.google.com with SMTP id 006d021491bc7-59a1e21b0ebso556783eaf.1; Mon, 29 Jan 2024 12:45:23 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1706561122; x=1707165922; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=xvTbQy9VMHt6fnQCY3TVYNEIJh4tIcaNRd3FXe7uHFs=; b=uccwupb73DTrI1WK5X/i8gspTnpHYmHAc5ljB68qc4sxDKZZDMRQs1ahvD01Qnx78E fOwxfLDrSLnVR5U6DYmLcVFS9a8kgYO3IhS0UANkVIuiF4DysA1YBxhx5EEsidz3QWP5 kLzH30NGMpoYMgJrbGKT5jCnbE3RFANaw7hO0NywF5jZnM8OyGBwhoxHnbAdnBhFhRaj ggfN71qBXZYWviRezGZvc/IVYVl+7OTVFgkYySicDOXTYWONNNahi1+LkgScDqfXAa0i Mo4uOf7MbIQlibysHPV0gZMp3+PAXvsFhYmTkCKU+NOFa5nGhE3NHZoyDW566jSfls7H w9Uw== X-Gm-Message-State: AOJu0YzyRjFcwC4IcvUMmZhSJk2FmZ8X/TXHdiTsPg1S4yxwl2gIRU8Y +Wyc4aiFScFIj0qzTSvscRPgfTSAv0f/OCY9DKyqwQTF22F7Fc+cN8pI1k5oSJgPuIwtrW08nFN Zqrt4I/KeMAVXzBJVyH9dEzZM5WM= X-Received: by 2002:a05:6870:a2c9:b0:210:9749:d377 with SMTP id w9-20020a056870a2c900b002109749d377mr8058390oak.2.1706561122709; Mon, 29 Jan 2024 12:45:22 -0800 (PST) Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 References: <20240106191502.29126-1-quic_manafm@quicinc.com> <921c2f90-fb8b-4e70-9e3d-6e185fec03b6@linaro.org> <41b284d7-e31f-48b5-8b21-0dca3e23cb1c@linaro.org> In-Reply-To: From: "Rafael J. Wysocki" Date: Mon, 29 Jan 2024 21:45:11 +0100 Message-ID: Subject: Re: [PATCH] thermal/sysfs: Always enable hysteresis write support To: Daniel Lezcano Cc: "Rafael J. Wysocki" , Manaf Meethalavalappu Pallikunhi , Zhang Rui , Lukasz Luba , linux-pm@vger.kernel.org, linux-kernel@vger.kernel.org Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Hi Daniel, On Mon, Jan 29, 2024 at 6:54=E2=80=AFPM Daniel Lezcano wrote: > > Hi Rafael, > > On 29/01/2024 18:07, Rafael J. Wysocki wrote: > > [ ... ] > > >> Index: linux-pm/drivers/thermal/thermal_sysfs.c > >> =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D > >> --- linux-pm.orig/drivers/thermal/thermal_sysfs.c > >> +++ linux-pm/drivers/thermal/thermal_sysfs.c > >> @@ -474,7 +474,8 @@ static int create_trip_attrs(struct ther > >> tz->trip_hyst_attrs[indx].name; > >> tz->trip_hyst_attrs[indx].attr.attr.mode =3D S_IRUGO; > >> tz->trip_hyst_attrs[indx].attr.show =3D trip_point_hyst_show= ; > >> - if (tz->ops->set_trip_hyst) { > >> + if (IS_ENABLED(CONFIG_THERMAL_WRITABLE_TRIPS) && > >> + mask & (1 << indx)) { > >> tz->trip_hyst_attrs[indx].attr.attr.mode |=3D S_IWUSR; > >> tz->trip_hyst_attrs[indx].attr.store =3D > >> trip_point_hyst_store; > > > > So it looks like I need to submit this, even though I'm not sure if > > anyone cares. > > > > In any case, I care about consistency. > > Yeah, sorry for the delay. I'll have a look at it tomorrow Thanks! Posted here with some additional remarks: https://lore.kernel.org/linux-pm/4565526.LvFx2qVVIh@kreacher/ Let's continue the discussion there.