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 3A213A0C43; Thu, 23 Sep 2021 08:45:53 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id C7D91410DD; Thu, 23 Sep 2021 08:45:52 +0200 (CEST) Received: from NAM10-DM6-obe.outbound.protection.outlook.com (mail-dm6nam10on2074.outbound.protection.outlook.com [40.107.93.74]) by mails.dpdk.org (Postfix) with ESMTP id BEF03410DC for ; Thu, 23 Sep 2021 08:45:50 +0200 (CEST) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=FT1Y0NAo5K9cIcRYPNDUcLPiNEDJtMhlkrp39buNF1CXYIi//BrZ9h/LYvFnjSvY04qQ9WruN0kjNsBw9yC7X2feRIEItCO5fjfOH0qXEm9iF/1AEyFKODJY6Yp/S9VXLkPZPi4M1PqiUWZ3CcaqrVuGSYbc0rt/G3TP0uEIa557RD7lohN2ahGU2nZpzZrhFTSDd9pMKW5BHROiOqEMtL+I+jwh2LRg8Ymt2cK4OTmPguKrHCntNgxRXvIyc1hvvZomcwJIvWx3ydwVWfp5ymAvAjLpdgXh6Ul6qfs3zcsEZuLNDbfLOcbJTkzCVTAiF+Lw6rHLmOyv+YVvngnpnA== 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; bh=E1UhVPZ0uyrRpMF0fFSzrFys30CNkUN1A9TLKSO229k=; b=E/Xzx6EVendQ5YrpniRkXimj2/v/fpuqm2eYvqGLX+/qnpgI5UYPiP0A3m4enGIohm0ZGOrgAKKSLhMmV8y82wYLjjpx1oQ9efziG9cyF/T8L62rIrL7PvXV9FDIhV+Nfo1ZifETWPo83NGQx4zYtH4/5c+dLl5w5Fv5uk+WZPVGtRzAwWUApM8eGvSaY1sZTCyUVSS9+KpUvEtfh7K2m4GgRj+LDOvP/BOEn0vr9RX/nWJREW974Gh6oi1KcPL3avJiZQ4JeeV1U8n5qh9zqkfV10qiLeICgNnFRCJQLjeFA3ixQS86uW1yCosx6qP2AAGxZnKb+qiRw62PGQZLWA== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 216.228.112.32) smtp.rcpttodomain=dpdk.org smtp.mailfrom=nvidia.com; dmarc=pass (p=quarantine sp=none 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=E1UhVPZ0uyrRpMF0fFSzrFys30CNkUN1A9TLKSO229k=; b=dXe2gjn2v5y0lzR/vuoFBPHo6LE8r9HdQtoG2NMn8Jcpg30xEBM/ivCkghT2xCLRkEUyGwP9yMG/V48TlBwKnqGDc277HpFKoUc5JBJ3IoMJgPLyPQLfrI9QhDOMt/whkW+2nu6tOimrQwNJb/YWqVpf1F/HRXt5gkvG0H3xtLIY7MKT2abKqaftjkQK7Rt5dsTy/WlSJECRKCyXYQG0BEPgbRkB1EZ/F7yvMiDfoBq90w8JvMI8n32DV6bo4jGFFFJyIrvXXZZGNm5olVHCeDyjQUmztUPAWdI/5C8FnAtAvE1xrT2OUBbt0U39xHJwsY99VMlAgu7T4za7+hQjVA== Received: from DM5PR06CA0059.namprd06.prod.outlook.com (2603:10b6:3:37::21) by DM5PR12MB1900.namprd12.prod.outlook.com (2603:10b6:3:10f::18) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4544.14; Thu, 23 Sep 2021 06:45:49 +0000 Received: from DM6NAM11FT066.eop-nam11.prod.protection.outlook.com (2603:10b6:3:37:cafe::66) by DM5PR06CA0059.outlook.office365.com (2603:10b6:3:37::21) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4544.13 via Frontend Transport; Thu, 23 Sep 2021 06:45:49 +0000 X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 216.228.112.32) smtp.mailfrom=nvidia.com; dpdk.org; dkim=none (message not signed) header.d=none;dpdk.org; dmarc=pass action=none header.from=nvidia.com; Received-SPF: Pass (protection.outlook.com: domain of nvidia.com designates 216.228.112.32 as permitted sender) receiver=protection.outlook.com; client-ip=216.228.112.32; helo=mail.nvidia.com; Received: from mail.nvidia.com (216.228.112.32) by DM6NAM11FT066.mail.protection.outlook.com (10.13.173.179) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384) id 15.20.4544.13 via Frontend Transport; Thu, 23 Sep 2021 06:45:49 +0000 Received: from DRHQMAIL107.nvidia.com (10.27.9.16) by HQMAIL109.nvidia.com (172.20.187.15) with Microsoft SMTP Server (TLS) id 15.0.1497.18; Wed, 22 Sep 2021 23:45:48 -0700 Received: from nvidia.com (172.20.187.6) by DRHQMAIL107.nvidia.com (10.27.9.16) with Microsoft SMTP Server (TLS) id 15.0.1497.18; Thu, 23 Sep 2021 06:45:46 +0000 From: Xueming Li To: CC: , Thomas Monjalon , "Viacheslav Ovsiienko" , Matan Azrad Date: Thu, 23 Sep 2021 14:45:26 +0800 Message-ID: <20210923064526.158381-1-xuemingl@nvidia.com> X-Mailer: git-send-email 2.33.0 In-Reply-To: <1610983607-7969-1-git-send-email-xuemingl@nvidia.com> References: <1610983607-7969-1-git-send-email-xuemingl@nvidia.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Type: text/plain X-Originating-IP: [172.20.187.6] X-ClientProxiedBy: HQMAIL107.nvidia.com (172.20.187.13) To DRHQMAIL107.nvidia.com (10.27.9.16) X-EOPAttributedMessage: 0 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 82cd00c7-e4e9-44f9-984c-08d97e5dc75d X-MS-TrafficTypeDiagnostic: DM5PR12MB1900: X-LD-Processed: 43083d15-7273-40c1-b7db-39efd9ccc17a,ExtAddr X-Microsoft-Antispam-PRVS: X-MS-Oob-TLC-OOBClassifiers: OLM:1303; X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: fg8fGdd3UHVTUUjSnHFy5rR0Ue6dLOCLT2awkOMQQ/RzOi3hcDJX6T8CRbmQtlfk54fZDgb5mNgWmB2YAj3uFQ/LVfV852eAvUF9LJcWGIC/gqw33goPkuKJzztLFvEtVLEXzZKOSFPFsvnfvVkeYScMi1ZUYVfLOed4uEVRWDWaNJhRsdRGELqp5MzNktwaM+LKoCf9saVV0pCN8yS0YNtSRJAvHv92cf4UAC3VEW5h7CICcjrm99pBj757PMVGjy4MSu7/Tklym8gTFjdIua7wtHO777Mp1qKB9Jis/MmakQzc1HkMDseTR3DEO5JFlrlefzzgQLoW/bI4ZdCuRVBJwrMLYJtyW0o+qJpatP762+pWxmil4JZRX55vkYyVzsp6OnH7cCDvBV0HgKosgnELQo2+aoImCV7q8lem4D/KTjhcUZmM5ARtKfFwWoHm5YIP7T134btg5lPtIpvMEi1vThQYgIyeTvafLzZZxXxZkkkaYzb2+udJ+EcUA1Ljp1ps7FTeOeRG+iEhuwJMPPE2FtrKDhjaXGeOc6ZPY6Elyqlg9EBxMt9crINnzHpfWvAyuS5VwnnReP39xsOKNDZ7MnboUEhT0n9IuJVt/OWDz+FXK4zCI+H2e8DGi7uHbFyg/EHu4A5Q1Qm/Y8R8202X8dQakzLgtzhvgRlj0Dzy3jGbpiq3HeR2uXwsHpMus8EjStxNvv1QifDxVv9tdQ== X-Forefront-Antispam-Report: CIP:216.228.112.32; CTRY:US; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:mail.nvidia.com; PTR:schybrid01.nvidia.com; CAT:NONE; SFS:(4636009)(36840700001)(46966006)(426003)(336012)(5660300002)(508600001)(7636003)(70586007)(70206006)(54906003)(186003)(86362001)(316002)(16526019)(2906002)(4326008)(26005)(8676002)(1076003)(47076005)(82310400003)(6286002)(6666004)(8936002)(2616005)(6916009)(356005)(36756003)(107886003)(36860700001)(7696005)(83380400001)(55016002); DIR:OUT; SFP:1101; X-OriginatorOrg: Nvidia.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 23 Sep 2021 06:45:49.0414 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 82cd00c7-e4e9-44f9-984c-08d97e5dc75d X-MS-Exchange-CrossTenant-Id: 43083d15-7273-40c1-b7db-39efd9ccc17a X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=43083d15-7273-40c1-b7db-39efd9ccc17a; Ip=[216.228.112.32]; Helo=[mail.nvidia.com] X-MS-Exchange-CrossTenant-AuthSource: DM6NAM11FT066.eop-nam11.prod.protection.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: DM5PR12MB1900 Subject: [dpdk-dev] [PATCH v3] net/mlx5: support new global device syntax 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 Sender: "dev" This patch support new global device syntax like: bus=pci,addr=BB:DD.F/class=eth/driver=mlx5,devargs,.. In driver parameters check, ignores "driver" key which is part of new global device syntax instead of reporting error. Signed-off-by: Xueming Li Acked-by: Viacheslav Ovsiienko --- drivers/net/mlx5/mlx5.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/drivers/net/mlx5/mlx5.c b/drivers/net/mlx5/mlx5.c index f84e061fe7..67808ec236 100644 --- a/drivers/net/mlx5/mlx5.c +++ b/drivers/net/mlx5/mlx5.c @@ -43,6 +43,9 @@ #define MLX5_ETH_DRIVER_NAME mlx5_eth +/* Driver type key for new device global syntax. */ +#define MLX5_DRIVER_KEY "driver" + /* Device parameter to enable RX completion queue compression. */ #define MLX5_RXQ_CQE_COMP_EN "rxq_cqe_comp_en" @@ -1860,7 +1863,7 @@ mlx5_args_check(const char *key, const char *val, void *opaque) signed long tmp; /* No-op, port representors are processed in mlx5_dev_spawn(). */ - if (!strcmp(MLX5_REPRESENTOR, key)) + if (!strcmp(MLX5_DRIVER_KEY, key) || !strcmp(MLX5_REPRESENTOR, key)) return 0; errno = 0; tmp = strtol(val, NULL, 0); @@ -2014,6 +2017,7 @@ int mlx5_args(struct mlx5_dev_config *config, struct rte_devargs *devargs) { const char **params = (const char *[]){ + MLX5_DRIVER_KEY, MLX5_RXQ_CQE_COMP_EN, MLX5_RXQ_PKT_PAD_EN, MLX5_RX_MPRQ_EN, -- 2.33.0