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 53FB141C8C; Mon, 13 Feb 2023 21:00:35 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id F1B9142D93; Mon, 13 Feb 2023 20:59:49 +0100 (CET) Received: from mail-pl1-f170.google.com (mail-pl1-f170.google.com [209.85.214.170]) by mails.dpdk.org (Postfix) with ESMTP id EB0CB42D64 for ; Mon, 13 Feb 2023 20:59:41 +0100 (CET) Received: by mail-pl1-f170.google.com with SMTP id o8so12321835pls.11 for ; Mon, 13 Feb 2023 11:59:41 -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=M8pRnn6UCXMDXQ5HMMtTZAPC9+D5OPOOwBhGsqw2t6A=; b=d8BuO7Ym29qerHTWA5YL2Von0DRGDzViCYxyGZDwBwWrDlu8gORIlzZxayNvmP2QyR NZNpJvkSayspE3rttbAtxTKY9ajpFsXEW6P7wJaYWUuTKONGsvohHwpvfkucW+vVT7cR NR+2hQp4WJUmci9zWYMIRqlP8cTsCctqvC8MtIWV2Ds56XmZSWgFt8K5NtjWOh1vtzZW jfaPedHE+PvzDjRDYpQK0Vcz9WjJPmkqoIgP1TYL9rCrDlH5aZubkeys/ypH59xddO3W D5LttE8cuf9oFj0OipXhVjBXqWzraW9DIMFZZdJtHbwvSqBC69eNuvu9E8y0A2+whVfd feuw== 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=M8pRnn6UCXMDXQ5HMMtTZAPC9+D5OPOOwBhGsqw2t6A=; b=EGTkfHpZZh9uxBhGvCRS4bpWRA9odo94pQQC1XDFk5yKdqBSBgiBANzGW1KK4ECfoe T3IoGc64pAEmEIQ+fBw4Wj6HtmpVzBGUp5Xb2t2yHlUd07F495pYScDkrcvaRjVLgzS0 O9EhvC2HpDvEK67or+UgnCKmKToyBrmHfPk10z1ZN7KDFOXk14BKtm07v9yob1eoGzOM Jobiir0TMm0VZkcPLJyNCtfeud9aY7NPy+Hi5n4JDu51GePSPh2iux1C/1J6f/Y+HheW /PgHM9NEcmG8XEPTTpqT7F3hVtzlygoMWuqnZdIz/7TPI7Fo8EoB/BAkrkLFL2oNXKsl kaKA== X-Gm-Message-State: AO0yUKWggoL2wzRnox3hh6eo9c7FjxdPWgMNCx7FuNCRukC1CSfOl/9o EVqbMwMFu3Ae3aWVhtBRhjfSL9lDxBX8Gn6idIw= X-Google-Smtp-Source: AK7set/lmPTS0ZdAzzt0cxYMm+bo6U0iqy54gVTHdhE7eNQVLTnfcdnHfBOcj1qdiuq3HucPrH99ZQ== X-Received: by 2002:a17:902:dac1:b0:194:d664:be3a with SMTP id q1-20020a170902dac100b00194d664be3amr164297plx.16.1676318381163; Mon, 13 Feb 2023 11:59:41 -0800 (PST) Received: from hermes.local (204-195-120-218.wavecable.com. [204.195.120.218]) by smtp.gmail.com with ESMTPSA id n20-20020a170902d0d400b001994e74c094sm8578911pln.275.2023.02.13.11.59.40 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 13 Feb 2023 11:59:40 -0800 (PST) From: Stephen Hemminger To: dev@dpdk.org Cc: Stephen Hemminger Subject: [PATCH v4 11/19] kni: replace RTE_LOGTYPE_KNI with dynamic type Date: Mon, 13 Feb 2023 11:55:43 -0800 Message-Id: <20230213195551.1146298-12-stephen@networkplumber.org> X-Mailer: git-send-email 2.39.1 In-Reply-To: <20230213195551.1146298-1-stephen@networkplumber.org> References: <20230207204151.1503491-1-stephen@networkplumber.org> <20230213195551.1146298-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 Even though KNI will eventually disappear, fix the logtype now. Signed-off-by: Stephen Hemminger --- lib/eal/common/eal_common_log.c | 1 - lib/eal/include/rte_log.h | 2 +- lib/kni/rte_kni.c | 3 +++ 3 files changed, 4 insertions(+), 2 deletions(-) diff --git a/lib/eal/common/eal_common_log.c b/lib/eal/common/eal_common_log.c index 6e2007e6ed4f..70d5bb7b1951 100644 --- a/lib/eal/common/eal_common_log.c +++ b/lib/eal/common/eal_common_log.c @@ -351,7 +351,6 @@ static const struct logtype logtype_strings[] = { {RTE_LOGTYPE_EAL, "lib.eal"}, {RTE_LOGTYPE_PMD, "pmd"}, {RTE_LOGTYPE_HASH, "lib.hash"}, - {RTE_LOGTYPE_KNI, "lib.kni"}, {RTE_LOGTYPE_METER, "lib.meter"}, {RTE_LOGTYPE_SCHED, "lib.sched"}, {RTE_LOGTYPE_PORT, "lib.port"}, diff --git a/lib/eal/include/rte_log.h b/lib/eal/include/rte_log.h index 115a48bf05f5..dc2454a0d9de 100644 --- a/lib/eal/include/rte_log.h +++ b/lib/eal/include/rte_log.h @@ -34,7 +34,7 @@ extern "C" { #define RTE_LOGTYPE_PMD 5 /**< Log related to poll mode driver. */ #define RTE_LOGTYPE_HASH 6 /**< Log related to hash table. */ /* was RTE_LOGTYPE_LPM */ -#define RTE_LOGTYPE_KNI 8 /**< Log related to KNI. */ + /* was RTE_LOGTYPE_KNI */ /* was RTE_LOGTYPE_ACL */ /* was RTE_LOGTYPE_POWER */ #define RTE_LOGTYPE_METER 11 /**< Log related to QoS meter. */ diff --git a/lib/kni/rte_kni.c b/lib/kni/rte_kni.c index 8ab6c4715314..9c37bcabcadd 100644 --- a/lib/kni/rte_kni.c +++ b/lib/kni/rte_kni.c @@ -23,6 +23,9 @@ #include #include "rte_kni_fifo.h" +RTE_LOG_REGISTER_DEFAULT(kni_logtype, INFO); +#define RTE_LOGTYPE_KNI kni_logtype + #define MAX_MBUF_BURST_NUM 32 /* Maximum number of ring entries */ -- 2.39.1