From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id A5B86A04FD; Mon, 4 Jul 2022 10:25:03 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 51D93410E5; Mon, 4 Jul 2022 10:25:03 +0200 (CEST) Received: from NAM12-BN8-obe.outbound.protection.outlook.com (mail-bn8nam12on2062.outbound.protection.outlook.com [40.107.237.62]) by mails.dpdk.org (Postfix) with ESMTP id E376F40E09 for ; Mon, 4 Jul 2022 10:25:01 +0200 (CEST) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=PKRNiU71tx1Ob1Zu5V6B7eSNp6xkzgAl5GHmSLMU6iawEy9qceB46noznNjOlLCgYrUEtOH0zVVgbfgfY8WPM+JP9AuxiqPNoJh6h9sXyF6L6Yltp7q4oKKRLMePhPUauZ1zMzvV5LkGGRHuaq9yhvcJ+ORdXP+/RdVzztEgjxoVSNp1Cmto5A0HxAGJx2sKN3dpvgeGAosRrhzl/h5k0HweieebTXB3hLocxwSqHomZVckH/Q2CYXNG1Brdx+/jI42P5NXEtv5d5ETsLcQQU4prVKWOtuip1o/2HIXPhcr85Etz0CZRHVURMatZ4onN3ikhatTFGr5+tdUVwLCQMA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=9xmm3LNndm+VhF66DhCB6qqpKYwUby/Gbr2wzxn72O8=; b=NZbPSifNsqspDmI8fcNqCdSytlJYzIZ0DuWNlp7pWhH9QoJKsgbq4zkqrk6gkL8wnobIZSwNfqVDXE3Jzp62DzWg0AeiaCCZ/yWXt2T4zb655KpeaHEtu/IgrJRchxSbhdl1msmDBPO/pw7nN9UPd8imnM59Vx+p/vQh3SlZLYg87+bEzUD5iRDiXRhTYJFcSP1h1fhkow7WMKWIJmFz5OHaEMsg5nOqPW7kUmNzjFoAqSmzcsYzzuc4vs6CRplxuJCRlSBCdnwsfTmhLcsgGBTCbrJFM1N7bUwjq/L6KWiwVG1D4vIfwwyEsef3OFKyAYROEGwRPywoUfrrizT4Ww== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 12.22.5.234) smtp.rcpttodomain=monjalon.net smtp.mailfrom=nvidia.com; dmarc=pass (p=reject sp=reject pct=100) action=none header.from=nvidia.com; dkim=none (message not signed); arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=Nvidia.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=9xmm3LNndm+VhF66DhCB6qqpKYwUby/Gbr2wzxn72O8=; b=WYNXzCFZXHVeAPGRAUjKiSY3XDjvYSpDWxO7DaG2+9dy5yog+t2VkPF7wECKvATeY/3TYQtMl6uJNBYxD7cbfWJeRQEEmbI4q1GV/JQwE4i9zaWEm53qTde3zX3xtKmrHKqGWw8d02hRzadJvYxBRcDCzkhH/PUc3cReE6We4Mwv5ek8xQkM9fHbNXum8ejO5Yk+/QLvxT6g+BRBNgmu2kDWI3tjm2Dpk6wfYwtOTCmML3jkYgK0i1fOah2yGMHHis4F/XJvKRdc1xvXunVs5hxcCIQfDcra0v5m8R5rsIXhPJrF92rtBPFCzfNJiySKODoAhhI3+XEn8sChHyX/gw== Received: from DM6PR05CA0040.namprd05.prod.outlook.com (2603:10b6:5:335::9) by PH7PR12MB6491.namprd12.prod.outlook.com (2603:10b6:510:1f4::14) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5395.17; Mon, 4 Jul 2022 08:24:59 +0000 Received: from DM6NAM11FT029.eop-nam11.prod.protection.outlook.com (2603:10b6:5:335:cafe::da) by DM6PR05CA0040.outlook.office365.com (2603:10b6:5:335::9) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5395.14 via Frontend Transport; Mon, 4 Jul 2022 08:24:59 +0000 X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 12.22.5.234) smtp.mailfrom=nvidia.com; dkim=none (message not signed) header.d=none;dmarc=pass action=none header.from=nvidia.com; Received-SPF: Pass (protection.outlook.com: domain of nvidia.com designates 12.22.5.234 as permitted sender) receiver=protection.outlook.com; client-ip=12.22.5.234; helo=mail.nvidia.com; pr=C Received: from mail.nvidia.com (12.22.5.234) by DM6NAM11FT029.mail.protection.outlook.com (10.13.173.23) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384) id 15.20.5395.14 via Frontend Transport; Mon, 4 Jul 2022 08:24:59 +0000 Received: from rnnvmail201.nvidia.com (10.129.68.8) by DRHQMAIL101.nvidia.com (10.27.9.10) with Microsoft SMTP Server (TLS) id 15.0.1497.32; Mon, 4 Jul 2022 08:24:58 +0000 Received: from nvidia.com (10.126.231.35) by rnnvmail201.nvidia.com (10.129.68.8) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.986.26; Mon, 4 Jul 2022 01:24:55 -0700 From: Eli Britstein To: , Thomas Monjalon CC: Slava Ovsiienko , Ori Kam , "Asaf Penso" , Matan Azrad , Gaetan Rivet , Nir Anteby , Eli Britstein Subject: [dpdk-dev] [RFC] testpmd: support user-id attribute Date: Mon, 4 Jul 2022 11:24:33 +0300 Message-ID: <20220704082433.3698761-1-elibr@nvidia.com> X-Mailer: git-send-email 2.25.1 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Type: text/plain X-Originating-IP: [10.126.231.35] X-ClientProxiedBy: rnnvmail203.nvidia.com (10.129.68.9) To rnnvmail201.nvidia.com (10.129.68.8) X-EOPAttributedMessage: 0 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 1c4f02f9-9955-4b8c-87d3-08da5d96af2c X-MS-TrafficTypeDiagnostic: PH7PR12MB6491:EE_ X-LD-Processed: 43083d15-7273-40c1-b7db-39efd9ccc17a,ExtAddr X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: 1Y8WqU2uXq4WEGL3xz7GKs14ugXytp8BIciTZR6LPK6S7Kr26m4Lv7xKDIWEKDfv9Z44eYILObHbRv2hhhuIxCWvV+F0QhFABJNW+WcMZybazvOd68i2VD5I+koWMoEufnwgkRQV21WJs2+4TRPNEB9wnB+S7+r1ia2d4QPiBhIXsbhL47Ac7E3evR88hmHcsWCBI+pzKslcANNRs4VH7b9iFB1OSPKkeQilT650afobCrB/t2gypKHrDzz1T+DVYwlQw/nN0vzVsA+HdvGluHSuSKY3jp1c7FQ1qT3stR+Ztm0+NU5SOftvfbPoOTHMB6dlbaTD5AM2KMd3ZxqfHkQ4WaBR1XHDF6zHaMHxa2er5V9S90uzGRVow47KEea4bFAHZNVB8Q+iiCwBr7cpIfBkNPIjhYUzuQkjBXiOIbX0sHoFZC2ZjNemMNnsE94GSiDLRgyuSaUOw3kqwjEQcy/ioknC0NVzMvePNXbKHUDphPctzfdkQ4FwYtVXsJy2DLgpiOsi3EnS6FNiQsxWa92QWpWNNJbC8wW+GM4TtIykDl8FTUIGld0qPDU7pgHSJh6U0mYIbEknzXw3QTYQSwPk2xm2+fdLdc/gmvn1+TLwKaw7MA5Lwib4C43/QIKJSw/kBWL2ioptI4cjM7c9yNO3drUwRy74rOHtFIWihXiARI2AreoEj8T1SDnYLhkIUK0NLFl3NBvcLk2PZVQ+YU0tqY1nY/GxKbiZBm1v+vebmZq5mlvAkV4rijDWY2H51nTOKF2rt9DzzKMEhoHLclp2SFWocqiLXtPaza2gkPujnWqxnFBKvRcSkxHDo9aVQKZtbb0+gU7ec+4XaOt31PcsUC0J5OO14hQ3gsj2gTo= X-Forefront-Antispam-Report: CIP:12.22.5.234; CTRY:US; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:mail.nvidia.com; PTR:InfoNoRecords; CAT:NONE; SFS:(13230016)(4636009)(136003)(39860400002)(346002)(396003)(376002)(36840700001)(46966006)(40470700004)(40460700003)(86362001)(36860700001)(316002)(81166007)(82740400003)(82310400005)(356005)(478600001)(8936002)(2906002)(5660300002)(6666004)(41300700001)(4326008)(54906003)(70206006)(70586007)(426003)(47076005)(336012)(186003)(1076003)(16526019)(40480700001)(55016003)(8676002)(110136005)(83380400001)(107886003)(26005)(7696005)(36756003)(2616005)(6286002)(36900700001); DIR:OUT; SFP:1101; X-OriginatorOrg: Nvidia.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 04 Jul 2022 08:24:59.0505 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 1c4f02f9-9955-4b8c-87d3-08da5d96af2c X-MS-Exchange-CrossTenant-Id: 43083d15-7273-40c1-b7db-39efd9ccc17a X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=43083d15-7273-40c1-b7db-39efd9ccc17a; Ip=[12.22.5.234]; Helo=[mail.nvidia.com] X-MS-Exchange-CrossTenant-AuthSource: DM6NAM11FT029.eop-nam11.prod.protection.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: PH7PR12MB6491 X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Upon creation of a flow, testpmd assigns it a flow ID. Later, the flow ID is used for flow operations (query, destroy, dump). The testpmd application allows to manage flow rules with its IDs. The flow ID is known only when the flow is created. In order to prepare a complete sequence of testpmd commands to copy/paste, the flow IDs must be predictable. The idea brought here is to allow providing some user-defined ID, chosen in advance of the effective flow creation. Example: testpmd> flow create 0 ingress user_id 0x1234 pattern eth / end actions count / drop / end Flow rule #0 created, user-id 0x1234 testpmd> flow destroy 0 user_id rule 0x1234 Flow rule #0 destroyed, user-id 0x1234 Here, "user_id" is a flag that signifies the "rule" ID is the user-id. The motivation is from OVS. OVS dumps its "rte_flow_create" calls to the log in testpmd commands syntax. As the flow ID testpmd would assign is unkwon, it cannot log valid "flow destroy" commands. With the enhancement described above, valid testpmd commands can be created in a log to copy/paste to testpmd. The application's flows sequence can then be played back in testpmd, to enable enhanced dpdk debug capabilities of the applications's flows in a controlled environment of testpmd rather than a dynamic, more difficult to debug environment of the application. -- 2.26.2.1730.g385c171