From: Lukasz Luba <lukasz.luba@arm.com>
To: Daniel Lezcano <daniel.lezcano@linaro.org>
Cc: Thierry Reding <thierry.reding@gmail.com>,
rafael@kernel.org, Amit Kucheria <amitk@kernel.org>,
Zhang Rui <rui.zhang@intel.com>,
"open list:THERMAL" <linux-pm@vger.kernel.org>,
open list <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH 1/2] thermal/core: Hardening the self-encapsulation
Date: Thu, 12 Oct 2023 13:01:00 +0100 [thread overview]
Message-ID: <a6b51de7-4f56-4db9-a7dd-60555ac6c37f@arm.com> (raw)
In-Reply-To: <20231012102700.2858952-1-daniel.lezcano@linaro.org>
Hi Daniel,
On 10/12/23 11:26, Daniel Lezcano wrote:
> The thermal private header has leaked all around the drivers which
> interacted with the core internals. The thermal zone structure which
> was part of the exported header led also to a leakage of the fields
> into the different drivers, making very difficult to improve the core
> code without having to change the drivers.
>
> Now we mostly fixed how the thermal drivers were interacting with the
> thermal zones (actually fixed how they should not interact). The
> thermal zone structure will be moved to the private thermal core
> header. This header has been removed from the different drivers and
> must belong to the core code only. In order to prevent this private
> header to be included again in the drivers, make explicit only the
> core code can include this header by defining a THERMAL_CORE_SUBSYS
> macro. The private header will contain a check against this macro.
>
> The Tegra SoCtherm driver needs to access thermal_core.h to have the
> get_thermal_instance() function definition. It is the only one
> remaining driver which need to access the thermal_core.h header, so
> the check will emit a warning at compilation time.
>
> Thierry Reding is reworking the driver to get rid of this function [1]
> and thus when the changes will be merged, the compilation warning will
> be converted to a compilation error, closing definitively the door to
> the drivers willing to play with the thermal zone device internals.
That looks like a good idea. Although, shouldn't we avoid the
compilation warnings and just first merge the fixes for drivers?
Regards,
Lukasz
next prev parent reply other threads:[~2023-10-12 12:01 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-10-12 10:26 [PATCH 1/2] thermal/core: Hardening the self-encapsulation Daniel Lezcano
2023-10-12 10:26 ` [PATCH 2/2] thermal/core: Reorder the headers inclusion Daniel Lezcano
2023-10-13 8:05 ` Lukasz Luba
2023-10-12 12:01 ` Lukasz Luba [this message]
2023-10-12 13:14 ` [PATCH 1/2] thermal/core: Hardening the self-encapsulation Daniel Lezcano
2023-10-12 14:30 ` Thierry Reding
2023-10-12 17:44 ` Rafael J. Wysocki
2023-10-12 21:13 ` Daniel Lezcano
2023-10-13 9:43 ` Rafael J. Wysocki
2023-10-13 8:03 ` Lukasz Luba
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=a6b51de7-4f56-4db9-a7dd-60555ac6c37f@arm.com \
--to=lukasz.luba@arm.com \
--cc=amitk@kernel.org \
--cc=daniel.lezcano@linaro.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-pm@vger.kernel.org \
--cc=rafael@kernel.org \
--cc=rui.zhang@intel.com \
--cc=thierry.reding@gmail.com \
/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