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 70D5BA00BE; Tue, 17 May 2022 05:39:33 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 42AB64282E; Tue, 17 May 2022 05:39:30 +0200 (CEST) Received: from EUR02-VE1-obe.outbound.protection.outlook.com (mail-eopbgr20060.outbound.protection.outlook.com [40.107.2.60]) by mails.dpdk.org (Postfix) with ESMTP id C1A6E4068B for ; Tue, 17 May 2022 05:39:28 +0200 (CEST) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=J8bpAPGClAw/mPk1sUWMClWtnukCP5WBhOscO40/4Ad+zsNYxkSk8HdMzBNgLeXVXNpyzKwct2dXGqrG25yCNIjfdXcxV3Wj6BCbUHmzYYHZrbQwRiulVkdDhNCJ910xM5RB821Oyz2YkZ3UBPOY5wS/AwvMY/lrWLyyI03U3hjox2YO9KLpRX76ADf5xCEXagLn1EQ3Xf2bXwGQ5aC64cmMzQWhT8aKrUkOOfIjSt311JC5xOlxcRT629QTsAycm11xxnDayXwk7kuEBuOzGLrJbmcxnxI3terJunbg4PEe3kCh7bAlm/NN3h1Om4+okmRiu6wzsjf3QrU+3lt3jg== 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=O4S5GUAkZK1l0/V5FY1IjVoC3ABpcw7SPSv22BprIQY=; b=W7KzNRCrIp/cJuf1uKCig8jJ9wT82YCKkIquHXO70+G9TMaUzcNs3mAQslIiCysBwH0PX7iJB3GthtbfY8AFuGIvqKz2MIafvNqH3t36KSL53ZIQOGU1A79bZti7MMeTFS6Mh6mjC3J4TZuODaxl5rslT5q/GJCjeDSsCV5qA3jCBXqbbkb81PTyl/DCfg397XxuKapykPLNd5k5afd+V9rOOldq/3zFVBPtoneEVBgePk3cEXBXs0MEcZPTKt8EBvf/lU3v2XVh8IFdeCCkyetD1bierf/VmtMQizt98+BSOAUALTH5nkbrmby9KbG5Hx37tl0KPQm9xpATWeMp1Q== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=nxp.com; dmarc=pass action=none header.from=nxp.com; dkim=pass header.d=nxp.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nxp.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=O4S5GUAkZK1l0/V5FY1IjVoC3ABpcw7SPSv22BprIQY=; b=pito201jNh3txldamtzLTTptia6jcEdwcpMN58d1KGc9N4GmOMctThvCVlAgIRCGTPKUTBvOZZBSzXJ1JRPb+OGeEAJdWzf/AxwxGRwRQkKUIdqRYs6k5+Fw2c6V7OdjGaDh8WFMgxP/ECtRdxdRhOwLPRF2E6JDjvGG1yEmWUY= Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=nxp.com; Received: from AS8PR04MB8198.eurprd04.prod.outlook.com (2603:10a6:20b:3b0::14) by DB8PR04MB6937.eurprd04.prod.outlook.com (2603:10a6:10:113::18) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5250.18; Tue, 17 May 2022 03:39:27 +0000 Received: from AS8PR04MB8198.eurprd04.prod.outlook.com ([fe80::8cf1:93b:c340:3be2]) by AS8PR04MB8198.eurprd04.prod.outlook.com ([fe80::8cf1:93b:c340:3be2%9]) with mapi id 15.20.5250.018; Tue, 17 May 2022 03:39:27 +0000 From: Gagandeep Singh To: gakhil@marvell.com, dev@dpdk.org Cc: Gagandeep Singh Subject: [PATCH v2 1/7] app/test-crypto-perf: support SDAP for PDCP operations Date: Tue, 17 May 2022 09:08:52 +0530 Message-Id: <20220517033858.40394-2-g.singh@nxp.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20220517033858.40394-1-g.singh@nxp.com> References: <20220425041423.2232034-1-g.singh@nxp.com> <20220517033858.40394-1-g.singh@nxp.com> Content-Transfer-Encoding: 8bit Content-Type: text/plain X-ClientProxiedBy: SI2PR01CA0046.apcprd01.prod.exchangelabs.com (2603:1096:4:193::18) To AS8PR04MB8198.eurprd04.prod.outlook.com (2603:10a6:20b:3b0::14) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 7b45e87c-4018-411f-6667-08da37b6d282 X-MS-TrafficTypeDiagnostic: DB8PR04MB6937:EE_ X-Microsoft-Antispam-PRVS: X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: beGIZQo/JyQ34+Qa/DJYEKUQRA01jJZsrrPXvt7nt0Gxkn9HBr1lUOr8VgOFnRFiXSqlv7hjiSsOTdkjnGTKdMudrId5zsEzAbCulsi0V9AIIYeKvQ9AvYAVB1VV9hsFmno800t/CyEy9jxBj+0I5HRA5lsTbN8o2hvmxGNNIxsnAiM0qmZhOhjePaKUPCTqTUjuT9HR8m2GtBPmuVnL5zUH4J6xrcsmKnRwFzZXgYXiN88sILDfUgNoKZfe0lpbdghhd3EICnSO6LkAOu4EsvBl+wDUCebWEwvI4w3qmp/MKqygqS0HvLjkdMlceNb0/VlMBO/v9VuvkMCZiIhxa6ZWEH0LRl2T7Pnu4GzzRFIj9BIkAdoP6B8RdtG0ndnPmLIMPqbY6ja169NMWd1kzFSik7j7A8c/8TeScc2P4f322dWHS/rRrovXgycvRVymsFwVNhNFOffldSX0FY2LVEPex24iLU8S5yOAi83xRMz6mOqJpKqDu2VS8B3tvBBswYF33kop6ieWrT3pKm9PDfsyCZ/JTjzi4ZmOPoKLa2lcf9j79CrHX1OQLQmmjIz/feRYJAPalCnd11MEQksvGECZ7clsiuMNCibwWhKGtI5wwRlzoOAoH5GCDK0AWRobSdXIt+FsiWsRa5K1y9VFxOYBWqmt3MriijJXwKW8+kNMs/yGmARHSlSrISJQsBdfNiq4QhxphncafMzzKIdu7Q== X-Forefront-Antispam-Report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:AS8PR04MB8198.eurprd04.prod.outlook.com; PTR:; CAT:NONE; SFS:(13230001)(4636009)(366004)(8936002)(316002)(55236004)(2906002)(38100700002)(2616005)(86362001)(66556008)(38350700002)(36756003)(26005)(186003)(6512007)(4326008)(6506007)(83380400001)(1076003)(6486002)(6666004)(52116002)(508600001)(8676002)(66946007)(5660300002)(66476007); DIR:OUT; SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?us-ascii?Q?pFyUzLNPYb/yDJa9cO+gEuDC9msVWpw+bcYnW767ctw8/Vv/5DaKdkSTMfjZ?= =?us-ascii?Q?ZRA+J85BZiQcOjcFmwwmiFmcUjcDnn3xg+aknn/xuXdZp9z5RtMFclwAXaNX?= =?us-ascii?Q?bzbBjnzDt4dICXGvOSKdwRKigLNcBBkUUxx0RnG6HT94QOOF9BvrXhJWomGx?= =?us-ascii?Q?Z0QZLDKEFojFKigVsDXEu4DyilJ2WhP9M6qWHRRLLq6yrVRQA2WY108A5FZM?= =?us-ascii?Q?TQw6LqxvREZe6KRuZQhlUOBVZS8PzI/+wuxFEIi2EwUv6+E++fzr+4NRQsqr?= =?us-ascii?Q?u5cAIInrWWxmUzh3glk8tAxN3wtKAwyOa++nSUmi7cdY9aTY9D4odxGb4t30?= =?us-ascii?Q?ztvc6Cls7wl9vSAi/1KjuDp4fYgPFYg+vW3Rb0za5wcMJ8oo4Ekxa/PLFg0/?= =?us-ascii?Q?DlshQ1O11Tr+ki6Xbct1zDV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ascii?Q?0vZowl6r2SH5b3VRC8WHsIdI/IAkWlf0YC3TjDZQVgtSL6pm7Sldx+ueTlWY?= =?us-ascii?Q?zXsn233/jhuDkiRXdRZZnJi5tk2tZrjj8FQAGCgbsxzOxQmkU3LyyEIUWtp0?= =?us-ascii?Q?u8jYcN+2J34vfx71wHnVqf4HdbVZrtdiErud4kvhbEWVe/bAck4QtqoiVR07?= =?us-ascii?Q?yQbvF6f9WnOrZspsVGnOYW3EHTjxa8VWW3v/k3NTl3UsfeliiqMBWihQ+Rnf?= =?us-ascii?Q?2hjpoUIo4f9Gi3mIXDh2WXrjq0tTeHuij39Kw6kBqs5MMFtrWjbP//dkwrLy?= =?us-ascii?Q?jkw+Q80DOicJxWF9ouTjftm/t8gxEtGJfWZUaoD8KhoP74WYbXS5Pi2E3Dgp?= =?us-ascii?Q?sSyoW50QE41avdBuuoUeqElK2BaR+bt/40Ffi3mMU4Zzv3XAUe6IAC6Gp/jR?= =?us-ascii?Q?IjpqNQMqYA=3D=3D?= X-OriginatorOrg: nxp.com X-MS-Exchange-CrossTenant-Network-Message-Id: 7b45e87c-4018-411f-6667-08da37b6d282 X-MS-Exchange-CrossTenant-AuthSource: AS8PR04MB8198.eurprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 17 May 2022 03:39:18.4039 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 686ea1d3-bc2b-4c6f-a92c-d99c5c301635 X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: cjf4qM/FhNSR2v4EBPSMGnD6a5Ps6wd0Op10XFnKmzd2iFs0IqOmiwraRcCDwnd3 X-MS-Exchange-Transport-CrossTenantHeadersStamped: DB8PR04MB6937 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 Add a command line option "--enable-sdap" to enable Service Data Adaptation Protocol. example command: ./dpdk-test-crypto-perf -c 0xc --log-level=8 -- --devtype crypto_dpaa2_sec --optype pdcp --cipher-algo aes-ctr --cipher-op encrypt --auth-algo zuc-eia3 --auth-op generate --auth-key-sz 16 --ptest throughput --total-ops 100000 --burst-sz 64 --buffer-sz 64,390,1512 --pool-sz 4096 --silent --pdcp-sn-sz 12 --pdcp-domain control --enable-sdap Signed-off-by: Gagandeep Singh --- app/test-crypto-perf/cperf_ops.c | 1 + app/test-crypto-perf/cperf_options.h | 2 ++ app/test-crypto-perf/cperf_options_parsing.c | 12 ++++++++++++ doc/guides/tools/cryptoperf.rst | 4 ++++ 4 files changed, 19 insertions(+) diff --git a/app/test-crypto-perf/cperf_ops.c b/app/test-crypto-perf/cperf_ops.c index cbefce8d6c..4295656a0b 100644 --- a/app/test-crypto-perf/cperf_ops.c +++ b/app/test-crypto-perf/cperf_ops.c @@ -861,6 +861,7 @@ cperf_create_session(struct rte_mempool *sess_mp, .hfn = options->pdcp_ses_hfn_en ? PDCP_DEFAULT_HFN : 0, .hfn_threshold = 0x70C0A, + .sdap_enabled = options->pdcp_sdap, .hfn_ovrd = !(options->pdcp_ses_hfn_en), } }, .crypto_xform = &cipher_xform diff --git a/app/test-crypto-perf/cperf_options.h b/app/test-crypto-perf/cperf_options.h index 09caefde22..613d6d31e2 100644 --- a/app/test-crypto-perf/cperf_options.h +++ b/app/test-crypto-perf/cperf_options.h @@ -14,6 +14,7 @@ #define CPERF_PTEST_TYPE ("ptest") #define CPERF_MODEX_LEN ("modex-len") #define CPERF_SILENT ("silent") +#define CPERF_ENABLE_SDAP ("enable-sdap") #define CPERF_POOL_SIZE ("pool-sz") #define CPERF_TOTAL_OPS ("total-ops") @@ -129,6 +130,7 @@ struct cperf_options { #ifdef RTE_LIB_SECURITY uint16_t pdcp_sn_sz; uint16_t pdcp_ses_hfn_en; + uint16_t pdcp_sdap; enum rte_security_pdcp_domain pdcp_domain; uint16_t docsis_hdr_sz; #endif diff --git a/app/test-crypto-perf/cperf_options_parsing.c b/app/test-crypto-perf/cperf_options_parsing.c index 09c98121c8..28680347f1 100644 --- a/app/test-crypto-perf/cperf_options_parsing.c +++ b/app/test-crypto-perf/cperf_options_parsing.c @@ -64,6 +64,7 @@ usage(char *progname) " --pdcp-sn-sz N: set PDCP SN size N <5/7/12/15/18>\n" " --pdcp-domain DOMAIN: set PDCP domain \n" " --pdcp-ses-hfn-en: enable session based fixed HFN\n" + " --enable-sdap: enable sdap\n" " --docsis-hdr-sz: set DOCSIS header size\n" #endif " -h: prints this help\n", @@ -548,6 +549,15 @@ parse_silent(struct cperf_options *opts, return 0; } +static int +parse_enable_sdap(struct cperf_options *opts, + const char *arg __rte_unused) +{ + opts->pdcp_sdap = 1; + + return 0; +} + static int parse_cipher_algo(struct cperf_options *opts, const char *arg) { @@ -879,6 +889,7 @@ static struct option lgopts[] = { { CPERF_PDCP_SN_SZ, required_argument, 0, 0 }, { CPERF_PDCP_DOMAIN, required_argument, 0, 0 }, { CPERF_PDCP_SES_HFN_EN, no_argument, 0, 0 }, + { CPERF_ENABLE_SDAP, no_argument, 0, 0 }, { CPERF_DOCSIS_HDR_SZ, required_argument, 0, 0 }, #endif { CPERF_CSV, no_argument, 0, 0}, @@ -994,6 +1005,7 @@ cperf_opts_parse_long(int opt_idx, struct cperf_options *opts) { CPERF_PDCP_SN_SZ, parse_pdcp_sn_sz }, { CPERF_PDCP_DOMAIN, parse_pdcp_domain }, { CPERF_PDCP_SES_HFN_EN, parse_pdcp_ses_hfn_en }, + { CPERF_ENABLE_SDAP, parse_enable_sdap }, { CPERF_DOCSIS_HDR_SZ, parse_docsis_hdr_sz }, #endif { CPERF_CSV, parse_csv_friendly}, diff --git a/doc/guides/tools/cryptoperf.rst b/doc/guides/tools/cryptoperf.rst index cf3b147213..c77e253417 100644 --- a/doc/guides/tools/cryptoperf.rst +++ b/doc/guides/tools/cryptoperf.rst @@ -332,6 +332,10 @@ The following are the application command-line options: Enable fixed session based HFN instead of per packet HFN. +* ``--enable-sdap`` + + Enable Service Data Adaptation Protocol. + * ``--modex-len `` Set modex length for asymmetric crypto perf test. -- 2.25.1