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 2E40641D40; Wed, 22 Feb 2023 17:09:43 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 536AF4302F; Wed, 22 Feb 2023 17:09:31 +0100 (CET) Received: from mail-pj1-f51.google.com (mail-pj1-f51.google.com [209.85.216.51]) by mails.dpdk.org (Postfix) with ESMTP id 08FB643004 for ; Wed, 22 Feb 2023 17:09:28 +0100 (CET) Received: by mail-pj1-f51.google.com with SMTP id il18-20020a17090b165200b0023127b2d602so8852213pjb.2 for ; Wed, 22 Feb 2023 08:09: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:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=F0D+hj5Bg0vmf4yNAzBM9EKiuqa4HmHrh/mXAEir/+o=; b=zc8DEPOWZXLuHDyg4FgVtpMQG8uA2JSGy6x3MtqjI0sJnvdXugE5OGuHrPlh5fkOyi FXsEneJZXFP/vgi5SgTESKpDZqZaYAE5fW8BwDJpIYW7Nyw0uEpMyJUrk+TxcgJgIuSd nMOd4b4b/r46KkzfTIrjp8fJZ5ePxpFdycB4vbCs/GTDSGiL8xnyVYIS2Qp8z0zyG4Dl YQC65BM81gzI1kLx5vJc4BSiF0fHbImYaT83BMDZtJhJ70VGc+aLHZLQ1scDIL/RTddf F5DRLg26DBsJyjgaRWxfk/H4jZlIt7mdOmtFgc6J3M9ypPGRMfDM8liSNlwQLQ6jFOfG pMlg== 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:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=F0D+hj5Bg0vmf4yNAzBM9EKiuqa4HmHrh/mXAEir/+o=; b=OmuDq8B231S9+keuIavog3OEaUc05qZ3NDZnVnU2UIGOw0QTLBiwE3OkdaZNyG8iJE rNi5W1VrogNMFa7R0TSDQVM6wFZZ21EAtawTj3KmrtLNLMiYW7AqITcnc8D6IkQk3tZM OiHgiBpR2uqcNqez/cbxG+oYFIyF8PSePXpBpeN6D7KmnAHmqEc0AQTrFF2xygY2pryx bcv7WklCvZOTpTlPj+QMUe+AqYlIXjIszsFHDPasocIWXMF89tCRrxM0t7YrhMHuyNAW DW/lVXnN4Lg6kAnS783KMElBm4YdQrEsp8WRrx1be5fjBkBT+eYwG5Vf1NfOKjbS5nJ5 QXZw== X-Gm-Message-State: AO0yUKW+f55r5NuppCvVeHZkwkjzVe8UIzDtCTP5aeGjKIbkbDAVVCeJ irDeil8h48QrGl4DKhVLn3uGZFoqXhAfUl84nj4= X-Google-Smtp-Source: AK7set+BAgBGXiQIXiaTOY0ti9yelumzfaqIZcDakUB+RyhK0ge0X6Tdc1PFVJTHq9HkEs8MNH+c8g== X-Received: by 2002:a17:903:5cf:b0:199:1852:d2e with SMTP id kf15-20020a17090305cf00b0019918520d2emr9280936plb.9.1677082166958; Wed, 22 Feb 2023 08:09:26 -0800 (PST) Received: from hermes.local (204-195-120-218.wavecable.com. [204.195.120.218]) by smtp.gmail.com with ESMTPSA id x24-20020a63db58000000b004fb71d96d78sm5063778pgi.2.2023.02.22.08.09.26 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 22 Feb 2023 08:09:26 -0800 (PST) From: Stephen Hemminger To: dev@dpdk.org Cc: Stephen Hemminger , Byron Marohn , Yipeng Wang Subject: [PATCH v10 04/22] efd: replace RTE_LOGTYPE_EFD with dynamic type Date: Wed, 22 Feb 2023 08:07:44 -0800 Message-Id: <20230222160802.123611-5-stephen@networkplumber.org> X-Mailer: git-send-email 2.39.1 In-Reply-To: <20230222160802.123611-1-stephen@networkplumber.org> References: <20230207204151.1503491-1-stephen@networkplumber.org> <20230222160802.123611-1-stephen@networkplumber.org> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit 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 Replace all uses of the global logtype with a dynamic log type. Signed-off-by: Stephen Hemminger --- lib/eal/common/eal_common_log.c | 1 - lib/eal/include/rte_log.h | 2 +- lib/efd/rte_efd.c | 4 ++++ 3 files changed, 5 insertions(+), 2 deletions(-) diff --git a/lib/eal/common/eal_common_log.c b/lib/eal/common/eal_common_log.c index 5421da008f5b..25bb17938cc1 100644 --- a/lib/eal/common/eal_common_log.c +++ b/lib/eal/common/eal_common_log.c @@ -365,7 +365,6 @@ static const struct logtype logtype_strings[] = { {RTE_LOGTYPE_PIPELINE, "lib.pipeline"}, {RTE_LOGTYPE_MBUF, "lib.mbuf"}, {RTE_LOGTYPE_CRYPTODEV, "lib.cryptodev"}, - {RTE_LOGTYPE_EFD, "lib.efd"}, {RTE_LOGTYPE_EVENTDEV, "lib.eventdev"}, {RTE_LOGTYPE_USER1, "user1"}, {RTE_LOGTYPE_USER2, "user2"}, diff --git a/lib/eal/include/rte_log.h b/lib/eal/include/rte_log.h index 16d6ea31583d..0b39795b4d06 100644 --- a/lib/eal/include/rte_log.h +++ b/lib/eal/include/rte_log.h @@ -44,7 +44,7 @@ extern "C" { #define RTE_LOGTYPE_PIPELINE 15 /**< Log related to pipeline. */ #define RTE_LOGTYPE_MBUF 16 /**< Log related to mbuf. */ #define RTE_LOGTYPE_CRYPTODEV 17 /**< Log related to cryptodev. */ -#define RTE_LOGTYPE_EFD 18 /**< Log related to EFD. */ + /* was RTE_LOGTYPE_EFD */ #define RTE_LOGTYPE_EVENTDEV 19 /**< Log related to eventdev. */ /* was RTE_LOGTYPE_GSO */ diff --git a/lib/efd/rte_efd.c b/lib/efd/rte_efd.c index 686a13775742..9edb11799c89 100644 --- a/lib/efd/rte_efd.c +++ b/lib/efd/rte_efd.c @@ -9,6 +9,7 @@ #include #include +#include #include #include #include @@ -28,6 +29,9 @@ #include "rte_efd_arm64.h" #endif +RTE_LOG_REGISTER_DEFAULT(efd_logtype, INFO); +#define RTE_LOGTYPE_EFD efd_logtype + #define EFD_KEY(key_idx, table) (table->keys + ((key_idx) * table->key_len)) /** Hash function used to determine chunk_id and bin_id for a group */ #define EFD_HASH(key, table) \ -- 2.39.1