Home
last modified time | relevance | path

Searched refs:maxtype (Results 1 – 25 of 50) sorted by relevance

12

/linux-6.12.1/drivers/block/drbd/
Ddrbd_nla.c7 static int drbd_nla_check_mandatory(int maxtype, struct nlattr *nla) in drbd_nla_check_mandatory() argument
24 if (nla_type(nla) > maxtype) in drbd_nla_check_mandatory()
31 int drbd_nla_parse_nested(struct nlattr *tb[], int maxtype, struct nlattr *nla, in drbd_nla_parse_nested() argument
36 err = drbd_nla_check_mandatory(maxtype, nla); in drbd_nla_parse_nested()
38 err = nla_parse_nested_deprecated(tb, maxtype, nla, policy, in drbd_nla_parse_nested()
44 struct nlattr *drbd_nla_find_nested(int maxtype, struct nlattr *nla, int attrtype) in drbd_nla_find_nested() argument
52 err = drbd_nla_check_mandatory(maxtype, nla); in drbd_nla_find_nested()
Ddrbd_nla.h5 extern int drbd_nla_parse_nested(struct nlattr *tb[], int maxtype, struct nlattr *nla,
7 extern struct nlattr *drbd_nla_find_nested(int maxtype, struct nlattr *nla, int attrtype);
/linux-6.12.1/net/netlink/
Dpolicy.c23 unsigned int maxtype; member
29 unsigned int maxtype) in add_policy() argument
34 if (!policy || !maxtype) in add_policy()
39 state->policies[i].maxtype == maxtype) in add_policy()
44 state->policies[i].maxtype = maxtype; in add_policy()
61 state->policies[old_n_alloc].maxtype = maxtype; in add_policy()
84 unsigned int maxtype) in netlink_policy_dump_get_policy_idx() argument
88 if (WARN_ON(!policy || !maxtype)) in netlink_policy_dump_get_policy_idx()
93 state->policies[i].maxtype == maxtype) in netlink_policy_dump_get_policy_idx()
129 unsigned int maxtype) in netlink_policy_dump_add_policy() argument
[all …]
/linux-6.12.1/tools/lib/bpf/
Dnlattr.c45 static int validate_nla(struct nlattr *nla, int maxtype, in validate_nla() argument
52 if (type < 0 || type > maxtype) in validate_nla()
104 int libbpf_nla_parse(struct nlattr *tb[], int maxtype, struct nlattr *head, in libbpf_nla_parse() argument
110 memset(tb, 0, sizeof(struct nlattr *) * (maxtype + 1)); in libbpf_nla_parse()
115 if (type > maxtype) in libbpf_nla_parse()
119 err = validate_nla(nla, maxtype, policy); in libbpf_nla_parse()
149 int libbpf_nla_parse_nested(struct nlattr *tb[], int maxtype, in libbpf_nla_parse_nested() argument
153 return libbpf_nla_parse(tb, maxtype, libbpf_nla_data(nla), in libbpf_nla_parse_nested()
Dnlattr.h123 int libbpf_nla_parse(struct nlattr *tb[], int maxtype, struct nlattr *head,
125 int libbpf_nla_parse_nested(struct nlattr *tb[], int maxtype,
/linux-6.12.1/include/net/
Dnetlink.h529 int __nla_validate(const struct nlattr *head, int len, int maxtype,
532 int __nla_parse(struct nlattr **tb, int maxtype, const struct nlattr *head,
678 static inline int nla_parse(struct nlattr **tb, int maxtype, in nla_parse() argument
683 return __nla_parse(tb, maxtype, head, len, policy, in nla_parse()
703 static inline int nla_parse_deprecated(struct nlattr **tb, int maxtype, in nla_parse_deprecated() argument
708 return __nla_parse(tb, maxtype, head, len, policy, in nla_parse_deprecated()
728 static inline int nla_parse_deprecated_strict(struct nlattr **tb, int maxtype, in nla_parse_deprecated_strict() argument
734 return __nla_parse(tb, maxtype, head, len, policy, in nla_parse_deprecated_strict()
751 struct nlattr *tb[], int maxtype, in __nlmsg_parse() argument
761 return __nla_parse(tb, maxtype, nlmsg_attrdata(nlh, hdrlen), in __nlmsg_parse()
[all …]
Dgenetlink.h385 struct nlattr *tb[], int maxtype, in genlmsg_parse_deprecated() argument
389 return __nlmsg_parse(nlh, family->hdrsize + GENL_HDRLEN, tb, maxtype, in genlmsg_parse_deprecated()
404 struct nlattr *tb[], int maxtype, in genlmsg_parse() argument
408 return __nlmsg_parse(nlh, family->hdrsize + GENL_HDRLEN, tb, maxtype, in genlmsg_parse()
Drtnetlink.h110 unsigned int maxtype; member
/linux-6.12.1/arch/x86/kernel/cpu/
Dtopology_ext.c48 unsigned int dom, maxtype; in topo_subleaf() local
67 case 0x0b: maxtype = MAX_TYPE_0B; map = topo_domain_map_0b_1f; break; in topo_subleaf()
68 case 0x1f: maxtype = MAX_TYPE_1F; map = topo_domain_map_0b_1f; break; in topo_subleaf()
69 case 0x80000026: maxtype = MAX_TYPE_80000026; map = topo_domain_map_80000026; break; in topo_subleaf()
78 if (sl.type >= maxtype) { in topo_subleaf()
/linux-6.12.1/lib/
Dnlattr.c60 static int __nla_validate_parse(const struct nlattr *head, int len, int maxtype,
89 static int nla_validate_array(const struct nlattr *head, int len, int maxtype, in nla_validate_array() argument
110 maxtype, policy, validate, extack, in nla_validate_array()
393 static int validate_nla(const struct nlattr *nla, int maxtype, in validate_nla() argument
405 if (type <= 0 || type > maxtype) in validate_nla()
408 type = array_index_nospec(type, maxtype + 1); in validate_nla()
604 static int __nla_validate_parse(const struct nlattr *head, int len, int maxtype, in __nla_validate_parse() argument
620 memset(tb, 0, sizeof(struct nlattr *) * (maxtype + 1)); in __nla_validate_parse()
625 if (type == 0 || type > maxtype) { in __nla_validate_parse()
633 type = array_index_nospec(type, maxtype + 1); in __nla_validate_parse()
[all …]
/linux-6.12.1/drivers/net/ethernet/rocker/
Drocker_tlv.h109 void rocker_tlv_parse(const struct rocker_tlv **tb, int maxtype,
113 int maxtype, in rocker_tlv_parse_nested() argument
116 rocker_tlv_parse(tb, maxtype, rocker_tlv_data(tlv), in rocker_tlv_parse_nested()
121 rocker_tlv_parse_desc(const struct rocker_tlv **tb, int maxtype, in rocker_tlv_parse_desc() argument
124 rocker_tlv_parse(tb, maxtype, desc_info->data, in rocker_tlv_parse_desc()
Drocker_tlv.c15 void rocker_tlv_parse(const struct rocker_tlv **tb, int maxtype, in rocker_tlv_parse() argument
22 memset(tb, 0, sizeof(struct rocker_tlv *) * (maxtype + 1)); in rocker_tlv_parse()
27 if (type > 0 && type <= maxtype) in rocker_tlv_parse()
/linux-6.12.1/net/xfrm/
Dxfrm_compat.c361 int maxtype) in xfrm_user_rcv_calculate_len64() argument
389 if (WARN_ON_ONCE(maxtype)) in xfrm_user_rcv_calculate_len64()
471 size_t size, u8 type, int maxtype, in xfrm_xlate32() argument
552 if (maxtype) { in xfrm_xlate32()
556 for (i = 1; i <= maxtype; i++) { in xfrm_xlate32()
589 int maxtype, const struct nla_policy *policy, in xfrm_user_rcv_msg_compat() argument
611 maxtype ? : XFRMA_MAX, policy ? : compat_policy, extack); in xfrm_user_rcv_msg_compat()
615 len = xfrm_user_rcv_calculate_len64(h32, attrs, maxtype); in xfrm_user_rcv_msg_compat()
625 err = xfrm_xlate32(h64, h32, attrs, len, type, maxtype, extack); in xfrm_user_rcv_msg_compat()
/linux-6.12.1/net/dsa/
Dnetlink.c58 .maxtype = IFLA_DSA_MAX,
/linux-6.12.1/drivers/infiniband/ulp/ipoib/
Dipoib_netlink.c171 .maxtype = IFLA_IPOIB_MAX,
/linux-6.12.1/include/linux/
Dgenl_magic_func.h143 const int maxtype = ARRAY_SIZE(s_name ## _nl_policy)-1; \
152 err = drbd_nla_parse_nested(ntb, maxtype, tla, s_name ## _nl_policy); \
/linux-6.12.1/drivers/net/can/
Dvxcan.c305 .maxtype = VXCAN_INFO_MAX,
/linux-6.12.1/net/8021q/
Dvlan_netlink.c291 .maxtype = IFLA_VLAN_MAX,
/linux-6.12.1/net/sched/
Dsch_netem.c946 static int parse_attr(struct nlattr *tb[], int maxtype, struct nlattr *nla, in parse_attr() argument
957 return nla_parse_deprecated(tb, maxtype, in parse_attr()
961 memset(tb, 0, sizeof(struct nlattr *) * (maxtype + 1)); in parse_attr()
/linux-6.12.1/drivers/net/ethernet/qualcomm/rmnet/
Drmnet_config.c399 .maxtype = IFLA_RMNET_MAX,
/linux-6.12.1/net/ipv4/
Dip_gre.c1647 .maxtype = IFLA_GRE_MAX,
1662 .maxtype = IFLA_GRE_MAX,
1677 .maxtype = IFLA_GRE_MAX,
Dipip.c572 .maxtype = IFLA_IPTUN_MAX,
/linux-6.12.1/net/caif/
Dchnl_net.c500 .maxtype = IFLA_CAIF_MAX,
/linux-6.12.1/net/hsr/
Dhsr_netlink.c181 .maxtype = IFLA_HSR_MAX,
/linux-6.12.1/drivers/net/can/dev/
Dnetlink.c641 .maxtype = IFLA_CAN_MAX,

12