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 00AA041C53; Thu, 9 Feb 2023 17:47:28 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 8E4C4410EA; Thu, 9 Feb 2023 17:47:28 +0100 (CET) Received: from mail-pj1-f54.google.com (mail-pj1-f54.google.com [209.85.216.54]) by mails.dpdk.org (Postfix) with ESMTP id 7151940EDC for ; Thu, 9 Feb 2023 17:47:27 +0100 (CET) Received: by mail-pj1-f54.google.com with SMTP id f16-20020a17090a9b1000b0023058bbd7b2so2973719pjp.0 for ; Thu, 09 Feb 2023 08:47:27 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=networkplumber-org.20210112.gappssmtp.com; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:subject:cc:to:from:date:from:to:cc:subject:date :message-id:reply-to; bh=6rTBZIaCpqV3ORpNqwnRcbzoiPIXYKWUure+zEh0Lfg=; b=J6oEeLsLzVtXruD9oOjVoXcr0Dm9tA0+IUFJ3nBs4+jm1nmO4qxDtRsWv3GesBrnXy gLNh1RA9Q7esK3NPtQIhHNJqGUPW31TesvmePuNk7LVCVDZKRMM0EcqlvgaXJ7GL5TGI OJ3dKgglu9ZupBc1FDgG2X7UC+EnpOpD4VVBtLU09BFFpP5epb2Gqd2KNNENNU4kYxPX 27+LjbYcqZzwYZ4xbgCCFt222h3++s1QDoqDbfzoAewL79E7Bisd2RizSEJ1j8+HptpR 9o4pMPAcFgsXhrTtWckEszDzQKUSEqvVwMe4yBF0q9kwpJ1MKyO0RyaUzgd2Rj//baFx Jz0Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:subject:cc:to:from:date:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=6rTBZIaCpqV3ORpNqwnRcbzoiPIXYKWUure+zEh0Lfg=; b=yIw9LSqNlNZharLcMcJjjlQB5p8lStdUZY4Di1ztQRrIuM3W3hpNMVaO4WqP9GiiEC rm9yNWUfWP8oU1NZjbYkqQ59ZeL2S0VdSVROMhOyj+VQ9mUvbymYRbWNn9Ni+G+T+Wr9 bHrrfzfiVhL3oPQyUhCiNcphK5S/MYbQKssn9axA4UbF6bfYwKzJJkpI+ArTG6LNAm3O 97IPwZE6G3qa2DTFG8FquYr9FufJOeA8hQUzT/S3jC8V7Acfk23t/n1yPwU7rj/Hvmni E84tj7QwMc6wosha7y7lsmr/pMFvUi7MVinm8kZy6NFz8AmhqgrVDZ1pB2/IveCxVir1 4MWQ== X-Gm-Message-State: AO0yUKU5Y95Cp6ZOAibu3vY16oYHT0/8FkRBWb7o+kssZ5PeY/66C/Pv ByFmdYISo9Y6yilyvQARaVDpsg== X-Google-Smtp-Source: AK7set8/y/kShU+C4/vmP6XQk+zMQF6aCRR0Hl4JrDmrMqE+PyZ4fFZ3A3P3G2BDXjNPiy5qBGQ4iQ== X-Received: by 2002:a17:903:234a:b0:199:2353:1eff with SMTP id c10-20020a170903234a00b0019923531effmr14198053plh.21.1675961246511; Thu, 09 Feb 2023 08:47:26 -0800 (PST) Received: from hermes.local (204-195-120-218.wavecable.com. [204.195.120.218]) by smtp.gmail.com with ESMTPSA id 13-20020a170902c10d00b001978e84753asm1726213pli.65.2023.02.09.08.47.26 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 09 Feb 2023 08:47:26 -0800 (PST) Date: Thu, 9 Feb 2023 08:47:24 -0800 From: Stephen Hemminger To: Mingxia Liu Cc: dev@dpdk.org, qi.z.zhang@intel.com, jingjing.wu@intel.com, beilei.xing@intel.com Subject: Re: [PATCH v5 00/21] add support for cpfl PMD in DPDK Message-ID: <20230209084724.17539e7b@hermes.local> In-Reply-To: <20230209084541.2712723-1-mingxia.liu@intel.com> References: <20230118075738.904616-1-mingxia.liu@intel.com> <20230209084541.2712723-1-mingxia.liu@intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable 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 Thu, 9 Feb 2023 08:45:20 +0000 Mingxia Liu wrote: > The patchset introduced the cpfl (Control Plane Function Library) PMD > for Intel=C2=AE IPU E2100=E2=80=99s Configure Physical Function (Device I= D: 0x1453) >=20 > The cpfl PMD inherits all the features from idpf PMD which will follow > an ongoing standard data plan function spec > https://www.oasis-open.org/committees/tc_home.php?wg_abbrev=3Didpf > Besides, it will also support more device specific hardware offloading > features from DPDK=E2=80=99s control path (e.g.: hairpin, rte_flow =E2=80= =A6). which is > different from idpf PMD, and that's why we need a new cpfl PMD. >=20 > This patchset mainly focuses on idpf PMD=E2=80=99s equivalent features. > To avoid duplicated code, the patchset depends on below patchsets which > move the common part from net/idpf into common/idpf as a shared library. >=20 > v2 changes: > - rebase to the new baseline. > - Fix rss lut config issue. > v3 changes: > - rebase to the new baseline. > v4 changes: > - Resend v3. No code changed. > v3 changes: > - rebase to the new baseline. > - optimize some code > - give "not supported" tips when user want to config rss hash type > - if stats reset fails at initialization time, don't rollback, just > print ERROR info >=20 > Mingxia Liu (21): > net/cpfl: support device initialization > net/cpfl: add Tx queue setup > net/cpfl: add Rx queue setup > net/cpfl: support device start and stop > net/cpfl: support queue start > net/cpfl: support queue stop > net/cpfl: support queue release > net/cpfl: support MTU configuration > net/cpfl: support basic Rx data path > net/cpfl: support basic Tx data path > net/cpfl: support write back based on ITR expire > net/cpfl: support RSS > net/cpfl: support Rx offloading > net/cpfl: support Tx offloading > net/cpfl: add AVX512 data path for single queue model > net/cpfl: support timestamp offload > net/cpfl: add AVX512 data path for split queue model > net/cpfl: add HW statistics > net/cpfl: add RSS set/get ops > net/cpfl: support scalar scatter Rx datapath for single queue model > net/cpfl: add xstats ops >=20 > MAINTAINERS | 9 + > doc/guides/nics/cpfl.rst | 88 ++ > doc/guides/nics/features/cpfl.ini | 17 + > doc/guides/rel_notes/release_23_03.rst | 6 + > drivers/net/cpfl/cpfl_ethdev.c | 1453 +++++++++++++++++++++++ > drivers/net/cpfl/cpfl_ethdev.h | 95 ++ > drivers/net/cpfl/cpfl_logs.h | 32 + > drivers/net/cpfl/cpfl_rxtx.c | 952 +++++++++++++++ > drivers/net/cpfl/cpfl_rxtx.h | 44 + > drivers/net/cpfl/cpfl_rxtx_vec_common.h | 116 ++ > drivers/net/cpfl/meson.build | 38 + > drivers/net/meson.build | 1 + > 12 files changed, 2851 insertions(+) > create mode 100644 doc/guides/nics/cpfl.rst > create mode 100644 doc/guides/nics/features/cpfl.ini > create mode 100644 drivers/net/cpfl/cpfl_ethdev.c > create mode 100644 drivers/net/cpfl/cpfl_ethdev.h > create mode 100644 drivers/net/cpfl/cpfl_logs.h > create mode 100644 drivers/net/cpfl/cpfl_rxtx.c > create mode 100644 drivers/net/cpfl/cpfl_rxtx.h > create mode 100644 drivers/net/cpfl/cpfl_rxtx_vec_common.h > create mode 100644 drivers/net/cpfl/meson.build >=20 Overall, the driver looks good. One recommendation would be to not use rte_memcpy for small fixed size structure. Regular memcpy() will be as fast or faster and get more checking from analyzers. Examples: rte_memcpy(adapter->mbx_resp, ctlq_msg.ctx.indirect.payload->va, rte_memcpy(ring_name, "cpfl Tx ring", sizeof("cpfl Tx ring")); rte_memcpy(ring_name, "cpfl Rx ring", sizeof("cpfl Rx ring")); rte_memcpy(ring_name, "cpfl Tx compl ring", sizeof("cpfl Tx compl ring")); rte_memcpy(ring_name, "cpfl Rx buf ring", sizeof("cpfl Rx buf ring")); rte_memcpy(vport->rss_key, rss_conf->rss_key, rte_memcpy(vport->rss_key, rss_conf->rss_key, rte_memcpy(rss_conf->rss_key, vport->rss_key, rss_conf->rss_key_len);