[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20200725024227.GD17052@linux.intel.com>
Date: Sat, 25 Jul 2020 05:42:27 +0300
From: Jarkko Sakkinen <jarkko.sakkinen@...ux.intel.com>
To: Mike Rapoport <rppt@...nel.org>
Cc: linux-kernel@...r.kernel.org, linux-mm@...ck.org,
Andi Kleen <ak@...ux.intel.com>,
Peter Zijlstra <peterz@...radead.org>,
Masami Hiramatsu <mhiramat@...nel.org>,
Jessica Yu <jeyu@...nel.org>,
"Naveen N. Rao" <naveen.n.rao@...ux.ibm.com>,
Anil S Keshavamurthy <anil.s.keshavamurthy@...el.com>,
"David S. Miller" <davem@...emloft.net>,
Steven Rostedt <rostedt@...dmis.org>,
Ingo Molnar <mingo@...hat.com>
Subject: Re: [PATCH v5 1/6] kprobes: Remove dependency to the module_mutex
On Fri, Jul 24, 2020 at 01:22:58PM +0300, Mike Rapoport wrote:
> On Fri, Jul 24, 2020 at 08:05:48AM +0300, Jarkko Sakkinen wrote:
> > Add lock_modules() and unlock_modules() wrappers for acquiring module_mutex
> > in order to remove the compile time dependency to it.
> >
> > Cc: linux-mm@...ck.org
> > Cc: Andi Kleen <ak@...ux.intel.com>
> > Cc: Peter Zijlstra <peterz@...radead.org>
> > Suggested-by: Masami Hiramatsu <mhiramat@...nel.org>
> > Signed-off-by: Jarkko Sakkinen <jarkko.sakkinen@...ux.intel.com>
> > ---
> > include/linux/module.h | 18 ++++++++++++++++++
> > kernel/kprobes.c | 4 ++--
> > kernel/trace/trace_kprobe.c | 4 ++--
> > 3 files changed, 22 insertions(+), 4 deletions(-)
>
> Any reason to convert only kprobes to the new API and leave others with
> opencoded implementation?
Not anything particular.
Lets see:
$ git --no-pager grep "mutex_lock(&module_mutex)"
arch/powerpc/platforms/powernv/pci-cxl.c: mutex_lock(&module_mutex);
drivers/gpu/drm/drm_fb_helper.c: mutex_lock(&module_mutex);
include/linux/module.h: mutex_lock(&module_mutex);
kernel/livepatch/core.c: mutex_lock(&module_mutex);
kernel/livepatch/core.c: mutex_lock(&module_mutex);
kernel/module.c: mutex_lock(&module_mutex);
kernel/module.c: mutex_lock(&module_mutex);
kernel/module.c: mutex_lock(&module_mutex);
kernel/module.c: mutex_lock(&module_mutex);
kernel/module.c: mutex_lock(&module_mutex);
kernel/module.c: mutex_lock(&module_mutex);
kernel/module.c: mutex_lock(&module_mutex);
kernel/module.c: mutex_lock(&module_mutex);
kernel/module.c: mutex_lock(&module_mutex);
kernel/module.c: mutex_lock(&module_mutex);
kernel/module.c: mutex_lock(&module_mutex);
kernel/module.c: mutex_lock(&module_mutex);
kernel/module.c: mutex_lock(&module_mutex);
I could refine this commit to patch these sites. Or should I split it
into multiple?
/Jarkko
Powered by blists - more mailing lists