Searched refs:rule4 (Results 1 - 1 of 1) sorted by relevance

/linux-4.1.27/net/ipv4/
H A Dfib_rules.c172 struct fib4_rule *rule4 = (struct fib4_rule *) rule; fib4_rule_configure() local
197 rule4->src = nla_get_in_addr(tb[FRA_SRC]); fib4_rule_configure()
200 rule4->dst = nla_get_in_addr(tb[FRA_DST]); fib4_rule_configure()
204 rule4->tclassid = nla_get_u32(tb[FRA_FLOW]); fib4_rule_configure()
205 if (rule4->tclassid) fib4_rule_configure()
210 rule4->src_len = frh->src_len; fib4_rule_configure()
211 rule4->srcmask = inet_make_mask(rule4->src_len); fib4_rule_configure()
212 rule4->dst_len = frh->dst_len; fib4_rule_configure()
213 rule4->dstmask = inet_make_mask(rule4->dst_len); fib4_rule_configure()
214 rule4->tos = frh->tos; fib4_rule_configure()
247 struct fib4_rule *rule4 = (struct fib4_rule *) rule; fib4_rule_compare() local
249 if (frh->src_len && (rule4->src_len != frh->src_len)) fib4_rule_compare()
252 if (frh->dst_len && (rule4->dst_len != frh->dst_len)) fib4_rule_compare()
255 if (frh->tos && (rule4->tos != frh->tos)) fib4_rule_compare()
259 if (tb[FRA_FLOW] && (rule4->tclassid != nla_get_u32(tb[FRA_FLOW]))) fib4_rule_compare()
263 if (frh->src_len && (rule4->src != nla_get_in_addr(tb[FRA_SRC]))) fib4_rule_compare()
266 if (frh->dst_len && (rule4->dst != nla_get_in_addr(tb[FRA_DST]))) fib4_rule_compare()
275 struct fib4_rule *rule4 = (struct fib4_rule *) rule; fib4_rule_fill() local
277 frh->dst_len = rule4->dst_len; fib4_rule_fill()
278 frh->src_len = rule4->src_len; fib4_rule_fill()
279 frh->tos = rule4->tos; fib4_rule_fill()
281 if ((rule4->dst_len && fib4_rule_fill()
282 nla_put_in_addr(skb, FRA_DST, rule4->dst)) || fib4_rule_fill()
283 (rule4->src_len && fib4_rule_fill()
284 nla_put_in_addr(skb, FRA_SRC, rule4->src))) fib4_rule_fill()
287 if (rule4->tclassid && fib4_rule_fill()
288 nla_put_u32(skb, FRA_FLOW, rule4->tclassid)) fib4_rule_fill()

Completed in 76 milliseconds