Convert 'alloc_flex' family to use the new default GFP_KERNEL argument

This is the exact same thing as the 'alloc_obj()' version, only much
smaller because there are a lot fewer users of the *alloc_flex()
interface.

As with alloc_obj() version, this was done entirely with mindless brute
force, using the same script, except using 'flex' in the pattern rather
than 'objs*'.

Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
This commit is contained in:
Linus Torvalds
2026-02-21 17:06:51 -08:00
parent bf4afc53b7
commit 323bbfcf1e
310 changed files with 352 additions and 352 deletions

View File

@@ -749,7 +749,7 @@ static int fprobe_init(struct fprobe *fp, unsigned long *addrs, int num)
return -E2BIG;
fp->entry_data_size = size;
hlist_array = kzalloc_flex(*hlist_array, array, num, GFP_KERNEL);
hlist_array = kzalloc_flex(*hlist_array, array, num);
if (!hlist_array)
return -ENOMEM;

View File

@@ -211,7 +211,7 @@ static struct trace_eprobe *alloc_event_probe(const char *group,
sys_name = event->class->system;
event_name = trace_event_name(event);
ep = kzalloc_flex(*ep, tp.args, nargs, GFP_KERNEL);
ep = kzalloc_flex(*ep, tp.args, nargs);
if (!ep) {
trace_event_put_ref(event);
return ERR_PTR(-ENOMEM);

View File

@@ -579,7 +579,7 @@ static struct trace_fprobe *alloc_trace_fprobe(const char *group,
struct trace_fprobe *tf __free(free_trace_fprobe) = NULL;
int ret = -ENOMEM;
tf = kzalloc_flex(*tf, tp.args, nargs, GFP_KERNEL);
tf = kzalloc_flex(*tf, tp.args, nargs);
if (!tf)
return ERR_PTR(ret);

View File

@@ -275,7 +275,7 @@ static struct trace_kprobe *alloc_trace_kprobe(const char *group,
struct trace_kprobe *tk __free(free_trace_kprobe) = NULL;
int ret = -ENOMEM;
tk = kzalloc_flex(*tk, tp.args, nargs, GFP_KERNEL);
tk = kzalloc_flex(*tk, tp.args, nargs);
if (!tk)
return ERR_PTR(ret);

View File

@@ -338,7 +338,7 @@ alloc_trace_uprobe(const char *group, const char *event, int nargs, bool is_ret)
struct trace_uprobe *tu;
int ret;
tu = kzalloc_flex(*tu, tp.args, nargs, GFP_KERNEL);
tu = kzalloc_flex(*tu, tp.args, nargs);
if (!tu)
return ERR_PTR(-ENOMEM);