summaryrefslogtreecommitdiff
path: root/drivers/net/netdevsim/fib.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 /drivers/net/netdevsim/fib.c
parente19e1b480ac73c3e62ffebbca1174f0f511f43e7 (diff)
downloadlwn-bf4afc53b77aeaa48b5409da5c8da6bb4eff7f43.tar.gz
lwn-bf4afc53b77aeaa48b5409da5c8da6bb4eff7f43.zip
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 'drivers/net/netdevsim/fib.c')
-rw-r--r--drivers/net/netdevsim/fib.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/drivers/net/netdevsim/fib.c b/drivers/net/netdevsim/fib.c
index b1292a8c0ef1..1a42bdbfaa41 100644
--- a/drivers/net/netdevsim/fib.c
+++ b/drivers/net/netdevsim/fib.c
@@ -277,7 +277,7 @@ nsim_fib4_rt_create(struct nsim_fib_data *data,
{
struct nsim_fib4_rt *fib4_rt;
- fib4_rt = kzalloc_obj(*fib4_rt, GFP_KERNEL);
+ fib4_rt = kzalloc_obj(*fib4_rt);
if (!fib4_rt)
return NULL;
@@ -497,7 +497,7 @@ static int nsim_fib6_rt_nh_add(struct nsim_fib6_rt *fib6_rt,
{
struct nsim_fib6_rt_nh *fib6_rt_nh;
- fib6_rt_nh = kzalloc_obj(*fib6_rt_nh, GFP_KERNEL);
+ fib6_rt_nh = kzalloc_obj(*fib6_rt_nh);
if (!fib6_rt_nh)
return -ENOMEM;
@@ -544,7 +544,7 @@ nsim_fib6_rt_create(struct nsim_fib_data *data,
int i = 0;
int err;
- fib6_rt = kzalloc_obj(*fib6_rt, GFP_KERNEL);
+ fib6_rt = kzalloc_obj(*fib6_rt);
if (!fib6_rt)
return ERR_PTR(-ENOMEM);
@@ -1116,7 +1116,7 @@ static struct nsim_nexthop *nsim_nexthop_create(struct nsim_fib_data *data,
u64 occ = 0;
int i;
- nexthop = kzalloc_obj(*nexthop, GFP_KERNEL);
+ nexthop = kzalloc_obj(*nexthop);
if (!nexthop)
return ERR_PTR(-ENOMEM);
@@ -1556,7 +1556,7 @@ struct nsim_fib_data *nsim_fib_create(struct devlink *devlink,
struct nsim_dev *nsim_dev;
int err;
- data = kzalloc_obj(*data, GFP_KERNEL);
+ data = kzalloc_obj(*data);
if (!data)
return ERR_PTR(-ENOMEM);
data->devlink = devlink;