From patchwork Tue Mar 26 16:32:07 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jacob Tanenbaum X-Patchwork-Id: 1916279 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@legolas.ozlabs.org Authentication-Results: legolas.ozlabs.org; dkim=fail reason="signature verification failed" (1024-bit key; unprotected) header.d=redhat.com header.i=@redhat.com header.a=rsa-sha256 header.s=mimecast20190719 header.b=FXFfN4j2; dkim-atps=neutral Authentication-Results: legolas.ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=openvswitch.org (client-ip=2605:bc80:3010::136; helo=smtp3.osuosl.org; envelope-from=ovs-dev-bounces@openvswitch.org; receiver=patchwork.ozlabs.org) Received: from smtp3.osuosl.org (smtp3.osuosl.org [IPv6:2605:bc80:3010::136]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (secp384r1) server-digest SHA384) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4V3wLr0Lsnz1yWv for ; Wed, 27 Mar 2024 03:32:19 +1100 (AEDT) Received: from localhost (localhost [127.0.0.1]) by smtp3.osuosl.org (Postfix) with ESMTP id AD95C60AEB; Tue, 26 Mar 2024 16:32:17 +0000 (UTC) X-Virus-Scanned: amavis at osuosl.org Received: from smtp3.osuosl.org ([127.0.0.1]) by localhost (smtp3.osuosl.org [127.0.0.1]) (amavis, port 10024) with ESMTP id 9n_8akb7l5Ym; Tue, 26 Mar 2024 16:32:16 +0000 (UTC) X-Comment: SPF check N/A for local connections - client-ip=140.211.9.56; helo=lists.linuxfoundation.org; envelope-from=ovs-dev-bounces@openvswitch.org; receiver= DKIM-Filter: OpenDKIM Filter v2.11.0 smtp3.osuosl.org 0C9556000A Authentication-Results: smtp3.osuosl.org; dkim=fail reason="signature verification failed" (1024-bit key) header.d=redhat.com header.i=@redhat.com header.a=rsa-sha256 header.s=mimecast20190719 header.b=FXFfN4j2 Received: from lists.linuxfoundation.org (lf-lists.osuosl.org [140.211.9.56]) by smtp3.osuosl.org (Postfix) with ESMTPS id 0C9556000A; Tue, 26 Mar 2024 16:32:16 +0000 (UTC) Received: from lf-lists.osuosl.org (localhost [127.0.0.1]) by lists.linuxfoundation.org (Postfix) with ESMTP id DF855C0072; Tue, 26 Mar 2024 16:32:15 +0000 (UTC) X-Original-To: ovs-dev@openvswitch.org Delivered-To: ovs-dev@lists.linuxfoundation.org Received: from smtp2.osuosl.org (smtp2.osuosl.org [IPv6:2605:bc80:3010::133]) by lists.linuxfoundation.org (Postfix) with ESMTP id 44DB2C0037 for ; Tue, 26 Mar 2024 16:32:15 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by smtp2.osuosl.org (Postfix) with ESMTP id 2BDB640484 for ; Tue, 26 Mar 2024 16:32:15 +0000 (UTC) X-Virus-Scanned: amavis at osuosl.org Received: from smtp2.osuosl.org ([127.0.0.1]) by localhost (smtp2.osuosl.org [127.0.0.1]) (amavis, port 10024) with ESMTP id arhDazN7_KWx for ; Tue, 26 Mar 2024 16:32:13 +0000 (UTC) Received-SPF: Pass (mailfrom) identity=mailfrom; client-ip=170.10.129.124; helo=us-smtp-delivery-124.mimecast.com; envelope-from=jtanenba@redhat.com; receiver= DMARC-Filter: OpenDMARC Filter v1.4.2 smtp2.osuosl.org 827CB403AE Authentication-Results: smtp2.osuosl.org; dmarc=pass (p=none dis=none) header.from=redhat.com DKIM-Filter: OpenDKIM Filter v2.11.0 smtp2.osuosl.org 827CB403AE Authentication-Results: smtp2.osuosl.org; dkim=pass (1024-bit key) header.d=redhat.com header.i=@redhat.com header.a=rsa-sha256 header.s=mimecast20190719 header.b=FXFfN4j2 Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.129.124]) by smtp2.osuosl.org (Postfix) with ESMTPS id 827CB403AE for ; Tue, 26 Mar 2024 16:32:13 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1711470732; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=FoI+scMLZpPReH1Ppc27+ITZXT4StHDwgoavBflnIv0=; b=FXFfN4j2gwYa44IRxvkQKDQwHP6XnqpMkReOQPTbUnz/oXx7ZgnEoIj3tOUIXk9SUawUum XM0pXFb3US6kyYHwMGHCeVV77f3z5ghGsnaxv7cnbSqSendbkzommHhanXFmyCNKRZGOTJ 5JiHR1hVm82ES7wxfqIrPaYPxr1gRCI= Received: from mimecast-mx02.redhat.com (mimecast-mx02.redhat.com [66.187.233.88]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-491-lYLHSPG_NfOAWRygk9rFJQ-1; Tue, 26 Mar 2024 12:32:11 -0400 X-MC-Unique: lYLHSPG_NfOAWRygk9rFJQ-1 Received: from smtp.corp.redhat.com (int-mx01.intmail.prod.int.rdu2.redhat.com [10.11.54.1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id AF34980F7E4 for ; Tue, 26 Mar 2024 16:32:10 +0000 (UTC) Received: from fedora.redhat.com (unknown [10.22.9.162]) by smtp.corp.redhat.com (Postfix) with ESMTP id 8BF9B3C20; Tue, 26 Mar 2024 16:32:10 +0000 (UTC) From: Jacob Tanenbaum To: ovs-dev@openvswitch.org Date: Tue, 26 Mar 2024 12:32:07 -0400 Message-ID: <20240326163208.1425569-1-jtanenba@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 3.4.1 on 10.11.54.1 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Subject: [ovs-dev] [PATCH ovn v2 1/2] Merge QoS logical pipelines. X-BeenThere: ovs-dev@openvswitch.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: ovs-dev-bounces@openvswitch.org Sender: "dev" currently there are 2 QoS pipelines for ingress (ls_in_qos_mark, ls_in_qos_meter) and egress (ls_out_qos_mark, ls_out_qos_meter). This is not necessary as there are no actions across the two pipelines that depend on each other. The two pipelines can be merged. Reported-at: https://issues.redhat.com/browse/FDP-397 Signed-off-by: Jacob Tanenbaum Acked-by: Ales Musil --- v2: addressed formatting from the day-0 bot diff --git a/northd/northd.c b/northd/northd.c index 1839b7d8b..d5aab756f 100644 --- a/northd/northd.c +++ b/northd/northd.c @@ -3484,7 +3484,7 @@ build_lb_vip_actions(const struct ovn_northd_lb *lb, } if (reject) { - int stage = ls_dp ? ovn_stage_get_table(S_SWITCH_OUT_QOS_MARK) + int stage = ls_dp ? ovn_stage_get_table(S_SWITCH_OUT_QOS) : ovn_stage_get_table(S_ROUTER_OUT_SNAT); ds_clear(action); ds_put_format(action, "reg0 = 0; reject { outport <-> inport; " @@ -6705,7 +6705,7 @@ build_acl_action_lflows(const struct ls_stateful_record *ls_stateful_rec, "/* eth.dst <-> eth.src; ip.dst <-> ip.src; is implicit. */ " "outport <-> inport; next(pipeline=%s,table=%d); };", ingress ? "egress" : "ingress", - ingress ? ovn_stage_get_table(S_SWITCH_OUT_QOS_MARK) + ingress ? ovn_stage_get_table(S_SWITCH_OUT_QOS) : ovn_stage_get_table(S_SWITCH_IN_L2_LKUP)); ovn_lflow_metered(lflows, od, stage, 1000, @@ -7081,24 +7081,39 @@ build_qos(struct ovn_datapath *od, struct lflow_table *lflows, struct lflow_ref *lflow_ref) { struct ds action = DS_EMPTY_INITIALIZER; - ovn_lflow_add(lflows, od, S_SWITCH_IN_QOS_MARK, 0, "1", "next;", + ovn_lflow_add(lflows, od, S_SWITCH_IN_QOS, 0, "1", "next;", lflow_ref); - ovn_lflow_add(lflows, od, S_SWITCH_OUT_QOS_MARK, 0, "1", "next;", - lflow_ref); - ovn_lflow_add(lflows, od, S_SWITCH_IN_QOS_METER, 0, "1", "next;", - lflow_ref); - ovn_lflow_add(lflows, od, S_SWITCH_OUT_QOS_METER, 0, "1", "next;", + ovn_lflow_add(lflows, od, S_SWITCH_OUT_QOS, 0, "1", "next;", lflow_ref); for (size_t i = 0; i < od->nbs->n_qos_rules; i++) { struct nbrec_qos *qos = od->nbs->qos_rules[i]; bool ingress = !strcmp(qos->direction, "from-lport") ? true :false; - enum ovn_stage stage = ingress ? S_SWITCH_IN_QOS_MARK : S_SWITCH_OUT_QOS_MARK; + enum ovn_stage stage = ingress ? S_SWITCH_IN_QOS : S_SWITCH_OUT_QOS; static struct vlog_rate_limit rl = VLOG_RATE_LIMIT_INIT(5, 1); int64_t rate = 0; int64_t burst = 0; ds_clear(&action); + for (size_t n = 0; n < qos->n_bandwidth; n++) { + if (!strcmp(qos->key_bandwidth[n], "rate")) { + rate = qos->value_bandwidth[n]; + } else if (!strcmp(qos->key_bandwidth[n], "burst")) { + burst = qos->value_bandwidth[n]; + } + } + if (rate) { + stage = ingress ? S_SWITCH_IN_QOS : S_SWITCH_OUT_QOS; + if (burst) { + ds_put_format(&action, + "set_meter(%"PRId64", %"PRId64"); ", + rate, burst); + } else { + ds_put_format(&action, + "set_meter(%"PRId64"); ", + rate); + } + } for (size_t j = 0; j < qos->n_action; j++) { if (!strcmp(qos->key_action[j], "dscp")) { if (qos->value_action[j] > QOS_MAX_DSCP) { @@ -7115,43 +7130,11 @@ build_qos(struct ovn_datapath *od, struct lflow_table *lflows, qos->value_action[j]); } } - - if (action.length) { ds_put_cstr(&action, "next;"); - ovn_lflow_add_with_hint(lflows, od, stage, qos->priority, - qos->match, ds_cstr(&action), - &qos->header_, lflow_ref); - } - - for (size_t n = 0; n < qos->n_bandwidth; n++) { - if (!strcmp(qos->key_bandwidth[n], "rate")) { - rate = qos->value_bandwidth[n]; - } else if (!strcmp(qos->key_bandwidth[n], "burst")) { - burst = qos->value_bandwidth[n]; - } - } - if (rate) { - stage = ingress ? S_SWITCH_IN_QOS_METER : S_SWITCH_OUT_QOS_METER; - ds_clear(&action); - if (burst) { - ds_put_format(&action, - "set_meter(%"PRId64", %"PRId64"); next;", - rate, burst); - } else { - ds_put_format(&action, - "set_meter(%"PRId64"); next;", - rate); - } - - /* Ingress and Egress QoS Meter Table. - * - * We limit the bandwidth of this flow by adding a meter table. - */ ovn_lflow_add_with_hint(lflows, od, stage, qos->priority, qos->match, ds_cstr(&action), &qos->header_, lflow_ref); - } } ds_destroy(&action); } diff --git a/northd/northd.h b/northd/northd.h index 3f1cd8341..d5161d17e 100644 --- a/northd/northd.h +++ b/northd/northd.h @@ -397,27 +397,26 @@ enum ovn_stage { PIPELINE_STAGE(SWITCH, IN, ACL_HINT, 7, "ls_in_acl_hint") \ PIPELINE_STAGE(SWITCH, IN, ACL_EVAL, 8, "ls_in_acl_eval") \ PIPELINE_STAGE(SWITCH, IN, ACL_ACTION, 9, "ls_in_acl_action") \ - PIPELINE_STAGE(SWITCH, IN, QOS_MARK, 10, "ls_in_qos_mark") \ - PIPELINE_STAGE(SWITCH, IN, QOS_METER, 11, "ls_in_qos_meter") \ - PIPELINE_STAGE(SWITCH, IN, LB_AFF_CHECK, 12, "ls_in_lb_aff_check") \ - PIPELINE_STAGE(SWITCH, IN, LB, 13, "ls_in_lb") \ - PIPELINE_STAGE(SWITCH, IN, LB_AFF_LEARN, 14, "ls_in_lb_aff_learn") \ - PIPELINE_STAGE(SWITCH, IN, PRE_HAIRPIN, 15, "ls_in_pre_hairpin") \ - PIPELINE_STAGE(SWITCH, IN, NAT_HAIRPIN, 16, "ls_in_nat_hairpin") \ - PIPELINE_STAGE(SWITCH, IN, HAIRPIN, 17, "ls_in_hairpin") \ - PIPELINE_STAGE(SWITCH, IN, ACL_AFTER_LB_EVAL, 18, \ + PIPELINE_STAGE(SWITCH, IN, QOS, 10, "ls_in_qos") \ + PIPELINE_STAGE(SWITCH, IN, LB_AFF_CHECK, 11, "ls_in_lb_aff_check") \ + PIPELINE_STAGE(SWITCH, IN, LB, 12, "ls_in_lb") \ + PIPELINE_STAGE(SWITCH, IN, LB_AFF_LEARN, 13, "ls_in_lb_aff_learn") \ + PIPELINE_STAGE(SWITCH, IN, PRE_HAIRPIN, 14, "ls_in_pre_hairpin") \ + PIPELINE_STAGE(SWITCH, IN, NAT_HAIRPIN, 15, "ls_in_nat_hairpin") \ + PIPELINE_STAGE(SWITCH, IN, HAIRPIN, 16, "ls_in_hairpin") \ + PIPELINE_STAGE(SWITCH, IN, ACL_AFTER_LB_EVAL, 17, \ "ls_in_acl_after_lb_eval") \ - PIPELINE_STAGE(SWITCH, IN, ACL_AFTER_LB_ACTION, 19, \ + PIPELINE_STAGE(SWITCH, IN, ACL_AFTER_LB_ACTION, 18, \ "ls_in_acl_after_lb_action") \ - PIPELINE_STAGE(SWITCH, IN, STATEFUL, 20, "ls_in_stateful") \ - PIPELINE_STAGE(SWITCH, IN, ARP_ND_RSP, 21, "ls_in_arp_rsp") \ - PIPELINE_STAGE(SWITCH, IN, DHCP_OPTIONS, 22, "ls_in_dhcp_options") \ - PIPELINE_STAGE(SWITCH, IN, DHCP_RESPONSE, 23, "ls_in_dhcp_response") \ - PIPELINE_STAGE(SWITCH, IN, DNS_LOOKUP, 24, "ls_in_dns_lookup") \ - PIPELINE_STAGE(SWITCH, IN, DNS_RESPONSE, 25, "ls_in_dns_response") \ - PIPELINE_STAGE(SWITCH, IN, EXTERNAL_PORT, 26, "ls_in_external_port") \ - PIPELINE_STAGE(SWITCH, IN, L2_LKUP, 27, "ls_in_l2_lkup") \ - PIPELINE_STAGE(SWITCH, IN, L2_UNKNOWN, 28, "ls_in_l2_unknown") \ + PIPELINE_STAGE(SWITCH, IN, STATEFUL, 19, "ls_in_stateful") \ + PIPELINE_STAGE(SWITCH, IN, ARP_ND_RSP, 20, "ls_in_arp_rsp") \ + PIPELINE_STAGE(SWITCH, IN, DHCP_OPTIONS, 21, "ls_in_dhcp_options") \ + PIPELINE_STAGE(SWITCH, IN, DHCP_RESPONSE, 22, "ls_in_dhcp_response") \ + PIPELINE_STAGE(SWITCH, IN, DNS_LOOKUP, 23, "ls_in_dns_lookup") \ + PIPELINE_STAGE(SWITCH, IN, DNS_RESPONSE, 24, "ls_in_dns_response") \ + PIPELINE_STAGE(SWITCH, IN, EXTERNAL_PORT, 25, "ls_in_external_port") \ + PIPELINE_STAGE(SWITCH, IN, L2_LKUP, 26, "ls_in_l2_lkup") \ + PIPELINE_STAGE(SWITCH, IN, L2_UNKNOWN, 27, "ls_in_l2_unknown") \ \ /* Logical switch egress stages. */ \ PIPELINE_STAGE(SWITCH, OUT, PRE_ACL, 0, "ls_out_pre_acl") \ @@ -426,11 +425,10 @@ enum ovn_stage { PIPELINE_STAGE(SWITCH, OUT, ACL_HINT, 3, "ls_out_acl_hint") \ PIPELINE_STAGE(SWITCH, OUT, ACL_EVAL, 4, "ls_out_acl_eval") \ PIPELINE_STAGE(SWITCH, OUT, ACL_ACTION, 5, "ls_out_acl_action") \ - PIPELINE_STAGE(SWITCH, OUT, QOS_MARK, 6, "ls_out_qos_mark") \ - PIPELINE_STAGE(SWITCH, OUT, QOS_METER, 7, "ls_out_qos_meter") \ - PIPELINE_STAGE(SWITCH, OUT, STATEFUL, 8, "ls_out_stateful") \ - PIPELINE_STAGE(SWITCH, OUT, CHECK_PORT_SEC, 9, "ls_out_check_port_sec") \ - PIPELINE_STAGE(SWITCH, OUT, APPLY_PORT_SEC, 10, "ls_out_apply_port_sec") \ + PIPELINE_STAGE(SWITCH, OUT, QOS, 6, "ls_out_qos") \ + PIPELINE_STAGE(SWITCH, OUT, STATEFUL, 7, "ls_out_stateful") \ + PIPELINE_STAGE(SWITCH, OUT, CHECK_PORT_SEC, 8, "ls_out_check_port_sec") \ + PIPELINE_STAGE(SWITCH, OUT, APPLY_PORT_SEC, 9, "ls_out_apply_port_sec") \ \ /* Logical router ingress stages. */ \ PIPELINE_STAGE(ROUTER, IN, ADMISSION, 0, "lr_in_admission") \ diff --git a/tests/ovn-northd.at b/tests/ovn-northd.at index 7893b0540..87c7e49a6 100644 --- a/tests/ovn-northd.at +++ b/tests/ovn-northd.at @@ -10080,6 +10080,7 @@ check ovn-nbctl qos-add ls from-lport 100 ip4 rate=100 burst=1000 check ovn-nbctl qos-add ls from-lport 101 ip4 mark=15 check ovn-nbctl qos-add ls from-lport 102 ip4 dscp=16 check ovn-nbctl qos-add ls from-lport 103 ip4 dscp=17 mark=18 +check ovn-nbctl qos-add ls from-lport 104 ip4 dscp=18 mark=19 rate=100 check ovn-nbctl qos-add ls to-lport 100 ip4 rate=100 burst=1000 check ovn-nbctl qos-add ls to-lport 101 ip4 mark=15 @@ -10088,18 +10089,17 @@ check ovn-nbctl qos-add ls to-lport 103 ip4 dscp=17 mark=18 check ovn-nbctl --wait=sb sync AT_CHECK([ovn-sbctl lflow-list ls | grep qos | ovn_strip_lflows], [0], [dnl - table=??(ls_in_qos_mark ), priority=0 , match=(1), action=(next;) - table=??(ls_in_qos_mark ), priority=101 , match=(ip4), action=(pkt.mark = 15; next;) - table=??(ls_in_qos_mark ), priority=102 , match=(ip4), action=(ip.dscp = 16; next;) - table=??(ls_in_qos_mark ), priority=103 , match=(ip4), action=(ip.dscp = 17; pkt.mark = 18; next;) - table=??(ls_in_qos_meter ), priority=0 , match=(1), action=(next;) - table=??(ls_in_qos_meter ), priority=100 , match=(ip4), action=(set_meter(100, 1000); next;) - table=??(ls_out_qos_mark ), priority=0 , match=(1), action=(next;) - table=??(ls_out_qos_mark ), priority=101 , match=(ip4), action=(pkt.mark = 15; next;) - table=??(ls_out_qos_mark ), priority=102 , match=(ip4), action=(ip.dscp = 16; next;) - table=??(ls_out_qos_mark ), priority=103 , match=(ip4), action=(ip.dscp = 17; pkt.mark = 18; next;) - table=??(ls_out_qos_meter ), priority=0 , match=(1), action=(next;) - table=??(ls_out_qos_meter ), priority=100 , match=(ip4), action=(set_meter(100, 1000); next;) + table=??(ls_in_qos ), priority=0 , match=(1), action=(next;) + table=??(ls_in_qos ), priority=100 , match=(ip4), action=(set_meter(100, 1000); next;) + table=??(ls_in_qos ), priority=101 , match=(ip4), action=(pkt.mark = 15; next;) + table=??(ls_in_qos ), priority=102 , match=(ip4), action=(ip.dscp = 16; next;) + table=??(ls_in_qos ), priority=103 , match=(ip4), action=(ip.dscp = 17; pkt.mark = 18; next;) + table=??(ls_in_qos ), priority=104 , match=(ip4), action=(set_meter(100); ip.dscp = 18; pkt.mark = 19; next;) + table=??(ls_out_qos ), priority=0 , match=(1), action=(next;) + table=??(ls_out_qos ), priority=100 , match=(ip4), action=(set_meter(100, 1000); next;) + table=??(ls_out_qos ), priority=101 , match=(ip4), action=(pkt.mark = 15; next;) + table=??(ls_out_qos ), priority=102 , match=(ip4), action=(ip.dscp = 16; next;) + table=??(ls_out_qos ), priority=103 , match=(ip4), action=(ip.dscp = 17; pkt.mark = 18; next;) ]) AT_CLEANUP diff --git a/tests/ovn.at b/tests/ovn.at index 4d0c7ad53..f04b74210 100644 --- a/tests/ovn.at +++ b/tests/ovn.at @@ -10205,9 +10205,8 @@ check ovn-nbctl --wait=hv set QoS $qos_id bandwidth=rate=100 # check at hv with a qos meter table AT_CHECK([as hv ovs-ofctl dump-meters br-int -O OpenFlow13 | grep rate=100 | wc -l], [0], [1 ]) -AT_CHECK([as hv ovs-ofctl dump-flows br-int -O OpenFlow13 | grep meter | wc -l], [0], [1 +AT_CHECK([as hv ovs-ofctl dump-flows br-int -O OpenFlow13 | grep meter | wc -l], [0], [2 ]) - # Update the DSCP marking check ovn-nbctl --wait=hv set QoS $qos_id action=dscp=63 check_tos 63 @@ -10218,7 +10217,7 @@ check ovn-nbctl --wait=hv set QoS $qos_id bandwidth=rate=4294967295,burst=429496 # check at hv with a qos meter table AT_CHECK([as hv ovs-ofctl dump-meters br-int -O OpenFlow13 | grep burst_size=4294967295 | wc -l], [0], [1 ]) -AT_CHECK([as hv ovs-ofctl dump-flows br-int -O OpenFlow13 | grep meter | wc -l], [0], [1 +AT_CHECK([as hv ovs-ofctl dump-flows br-int -O OpenFlow13 | grep meter | wc -l], [0], [2 ]) check ovn-nbctl --wait=hv set QoS $qos_id match="outport\=\=\"lp2\"" direction="to-lport" @@ -22071,7 +22070,7 @@ check_row_count Port_Binding 1 logical_port=sw0-vir virtual_parent=sw0-p1 wait_for_ports_up sw0-vir check ovn-nbctl --wait=hv sync AT_CHECK([test 2 = `cat hv1/ovn-controller.log | grep "pinctrl received packet-in" | \ -grep opcode=BIND_VPORT | grep OF_Table_ID=29 | wc -l`]) +grep opcode=BIND_VPORT | grep OF_Table_ID=28 | wc -l`]) wait_row_count Port_Binding 1 logical_port=sw0-vir6 chassis=$hv1_ch_uuid check_row_count Port_Binding 1 logical_port=sw0-vir6 virtual_parent=sw0-p1 @@ -37685,7 +37684,7 @@ tpa=$(ip_to_hex 10 0 0 10) send_garp 1 1 $eth_src $eth_dst $spa $tpa OVS_WAIT_UNTIL([test 1 = `cat hv1/ovn-controller.log | grep "pinctrl received packet-in" | \ -grep opcode=BIND_VPORT | grep OF_Table_ID=29 | wc -l`]) +grep opcode=BIND_VPORT | grep OF_Table_ID=28 | wc -l`]) sleep_controller hv1 From patchwork Tue Mar 26 16:32:08 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jacob Tanenbaum X-Patchwork-Id: 1916280 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@legolas.ozlabs.org Authentication-Results: legolas.ozlabs.org; dkim=fail reason="signature verification failed" (1024-bit key; unprotected) header.d=redhat.com header.i=@redhat.com header.a=rsa-sha256 header.s=mimecast20190719 header.b=VgkmxlHz; dkim-atps=neutral Authentication-Results: legolas.ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=openvswitch.org (client-ip=140.211.166.136; helo=smtp3.osuosl.org; envelope-from=ovs-dev-bounces@openvswitch.org; receiver=patchwork.ozlabs.org) Received: from smtp3.osuosl.org (smtp3.osuosl.org [140.211.166.136]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (secp384r1) server-digest SHA384) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4V3wLt3w4Kz1yWv for ; Wed, 27 Mar 2024 03:32:22 +1100 (AEDT) Received: from localhost (localhost [127.0.0.1]) by smtp3.osuosl.org (Postfix) with ESMTP id 9B71F60AEE; Tue, 26 Mar 2024 16:32:20 +0000 (UTC) X-Virus-Scanned: amavis at osuosl.org Received: from smtp3.osuosl.org ([127.0.0.1]) by localhost (smtp3.osuosl.org [127.0.0.1]) (amavis, port 10024) with ESMTP id 5d1SKBORW9mL; Tue, 26 Mar 2024 16:32:19 +0000 (UTC) X-Comment: SPF check N/A for local connections - client-ip=2605:bc80:3010:104::8cd3:938; helo=lists.linuxfoundation.org; envelope-from=ovs-dev-bounces@openvswitch.org; receiver= DKIM-Filter: OpenDKIM Filter v2.11.0 smtp3.osuosl.org 7B98F60836 Authentication-Results: smtp3.osuosl.org; dkim=fail reason="signature verification failed" (1024-bit key) header.d=redhat.com header.i=@redhat.com header.a=rsa-sha256 header.s=mimecast20190719 header.b=VgkmxlHz Received: from lists.linuxfoundation.org (lf-lists.osuosl.org [IPv6:2605:bc80:3010:104::8cd3:938]) by smtp3.osuosl.org (Postfix) with ESMTPS id 7B98F60836; Tue, 26 Mar 2024 16:32:19 +0000 (UTC) Received: from lf-lists.osuosl.org (localhost [127.0.0.1]) by lists.linuxfoundation.org (Postfix) with ESMTP id 3720DC007C; Tue, 26 Mar 2024 16:32:19 +0000 (UTC) X-Original-To: ovs-dev@openvswitch.org Delivered-To: ovs-dev@lists.linuxfoundation.org Received: from smtp4.osuosl.org (smtp4.osuosl.org [140.211.166.137]) by lists.linuxfoundation.org (Postfix) with ESMTP id A01CEC0037 for ; Tue, 26 Mar 2024 16:32:15 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by smtp4.osuosl.org (Postfix) with ESMTP id 7E57240582 for ; Tue, 26 Mar 2024 16:32:15 +0000 (UTC) X-Virus-Scanned: amavis at osuosl.org Received: from smtp4.osuosl.org ([127.0.0.1]) by localhost (smtp4.osuosl.org [127.0.0.1]) (amavis, port 10024) with ESMTP id 2zbP9lmKJH1M for ; Tue, 26 Mar 2024 16:32:14 +0000 (UTC) Received-SPF: Pass (mailfrom) identity=mailfrom; client-ip=170.10.133.124; helo=us-smtp-delivery-124.mimecast.com; envelope-from=jtanenba@redhat.com; receiver= DMARC-Filter: OpenDMARC Filter v1.4.2 smtp4.osuosl.org 75EC640571 Authentication-Results: smtp4.osuosl.org; dmarc=pass (p=none dis=none) header.from=redhat.com DKIM-Filter: OpenDKIM Filter v2.11.0 smtp4.osuosl.org 75EC640571 Authentication-Results: smtp4.osuosl.org; dkim=pass (1024-bit key) header.d=redhat.com header.i=@redhat.com header.a=rsa-sha256 header.s=mimecast20190719 header.b=VgkmxlHz Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) by smtp4.osuosl.org (Postfix) with ESMTPS id 75EC640571 for ; Tue, 26 Mar 2024 16:32:14 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1711470733; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=AGsS5ufjYBJSJkiJNEiqiiiDa4cCgs9grB1gs8KIyDA=; b=VgkmxlHzpylLVdSR5/CM+rTjWD203fx5PdBNDquhcfKGKwkQzwF25I3GvDxZnqm3nApUKl TPy28yXaH8/vgbUuxmbhsj2wkCG2ajEOshRSsfUewQasmhcc9rpTPUhXHWuzUkK0vQygHy sIIowoXJoLkL1mXqzgVC65amk6t2/Lk= Received: from mimecast-mx02.redhat.com (mimecast-mx02.redhat.com [66.187.233.88]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-624-g3xwKtffNOWR8fCVCCzdAA-1; Tue, 26 Mar 2024 12:32:12 -0400 X-MC-Unique: g3xwKtffNOWR8fCVCCzdAA-1 Received: from smtp.corp.redhat.com (int-mx01.intmail.prod.int.rdu2.redhat.com [10.11.54.1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id 002EC8007A7 for ; Tue, 26 Mar 2024 16:32:12 +0000 (UTC) Received: from fedora.redhat.com (unknown [10.22.9.162]) by smtp.corp.redhat.com (Postfix) with ESMTP id D7F8A3C20; Tue, 26 Mar 2024 16:32:11 +0000 (UTC) From: Jacob Tanenbaum To: ovs-dev@openvswitch.org Date: Tue, 26 Mar 2024 12:32:08 -0400 Message-ID: <20240326163208.1425569-2-jtanenba@redhat.com> In-Reply-To: <20240326163208.1425569-1-jtanenba@redhat.com> References: <20240326163208.1425569-1-jtanenba@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 3.4.1 on 10.11.54.1 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Subject: [ovs-dev] [PATCH ovn v2 2/2] missed during test simplification. X-BeenThere: ovs-dev@openvswitch.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: ovs-dev-bounces@openvswitch.org Sender: "dev" the testing was changed to remove the hardcoded table numbers from flows. Two referances to table=28 where missed, this patch corrects that and adds the correct variable name to the flow. Fixes: f614335abca1 ("tests: Remove table numbers from "action parsing".") Signed-off-by: Jacob Tanenbaum Acked-by: Ales Musil --- v2: addressed formatting seen by the day-0 bot and an additional referance to table=28 was identified diff --git a/tests/ovn.at b/tests/ovn.at index f04b74210..d269077ac 100644 --- a/tests/ovn.at +++ b/tests/ovn.at @@ -22070,7 +22070,7 @@ check_row_count Port_Binding 1 logical_port=sw0-vir virtual_parent=sw0-p1 wait_for_ports_up sw0-vir check ovn-nbctl --wait=hv sync AT_CHECK([test 2 = `cat hv1/ovn-controller.log | grep "pinctrl received packet-in" | \ -grep opcode=BIND_VPORT | grep OF_Table_ID=28 | wc -l`]) +grep opcode=BIND_VPORT | grep OF_Table_ID=$(ovn-debug lflow-stage-to-oftable ls_in_arp_rsp) | wc -l`]) wait_row_count Port_Binding 1 logical_port=sw0-vir6 chassis=$hv1_ch_uuid check_row_count Port_Binding 1 logical_port=sw0-vir6 virtual_parent=sw0-p1 @@ -37684,7 +37684,7 @@ tpa=$(ip_to_hex 10 0 0 10) send_garp 1 1 $eth_src $eth_dst $spa $tpa OVS_WAIT_UNTIL([test 1 = `cat hv1/ovn-controller.log | grep "pinctrl received packet-in" | \ -grep opcode=BIND_VPORT | grep OF_Table_ID=28 | wc -l`]) +grep opcode=BIND_VPORT | grep OF_Table_ID=$(ovn-debug lflow-stage-to-oftable ls_in_arp_rsp) | wc -l`]) sleep_controller hv1