From patchwork Tue Oct 10 20:33:47 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Mark Michelson X-Patchwork-Id: 1846071 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=azKQSyq/; 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 4S4ngX5qk5z1yq3 for ; Wed, 11 Oct 2023 07:34:16 +1100 (AEDT) Received: from localhost (localhost [127.0.0.1]) by smtp3.osuosl.org (Postfix) with ESMTP id B868E61460; Tue, 10 Oct 2023 20:34:14 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp3.osuosl.org B868E61460 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=azKQSyq/ X-Virus-Scanned: amavisd-new at osuosl.org Received: from smtp3.osuosl.org ([127.0.0.1]) by localhost (smtp3.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id Up9-7rkEjU7e; Tue, 10 Oct 2023 20:34:12 +0000 (UTC) Received: from lists.linuxfoundation.org (lf-lists.osuosl.org [IPv6:2605:bc80:3010:104::8cd3:938]) by smtp3.osuosl.org (Postfix) with ESMTPS id CEFEF60F8E; Tue, 10 Oct 2023 20:34:10 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp3.osuosl.org CEFEF60F8E Received: from lf-lists.osuosl.org (localhost [127.0.0.1]) by lists.linuxfoundation.org (Postfix) with ESMTP id B94B8C0DD7; Tue, 10 Oct 2023 20:34:09 +0000 (UTC) X-Original-To: dev@openvswitch.org Delivered-To: ovs-dev@lists.linuxfoundation.org Received: from smtp3.osuosl.org (smtp3.osuosl.org [140.211.166.136]) by lists.linuxfoundation.org (Postfix) with ESMTP id 0968EC0032 for ; Tue, 10 Oct 2023 20:34:08 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by smtp3.osuosl.org (Postfix) with ESMTP id C8B366137D for ; Tue, 10 Oct 2023 20:34:07 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp3.osuosl.org C8B366137D X-Virus-Scanned: amavisd-new at osuosl.org Received: from smtp3.osuosl.org ([127.0.0.1]) by localhost (smtp3.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id vAtcnBsqA0mL for ; Tue, 10 Oct 2023 20:34:05 +0000 (UTC) Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) by smtp3.osuosl.org (Postfix) with ESMTPS id 12C5860F8E for ; Tue, 10 Oct 2023 20:34:04 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp3.osuosl.org 12C5860F8E DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1696970043; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=QSge7TcAoxLchtjK4JRf8rb7KKcb6LtkHhvr97F/BOw=; b=azKQSyq/Fk1pPfL6sBYje3CM/JeLRuKROSC099GRaybucK1hmVF6Hm55RmWcj721nCTDhm OJluZV8IV3zGWc2bNNGfHv7mMqiQHiFzvJnPv16y7yB6bajZ1CjBA01LnA4DJSy2r5xgnI vw9501Kqz6l04Q3/0wOWsZb7otGsJbQ= Received: from mimecast-mx02.redhat.com (mimecast-mx02.redhat.com [66.187.233.88]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id us-mta-364-Qu0PtdeTN5O-YD-sPsZHyw-1; Tue, 10 Oct 2023 16:34:02 -0400 X-MC-Unique: Qu0PtdeTN5O-YD-sPsZHyw-1 Received: from smtp.corp.redhat.com (int-mx02.intmail.prod.int.rdu2.redhat.com [10.11.54.2]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id CF02D8F5DA0 for ; Tue, 10 Oct 2023 20:34:01 +0000 (UTC) Received: from localhost.localdomain.com (unknown [10.22.48.27]) by smtp.corp.redhat.com (Postfix) with ESMTP id 7D35040C6F79 for ; Tue, 10 Oct 2023 20:34:01 +0000 (UTC) From: Mark Michelson To: dev@openvswitch.org Date: Tue, 10 Oct 2023 16:33:47 -0400 Message-Id: <20231010203400.1045353-2-mmichels@redhat.com> In-Reply-To: <20231010203400.1045353-1-mmichels@redhat.com> References: <20231010203400.1045353-1-mmichels@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 3.4.1 on 10.11.54.2 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Subject: [ovs-dev] [PATCH ovn 01/13] tests: Use fmt_pkt in ovn -- allows ACLs to match ... 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" ... against vlan-transparent double tagged traffic L3 fields. Execution time: 2.377s Execution time on "main" branch: 1.997s Signed-off-by: Mark Michelson --- tests/ovn.at | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) diff --git a/tests/ovn.at b/tests/ovn.at index 96a77b070..3f00829ff 100644 --- a/tests/ovn.at +++ b/tests/ovn.at @@ -2335,8 +2335,11 @@ done test_tcp_packet() { local inport=$1 eth_dst=$2 eth_src=$3 ip_dst=$4 ip_src=$5 eout=$6 lout=$7 fail=$8 - tag=810000ff - local packet=${eth_dst}${eth_src}${tag}${tag}08004500002800004000ff060000${ip_src}${ip_dst}0001000100000001000000005000ffff00000000 + local packet=$(fmt_pkt "Ether(dst='${eth_dst}', src='${eth_src}')/ \ + Dot1Q()/ \ + Dot1Q()/ \ + IP(dst='${ip_dst}', src='${ip_src}')/ \ + TCP()") as hv-$inport ovs-appctl netdev-dummy/receive vif$inport $packet if [[ $fail -eq 0 ]]; then echo $packet >> ${eout#lp}.expected @@ -2349,8 +2352,8 @@ for i in 1 2; do done check ovn-nbctl --wait=hv sync -test_tcp_packet 1 f00000000002 f00000000001 0a000002 0a000001 lp2 lp2 1 -test_tcp_packet 2 f00000000001 f00000000002 0a000001 0a000002 lp1 lp1 1 +test_tcp_packet 1 f0:00:00:00:00:02 f0:00:00:00:00:01 10.0.0.2 10.0.0.1 lp2 lp2 1 +test_tcp_packet 2 f0:00:00:00:00:01 f0:00:00:00:00:02 10.0.0.1 10.0.0.2 lp1 lp1 1 for i in 1 2; do OVN_CHECK_PACKETS_REMOVE_BROADCAST([vif$i-tx.pcap], [$i.expected]) @@ -2363,8 +2366,8 @@ for i in 1 2; do done check ovn-nbctl --wait=hv sync -test_tcp_packet 2 f00000000001 f00000000002 0a000001 0a000002 lp1 lp1 0 -test_tcp_packet 1 f00000000002 f00000000001 0a000002 0a000001 lp2 lp2 0 +test_tcp_packet 2 f0:00:00:00:00:01 f0:00:00:00:00:02 10.0.0.1 10.0.0.2 lp1 lp1 0 +test_tcp_packet 1 f0:00:00:00:00:02 f0:00:00:00:00:01 10.0.0.2 10.0.0.1 lp2 lp2 0 for i in 1 2; do OVN_CHECK_PACKETS_REMOVE_BROADCAST([vif$i-tx.pcap], [$i.expected])