Lines Matching refs:policy
163 * Standard attribute types to specify validation policy
211 * struct nla_policy - attribute validation policy
231 * number in the nested policy.
250 * NLA_NESTED `nested_policy' to a nested policy to validate, must
255 * NLA_NESTED_ARRAY `nested_policy' points to a nested policy to validate,
330 * only, and specifies special data about the policy, namely it
338 * of this is that types not specified in the policy will be
344 * the enum used by the policy, and be set to the new value that
367 #define _NLA_POLICY_NESTED(maxattr, policy) \
368 { .type = NLA_NESTED, .nested_policy = policy, .len = maxattr }
369 #define _NLA_POLICY_NESTED_ARRAY(maxattr, policy) \
370 { .type = NLA_NESTED_ARRAY, .nested_policy = policy, .len = maxattr }
371 #define NLA_POLICY_NESTED(policy) \
372 _NLA_POLICY_NESTED(ARRAY_SIZE(policy) - 1, policy)
373 #define NLA_POLICY_NESTED_ARRAY(policy) \
374 _NLA_POLICY_NESTED_ARRAY(ARRAY_SIZE(policy) - 1, policy)
481 * @NL_VALIDATE_UNSPEC: Reject attributes with NLA_UNSPEC in the policy.
482 * This can safely be set by the kernel when the given policy has no
483 * NLA_UNSPEC anymore, and can thus be used to ensure policy entries
485 * @NL_VALIDATE_STRICT_ATTRS: strict attribute policy parsing (e.g.
514 const struct nla_policy *policy, unsigned int validate,
517 int len, const struct nla_policy *policy, unsigned int validate,
652 * @policy: validation policy
657 * exceeding maxtype will be rejected, policy must be specified, attributes
664 const struct nla_policy *policy,
667 return __nla_parse(tb, maxtype, head, len, policy,
677 * @policy: validation policy
682 * exceeding maxtype will be ignored and attributes from the policy are not
689 const struct nla_policy *policy,
692 return __nla_parse(tb, maxtype, head, len, policy,
702 * @policy: validation policy
708 * policy is not completely strictly validated (only for new attributes).
715 const struct nla_policy *policy,
718 return __nla_parse(tb, maxtype, head, len, policy,
728 * @policy: validation policy
736 const struct nla_policy *policy,
746 nlmsg_attrlen(nlh, hdrlen), policy, validate,
756 * @policy: validation policy
763 const struct nla_policy *policy,
766 return __nlmsg_parse(nlh, hdrlen, tb, maxtype, policy,
776 * @policy: validation policy
783 const struct nla_policy *policy,
786 return __nlmsg_parse(nlh, hdrlen, tb, maxtype, policy,
796 * @policy: validation policy
804 const struct nla_policy *policy,
807 return __nlmsg_parse(nlh, hdrlen, tb, maxtype, policy,
831 * @policy: validation policy
835 * specified policy. Validation is done in liberal mode.
842 const struct nla_policy *policy,
845 return __nla_validate(head, len, maxtype, policy, NL_VALIDATE_LIBERAL,
854 * @policy: validation policy
858 * specified policy. Validation is done in strict mode.
864 const struct nla_policy *policy,
867 return __nla_validate(head, len, maxtype, policy, NL_VALIDATE_STRICT,
876 * @policy: validation policy
881 const struct nla_policy *policy,
889 policy, NL_VALIDATE_LIBERAL, extack);
1243 * @policy: validation policy
1250 const struct nla_policy *policy,
1258 return __nla_parse(tb, maxtype, nla_data(nla), nla_len(nla), policy,
1267 * @policy: validation policy
1274 const struct nla_policy *policy,
1277 return __nla_parse(tb, maxtype, nla_data(nla), nla_len(nla), policy,
1867 * @policy: validation policy
1872 * specified policy. Attributes with a type exceeding maxtype will be
1878 const struct nla_policy *policy,
1882 return __nla_validate(nla_data(start), nla_len(start), maxtype, policy,
1888 const struct nla_policy *policy,
1891 return __nla_validate_nested(start, maxtype, policy,
1897 const struct nla_policy *policy,
1900 return __nla_validate_nested(start, maxtype, policy,
1998 const struct nla_policy *policy,
2001 const struct nla_policy *policy,