summaryrefslogtreecommitdiff
path: root/net
diff options
context:
space:
mode:
Diffstat (limited to 'net')
-rw-r--r--net/bluetooth/hci_core.c2
-rw-r--r--net/bluetooth/mgmt.c2
-rw-r--r--net/bluetooth/rfcomm/tty.c2
-rw-r--r--net/core/bpf_sk_storage.c2
-rw-r--r--net/core/dev.c2
-rw-r--r--net/core/flow_offload.c2
-rw-r--r--net/devlink/core.c2
-rw-r--r--net/ethtool/common.c4
-rw-r--r--net/ipv4/fib_semantics.c2
-rw-r--r--net/ipv4/nexthop.c2
-rw-r--r--net/ipv4/udp_tunnel_nic.c2
-rw-r--r--net/netfilter/nft_set_pipapo.c2
-rw-r--r--net/netfilter/xt_hashlimit.c2
-rw-r--r--net/netfilter/xt_recent.c2
-rw-r--r--net/openvswitch/meter.c2
-rw-r--r--net/sched/cls_u32.c10
-rw-r--r--net/sched/sch_api.c2
-rw-r--r--net/sched/sch_netem.c2
-rw-r--r--net/sunrpc/svcsock.c2
-rw-r--r--net/sunrpc/xprtrdma/svc_rdma_pcl.c2
-rw-r--r--net/wireless/nl80211.c14
-rw-r--r--net/wireless/pmsr.c2
-rw-r--r--net/wireless/reg.c6
-rw-r--r--net/wireless/scan.c2
-rw-r--r--net/xdp/xsk_buff_pool.c2
25 files changed, 38 insertions, 38 deletions
diff --git a/net/bluetooth/hci_core.c b/net/bluetooth/hci_core.c
index 7094f80de24e..31308c1de4ec 100644
--- a/net/bluetooth/hci_core.c
+++ b/net/bluetooth/hci_core.c
@@ -797,7 +797,7 @@ int hci_get_dev_list(void __user *arg)
if (!dev_num || dev_num > (PAGE_SIZE * 2) / sizeof(*dr))
return -EINVAL;
- dl = kzalloc_flex(*dl, dev_req, dev_num, GFP_KERNEL);
+ dl = kzalloc_flex(*dl, dev_req, dev_num);
if (!dl)
return -ENOMEM;
diff --git a/net/bluetooth/mgmt.c b/net/bluetooth/mgmt.c
index 1cfe03260d50..a7238fd3b03b 100644
--- a/net/bluetooth/mgmt.c
+++ b/net/bluetooth/mgmt.c
@@ -3360,7 +3360,7 @@ static int get_connections(struct sock *sk, struct hci_dev *hdev, void *data,
i++;
}
- rp = kmalloc_flex(*rp, addr, i, GFP_KERNEL);
+ rp = kmalloc_flex(*rp, addr, i);
if (!rp) {
err = -ENOMEM;
goto unlock;
diff --git a/net/bluetooth/rfcomm/tty.c b/net/bluetooth/rfcomm/tty.c
index b65feeba1b30..91bf5274262e 100644
--- a/net/bluetooth/rfcomm/tty.c
+++ b/net/bluetooth/rfcomm/tty.c
@@ -510,7 +510,7 @@ static int rfcomm_get_dev_list(void __user *arg)
if (!dev_num || dev_num > (PAGE_SIZE * 4) / sizeof(*di))
return -EINVAL;
- dl = kzalloc_flex(*dl, dev_info, dev_num, GFP_KERNEL);
+ dl = kzalloc_flex(*dl, dev_info, dev_num);
if (!dl)
return -ENOMEM;
diff --git a/net/core/bpf_sk_storage.c b/net/core/bpf_sk_storage.c
index 8165d606bfd4..f8338acebf07 100644
--- a/net/core/bpf_sk_storage.c
+++ b/net/core/bpf_sk_storage.c
@@ -500,7 +500,7 @@ bpf_sk_storage_diag_alloc(const struct nlattr *nla_stgs)
nr_maps++;
}
- diag = kzalloc_flex(*diag, maps, nr_maps, GFP_KERNEL);
+ diag = kzalloc_flex(*diag, maps, nr_maps);
if (!diag)
return ERR_PTR(-ENOMEM);
diff --git a/net/core/dev.c b/net/core/dev.c
index b91aabb18bbe..27e5fcbaa2d6 100644
--- a/net/core/dev.c
+++ b/net/core/dev.c
@@ -6510,7 +6510,7 @@ struct flush_backlogs {
static struct flush_backlogs *flush_backlogs_alloc(void)
{
- return kmalloc_flex(struct flush_backlogs, w, nr_cpu_ids, GFP_KERNEL);
+ return kmalloc_flex(struct flush_backlogs, w, nr_cpu_ids);
}
static struct flush_backlogs *flush_backlogs_fallback;
diff --git a/net/core/flow_offload.c b/net/core/flow_offload.c
index c55bf9d5ac8c..c0a9c5b3c977 100644
--- a/net/core/flow_offload.c
+++ b/net/core/flow_offload.c
@@ -12,7 +12,7 @@ struct flow_rule *flow_rule_alloc(unsigned int num_actions)
struct flow_rule *rule;
int i;
- rule = kzalloc_flex(*rule, action.entries, num_actions, GFP_KERNEL);
+ rule = kzalloc_flex(*rule, action.entries, num_actions);
if (!rule)
return NULL;
diff --git a/net/devlink/core.c b/net/devlink/core.c
index 0b020f69cef1..d8e509a669bf 100644
--- a/net/devlink/core.c
+++ b/net/devlink/core.c
@@ -418,7 +418,7 @@ struct devlink *devlink_alloc_ns(const struct devlink_ops *ops,
if (!devlink_reload_actions_valid(ops))
return NULL;
- devlink = kvzalloc_flex(*devlink, priv, priv_size, GFP_KERNEL);
+ devlink = kvzalloc_flex(*devlink, priv, priv_size);
if (!devlink)
return NULL;
diff --git a/net/ethtool/common.c b/net/ethtool/common.c
index 7a302a93f52c..e252cf20c22f 100644
--- a/net/ethtool/common.c
+++ b/net/ethtool/common.c
@@ -687,7 +687,7 @@ static int ethtool_get_max_rxnfc_channel(struct net_device *dev, u64 *max)
if (rule_cnt <= 0)
return -EINVAL;
- info = kvzalloc_flex(*info, rule_locs, rule_cnt, GFP_KERNEL);
+ info = kvzalloc_flex(*info, rule_locs, rule_cnt);
if (!info)
return -ENOMEM;
@@ -841,7 +841,7 @@ int ethtool_check_rss_ctx_busy(struct net_device *dev, u32 rss_context)
if (rule_cnt < 0)
return -EINVAL;
- info = kvzalloc_flex(*info, rule_locs, rule_cnt, GFP_KERNEL);
+ info = kvzalloc_flex(*info, rule_locs, rule_cnt);
if (!info)
return -ENOMEM;
diff --git a/net/ipv4/fib_semantics.c b/net/ipv4/fib_semantics.c
index ceef080112a9..a521ac0da2f7 100644
--- a/net/ipv4/fib_semantics.c
+++ b/net/ipv4/fib_semantics.c
@@ -1399,7 +1399,7 @@ struct fib_info *fib_create_info(struct fib_config *cfg,
fib_info_hash_grow(net);
- fi = kzalloc_flex(*fi, fib_nh, nhs, GFP_KERNEL);
+ fi = kzalloc_flex(*fi, fib_nh, nhs);
if (!fi) {
err = -ENOBUFS;
goto failure;
diff --git a/net/ipv4/nexthop.c b/net/ipv4/nexthop.c
index b9873370c69e..3518c5f27cb2 100644
--- a/net/ipv4/nexthop.c
+++ b/net/ipv4/nexthop.c
@@ -549,7 +549,7 @@ static struct nh_group *nexthop_grp_alloc(u16 num_nh)
{
struct nh_group *nhg;
- nhg = kzalloc_flex(*nhg, nh_entries, num_nh, GFP_KERNEL);
+ nhg = kzalloc_flex(*nhg, nh_entries, num_nh);
if (nhg)
nhg->num_nh = num_nh;
diff --git a/net/ipv4/udp_tunnel_nic.c b/net/ipv4/udp_tunnel_nic.c
index 75d9b6d3f51a..9716e98b9291 100644
--- a/net/ipv4/udp_tunnel_nic.c
+++ b/net/ipv4/udp_tunnel_nic.c
@@ -753,7 +753,7 @@ udp_tunnel_nic_alloc(const struct udp_tunnel_nic_info *info,
struct udp_tunnel_nic *utn;
unsigned int i;
- utn = kzalloc_flex(*utn, entries, n_tables, GFP_KERNEL);
+ utn = kzalloc_flex(*utn, entries, n_tables);
if (!utn)
return NULL;
utn->n_tables = n_tables;
diff --git a/net/netfilter/nft_set_pipapo.c b/net/netfilter/nft_set_pipapo.c
index 6341b5bcb4cf..7ef4b44471d3 100644
--- a/net/netfilter/nft_set_pipapo.c
+++ b/net/netfilter/nft_set_pipapo.c
@@ -2236,7 +2236,7 @@ static int nft_pipapo_init(const struct nft_set *set,
if (field_count > NFT_PIPAPO_MAX_FIELDS)
return -EINVAL;
- m = kmalloc_flex(*m, f, field_count, GFP_KERNEL);
+ m = kmalloc_flex(*m, f, field_count);
if (!m)
return -ENOMEM;
diff --git a/net/netfilter/xt_hashlimit.c b/net/netfilter/xt_hashlimit.c
index 64ed12a32906..3bd127bfc114 100644
--- a/net/netfilter/xt_hashlimit.c
+++ b/net/netfilter/xt_hashlimit.c
@@ -293,7 +293,7 @@ static int htable_create(struct net *net, struct hashlimit_cfg3 *cfg,
if (size < 16)
size = 16;
}
- hinfo = kvmalloc_flex(*hinfo, hash, size, GFP_KERNEL);
+ hinfo = kvmalloc_flex(*hinfo, hash, size);
if (hinfo == NULL)
return -ENOMEM;
*out_hinfo = hinfo;
diff --git a/net/netfilter/xt_recent.c b/net/netfilter/xt_recent.c
index c9a1cc591171..f72752fa4374 100644
--- a/net/netfilter/xt_recent.c
+++ b/net/netfilter/xt_recent.c
@@ -391,7 +391,7 @@ static int recent_mt_check(const struct xt_mtchk_param *par,
goto out;
}
- t = kvzalloc_flex(*t, iphash, ip_list_hash_size, GFP_KERNEL);
+ t = kvzalloc_flex(*t, iphash, ip_list_hash_size);
if (t == NULL) {
ret = -ENOMEM;
goto out;
diff --git a/net/openvswitch/meter.c b/net/openvswitch/meter.c
index 0c2db78bb71e..a02c47277337 100644
--- a/net/openvswitch/meter.c
+++ b/net/openvswitch/meter.c
@@ -69,7 +69,7 @@ static struct dp_meter_instance *dp_meter_instance_alloc(const u32 size)
{
struct dp_meter_instance *ti;
- ti = kvzalloc_flex(*ti, dp_meters, size, GFP_KERNEL);
+ ti = kvzalloc_flex(*ti, dp_meters, size);
if (!ti)
return NULL;
diff --git a/net/sched/cls_u32.c b/net/sched/cls_u32.c
index 75a1c8c8ace1..eec222908977 100644
--- a/net/sched/cls_u32.c
+++ b/net/sched/cls_u32.c
@@ -364,7 +364,7 @@ static int u32_init(struct tcf_proto *tp)
void *key = tc_u_common_ptr(tp);
struct tc_u_common *tp_c = tc_u_common_find(key);
- root_ht = kzalloc_flex(*root_ht, ht, 1, GFP_KERNEL);
+ root_ht = kzalloc_flex(*root_ht, ht, 1);
if (root_ht == NULL)
return -ENOBUFS;
@@ -825,7 +825,7 @@ static struct tc_u_knode *u32_init_knode(struct net *net, struct tcf_proto *tp,
struct tc_u32_sel *s = &n->sel;
struct tc_u_knode *new;
- new = kzalloc_flex(*new, sel.keys, s->nkeys, GFP_KERNEL);
+ new = kzalloc_flex(*new, sel.keys, s->nkeys);
if (!new)
return NULL;
@@ -974,7 +974,7 @@ static int u32_change(struct net *net, struct sk_buff *in_skb,
NL_SET_ERR_MSG_MOD(extack, "Divisor can only be used on a hash table");
return -EINVAL;
}
- ht = kzalloc_flex(*ht, ht, divisor + 1, GFP_KERNEL);
+ ht = kzalloc_flex(*ht, ht, divisor + 1);
if (ht == NULL)
return -ENOBUFS;
if (handle == 0) {
@@ -1104,7 +1104,7 @@ static int u32_change(struct net *net, struct sk_buff *in_skb,
goto erridr;
}
- n = kzalloc_flex(*n, sel.keys, s->nkeys, GFP_KERNEL);
+ n = kzalloc_flex(*n, sel.keys, s->nkeys);
if (n == NULL) {
err = -ENOBUFS;
goto erridr;
@@ -1417,7 +1417,7 @@ static int u32_dump(struct net *net, struct tcf_proto *tp, void *fh,
goto nla_put_failure;
}
#ifdef CONFIG_CLS_U32_PERF
- gpf = kzalloc_flex(*gpf, kcnts, n->sel.nkeys, GFP_KERNEL);
+ gpf = kzalloc_flex(*gpf, kcnts, n->sel.nkeys);
if (!gpf)
goto nla_put_failure;
diff --git a/net/sched/sch_api.c b/net/sched/sch_api.c
index deb8ebc4401a..cc43e3f7574f 100644
--- a/net/sched/sch_api.c
+++ b/net/sched/sch_api.c
@@ -530,7 +530,7 @@ static struct qdisc_size_table *qdisc_get_stab(struct nlattr *opt,
return ERR_PTR(-EINVAL);
}
- stab = kmalloc_flex(*stab, data, tsize, GFP_KERNEL);
+ stab = kmalloc_flex(*stab, data, tsize);
if (!stab)
return ERR_PTR(-ENOMEM);
diff --git a/net/sched/sch_netem.c b/net/sched/sch_netem.c
index 334d2f93ae89..5de1c932944a 100644
--- a/net/sched/sch_netem.c
+++ b/net/sched/sch_netem.c
@@ -814,7 +814,7 @@ static int get_dist_table(struct disttable **tbl, const struct nlattr *attr)
if (!n || n > NETEM_DIST_MAX)
return -EINVAL;
- d = kvmalloc_flex(*d, table, n, GFP_KERNEL);
+ d = kvmalloc_flex(*d, table, n);
if (!d)
return -ENOMEM;
diff --git a/net/sunrpc/svcsock.c b/net/sunrpc/svcsock.c
index e1576c807e07..d7845650f0a0 100644
--- a/net/sunrpc/svcsock.c
+++ b/net/sunrpc/svcsock.c
@@ -1436,7 +1436,7 @@ static struct svc_sock *svc_setup_socket(struct svc_serv *serv,
return ERR_PTR(sendpages);
pages = svc_serv_maxpages(serv);
- svsk = kzalloc_flex(*svsk, sk_pages, pages, GFP_KERNEL);
+ svsk = kzalloc_flex(*svsk, sk_pages, pages);
if (!svsk)
return ERR_PTR(-ENOMEM);
diff --git a/net/sunrpc/xprtrdma/svc_rdma_pcl.c b/net/sunrpc/xprtrdma/svc_rdma_pcl.c
index b7c09a1f1c62..1f8f7dad8b6f 100644
--- a/net/sunrpc/xprtrdma/svc_rdma_pcl.c
+++ b/net/sunrpc/xprtrdma/svc_rdma_pcl.c
@@ -29,7 +29,7 @@ static struct svc_rdma_chunk *pcl_alloc_chunk(u32 segcount, u32 position)
{
struct svc_rdma_chunk *chunk;
- chunk = kmalloc_flex(*chunk, ch_segments, segcount, GFP_KERNEL);
+ chunk = kmalloc_flex(*chunk, ch_segments, segcount);
if (!chunk)
return NULL;
diff --git a/net/wireless/nl80211.c b/net/wireless/nl80211.c
index e25a15b9267d..814992861b4f 100644
--- a/net/wireless/nl80211.c
+++ b/net/wireless/nl80211.c
@@ -5333,7 +5333,7 @@ static struct cfg80211_acl_data *parse_acl_data(struct wiphy *wiphy,
if (n_entries > wiphy->max_acl_mac_addrs)
return ERR_PTR(-EOPNOTSUPP);
- acl = kzalloc_flex(*acl, mac_addrs, n_entries, GFP_KERNEL);
+ acl = kzalloc_flex(*acl, mac_addrs, n_entries);
if (!acl)
return ERR_PTR(-ENOMEM);
acl->n_acl_entries = n_entries;
@@ -6113,7 +6113,7 @@ nl80211_parse_mbssid_elems(struct wiphy *wiphy, struct nlattr *attrs)
num_elems++;
}
- elems = kzalloc_flex(*elems, elem, num_elems, GFP_KERNEL);
+ elems = kzalloc_flex(*elems, elem, num_elems);
if (!elems)
return ERR_PTR(-ENOMEM);
elems->cnt = num_elems;
@@ -6145,7 +6145,7 @@ nl80211_parse_rnr_elems(struct wiphy *wiphy, struct nlattr *attrs,
num_elems++;
}
- elems = kzalloc_flex(*elems, elem, num_elems, GFP_KERNEL);
+ elems = kzalloc_flex(*elems, elem, num_elems);
if (!elems)
return ERR_PTR(-ENOMEM);
elems->cnt = num_elems;
@@ -10157,7 +10157,7 @@ static int nl80211_set_reg(struct sk_buff *skb, struct genl_info *info)
goto out;
}
- rd = kzalloc_flex(*rd, reg_rules, num_rules, GFP_KERNEL);
+ rd = kzalloc_flex(*rd, reg_rules, num_rules);
if (!rd) {
r = -ENOMEM;
goto out;
@@ -15378,7 +15378,7 @@ static int nl80211_set_coalesce(struct sk_buff *skb, struct genl_info *info)
if (n_rules > coalesce->n_rules)
return -EINVAL;
- new_coalesce = kzalloc_flex(*new_coalesce, rules, n_rules, GFP_KERNEL);
+ new_coalesce = kzalloc_flex(*new_coalesce, rules, n_rules);
if (!new_coalesce)
return -ENOMEM;
@@ -17462,7 +17462,7 @@ static int nl80211_set_tid_config(struct sk_buff *skb,
rem_conf)
num_conf++;
- tid_config = kzalloc_flex(*tid_config, tid_conf, num_conf, GFP_KERNEL);
+ tid_config = kzalloc_flex(*tid_config, tid_conf, num_conf);
if (!tid_config)
return -ENOMEM;
@@ -18256,7 +18256,7 @@ static int nl80211_set_sar_specs(struct sk_buff *skb, struct genl_info *info)
if (specs > rdev->wiphy.sar_capa->num_freq_ranges)
return -EINVAL;
- sar_spec = kzalloc_flex(*sar_spec, sub_specs, specs, GFP_KERNEL);
+ sar_spec = kzalloc_flex(*sar_spec, sub_specs, specs);
if (!sar_spec)
return -ENOMEM;
diff --git a/net/wireless/pmsr.c b/net/wireless/pmsr.c
index 41aa8636a243..44bd88c9ea66 100644
--- a/net/wireless/pmsr.c
+++ b/net/wireless/pmsr.c
@@ -312,7 +312,7 @@ int nl80211_pmsr_start(struct sk_buff *skb, struct genl_info *info)
}
}
- req = kzalloc_flex(*req, peers, count, GFP_KERNEL);
+ req = kzalloc_flex(*req, peers, count);
if (!req)
return -ENOMEM;
req->n_peers = count;
diff --git a/net/wireless/reg.c b/net/wireless/reg.c
index 4d7479ffda36..1c5c38d18feb 100644
--- a/net/wireless/reg.c
+++ b/net/wireless/reg.c
@@ -452,7 +452,7 @@ reg_copy_regd(const struct ieee80211_regdomain *src_regd)
struct ieee80211_regdomain *regd;
unsigned int i;
- regd = kzalloc_flex(*regd, reg_rules, src_regd->n_reg_rules, GFP_KERNEL);
+ regd = kzalloc_flex(*regd, reg_rules, src_regd->n_reg_rules);
if (!regd)
return ERR_PTR(-ENOMEM);
@@ -932,7 +932,7 @@ static int regdb_query_country(const struct fwdb_header *db,
struct ieee80211_regdomain *regdom;
unsigned int i;
- regdom = kzalloc_flex(*regdom, reg_rules, coll->n_rules, GFP_KERNEL);
+ regdom = kzalloc_flex(*regdom, reg_rules, coll->n_rules);
if (!regdom)
return -ENOMEM;
@@ -1530,7 +1530,7 @@ regdom_intersect(const struct ieee80211_regdomain *rd1,
if (!num_rules)
return NULL;
- rd = kzalloc_flex(*rd, reg_rules, num_rules, GFP_KERNEL);
+ rd = kzalloc_flex(*rd, reg_rules, num_rules);
if (!rd)
return NULL;
diff --git a/net/wireless/scan.c b/net/wireless/scan.c
index 89174a9049a3..328af43ef832 100644
--- a/net/wireless/scan.c
+++ b/net/wireless/scan.c
@@ -1085,7 +1085,7 @@ int cfg80211_scan(struct cfg80211_registered_device *rdev)
if (!n_channels)
return cfg80211_scan_6ghz(rdev, true);
- request = kzalloc_flex(*request, req.channels, n_channels, GFP_KERNEL);
+ request = kzalloc_flex(*request, req.channels, n_channels);
if (!request)
return -ENOMEM;
diff --git a/net/xdp/xsk_buff_pool.c b/net/xdp/xsk_buff_pool.c
index c5015802f946..e8a62743e3db 100644
--- a/net/xdp/xsk_buff_pool.c
+++ b/net/xdp/xsk_buff_pool.c
@@ -59,7 +59,7 @@ struct xsk_buff_pool *xp_create_and_assign_umem(struct xdp_sock *xs,
u32 i, entries;
entries = unaligned ? umem->chunks : 0;
- pool = kvzalloc_flex(*pool, free_heads, entries, GFP_KERNEL);
+ pool = kvzalloc_flex(*pool, free_heads, entries);
if (!pool)
goto out;