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 EF1A543066; Mon, 14 Aug 2023 18:31:58 +0200 (CEST) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 3ACA9432B6; Mon, 14 Aug 2023 18:31:42 +0200 (CEST) Received: from mail-pl1-f174.google.com (mail-pl1-f174.google.com [209.85.214.174]) by mails.dpdk.org (Postfix) with ESMTP id 01C75432AA for ; Mon, 14 Aug 2023 18:31:40 +0200 (CEST) Received: by mail-pl1-f174.google.com with SMTP id d9443c01a7336-1bdc510e981so15547325ad.2 for ; Mon, 14 Aug 2023 09:31:39 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=networkplumber-org.20221208.gappssmtp.com; s=20221208; t=1692030699; x=1692635499; 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=fNcvR3d+Xah/IBDLdHt1mxywfKv6Ei+qxoixbMYWsIU=; b=oK4ex43b/pmg90Mj9kTB/1PNteYuBwaMM1C7BmqDtjcl/Z5Kyk8X+qIAUlTm+TvXpj 52bDt6ZgbGlj9/yfot2fgS2EgzfRo+BNPpZJ2qHdkPHPGOYSmIuVCKcJREvaOXoxBCvV aSooMpxPbcf6RZhlYiqN7UOn9RUW4GBx65VtP1od3H/54kakCxcUN2afJ+LrbqkJNZiV 4Go17w5QndHMmzTBb2RWKXKcZG1PPoZVeXhtG2sHh/EJR5XWixuDMqzT3+RZ3AsobuOq vVz2QXvrGiNXCninZ7qKXTgtv+5YsV5PngZ79TI4rkZn2Mcm8O7qc1xTG4HgpS0/CqHQ tV8w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1692030699; x=1692635499; 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=fNcvR3d+Xah/IBDLdHt1mxywfKv6Ei+qxoixbMYWsIU=; b=SXD/cYJOm5wknL0wy/WgYrHPGZTerHPt+19cxFTvHHjfEQCr3B1g17tJHgFQF2b7+3 lM0kHU6rM6KvNgTVg8SvRdL+egYhDU5lbTEhTpnmKP99iWhdDlGm3b7XRn2s9nPbAFtd xyn6wVO2nATn29d9seEep1G2wOWIRBRLzBAV9u5cxO8F1V0jFSf7ad1K9AoeQR4LpIks 1fnxx5DArlbG1WAeA9uVnOAqOMIJodkaKjZ9ntpZnKGzXkEz3CiPOerc1pihH93gkdLJ /FalBGPFNXWMjT1bg6Q3dKCERL9zltlhlVaGD7zVOLP8FGl6ZOS0VqKJsNjMhcgGrNaj 7zcg== X-Gm-Message-State: AOJu0YwjFL0S9NvdKiP+LKOeqrf1JKVlx5xBDb7YiheV6W3ZFWvbfJhg XWZXUM1QvDII5EnbgkP2fKxJ0xndLHYcPuwEmMIiinnw600= X-Google-Smtp-Source: AGHT+IHogT5ZUJXjuNoIoQhcfQnw4lEnO5coRaY2xUX0K/VJx/ou+o+q9ib8HSCn3yDYwHVPXIlCOw== X-Received: by 2002:a17:903:18c:b0:1bb:a7bc:37a4 with SMTP id z12-20020a170903018c00b001bba7bc37a4mr12065365plg.24.1692030698963; Mon, 14 Aug 2023 09:31:38 -0700 (PDT) Received: from hermes.local (204-195-127-207.wavecable.com. [204.195.127.207]) by smtp.gmail.com with ESMTPSA id t10-20020a170902bc4a00b001bdd51748f8sm3892743plz.271.2023.08.14.09.31.38 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 14 Aug 2023 09:31:38 -0700 (PDT) From: Stephen Hemminger To: dev@dpdk.org Cc: Stephen Hemminger , reshma.pattan@intel.com, Harry van Haaren , Remy Horton Subject: [PATCH v8 3/6] latencystats: use dynamic logtype Date: Mon, 14 Aug 2023 09:31:22 -0700 Message-Id: <20230814163125.63033-4-stephen@networkplumber.org> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20230814163125.63033-1-stephen@networkplumber.org> References: <20230208044825.1682620-1-stephen@networkplumber.org> <20230814163125.63033-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 Libraries should not reuse RTE_LOGTYPE_USER1 for their logging. Instead they should register their own type. Fixes: 5cd3cac9ed22 ("latency: added new library for latency stats") Cc: reshma.pattan@intel.com Signed-off-by: Stephen Hemminger --- lib/latencystats/rte_latencystats.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lib/latencystats/rte_latencystats.c b/lib/latencystats/rte_latencystats.c index 8985a377db4e..f3c1746cca00 100644 --- a/lib/latencystats/rte_latencystats.c +++ b/lib/latencystats/rte_latencystats.c @@ -26,7 +26,8 @@ latencystat_cycles_per_ns(void) } /* Macros for printing using RTE_LOG */ -#define RTE_LOGTYPE_LATENCY_STATS RTE_LOGTYPE_USER1 +RTE_LOG_REGISTER_DEFAULT(latencystat_logtype, INFO); +#define RTE_LOGTYPE_LATENCY_STATS latencystat_logtype static uint64_t timestamp_dynflag; static int timestamp_dynfield_offset = -1; -- 2.39.2