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 63C9541C8E; Tue, 14 Feb 2023 03:20:42 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 315D542DB8; Tue, 14 Feb 2023 03:19:42 +0100 (CET) Received: from mail-pg1-f169.google.com (mail-pg1-f169.google.com [209.85.215.169]) by mails.dpdk.org (Postfix) with ESMTP id 5498B42D6C for ; Tue, 14 Feb 2023 03:19:33 +0100 (CET) Received: by mail-pg1-f169.google.com with SMTP id u75so9341901pgc.10 for ; Mon, 13 Feb 2023 18:19:33 -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=hrpXSnSVNDgNeojAgOLo10m50yadvybRAllK/odJq1PS1fQM/cK6Sr+V0dJ0638q5f C2m7Y7oxnzNDTWQsHmHvExKQki32tkt2MVRsuaIRrLrQ0Ush5mUiWKcAaSeGCehTA6bx iVIkPog9CAO/7eLoXbapNPTxwUgpfyVxOhm4JVcNLa2GcT4vhgLSZ+gpZGbTQbj7O9cd /puwCsdaKceyWJlqUb03Lwu7yd7976/4d2SSjEtVyzghAAArlRGAqxUlg6Kq4fvh+fMZ ehuX9a+n/wbCUFVCeurnodaQ6+kuuKKUeoC7ZeJ4+6PDWzXgNoCAV9F6mKfLHzuWc+wr wKng== 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=p8Do/JcIkjdaXmpehdWMssz6Dteh1FwZb+a23ZxZWDvHdj5IqwYs9ImOSRrI4FBKZx QGoLUjIItQi61glnUQL3Zq8cP3ZoViviOZjGv83dGc4ye3/jJF7L0rKQ4MoaMScizJFh 8O0KQ8D3L7RThgmC+MI/Kk5bqTdKS/B9xjHviUwfDAmKN6cZQr68+a4uWg9YBnthhCRm ZFLd5u/acL6y8RyNbg+vQYtscA/38rUrUzFCm3K1qBXWgtO1rLe1Fulpab3evNicWKHH H3gdqcO4w4ASwWCUoSp2p1AIxmt0YzOm5y6wH6B86jESl8Mjom1I61jks7cgQTeQN4vp epJQ== X-Gm-Message-State: AO0yUKUkndOqsaz2kwFBOYL5PLJ35fbLrjJMAgF4rX7vSLPPNAE3Oqy/ LT2tD5hHjxOJ/2dQ0W6BOWjLzf7iZ0NW12JpI8M= X-Google-Smtp-Source: AK7set9n0x4AqdpBmskmpQZ8z4RKREV4cCov+pzOocOjnoQadAhuYE8l+n7BRNe+NaNKDUzfh/vgDQ== X-Received: by 2002:aa7:8bdb:0:b0:5a8:52d5:3bb9 with SMTP id s27-20020aa78bdb000000b005a852d53bb9mr641272pfd.10.1676341172379; Mon, 13 Feb 2023 18:19:32 -0800 (PST) Received: from hermes.local (204-195-120-218.wavecable.com. [204.195.120.218]) by smtp.gmail.com with ESMTPSA id e16-20020aa78250000000b005a75d85c0c7sm8494840pfn.51.2023.02.13.18.19.31 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 13 Feb 2023 18:19:31 -0800 (PST) From: Stephen Hemminger To: dev@dpdk.org Cc: Stephen Hemminger Subject: [PATCH v5 13/22] kni: replace RTE_LOGTYPE_KNI with dynamic type Date: Mon, 13 Feb 2023 18:18:59 -0800 Message-Id: <20230214021908.1396498-14-stephen@networkplumber.org> X-Mailer: git-send-email 2.39.1 In-Reply-To: <20230214021908.1396498-1-stephen@networkplumber.org> References: <20230207204151.1503491-1-stephen@networkplumber.org> <20230214021908.1396498-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