From: Johan Hovold <johan@kernel.org>
To: Daniel Lezcano <daniel.lezcano@linaro.org>
Cc: Thomas Gleixner <tglx@linutronix.de>,
Maxime Coquelin <mcoquelin.stm32@gmail.com>,
Alexandre Torgue <alexandre.torgue@foss.st.com>,
linux-kernel@vger.kernel.org, stable@vger.kernel.org
Subject: Re: [PATCH] clocksource/drivers/stm: Fix section mismatches
Date: Mon, 10 Nov 2025 15:51:13 +0100 [thread overview]
Message-ID: <aRH74auttb6UgnjP@hovoldconsulting.com> (raw)
In-Reply-To: <7ad2b976-3b0d-4823-a145-ceedf071450d@linaro.org>
Hi Daniel,
On Wed, Nov 05, 2025 at 02:32:18PM +0100, Daniel Lezcano wrote:
> You should replace __init by __init_or_module
That's not sufficient as the driver can still be rebound through sysfs
currently (the driver would probably crash anyway, but that's a separate
issue).
Also note that no drivers use __init_or_module these days, likely as
everyone uses modules and it's not worth the added complexity in trying
to get the section markers right for a build configuration that few
people care about.
I can send a follow-on patch to suppress the unbind attribute, or
include it in a v2 if you insist on using __init_or_module.
What do you prefer?
> On 10/17/25 07:49, Johan Hovold wrote:
> > Platform drivers can be probed after their init sections have been
> > discarded (e.g. on probe deferral or manual rebind through sysfs) so the
> > probe function must not live in init. Device managed resource actions
> > similarly cannot be discarded.
Johan
next prev parent reply other threads:[~2025-11-10 14:51 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-10-17 5:49 [PATCH] clocksource/drivers/stm: Fix section mismatches Johan Hovold
2025-10-20 9:32 ` Johan Hovold
2025-10-20 9:39 ` Greg KH
2025-10-20 9:44 ` Johan Hovold
2025-11-05 13:32 ` Daniel Lezcano
2025-11-10 14:51 ` Johan Hovold [this message]
2025-11-12 9:57 ` Daniel Lezcano
2025-11-12 10:58 ` Johan Hovold
2025-11-12 15:22 ` Daniel Lezcano
2025-11-26 14:40 ` [tip: timers/clocksource] clocksource/drivers/nxp-stm: " tip-bot2 for Johan Hovold
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=aRH74auttb6UgnjP@hovoldconsulting.com \
--to=johan@kernel.org \
--cc=alexandre.torgue@foss.st.com \
--cc=daniel.lezcano@linaro.org \
--cc=linux-kernel@vger.kernel.org \
--cc=mcoquelin.stm32@gmail.com \
--cc=stable@vger.kernel.org \
--cc=tglx@linutronix.de \
/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;
as well as URLs for NNTP newsgroup(s).