Lines Matching refs:rule6
346 struct fib6_rule *rule6 = (struct fib6_rule *) rule; in fib6_rule_configure() local
361 rule6->src.addr = nla_get_in6_addr(tb[FRA_SRC]); in fib6_rule_configure()
364 rule6->dst.addr = nla_get_in6_addr(tb[FRA_DST]); in fib6_rule_configure()
366 rule6->src.plen = frh->src_len; in fib6_rule_configure()
367 rule6->dst.plen = frh->dst_len; in fib6_rule_configure()
368 rule6->tclass = frh->tos; in fib6_rule_configure()
393 struct fib6_rule *rule6 = (struct fib6_rule *) rule; in fib6_rule_compare() local
395 if (frh->src_len && (rule6->src.plen != frh->src_len)) in fib6_rule_compare()
398 if (frh->dst_len && (rule6->dst.plen != frh->dst_len)) in fib6_rule_compare()
401 if (frh->tos && (rule6->tclass != frh->tos)) in fib6_rule_compare()
405 nla_memcmp(tb[FRA_SRC], &rule6->src.addr, sizeof(struct in6_addr))) in fib6_rule_compare()
409 nla_memcmp(tb[FRA_DST], &rule6->dst.addr, sizeof(struct in6_addr))) in fib6_rule_compare()
418 struct fib6_rule *rule6 = (struct fib6_rule *) rule; in fib6_rule_fill() local
420 frh->dst_len = rule6->dst.plen; in fib6_rule_fill()
421 frh->src_len = rule6->src.plen; in fib6_rule_fill()
422 frh->tos = rule6->tclass; in fib6_rule_fill()
424 if ((rule6->dst.plen && in fib6_rule_fill()
425 nla_put_in6_addr(skb, FRA_DST, &rule6->dst.addr)) || in fib6_rule_fill()
426 (rule6->src.plen && in fib6_rule_fill()
427 nla_put_in6_addr(skb, FRA_SRC, &rule6->src.addr))) in fib6_rule_fill()