Lines Matching defs:rtm

5009 	struct rtmsg *rtm;
5014 err = nlmsg_parse_deprecated(nlh, sizeof(*rtm), tb, RTA_MAX,
5020 rtm = nlmsg_data(nlh);
5022 if (rtm->rtm_tos) {
5029 .fc_table = rtm->rtm_table,
5030 .fc_dst_len = rtm->rtm_dst_len,
5031 .fc_src_len = rtm->rtm_src_len,
5033 .fc_protocol = rtm->rtm_protocol,
5034 .fc_type = rtm->rtm_type,
5041 if (rtm->rtm_type == RTN_UNREACHABLE ||
5042 rtm->rtm_type == RTN_BLACKHOLE ||
5043 rtm->rtm_type == RTN_PROHIBIT ||
5044 rtm->rtm_type == RTN_THROW)
5047 if (rtm->rtm_type == RTN_LOCAL)
5050 if (rtm->rtm_flags & RTM_F_CLONED)
5053 cfg->fc_flags |= (rtm->rtm_flags & RTNH_F_ONLINK);
5075 int plen = (rtm->rtm_dst_len + 7) >> 3;
5084 int plen = (rtm->rtm_src_len + 7) >> 3;
5616 struct rtmsg *rtm;
5619 nlh = nlmsg_put(skb, portid, seq, type, sizeof(*rtm), flags);
5633 rtm = nlmsg_data(nlh);
5634 rtm->rtm_family = AF_INET6;
5635 rtm->rtm_dst_len = rt6_dst->plen;
5636 rtm->rtm_src_len = rt6_src->plen;
5637 rtm->rtm_tos = 0;
5642 rtm->rtm_table = table < 256 ? table : RT_TABLE_COMPAT;
5646 rtm->rtm_type = rt->fib6_type;
5647 rtm->rtm_flags = 0;
5648 rtm->rtm_scope = RT_SCOPE_UNIVERSE;
5649 rtm->rtm_protocol = rt->fib6_protocol;
5652 rtm->rtm_flags |= RTM_F_CLONED;
5657 rtm->rtm_dst_len = 128;
5658 } else if (rtm->rtm_dst_len)
5665 rtm->rtm_src_len = 128;
5666 } else if (rtm->rtm_src_len &&
5673 int err = ip6mr_get_route(net, skb, rtm, portid);
5745 rtm->rtm_type = RTN_BLACKHOLE;
5751 rtm->rtm_flags |= nh_flags;
5757 rtm->rtm_flags |= nh_flags;
5767 rtm->rtm_flags |= RTM_F_OFFLOAD;
5769 rtm->rtm_flags |= RTM_F_TRAP;
5771 rtm->rtm_flags |= RTM_F_OFFLOAD_FAILED;
5958 struct rtmsg *rtm;
5961 if (nlh->nlmsg_len < nlmsg_msg_size(sizeof(*rtm))) {
5968 return nlmsg_parse_deprecated(nlh, sizeof(*rtm), tb, RTA_MAX,
5971 rtm = nlmsg_data(nlh);
5972 if ((rtm->rtm_src_len && rtm->rtm_src_len != 128) ||
5973 (rtm->rtm_dst_len && rtm->rtm_dst_len != 128) ||
5974 rtm->rtm_table || rtm->rtm_protocol || rtm->rtm_scope ||
5975 rtm->rtm_type) {
5979 if (rtm->rtm_flags & ~RTM_F_FIB_MATCH) {
5985 err = nlmsg_parse_deprecated_strict(nlh, sizeof(*rtm), tb, RTA_MAX,
5990 if ((tb[RTA_SRC] && !rtm->rtm_src_len) ||
5991 (tb[RTA_DST] && !rtm->rtm_dst_len)) {
6030 struct rtmsg *rtm;
6039 rtm = nlmsg_data(nlh);
6040 fl6.flowlabel = ip6_make_flowinfo(rtm->rtm_tos, 0);
6041 fibmatch = !!(rtm->rtm_flags & RTM_F_FIB_MATCH);