Lines Matching refs:match

297 			       const struct flow_match_meta *match,
303 if (!match->mask->ingress_ifindex)
306 if (match->mask->ingress_ifindex != 0xFFFFFFFF) {
312 match->key->ingress_ifindex);
314 NL_SET_ERR_MSG_MOD(extack, "Can't find specified ingress port to match on");
319 NL_SET_ERR_MSG_MOD(extack, "Can't match on non-mlxsw ingress port");
325 NL_SET_ERR_MSG_MOD(extack, "Can't match on a port from different device");
342 struct flow_match_meta match;
347 flow_rule_match_meta(rule, &match);
350 match.key->l2_miss, match.mask->l2_miss);
352 return mlxsw_sp_flower_parse_meta_iif(rulei, block, &match,
359 struct flow_match_ipv4_addrs match;
361 flow_rule_match_ipv4_addrs(f->rule, &match);
364 (char *) &match.key->src,
365 (char *) &match.mask->src, 4);
367 (char *) &match.key->dst,
368 (char *) &match.mask->dst, 4);
374 struct flow_match_ipv6_addrs match;
376 flow_rule_match_ipv6_addrs(f->rule, &match);
379 &match.key->src.s6_addr[0x0],
380 &match.mask->src.s6_addr[0x0], 4);
382 &match.key->src.s6_addr[0x4],
383 &match.mask->src.s6_addr[0x4], 4);
385 &match.key->src.s6_addr[0x8],
386 &match.mask->src.s6_addr[0x8], 4);
388 &match.key->src.s6_addr[0xC],
389 &match.mask->src.s6_addr[0xC], 4);
391 &match.key->dst.s6_addr[0x0],
392 &match.mask->dst.s6_addr[0x0], 4);
394 &match.key->dst.s6_addr[0x4],
395 &match.mask->dst.s6_addr[0x4], 4);
397 &match.key->dst.s6_addr[0x8],
398 &match.mask->dst.s6_addr[0x8], 4);
400 &match.key->dst.s6_addr[0xC],
401 &match.mask->dst.s6_addr[0xC], 4);
410 struct flow_match_ports match;
421 flow_rule_match_ports(rule, &match);
423 ntohs(match.key->dst),
424 ntohs(match.mask->dst));
426 ntohs(match.key->src),
427 ntohs(match.mask->src));
437 struct flow_match_ports_range match;
448 flow_rule_match_ports_range(rule, &match);
450 if (match.mask->tp_min.src) {
452 .min = ntohs(match.key->tp_min.src),
453 .max = ntohs(match.key->tp_max.src),
469 if (match.mask->tp_min.dst) {
471 .min = ntohs(match.key->tp_min.dst),
472 .max = ntohs(match.key->tp_max.dst),
499 struct flow_match_tcp match;
510 flow_rule_match_tcp(rule, &match);
512 if (match.mask->flags & htons(0x0E00)) {
513 NL_SET_ERR_MSG_MOD(f->common.extack, "TCP flags match not supported on reserved bits");
514 dev_err(mlxsw_sp->bus_info->dev, "TCP flags match not supported on reserved bits\n");
519 ntohs(match.key->flags),
520 ntohs(match.mask->flags));
530 struct flow_match_ip match;
541 flow_rule_match_ip(rule, &match);
544 match.key->ttl, match.mask->ttl);
547 match.key->tos & 0x3,
548 match.mask->tos & 0x3);
551 match.key->tos >> 2,
552 match.mask->tos >> 2);
563 struct flow_dissector *dissector = rule->match.dissector;
594 struct flow_match_control match;
596 flow_rule_match_control(rule, &match);
597 addr_type = match.key->addr_type;
601 struct flow_match_basic match;
603 flow_rule_match_basic(rule, &match);
604 n_proto_key = ntohs(match.key->n_proto);
605 n_proto_mask = ntohs(match.mask->n_proto);
615 ip_proto = match.key->ip_proto;
618 match.key->ip_proto,
619 match.mask->ip_proto);
623 struct flow_match_eth_addrs match;
625 flow_rule_match_eth_addrs(rule, &match);
628 match.key->dst,
629 match.mask->dst, 2);
632 match.key->dst + 2,
633 match.mask->dst + 2, 4);
636 match.key->src,
637 match.mask->src, 2);
640 match.key->src + 2,
641 match.mask->src + 2, 4);
645 struct flow_match_vlan match;
647 flow_rule_match_vlan(rule, &match);
649 match.mask->vlan_id) {
659 if (match.mask->vlan_id != 0)
662 match.key->vlan_id,
663 match.mask->vlan_id);
664 if (match.mask->vlan_priority != 0)
667 match.key->vlan_priority,
668 match.mask->vlan_priority);