Lines Matching defs:nlh

519 	struct nlmsghdr  *nlh;
523 nlh = nlmsg_put(skb, portid, seq, event, sizeof(struct netconfmsg),
525 if (!nlh)
531 ncm = nlmsg_data(nlh);
559 nlmsg_end(skb, nlh);
563 nlmsg_cancel(skb, nlh);
599 const struct nlmsghdr *nlh,
605 if (nlh->nlmsg_len < nlmsg_msg_size(sizeof(struct netconfmsg))) {
611 return nlmsg_parse_deprecated(nlh, sizeof(struct netconfmsg),
615 err = nlmsg_parse_deprecated_strict(nlh, sizeof(struct netconfmsg),
638 struct nlmsghdr *nlh,
650 err = inet6_netconf_valid_get_req(in_skb, nlh, tb, extack);
684 nlh->nlmsg_seq, RTM_NEWNETCONF, 0,
704 const struct nlmsghdr *nlh = cb->nlh;
716 if (nlh->nlmsg_len < nlmsg_msg_size(sizeof(*ncm))) {
721 if (nlmsg_attrlen(nlh, sizeof(*ncm))) {
746 nlh->nlmsg_seq,
763 nlh->nlmsg_seq,
774 nlh->nlmsg_seq,
4654 inet6_rtm_deladdr(struct sk_buff *skb, struct nlmsghdr *nlh,
4664 err = nlmsg_parse_deprecated(nlh, sizeof(*ifm), tb, IFA_MAX,
4669 ifm = nlmsg_data(nlh);
4838 inet6_rtm_newaddr(struct sk_buff *skb, struct nlmsghdr *nlh,
4851 err = nlmsg_parse_deprecated(nlh, sizeof(*ifm), tb, IFA_MAX,
4858 ifm = nlmsg_data(nlh);
4915 if (nlh->nlmsg_flags & NLM_F_EXCL ||
4916 !(nlh->nlmsg_flags & NLM_F_REPLACE))
4926 static void put_ifaddrmsg(struct nlmsghdr *nlh, u8 prefixlen, u32 flags,
4931 ifm = nlmsg_data(nlh);
4993 struct nlmsghdr *nlh;
4996 nlh = nlmsg_put(skb, args->portid, args->seq, args->event,
4998 if (!nlh)
5001 put_ifaddrmsg(nlh, ifa->prefix_len, ifa->flags, rt_scope(ifa->scope),
5050 nlmsg_end(skb, nlh);
5054 nlmsg_cancel(skb, nlh);
5061 struct nlmsghdr *nlh;
5068 nlh = nlmsg_put(skb, args->portid, args->seq, args->event,
5070 if (!nlh)
5075 nlmsg_cancel(skb, nlh);
5079 put_ifaddrmsg(nlh, 128, IFA_F_PERMANENT, scope, ifindex);
5083 nlmsg_cancel(skb, nlh);
5087 nlmsg_end(skb, nlh);
5096 struct nlmsghdr *nlh;
5102 nlh = nlmsg_put(skb, args->portid, args->seq, args->event,
5104 if (!nlh)
5109 nlmsg_cancel(skb, nlh);
5113 put_ifaddrmsg(nlh, 128, IFA_F_PERMANENT, scope, ifindex);
5117 nlmsg_cancel(skb, nlh);
5121 nlmsg_end(skb, nlh);
5187 static int inet6_valid_dump_ifaddr_req(const struct nlmsghdr *nlh,
5197 if (nlh->nlmsg_len < nlmsg_msg_size(sizeof(*ifm))) {
5202 ifm = nlmsg_data(nlh);
5214 err = nlmsg_parse_deprecated_strict(nlh, sizeof(*ifm), tb, IFA_MAX,
5246 const struct nlmsghdr *nlh = cb->nlh;
5249 .seq = cb->nlh->nlmsg_seq,
5268 err = inet6_valid_dump_ifaddr_req(nlh, &fillargs, &tgt_net,
5346 const struct nlmsghdr *nlh,
5353 if (nlh->nlmsg_len < nlmsg_msg_size(sizeof(*ifm))) {
5359 return nlmsg_parse_deprecated(nlh, sizeof(*ifm), tb, IFA_MAX,
5362 ifm = nlmsg_data(nlh);
5368 err = nlmsg_parse_deprecated_strict(nlh, sizeof(*ifm), tb, IFA_MAX,
5391 static int inet6_rtm_getaddr(struct sk_buff *in_skb, struct nlmsghdr *nlh,
5397 .seq = nlh->nlmsg_seq,
5411 err = inet6_rtm_valid_getaddr_req(in_skb, nlh, tb, extack);
5429 ifm = nlmsg_data(nlh);
5874 struct nlmsghdr *nlh;
5877 nlh = nlmsg_put(skb, portid, seq, event, sizeof(*hdr), flags);
5878 if (!nlh)
5881 hdr = nlmsg_data(nlh);
5906 nlmsg_end(skb, nlh);
5910 nlmsg_cancel(skb, nlh);
5914 static int inet6_valid_dump_ifinfo(const struct nlmsghdr *nlh,
5919 if (nlh->nlmsg_len < nlmsg_msg_size(sizeof(*ifm))) {
5924 if (nlmsg_attrlen(nlh, sizeof(*ifm))) {
5929 ifm = nlmsg_data(nlh);
5952 int err = inet6_valid_dump_ifinfo(cb->nlh, cb->extack);
5973 cb->nlh->nlmsg_seq,
6024 struct nlmsghdr *nlh;
6027 nlh = nlmsg_put(skb, portid, seq, event, sizeof(*pmsg), flags);
6028 if (!nlh)
6031 pmsg = nlmsg_data(nlh);
6047 nlmsg_end(skb, nlh);
6051 nlmsg_cancel(skb, nlh);