diff options
| author | Linus Torvalds <torvalds@linux-foundation.org> | 2026-02-21 16:37:42 -0800 |
|---|---|---|
| committer | Linus Torvalds <torvalds@linux-foundation.org> | 2026-02-21 17:09:51 -0800 |
| commit | bf4afc53b77aeaa48b5409da5c8da6bb4eff7f43 (patch) | |
| tree | 01fdd9d27f1b272bef0127966e08eac44d134d0a /drivers/net/vxlan | |
| parent | e19e1b480ac73c3e62ffebbca1174f0f511f43e7 (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 'drivers/net/vxlan')
| -rw-r--r-- | drivers/net/vxlan/vxlan_core.c | 2 | ||||
| -rw-r--r-- | drivers/net/vxlan/vxlan_mdb.c | 10 | ||||
| -rw-r--r-- | drivers/net/vxlan/vxlan_vnifilter.c | 4 |
3 files changed, 8 insertions, 8 deletions
diff --git a/drivers/net/vxlan/vxlan_core.c b/drivers/net/vxlan/vxlan_core.c index c1cf3eff4c1b..05558b6afecd 100644 --- a/drivers/net/vxlan/vxlan_core.c +++ b/drivers/net/vxlan/vxlan_core.c @@ -3578,7 +3578,7 @@ static struct vxlan_sock *vxlan_socket_create(struct net *net, bool ipv6, ASSERT_RTNL(); - vs = kzalloc_obj(*vs, GFP_KERNEL); + vs = kzalloc_obj(*vs); if (!vs) return ERR_PTR(-ENOMEM); diff --git a/drivers/net/vxlan/vxlan_mdb.c b/drivers/net/vxlan/vxlan_mdb.c index 8f53ae776613..055a4969f593 100644 --- a/drivers/net/vxlan/vxlan_mdb.c +++ b/drivers/net/vxlan/vxlan_mdb.c @@ -430,7 +430,7 @@ static int vxlan_mdb_config_src_entry_init(struct vxlan_mdb_config *cfg, extack)) return -EINVAL; - src = kzalloc_obj(*src, GFP_KERNEL); + src = kzalloc_obj(*src); if (!src) return -ENOMEM; @@ -697,7 +697,7 @@ static int vxlan_mdb_remote_rdst_init(const struct vxlan_mdb_config *cfg, struct vxlan_rdst *rd; int err; - rd = kzalloc_obj(*rd, GFP_KERNEL); + rd = kzalloc_obj(*rd); if (!rd) return -ENOMEM; @@ -767,7 +767,7 @@ vxlan_mdb_remote_src_entry_add(struct vxlan_mdb_remote *remote, { struct vxlan_mdb_src_entry *ent; - ent = kzalloc_obj(*ent, GFP_KERNEL); + ent = kzalloc_obj(*ent); if (!ent) return NULL; @@ -1139,7 +1139,7 @@ static int vxlan_mdb_remote_add(const struct vxlan_mdb_config *cfg, return -ENOENT; } - remote = kzalloc_obj(*remote, GFP_KERNEL); + remote = kzalloc_obj(*remote); if (!remote) return -ENOMEM; @@ -1187,7 +1187,7 @@ vxlan_mdb_entry_get(struct vxlan_dev *vxlan, if (mdb_entry) return mdb_entry; - mdb_entry = kzalloc_obj(*mdb_entry, GFP_KERNEL); + mdb_entry = kzalloc_obj(*mdb_entry); if (!mdb_entry) return ERR_PTR(-ENOMEM); diff --git a/drivers/net/vxlan/vxlan_vnifilter.c b/drivers/net/vxlan/vxlan_vnifilter.c index 726a34d16fa2..2042369379ff 100644 --- a/drivers/net/vxlan/vxlan_vnifilter.c +++ b/drivers/net/vxlan/vxlan_vnifilter.c @@ -697,7 +697,7 @@ static struct vxlan_vni_node *vxlan_vni_alloc(struct vxlan_dev *vxlan, { struct vxlan_vni_node *vninode; - vninode = kzalloc_obj(*vninode, GFP_KERNEL); + vninode = kzalloc_obj(*vninode); if (!vninode) return NULL; vninode->stats = netdev_alloc_pcpu_stats(struct vxlan_vni_stats_pcpu); @@ -925,7 +925,7 @@ int vxlan_vnigroup_init(struct vxlan_dev *vxlan) struct vxlan_vni_group *vg; int ret; - vg = kzalloc_obj(*vg, GFP_KERNEL); + vg = kzalloc_obj(*vg); if (!vg) return -ENOMEM; ret = rhashtable_init(&vg->vni_hash, &vxlan_vni_rht_params); |
