Linux Documentation
 help / color / mirror / Atom feed
From: Bradley Morgan <brads@mainlining.org>
To: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Cc: Luis Chamberlain <mcgrof@kernel.org>,
	Petr Pavlu <petr.pavlu@suse.com>,
	Daniel Gomez <da.gomez@kernel.org>,
	Sami Tolvanen <samitolvanen@google.com>,
	Aaron Tomlin <atomlin@atomlin.com>,
	Jonathan Corbet <corbet@lwn.net>,
	Shuah Khan <skhan@linuxfoundation.org>,
	Randy Dunlap <rdunlap@infradead.org>,
	"Rafael J. Wysocki" <rafael@kernel.org>,
	Danilo Krummrich <dakr@kernel.org>,
	Steven Rostedt <rostedt@goodmis.org>,
	Masami Hiramatsu <mhiramat@kernel.org>,
	Mathieu Desnoyers <mathieu.desnoyers@efficios.com>,
	Aleksandr Nogikh <nogikh@google.com>,
	linux-modules@vger.kernel.org, linux-kernel@vger.kernel.org,
	linux-doc@vger.kernel.org, linux-usb@vger.kernel.org,
	driver-core@lists.linux.dev, linux-trace-kernel@vger.kernel.org,
	Johan Hovold <johan@kernel.org>
Subject: Re: [PATCH v2 1/2] module: pull out add_taint_module() to be public
Date: Mon, 31 Aug 2026 12:38:07 +0100	[thread overview]
Message-ID: <F4CE5DE5-66B7-491C-B288-A5666A56FC0F@mainlining.org> (raw)
In-Reply-To: <2026083107-gently-leverage-7f97@gregkh>

On 31 August 2026 12:28:48 BST, Greg Kroah-Hartman
<gregkh@linuxfoundation.org> wrote:
>On Mon, Aug 31, 2026 at 12:14:17PM +0100, Bradley Morgan wrote:
>> On 31 August 2026 12:07:50 BST, Greg Kroah-Hartman
>> <gregkh@linuxfoundation.org> wrote:
>> >On Mon, Aug 31, 2026 at 12:51:46PM +0200, Greg Kroah-Hartman wrote:
>> >> Other kernel code might want to call add_taint_module() so pull it
>out
>> >> and make it global.  If modules are not enabled, this defaults to a
>call
>> >> to add_taint(), so all is fine.
>> >> 
>> >> Reviewed-by: Johan Hovold <johan@kernel.org>
>> >> Tested-by: Johan Hovold <johan@kernel.org>
>> >> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
>> >> ---
>> >>  include/linux/module.h | 10 ++++++++++
>> >>  kernel/module/main.c   | 16 +++++++++++++---
>> >>  2 files changed, 23 insertions(+), 3 deletions(-)
>> >> 
>> >> diff --git a/include/linux/module.h b/include/linux/module.h
>> >> index 96cc98568eea..0636e0f2728c 100644
>> >> --- a/include/linux/module.h
>> >> +++ b/include/linux/module.h
>> >> @@ -29,6 +29,7 @@
>> >>  #include <linux/srcu.h>
>> >>  #include <linux/static_call_types.h>
>> >>  #include <linux/dynamic_debug.h>
>> >> +#include <linux/panic.h>
>> >>  
>> >>  #include <linux/percpu.h>
>> >>  #include <asm/module.h>
>> >> @@ -770,6 +771,9 @@ static inline bool is_livepatch_module(struct
>module
>> >*mod)
>> >>  
>> >>  void module_for_each_mod(int(*func)(struct module *mod, void *data),
>> >void *data);
>> >>  
>> >> +void add_taint_module(struct module *mod, unsigned flag,
>> >> +		      enum lockdep_ok lockdep_ok);
>> >> +
>> >>  #else /* !CONFIG_MODULES... */
>> >>  
>> >>  static inline struct module *__module_address(unsigned long addr)
>> >> @@ -877,6 +881,12 @@ static inline bool module_is_coming(struct
>module
>> >*mod)
>> >>  static inline void module_for_each_mod(int(*func)(struct module
>*mod,
>> >void *data), void *data)
>> >>  {
>> >>  }
>> >> +
>> >> +static inline void add_taint_module(struct module *mod, unsigned
>flag,
>> >> +				    enum lockdep_ok, lockdep_ok)
>> >
>> >And this line is wrong, ugh.  I gotta go get sashiko running locally...
>> 
>> Cough cough, Claude code speaking 
>
>Nope, no claude running here at all, sorry to burst your bubble.  If I
>had, it would have caught this :)
>
>greg k-h
Nooooo lol.

I mean asking Claudy to find bugs in the code submitted before submitting
it.

Saves me a ridiculous amount of time.
--- Thanks!
https://lore.kernel.org/all/EE579805-42F2-4C58-B752-F28779EEB717@grrlz.net/

  reply	other threads:[~2026-08-31 11:38 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-08-31 10:51 [PATCH v2 0/2] driver core: add TAINT_FORCED_BIND for when userspace manually messes with devices and drivers Greg Kroah-Hartman
2026-08-31 10:51 ` [PATCH v2 1/2] module: pull out add_taint_module() to be public Greg Kroah-Hartman
2026-08-31 11:07   ` Greg Kroah-Hartman
2026-08-31 11:14     ` Bradley Morgan
2026-08-31 11:28       ` Greg Kroah-Hartman
2026-08-31 11:38         ` Bradley Morgan [this message]
2026-08-31 10:51 ` [PATCH v2 2/2] driver core: add TAINT_FORCED_BIND for when userspace manually messes with devices and drivers Greg Kroah-Hartman
2026-08-31 11:47   ` Aaron Tomlin
2026-08-31 11:57 ` [PATCH v2 0/2] " Bradley Morgan

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=F4CE5DE5-66B7-491C-B288-A5666A56FC0F@mainlining.org \
    --to=brads@mainlining.org \
    --cc=atomlin@atomlin.com \
    --cc=corbet@lwn.net \
    --cc=da.gomez@kernel.org \
    --cc=dakr@kernel.org \
    --cc=driver-core@lists.linux.dev \
    --cc=gregkh@linuxfoundation.org \
    --cc=johan@kernel.org \
    --cc=linux-doc@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-modules@vger.kernel.org \
    --cc=linux-trace-kernel@vger.kernel.org \
    --cc=linux-usb@vger.kernel.org \
    --cc=mathieu.desnoyers@efficios.com \
    --cc=mcgrof@kernel.org \
    --cc=mhiramat@kernel.org \
    --cc=nogikh@google.com \
    --cc=petr.pavlu@suse.com \
    --cc=rafael@kernel.org \
    --cc=rdunlap@infradead.org \
    --cc=rostedt@goodmis.org \
    --cc=samitolvanen@google.com \
    --cc=skhan@linuxfoundation.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