From: "Rafael J. Wysocki" <rjw@rjwysocki.net>
To: Linux PM <linux-pm@vger.kernel.org>
Cc: LKML <linux-kernel@vger.kernel.org>,
Lukasz Luba <lukasz.luba@arm.com>,
Daniel Lezcano <daniel.lezcano@linaro.org>,
Neil Armstrong <neil.armstrong@linaro.org>
Subject: [PATCH v1 0/2] thermal: core: Handle failed temperature checks more carefully
Date: Thu, 18 Jul 2024 20:57:28 +0200 [thread overview]
Message-ID: <2348857.ElGaqSPkdT@rjwysocki.net> (raw)
Hi Everyone,
This series kind of augments
https://lore.kernel.org/linux-pm/4950004.31r3eYUQgx@rjwysocki.net/
so I'm considering adding it to 6.11.
The problem with handing temperature check errors in __thermal_zone_device_update()
after the above is that if someone has a dead thermal zone returning such errors
continuously lurking somewhere in their system, they will get a flood of
"temperature check failed" messages in the log which will be reported as a
regression. Rightfully, because these messages render the kernel log
practically unusable and the continuous and useless polling of such a thermal
zone may even prevent the system from entering deep idle states. Clearly,
something needs to be done about this.
One possible approach might be to simply disable the thermal zone in question
after the first error (that is not -EAGAIN) returned by its .get_temp()
callback, but that cannot be done because there are thermal zones in which
.get_temp() returns errors to start with, but they recover later, and they
need to be taken into account.
So the only other alternative that is not overly complicated is to add a
back-off mechanism to the polling, so the thermal zone has a chance to recover,
but the core will not wait for that forever. At one point it will just disable
the thermal zone and let user space re-enable it if that's regarded as a good
idea. This is done in the second patch and the first patch is preparatory.
Thanks!
next reply other threads:[~2024-07-18 19:01 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-07-18 18:57 Rafael J. Wysocki [this message]
2024-07-18 19:00 ` [PATCH v1 1/2] thermal: trip: Split thermal_zone_device_set_mode() Rafael J. Wysocki
2024-07-18 19:01 ` [PATCH v1 2/2] thermal: core: Back off when polling thermal zones on errors Rafael J. Wysocki
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=2348857.ElGaqSPkdT@rjwysocki.net \
--to=rjw@rjwysocki.net \
--cc=daniel.lezcano@linaro.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-pm@vger.kernel.org \
--cc=lukasz.luba@arm.com \
--cc=neil.armstrong@linaro.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®