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 EF4FE436C8; Mon, 11 Dec 2023 18:25:09 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id ACEA242DBE; Mon, 11 Dec 2023 18:24:52 +0100 (CET) Received: from mail-pg1-f171.google.com (mail-pg1-f171.google.com [209.85.215.171]) by mails.dpdk.org (Postfix) with ESMTP id 80A5242D95 for ; Mon, 11 Dec 2023 18:24:50 +0100 (CET) Received: by mail-pg1-f171.google.com with SMTP id 41be03b00d2f7-5c701bd9a3cso759424a12.0 for ; Mon, 11 Dec 2023 09:24:50 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=networkplumber-org.20230601.gappssmtp.com; s=20230601; t=1702315490; x=1702920290; darn=dpdk.org; 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=oMNS7zGLE/YNoxn7ndPcHRk5tzoRrQzhfWcHywJyY2s=; b=cnTtKYuRPNvO96Gi+GduPCFjWEf5k/2FPIAGVk+dZUnoZtbWjhzBuCgGZ1HRKMxdYH uKtYz2vwDgCLAnGqJcdREXlTBlybJ4ktdAk5OuTJKkmRPtneCZgmv13eqZwziFJXf+lq EbGt9uCSeu0QjqSHbTlOVswv3mTCHAzUjlf2GH0Tqpm5VltQvr5bOfIrIanzwA4djsAd LYeyU1uIsu5Md9yYcNBz/IfSA3egCtFPFM6UoEWaWVNbmAW5qLteLIPxfOBTynoVGJnF sTU5lXB8JtEjWrMgaXuaOF0VZdwbkQXQaar0wVLp5dpaNg3kb4SebrK/epMLpZ4/tte7 R1fA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1702315490; x=1702920290; 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=oMNS7zGLE/YNoxn7ndPcHRk5tzoRrQzhfWcHywJyY2s=; b=q3z/shYOnzdRAy5V6z6r+IlwnxkLp8wMx7pD74Gvl478gpreEbY4hv+BFVqOa+7wCp LOjOutPgwN0mkb7zUrriG7zPU2c+oJnfEmra2ZZVKq4Rq1YiGO2ssdmP9fsIUC0YbpPP jlqAPuCQ8UVqBRQ/wl+mgdsXYCV2sGrcqjSJuxSgObvKMlrrxHnNGNmzStWElWZCwbs/ DCusn3/2HEkw/pWTaFT/RJjBOcTq04N4lTOxsCaZ3KQ02EgmUP96QA6VZLiAl6nePSvK FGyim1NC6Jlg0kp64NOtws2GOYb4lGuSBrC4qegUIut180+0IBjdK4RKQtLcK33oMfZw NuGg== X-Gm-Message-State: AOJu0Yyeuq/A3p6zbByHYWqIjMWFfC21QC1SpdbXux2JcqKdy0ftXgqR 6Th1jQcNVbgYnhmHLnV+GC6VZF4lnXAIWFpTxORMcg== X-Google-Smtp-Source: AGHT+IFfqR4bMG5hNPVq1yWrhQXR3qNsEUkdzjvyNYZMO1LrOTi0MdYtENxNFQMQAvedEomKelHjJQ== X-Received: by 2002:a05:6a20:6d9e:b0:190:665b:f789 with SMTP id gl30-20020a056a206d9e00b00190665bf789mr1869629pzb.83.1702315489739; Mon, 11 Dec 2023 09:24:49 -0800 (PST) Received: from hermes.local (204-195-123-141.wavecable.com. [204.195.123.141]) by smtp.gmail.com with ESMTPSA id f16-20020aa782d0000000b006ce6878b274sm6494425pfn.216.2023.12.11.09.24.49 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 11 Dec 2023 09:24:49 -0800 (PST) From: Stephen Hemminger To: dev@dpdk.org Cc: Stephen Hemminger , Anatoly Burakov , David Hunt , Sivaprasad Tummala Subject: [PATCH 3/3] examples/vm_power_manager: do not use EAL logtype Date: Mon, 11 Dec 2023 09:23:25 -0800 Message-ID: <20231211172437.61958-4-stephen@networkplumber.org> X-Mailer: git-send-email 2.42.0 In-Reply-To: <20231211172437.61958-1-stephen@networkplumber.org> References: <20231211172437.61958-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 Be consistent for all the error printouts and use fprintf(). The EAL logtype is reserved for internal use by EAL. Signed-off-by: Stephen Hemminger --- examples/vm_power_manager/main.c | 11 ++++------- 1 file changed, 4 insertions(+), 7 deletions(-) diff --git a/examples/vm_power_manager/main.c b/examples/vm_power_manager/main.c index b159291d77ce..c14138202004 100644 --- a/examples/vm_power_manager/main.c +++ b/examples/vm_power_manager/main.c @@ -17,7 +17,6 @@ #include #include #include -#include #include #include #include @@ -425,8 +424,7 @@ main(int argc, char **argv) lcore_id = rte_get_next_lcore(-1, 1, 0); if (lcore_id == RTE_MAX_LCORE) { - RTE_LOG(ERR, EAL, "A minimum of three cores are required to run " - "application\n"); + fprintf(stderr, "A minimum of three cores are required to run application\n"); return 0; } printf("Running channel monitor on lcore id %d\n", lcore_id); @@ -434,16 +432,15 @@ main(int argc, char **argv) lcore_id = rte_get_next_lcore(lcore_id, 1, 0); if (lcore_id == RTE_MAX_LCORE) { - RTE_LOG(ERR, EAL, "A minimum of three cores are required to run " - "application\n"); + fprintf(stderr, "A minimum of three cores are required to run application\n"); return 0; } if (power_manager_init() < 0) { - printf("Unable to initialize power manager\n"); + fprintf(stderr, "Unable to initialize power manager\n"); return -1; } if (channel_manager_init(CHANNEL_MGR_DEFAULT_HV_PATH) < 0) { - printf("Unable to initialize channel manager\n"); + fprintf(stderr, "Unable to initialize channel manager\n"); return -1; } -- 2.42.0