Lines Matching defs:rtm

1812 	struct rtmsg *rtm;
1817 err = nlmsg_parse_deprecated(nlh, sizeof(*rtm), tb, RTA_MAX,
1823 rtm = nlmsg_data(nlh);
1825 if (rtm->rtm_family != AF_MPLS) {
1829 if (rtm->rtm_dst_len != 20) {
1833 if (rtm->rtm_src_len != 0) {
1837 if (rtm->rtm_tos != 0) {
1841 if (rtm->rtm_table != RT_TABLE_MAIN) {
1852 if (rtm->rtm_scope != RT_SCOPE_UNIVERSE) {
1857 if (rtm->rtm_type != RTN_UNICAST) {
1862 if (rtm->rtm_flags != 0) {
1868 cfg->rc_protocol = rtm->rtm_protocol;
1994 struct rtmsg *rtm;
1996 nlh = nlmsg_put(skb, portid, seq, event, sizeof(*rtm), flags);
2000 rtm = nlmsg_data(nlh);
2001 rtm->rtm_family = AF_MPLS;
2002 rtm->rtm_dst_len = 20;
2003 rtm->rtm_src_len = 0;
2004 rtm->rtm_tos = 0;
2005 rtm->rtm_table = RT_TABLE_MAIN;
2006 rtm->rtm_protocol = rt->rt_protocol;
2007 rtm->rtm_scope = RT_SCOPE_UNIVERSE;
2008 rtm->rtm_type = RTN_UNICAST;
2009 rtm->rtm_flags = 0;
2037 rtm->rtm_flags |= RTNH_F_LINKDOWN;
2039 rtm->rtm_flags |= RTNH_F_DEAD;
2084 rtm->rtm_flags |= RTNH_F_LINKDOWN;
2086 rtm->rtm_flags |= RTNH_F_DEAD;
2113 struct rtmsg *rtm;
2116 if (nlh->nlmsg_len < nlmsg_msg_size(sizeof(*rtm))) {
2121 rtm = nlmsg_data(nlh);
2122 if (rtm->rtm_dst_len || rtm->rtm_src_len || rtm->rtm_tos ||
2123 rtm->rtm_table || rtm->rtm_scope || rtm->rtm_type ||
2124 rtm->rtm_flags) {
2129 if (rtm->rtm_protocol) {
2130 filter->protocol = rtm->rtm_protocol;
2135 err = nlmsg_parse_deprecated_strict(nlh, sizeof(*rtm), tb, RTA_MAX,
2307 struct rtmsg *rtm;
2310 if (nlh->nlmsg_len < nlmsg_msg_size(sizeof(*rtm))) {
2317 return nlmsg_parse_deprecated(nlh, sizeof(*rtm), tb, RTA_MAX,
2320 rtm = nlmsg_data(nlh);
2321 if ((rtm->rtm_dst_len && rtm->rtm_dst_len != 20) ||
2322 rtm->rtm_src_len || rtm->rtm_tos || rtm->rtm_table ||
2323 rtm->rtm_protocol || rtm->rtm_scope || rtm->rtm_type) {
2327 if (rtm->rtm_flags & ~RTM_F_FIB_MATCH) {
2333 err = nlmsg_parse_deprecated_strict(nlh, sizeof(*rtm), tb, RTA_MAX,
2338 if ((tb[RTA_DST] || tb[RTA_NEWDST]) && !rtm->rtm_dst_len) {
2373 struct rtmsg *rtm, *r;
2383 rtm = nlmsg_data(in_nlh);
2406 if (rtm->rtm_flags & RTM_F_FIB_MATCH) {