summaryrefslogtreecommitdiff
path: root/kernel/trace/tracing_map.c
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2026-02-21 16:37:42 -0800
committerLinus Torvalds <torvalds@linux-foundation.org>2026-02-21 17:09:51 -0800
commitbf4afc53b77aeaa48b5409da5c8da6bb4eff7f43 (patch)
tree01fdd9d27f1b272bef0127966e08eac44d134d0a /kernel/trace/tracing_map.c
parente19e1b480ac73c3e62ffebbca1174f0f511f43e7 (diff)
Convert 'alloc_obj' family to use the new default GFP_KERNEL argument
This was done entirely with mindless brute force, using git grep -l '\<k[vmz]*alloc_objs*(.*, GFP_KERNEL)' | xargs sed -i 's/\(alloc_objs*(.*\), GFP_KERNEL)/\1)/' to convert the new alloc_obj() users that had a simple GFP_KERNEL argument to just drop that argument. Note that due to the extreme simplicity of the scripting, any slightly more complex cases spread over multiple lines would not be triggered: they definitely exist, but this covers the vast bulk of the cases, and the resulting diff is also then easier to check automatically. For the same reason the 'flex' versions will be done as a separate conversion. Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'kernel/trace/tracing_map.c')
-rw-r--r--kernel/trace/tracing_map.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/kernel/trace/tracing_map.c b/kernel/trace/tracing_map.c
index ef28c6c52295..bf1a507695b6 100644
--- a/kernel/trace/tracing_map.c
+++ b/kernel/trace/tracing_map.c
@@ -324,7 +324,7 @@ static struct tracing_map_array *tracing_map_array_alloc(unsigned int n_elts,
struct tracing_map_array *a;
unsigned int i;
- a = kzalloc_obj(*a, GFP_KERNEL);
+ a = kzalloc_obj(*a);
if (!a)
return NULL;
@@ -405,7 +405,7 @@ static struct tracing_map_elt *tracing_map_elt_alloc(struct tracing_map *map)
struct tracing_map_elt *elt;
int err = 0;
- elt = kzalloc_obj(*elt, GFP_KERNEL);
+ elt = kzalloc_obj(*elt);
if (!elt)
return ERR_PTR(-ENOMEM);
@@ -417,19 +417,19 @@ static struct tracing_map_elt *tracing_map_elt_alloc(struct tracing_map *map)
goto free;
}
- elt->fields = kzalloc_objs(*elt->fields, map->n_fields, GFP_KERNEL);
+ elt->fields = kzalloc_objs(*elt->fields, map->n_fields);
if (!elt->fields) {
err = -ENOMEM;
goto free;
}
- elt->vars = kzalloc_objs(*elt->vars, map->n_vars, GFP_KERNEL);
+ elt->vars = kzalloc_objs(*elt->vars, map->n_vars);
if (!elt->vars) {
err = -ENOMEM;
goto free;
}
- elt->var_set = kzalloc_objs(*elt->var_set, map->n_vars, GFP_KERNEL);
+ elt->var_set = kzalloc_objs(*elt->var_set, map->n_vars);
if (!elt->var_set) {
err = -ENOMEM;
goto free;
@@ -777,7 +777,7 @@ struct tracing_map *tracing_map_create(unsigned int map_bits,
map_bits > TRACING_MAP_BITS_MAX)
return ERR_PTR(-EINVAL);
- map = kzalloc_obj(*map, GFP_KERNEL);
+ map = kzalloc_obj(*map);
if (!map)
return ERR_PTR(-ENOMEM);
@@ -949,7 +949,7 @@ create_sort_entry(void *key, struct tracing_map_elt *elt)
{
struct tracing_map_sort_entry *sort_entry;
- sort_entry = kzalloc_obj(*sort_entry, GFP_KERNEL);
+ sort_entry = kzalloc_obj(*sort_entry);
if (!sort_entry)
return NULL;