From patchwork Tue Jul 21 17:47:11 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ajit Khaparde X-Patchwork-Id: 74584 X-Patchwork-Delegate: ajit.khaparde@broadcom.com Return-Path: X-Original-To: patchwork@inbox.dpdk.org Delivered-To: patchwork@inbox.dpdk.org Received: from dpdk.org (dpdk.org [92.243.14.124]) by inbox.dpdk.org (Postfix) with ESMTP id 878ECA0526; Tue, 21 Jul 2020 19:47:32 +0200 (CEST) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 1946F1C039; Tue, 21 Jul 2020 19:47:24 +0200 (CEST) Received: from mail-wr1-f99.google.com (mail-wr1-f99.google.com [209.85.221.99]) by dpdk.org (Postfix) with ESMTP id E216A1C02C for ; Tue, 21 Jul 2020 19:47:21 +0200 (CEST) Received: by mail-wr1-f99.google.com with SMTP id a14so7182456wra.5 for ; Tue, 21 Jul 2020 10:47:21 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=broadcom.com; s=google; h=from:to:subject:date:message-id:mime-version :content-transfer-encoding; bh=OSm/+31hDTjS0JDXwg4akIGnsSTGtq6U57BK5Tcqoa8=; b=JOGv2D067DzgNXxVOAypgpD0SJo0rduhC++Xc/GS08R5S+PfrZGHeSST4ofbHsdQmq x4BO+2EfZLqDTna8ZMnS9aKIXdVsVwk2H+Zrqpv4o+iS8koaTERN9DUp5enKCqpRp/Zq SvvtK+esX7tLL3BP+BwPfYpWYxTTWJKqBgWvc= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:subject:date:message-id:mime-version :content-transfer-encoding; bh=OSm/+31hDTjS0JDXwg4akIGnsSTGtq6U57BK5Tcqoa8=; b=ZeBE037MKkxnvccAcC60HDeKHBIa3vux8S1bGI1IIBoHA42Kkaa37uobqqIybksGbd 8jx9kz8plUW3fUKjyaZeKc9MGC9I+AC/xPuRo4MqkKCNbi09NuYoDudy5l5DH9cF5nLy 20CJCbkF5uCeA1dWRl1O73PfaEYOOtlKgON3hnxcxIQFyeYSvsajW8fB8LiIMklyuBig Ngw+DWRKp2Ug20XhfIW7XqM3lyASx4VAZB9/TrANesVpBaAyy23BhXi9l2WYoqGavFCv LlKN12mfoCz51F+rYGtx9Jq8JN3IIZ+YmWdI5PnBbr99KXvwCek0YkQXB4K3iUEDW4TS tbFw== X-Gm-Message-State: AOAM5318pLIUk/eoo/zqIVUMg5d8Hb+p3veyDahE5/+KuT2KozkMHp1z war65C6HP8Taelrz4l6oNxyJj2v74TslDSQJILJ2bQxXjO9RKiRL+fheTGw1YWOYAGkHUIk7zca 0cbUelVBIl4sZ2mmd5bI584tmmEj/DNIKlTLTDG85wgvOcBfVtXwHaoDm9d++i7jE3/fbgaUId7 ehOQ== X-Google-Smtp-Source: ABdhPJypvbANQwM6xve1LsuKqGj77AZWuzf0NxPjVrP1bxTLx/ZcipoNXHi7WrZSWpCiWtqvWwmQUuM9RZdh X-Received: by 2002:a05:6000:1288:: with SMTP id f8mr19376786wrx.62.1595353641253; Tue, 21 Jul 2020 10:47:21 -0700 (PDT) Received: from localhost.localdomain ([192.19.223.252]) by smtp-relay.gmail.com with ESMTPS id y6sm71632wmb.38.2020.07.21.10.47.20 for (version=TLS1_2 cipher=ECDHE-ECDSA-AES128-GCM-SHA256 bits=128/128); Tue, 21 Jul 2020 10:47:21 -0700 (PDT) X-Relaying-Domain: broadcom.com From: Ajit Khaparde To: dev@dpdk.org Date: Tue, 21 Jul 2020 10:47:11 -0700 Message-Id: <20200721174712.48625-1-ajit.khaparde@broadcom.com> X-Mailer: git-send-email 2.21.1 (Apple Git-122.3) MIME-Version: 1.0 Subject: [dpdk-dev] [PATCH 1/2] net/bnxt: add meson build option X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 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" Add an option in meson build to indicate the memory management scheme. bnxt_eem_system is set to false by default. Signed-off-by: Ajit Khaparde --- doc/guides/nics/bnxt.rst | 9 +++++++++ drivers/net/bnxt/meson.build | 16 ++++++++++++++-- meson_options.txt | 2 ++ 3 files changed, 25 insertions(+), 2 deletions(-) diff --git a/doc/guides/nics/bnxt.rst b/doc/guides/nics/bnxt.rst index 6ff75d0a2..dcb4309d2 100644 --- a/doc/guides/nics/bnxt.rst +++ b/doc/guides/nics/bnxt.rst @@ -809,6 +809,15 @@ is stopped. Note that TX (or RX) vector mode can be enabled independently from RX (or TX) vector mode. +Configuration +------------- + +Compilation options +~~~~~~~~~~~~~~~~~~~ + +- ``bnxt_eem_system`` (default **false**) +This option allows to select the flow table memory management scheme. + Appendix -------- diff --git a/drivers/net/bnxt/meson.build b/drivers/net/bnxt/meson.build index 8529b333c..21a1df915 100644 --- a/drivers/net/bnxt/meson.build +++ b/drivers/net/bnxt/meson.build @@ -4,6 +4,14 @@ install_headers('rte_pmd_bnxt.h') +bnxt_eem_sys = (get_option('bnxt_eem_system')) +if bnxt_eem_sys + dpdk_conf.set('RTE_LIBRTE_BNXT_PMD_SYSTEM', true) + cflags += [ + '-DTF_USE_SYSTEM_MEM' + ] +endif + includes += include_directories('tf_ulp') includes += include_directories('tf_core') @@ -29,7 +37,6 @@ sources = files('bnxt_cpr.c', 'tf_core/rand.c', 'tf_core/stack.c', 'tf_core/tf_em_common.c', - 'tf_core/tf_em_host.c', 'tf_core/tf_em_internal.c', 'tf_core/tf_rm.c', 'tf_core/tf_tbl.c', @@ -45,7 +52,6 @@ sources = files('bnxt_cpr.c', 'tf_core/tf_if_tbl.c', 'tf_core/ll.c', 'tf_core/tf_global_cfg.c', - 'tf_core/tf_em_host.c', 'tf_core/tf_shadow_identifier.c', 'hcapi/hcapi_cfa_p4.c', @@ -67,6 +73,12 @@ sources = files('bnxt_cpr.c', 'rte_pmd_bnxt.c') +if bnxt_eem_sys + sources += files('tf_core/tf_em_system.c') +elif not bnxt_eem_sys + sources += files('tf_core/tf_em_host.c') +endif + if arch_subdir == 'x86' sources += files('bnxt_rxtx_vec_sse.c') elif arch_subdir == 'arm' and host_machine.cpu_family().startswith('aarch64') diff --git a/meson_options.txt b/meson_options.txt index 9bf18ab6b..24d72fb10 100644 --- a/meson_options.txt +++ b/meson_options.txt @@ -2,6 +2,8 @@ option('armv8_crypto_dir', type: 'string', value: '', description: 'path to the armv8_crypto library installation directory') +option('bnxt_eem_system', type: 'boolean', value: false, + description: 'EEM system memory support') option('disable_drivers', type: 'string', value: '', description: 'Comma-separated list of drivers to explicitly disable.') option('drivers_install_subdir', type: 'string', value: 'dpdk/pmds-',