Re: [PATCH 10/13] module: pass struct find_symbol_args to find_symbol

2021-02-03 Thread Miroslav Benes
On Wed, 3 Feb 2021, Christoph Hellwig wrote: > FYI, this is the updated version: > > --- > >From 664ca3378deac7530fe8fc15fe73d583ddf2 Mon Sep 17 00:00:00 2001 > From: Christoph Hellwig > Date: Wed, 20 Jan 2021 14:58:27 +0100 > Subject: module: pass struct find_symbol_args to find_symbol > >

Re: [PATCH 10/13] module: pass struct find_symbol_args to find_symbol

2021-02-03 Thread Christoph Hellwig
FYI, this is the updated version: --- >From 664ca3378deac7530fe8fc15fe73d583ddf2 Mon Sep 17 00:00:00 2001 From: Christoph Hellwig Date: Wed, 20 Jan 2021 14:58:27 +0100 Subject: module: pass struct find_symbol_args to find_symbol Simplify the calling convention by passing the find_symbol_args

Re: [PATCH 10/13] module: pass struct find_symbol_args to find_symbol

2021-02-02 Thread Christoph Hellwig
On Tue, Feb 02, 2021 at 03:07:51PM +0100, Miroslav Benes wrote: > > preempt_disable(); > > - sym = find_symbol(symbol, &owner, NULL, NULL, true, true); > > - if (sym && strong_try_module_get(owner)) > > - sym = NULL; > > + if (!find_symbol(&fsa) || !strong_try_module_get(fsa.own

Re: [PATCH 10/13] module: pass struct find_symbol_args to find_symbol

2021-02-02 Thread Miroslav Benes
> void *__symbol_get(const char *symbol) > { > - struct module *owner; > - const struct kernel_symbol *sym; > + struct find_symbol_arg fsa = { > + .name = symbol, > + .gplok = true, > + .warn = true, > + }; > > preempt_disable(); >

[PATCH 10/13] module: pass struct find_symbol_args to find_symbol

2021-02-02 Thread Christoph Hellwig
Simplify the calling convention by passing the find_symbol_args structure to find_symbol instead of initializing it inside the function. Signed-off-by: Christoph Hellwig --- kernel/module.c | 113 ++-- 1 file changed, 52 insertions(+), 61 deletions(-)

[PATCH 10/13] module: pass struct find_symbol_args to find_symbol

2021-01-28 Thread Christoph Hellwig
Simplify the calling convention by passing the find_symbol_args structure to find_symbol instead of initializing it inside the function. Signed-off-by: Christoph Hellwig --- kernel/module.c | 113 ++-- 1 file changed, 52 insertions(+), 61 deletions(-)