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 D37FD41CC0; Fri, 17 Feb 2023 14:01:28 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id BF79B42B8B; Fri, 17 Feb 2023 14:01:28 +0100 (CET) Received: from NAM11-BN8-obe.outbound.protection.outlook.com (mail-bn8nam11on2041.outbound.protection.outlook.com [40.107.236.41]) by mails.dpdk.org (Postfix) with ESMTP id 9CEF840EE1 for ; Fri, 17 Feb 2023 14:01:27 +0100 (CET) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=Vv99UbvammscfpGC+/DMoFi4nNwpYMbnXSXkd/xGb53P8XU4gEdlCB8IHc2wHjXwQd24/YS72gBLkWUUeNJqtnPvcBweEj7R4UrfXjBUyYCOjAPRNkHh81YZ/9Mb6/wzuqWphy/NjYZYNmCVXPQWpeZtCS20nLwgfvz1guLB4NBDVxHwEu3HMHx5IXNBe0MqFpDRBq64o6XTJ1qQcdi6efYXTXEHA8fo8lfzlZXoe3PfYZ/98euS1VaVXfaNMeUEzHOwCMufRKToDKVfZz59Crnan8AkdyR4chd6NprU6I6gjtYSDQW+na6p1CluIwdPslv8Bhlcasf+m5neATR7pw== 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=0W9Wou4I7vqnnMqrRwgaYzCiqSFHp6qWuDFmKiCZdfc=; b=OqgZaDUoUeFl2wwydfvA0tQGFk5gcQrm9BnCe0q0ktuzhwUUYcGjQ8rzVGzHgzSRIeCW/zPHwm2S+DJRoL0tk5VfSWm/0Yk7t3tjnHZO+6xFx+/DVP1yLEK6ooNK/fsX5JXysuAT8T2XeeNdm6y6p2hBqmG3BRhwsSPsvPmv4fNlkujurUILX/euCT2BHYMp1fWdKvDtXut4pu6j5IQ1Kl2nuj8CuS7PJN+fhjfUILI7FnuYSiNq72CwrEagPvQJYlQz/O0hYcOjYBPbRSLWmt8V2UNYE2bW1FyqGXuXL0EYmQ8TspkKBCj/3w+Ts42dqRbFtpXfk2Befr5M98Zu6g== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=amd.com; dmarc=pass action=none header.from=amd.com; dkim=pass header.d=amd.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amd.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=0W9Wou4I7vqnnMqrRwgaYzCiqSFHp6qWuDFmKiCZdfc=; b=wpE+VrQQdT9nd0sQHVQyuoM+vZo5vhb4hOiTf7Ks+H7zWcptJMUhpl2s1iNDolXt9YPQAr+SmsKjHFmsca5ainSKuK6bZyVIQVvoTn30CQF+9mAqdtX8KGmOzEisH0rCs78hHzSZl8R+9U4362kjPgT4Sn//kkPeKQ3PIbMMBfY= Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=amd.com; Received: from CH2PR12MB4294.namprd12.prod.outlook.com (2603:10b6:610:a9::11) by MN2PR12MB4454.namprd12.prod.outlook.com (2603:10b6:208:26c::18) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6111.13; Fri, 17 Feb 2023 13:01:25 +0000 Received: from CH2PR12MB4294.namprd12.prod.outlook.com ([fe80::3614:22ed:ed5:5b48]) by CH2PR12MB4294.namprd12.prod.outlook.com ([fe80::3614:22ed:ed5:5b48%7]) with mapi id 15.20.6111.013; Fri, 17 Feb 2023 13:01:25 +0000 Message-ID: <661e99ab-c05f-0be3-d877-31e4b911e67f@amd.com> Date: Fri, 17 Feb 2023 13:01:19 +0000 User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:102.0) Gecko/20100101 Thunderbird/102.7.2 Subject: Re: [PATCH v6 0/2] Add Tx queue mapping of aggregated ports Content-Language: en-US To: Jiawei Wang , viacheslavo@nvidia.com, orika@nvidia.com, thomas@monjalon.net, andrew.rybchenko@oktetlabs.ru Cc: dev@dpdk.org, rasland@nvidia.com References: <20230203050717.46914-1-jiaweiw@nvidia.com> <20230217105026.12927-1-jiaweiw@nvidia.com> From: Ferruh Yigit In-Reply-To: <20230217105026.12927-1-jiaweiw@nvidia.com> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-ClientProxiedBy: LO4P123CA0284.GBRP123.PROD.OUTLOOK.COM (2603:10a6:600:195::19) To CH2PR12MB4294.namprd12.prod.outlook.com (2603:10b6:610:a9::11) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: CH2PR12MB4294:EE_|MN2PR12MB4454:EE_ X-MS-Office365-Filtering-Correlation-Id: 23449f33-e77a-4a7f-f5a5-08db10e7139f X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: y+zUY7DXLE8/9nt8iTBVgqOyPYDFgHqTDqBZ6Jz6O88kFW0JxNGpqJtIF8Ev88TlnsjoRFCVqCwuzYq6rhxyLsKGsG0SIA9P8B4+aNxSmRXKLVc3RJi6fjtndnhfV6Rovz3iKRZ65xLrUqTMRnBVpPhazkGr+E3zsoFqZoITTx+KFukq6+1lA/QhnP95ajFLeXXTNlVl7YPb1vppOldIajXdjV8fKBsEQynWr6IlxKIK0rPOFZP5VbJPH6aQCz2zZVti6heTMeIAHl5jLTC2A6CqEMt8DgeJDqxkz4I0LAPDpIf+XTLIP8OnzeE48comY8eVj2slqPw/KOGva4GWrYghLqexyeSIorjVzJk4mCCXR9/nSFyqu29i11r0bkUUpeeTlkHPaOMZX/kVZZWZPX12FtYjpBKWqIYYaH9c2K2G7XQX8d66n23fJPRvIrdsSRZgYzl3RE8ipg+HRgThWRe+hQKnl54MPuvj74xud8zrkbzEkG8sKQUDdf6HGBKB6VGCKD2Z/gJwRVKHR502soQkHrEssk8QeV1ASnD6AQ763hCB0u93Sicd98v1PeGQJl8eVuyy0M0UNOIz7eflED1nukLRUy2Pzm1a1BnsXWBtVOp+3R5VuyYAEPk15ii6olxyIS4KF3YFKzMIxgu5LVQwEpsO7OUiRuR/hQVb7VGb+OF4t53gO2HH7mncoVjHlnTf6cscl9bxc00UW0/LbyO5V5jm/PEWC9iOZY+cUk43DRgRXuHZwUhOqWuVev38 X-Forefront-Antispam-Report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:CH2PR12MB4294.namprd12.prod.outlook.com; PTR:; CAT:NONE; SFS:(13230025)(4636009)(376002)(396003)(346002)(39860400002)(366004)(136003)(451199018)(31686004)(4326008)(66946007)(41300700001)(478600001)(66476007)(66556008)(8676002)(36756003)(86362001)(31696002)(5660300002)(8936002)(316002)(6512007)(83380400001)(38100700002)(44832011)(186003)(2616005)(6506007)(53546011)(26005)(2906002)(966005)(6486002)(6666004)(45980500001)(43740500002); DIR:OUT; SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?utf-8?B?aEpPTTVaUjhWTkpxaXgwT1V2SjNqRnlRdWlSOHFWU1pQQ0NUU3BBVEp6R25K?= =?utf-8?B?UWJETmhXdEMrL0xzbjMvL3lSYUZVVGV5Nnc5RjBJbHU1TzI2eDhCMUt0dkww?= =?utf-8?B?a3lJczUwUGJ3VGhYZldmYjhXditQdXVUSFNZZGtZQ3FmNXJiRGJ6aVJRVVJh?= =?utf-8?B?eTh3bkNoR29NZm1PdmJlc0g5ZE9nK3FCdm9FRHAxaVd5Vy8zZVdNT1lhL3JK?= =?utf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IvcWFiMUZKSHl5?= =?utf-8?B?amlrUWYrWTYwbFN0WmxFRlkyU1ZUYTl3eDkyc1hzR3JkWk9xVU1LWUN1TmJU?= =?utf-8?Q?r5re4dOlcxa/3zUdVkNy3Uwth?= X-OriginatorOrg: amd.com X-MS-Exchange-CrossTenant-Network-Message-Id: 23449f33-e77a-4a7f-f5a5-08db10e7139f X-MS-Exchange-CrossTenant-AuthSource: CH2PR12MB4294.namprd12.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 17 Feb 2023 13:01:25.7984 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 3dd8961f-e488-4e60-8e11-a82d994e183d X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: ILHBjPyVvhe4nU3adcLsZDdnNmcpxRh7fb0b9uzCfsVBjWxhgVkisMN0HvGCqv72 X-MS-Exchange-Transport-CrossTenantHeadersStamped: MN2PR12MB4454 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 On 2/17/2023 10:50 AM, Jiawei Wang wrote: > When multiple ports are aggregated into a single DPDK port, > (example: Linux bonding, DPDK bonding, failsafe, etc.), > we want to know which port is used for Rx and Tx. > > This patch introduces the new ethdev API > rte_eth_dev_map_aggr_tx_affinity(), it's used to map a Tx queue > with an aggregated port of the DPDK port (specified with port_id), > The affinity is the number of the aggregated port. > Value 0 means no affinity and traffic could be routed to any > aggregated port, this is the default current behavior. > > The maximum number of affinity is given by rte_eth_dev_count_aggr_ports(). > > This patch allows to map a Rx queue with an aggregated port by using > a flow rule. The new item is called RTE_FLOW_ITEM_TYPE_AGGR_AFFINITY. > > While uses the aggregated affinity as a matching item in the flow rule, > and sets the same affinity value by call > rte_eth_dev_map_aggr_tx_affinity(), then the packet can be sent from > the same port as the receiving one. > The affinity numbering starts from 1, then trying to match on > aggr_affinity 0 will result in an error. > > RFC: http://patches.dpdk.org/project/dpdk/cover/20221221102934.13822-1-jiaweiw@nvidia.com/ > > v6: > * Update the commit titles. > * Return 0 by default if dev_ops.count_aggr_ports is not defined. > * Adds the dev_configure and affinity value checking before call map_aggr_tx_affinity. > * Update the rte_eth_dev_count_aggr_ports description. > > v5: > * Adds rte_eth_dev_map_aggr_tx_affinity() to map a Tx queue to an aggregated port. > * Adds rte_eth_dev_count_aggr_ports() to get the number of aggregated ports. > * Updates the flow item RTE_FLOW_ITEM_TYPE_AGGR_AFFINITY. > > v4: > * Rebase the latest code > * Update new field description > * Update release release note > * Reword the commit log to make clear > > v3: > * Update exception rule > * Update the commit log > * Add the description for PHY affinity and numbering definition > * Add the number of physical ports into device info > * Change the patch order > > v2: Update based on the comments > > Jiawei Wang (2): > ethdev: add Tx queue mapping of aggregated ports > ethdev: add flow matching of aggregated port It looks like there will be a new version, can you please rebase next version on top of next-net [1], there are multiple conflicts with this patch, it is safer if you resolve them yourself. [1] https://git.dpdk.org/next/dpdk-next-net/