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 58F0941C99; Tue, 14 Feb 2023 23:49:17 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 2C37F43022; Tue, 14 Feb 2023 23:48:11 +0100 (CET) Received: from mail-pj1-f43.google.com (mail-pj1-f43.google.com [209.85.216.43]) by mails.dpdk.org (Postfix) with ESMTP id 440C742FFE for ; Tue, 14 Feb 2023 23:48:03 +0100 (CET) Received: by mail-pj1-f43.google.com with SMTP id d2so16476467pjd.5 for ; Tue, 14 Feb 2023 14:48:03 -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=YisPMRv6Qin1K+phXCnHvrqkUajMjJ3DnP6a01V0gueT3U67qWitTJW3BQ3j3rJb/l wzNvh4qBLUcOubOv0lTGeUZeTrQ0s4vs1qignRmEuKkA1RHMdL694DpEzVxEjzwaXmN4 3mczBeAsc0kOBpMUagPI23PFGZHEYEKwwMav1gxBDzQjLK3RkcZ+sRnmJgoKUIBFy0ua 1aO5UHhq2PS/EXBtAmYnqlI/ADQKOIk+gup5Ew/qnMTSwDa1pCfbWnUsuTkNIgeefnG/ E+XEcug/JXP75+w4ujFN3RnXWqfz7hZFx1LbYZ5Sv+F/WMrD0+0KE0O5VN/yty1IQcbV PSAA== 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=l0loWAoNQd8/IV1eY/salioXTABG+hiKyFzn7BI4e1BpPT6sidFT5ay9C13465U4bn HJ+NzeGSrXzeZqpIG5CdSGRYCDalN4y201rFwFJyCOJFNENgSCf22Z2D6fBs0d/9ft7c qhKgwzbfvWJPFoDDgbDDxjhaKaF3lffJm1eoTrqMtrFkypycq9d2fV7TABiKtUAW8RSQ v5RZWWZ8mi7G/Y3FrQIMP/uTzx38DCtX4bVh4TTtQMFOyalSIfa5HspLaEsUtYwaawty O8qLSAWE7JQac+MfaBQSV1L4W0KNeCR6IHAnVjztaTaE777hFoMdyvt9pyNLyY+IN6wi tAVw== X-Gm-Message-State: AO0yUKXLIUcMakCF7/sPyFf30ooNOfA4RqWtN7NIqngFtlURpUFrFkjZ SDjvj4WdPbwN3ubgw3uPsaF6pWGtHpsC86X/5N4= X-Google-Smtp-Source: AK7set8SBNUkLnKVxbV+l49Sn2c+p6EUG3HqNaDhmLrCrTV4DtwF/dleycvQ+JeuhWeGW658od4MuA== X-Received: by 2002:a17:902:e40c:b0:19a:787e:87bc with SMTP id m12-20020a170902e40c00b0019a787e87bcmr222671ple.10.1676414882318; Tue, 14 Feb 2023 14:48:02 -0800 (PST) Received: from hermes.local (204-195-120-218.wavecable.com. [204.195.120.218]) by smtp.gmail.com with ESMTPSA id u9-20020a17090341c900b0019607984a5esm10735785ple.95.2023.02.14.14.48.01 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 14 Feb 2023 14:48:01 -0800 (PST) From: Stephen Hemminger To: dev@dpdk.org Cc: Stephen Hemminger Subject: [PATCH v6 13/22] kni: replace RTE_LOGTYPE_KNI with dynamic type Date: Tue, 14 Feb 2023 14:47:26 -0800 Message-Id: <20230214224735.1404326-14-stephen@networkplumber.org> X-Mailer: git-send-email 2.39.1 In-Reply-To: <20230214224735.1404326-1-stephen@networkplumber.org> References: <20230207204151.1503491-1-stephen@networkplumber.org> <20230214224735.1404326-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