From patchwork Mon Dec 11 17:23:23 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Stephen Hemminger X-Patchwork-Id: 135042 X-Patchwork-Delegate: david.marchand@redhat.com Return-Path: X-Original-To: patchwork@inbox.dpdk.org Delivered-To: patchwork@inbox.dpdk.org Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id C6D7B436C8; Mon, 11 Dec 2023 18:24:56 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id C137A42D9F; Mon, 11 Dec 2023 18:24:50 +0100 (CET) Received: from mail-pg1-f170.google.com (mail-pg1-f170.google.com [209.85.215.170]) by mails.dpdk.org (Postfix) with ESMTP id 32729415D7 for ; Mon, 11 Dec 2023 18:24:49 +0100 (CET) Received: by mail-pg1-f170.google.com with SMTP id 41be03b00d2f7-5c68da9d639so2679046a12.3 for ; Mon, 11 Dec 2023 09:24:49 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=networkplumber-org.20230601.gappssmtp.com; s=20230601; t=1702315488; x=1702920288; 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=AdSOLFN0uWyvnObgF5SQIQtC2oO59IGu1ZJzjaCxHHo=; b=piS/E1mz8MgncGPlgSkumWgbeP1TtuR4Lo6JkCJ3/gK7/kbH0ujjDn6BVlqIHPPGEv CmW6sEWsqLXJX2IVYZUkvnEirSWKUfwET8UTBj2LobHFOoPwUOiSwyImfTeevdj1EA49 tdWlya06f5SP/LHCwNDzRZLVQ38VTOQ3GrcHFVUm2awH4NETLjHFgeLxiGfXLlLziRkl R9G9XRW270Y6HXc5pCrmKONnrMutdIFEsev2HR1bBnyjvwSce4dV0Q4LapyP9p52y1xx jRMZhA/CmrWlHZUWIQYl7irjtGpr7Bnysa3WYsDdYlJ3e2uHOnZ97etB5N7Q+ohs/QHF F7IA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1702315488; x=1702920288; 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=AdSOLFN0uWyvnObgF5SQIQtC2oO59IGu1ZJzjaCxHHo=; b=pmpuqB7Q/p5t850fgprZAJAZh+FqAJQaC6+vJXCt+SN67BbGgjVD/UHcW/rmCcVu/b LRrFnq6zi7SdqDWgbRltwt8EoPOGGMAKKdO0rwZUiWBImilLTbOj8jMUOyL9wnBSb3U6 qagC1oiuGq80IP+a67kfz27gmWRvFPs7maZHlxYWTdCvz4TB4CjCoRX4IGzFuPNIaXZj PLo9l+qAOGgqFXmeElLmqN5sBT/6RyrdlygLaZzMxyFU1aXty5Z0Ysxhup4db9ixgbAt wdBNeZANyRU+GgHpzUGUbTF5dDe9fJfFHrAiY5j1YUUqVxiUrjZ+/MJt8xsBuabLu3yD 1p2Q== X-Gm-Message-State: AOJu0YwJIv5k4pWtfwp2d4PhYTuszboOdV5TSFkKvutgW/OtE3eCXReS Q26dxWjZPfibiYrjLJ42txS6N2DHz3SBL/HXXO9bjQ== X-Google-Smtp-Source: AGHT+IE3OSGZTGbNbzMYVEj7VohlMVAxN3MBcqkiaiZ37h4meu6+vLGAP17fkdyF09Xp9hfcLcbJww== X-Received: by 2002:a05:6a20:a111:b0:190:17a6:24b7 with SMTP id q17-20020a056a20a11100b0019017a624b7mr2666450pzk.19.1702315488316; Mon, 11 Dec 2023 09:24:48 -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.47 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 11 Dec 2023 09:24:47 -0800 (PST) From: Stephen Hemminger To: dev@dpdk.org Cc: Stephen Hemminger , Aman Singh , Yuying Zhang Subject: [PATCH 1/3] testpmd: replace EAL logtype with fprintf Date: Mon, 11 Dec 2023 09:23:23 -0800 Message-ID: <20231211172437.61958-2-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 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 Testpmd is misusing EAL logtype for its own errors. Since the code directly calls fprintf in other places, change to use that everywhere. This has the added benefit of not having testpmd output clutter up syslog(). Signed-off-by: Stephen Hemminger Acked-by: Huisong Li --- app/test-pmd/testpmd.c | 33 +++++++++++---------------------- 1 file changed, 11 insertions(+), 22 deletions(-) diff --git a/app/test-pmd/testpmd.c b/app/test-pmd/testpmd.c index 9e4e99e53b9a..aa350d61e451 100644 --- a/app/test-pmd/testpmd.c +++ b/app/test-pmd/testpmd.c @@ -3413,8 +3413,7 @@ stop_port(portid_t pid) ret = eth_dev_stop_mp(pi); if (ret != 0) { - RTE_LOG(ERR, EAL, "rte_eth_dev_stop failed for port %u\n", - pi); + fprintf(stderr, "rte_eth_dev_stop failed for port %u\n", pi); /* Allow to retry stopping the port. */ port->port_status = RTE_PORT_STARTED; continue; @@ -3812,23 +3811,20 @@ pmd_test_exit(void) if (hot_plug) { ret = rte_dev_event_monitor_stop(); if (ret) { - RTE_LOG(ERR, EAL, - "fail to stop device event monitor."); + fprintf(stderr, "fail to stop device event monitor."); return; } ret = rte_dev_event_callback_unregister(NULL, dev_event_callback, NULL); if (ret < 0) { - RTE_LOG(ERR, EAL, - "fail to unregister device event callback.\n"); + fprintf(stderr, "fail to unregister device event callback.\n"); return; } ret = rte_dev_hotplug_handle_disable(); if (ret) { - RTE_LOG(ERR, EAL, - "fail to disable hotplug handling.\n"); + fprintf(stderr, "fail to disable hotplug handling.\n"); return; } } @@ -4062,12 +4058,10 @@ dev_event_callback(const char *device_name, enum rte_dev_event_type type, switch (type) { case RTE_DEV_EVENT_REMOVE: - RTE_LOG(DEBUG, EAL, "The device: %s has been removed!\n", - device_name); + fprintf(stderr, "The device: %s has been removed!\n", device_name); ret = rte_eth_dev_get_port_by_name(device_name, &port_id); if (ret) { - RTE_LOG(ERR, EAL, "can not get port by device %s!\n", - device_name); + fprintf(stderr, "Can not get port by device %s!\n", device_name); return; } /* @@ -4081,12 +4075,10 @@ dev_event_callback(const char *device_name, enum rte_dev_event_type type, */ if (rte_eal_alarm_set(100000, rmv_port_callback, (void *)(intptr_t)port_id)) - RTE_LOG(ERR, EAL, - "Could not set up deferred device removal\n"); + fprintf(stderr, "Could not set up deferred device removal\n"); break; case RTE_DEV_EVENT_ADD: - RTE_LOG(ERR, EAL, "The device: %s has been added!\n", - device_name); + fprintf(stderr, "The device: %s has been added!\n", device_name); /* TODO: After finish kernel driver binding, * begin to attach port. */ @@ -4632,23 +4624,20 @@ main(int argc, char** argv) if (hot_plug) { ret = rte_dev_hotplug_handle_enable(); if (ret) { - RTE_LOG(ERR, EAL, - "fail to enable hotplug handling."); + fprintf(stderr, "fail to enable hotplug handling."); return -1; } ret = rte_dev_event_monitor_start(); if (ret) { - RTE_LOG(ERR, EAL, - "fail to start device event monitoring."); + fprintf(stderr, "fail to start device event monitoring."); return -1; } ret = rte_dev_event_callback_register(NULL, dev_event_callback, NULL); if (ret) { - RTE_LOG(ERR, EAL, - "fail to register device event callback\n"); + fprintf(stderr, "fail to register device event callback\n"); return -1; } } From patchwork Mon Dec 11 17:23:24 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Stephen Hemminger X-Patchwork-Id: 135043 X-Patchwork-Delegate: david.marchand@redhat.com Return-Path: X-Original-To: patchwork@inbox.dpdk.org Delivered-To: patchwork@inbox.dpdk.org Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 30906436C8; Mon, 11 Dec 2023 18:25:03 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id AB65642DB6; Mon, 11 Dec 2023 18:24:51 +0100 (CET) Received: from mail-pf1-f180.google.com (mail-pf1-f180.google.com [209.85.210.180]) by mails.dpdk.org (Postfix) with ESMTP id D1E0242D7B for ; Mon, 11 Dec 2023 18:24:49 +0100 (CET) Received: by mail-pf1-f180.google.com with SMTP id d2e1a72fcca58-6ce6b62746dso2836586b3a.2 for ; Mon, 11 Dec 2023 09:24:49 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=networkplumber-org.20230601.gappssmtp.com; s=20230601; t=1702315489; x=1702920289; 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=25ZoFARyOPtyYoPI2e1WyYevGR77sAKqv+bkoIW2fRE=; b=JLAlTtcomAicZ1T0ThspN13FfjGIct9zz05LZQflSGdV05+hhwCU1Gf0iJO3BRmlNE 5vn3L9fMUeGQKsyH3rUffjdOstZE1kBWINKipgmAVYCmKhm3drvWSnomi11bD67ViulZ CnsAEG3Y2+Rpl2e8cKquG+RdmFekUxkSVumEjGS1qVtYa/XdHAf2rsvU9Dr8Fc+v71ns Sqf5RAIMpor0J+oYktiOtfW88tsY+NLY9WNYObz+3QnTG1I9xcRtPZP5v928R1wvSvWF WTXZ3AYh8uqY0LYGtk43Xyc54arU3eQU22N0Qbm125lP2cMcjgpcSDI60mAzW/sMD7zX RiIQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1702315489; x=1702920289; 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=25ZoFARyOPtyYoPI2e1WyYevGR77sAKqv+bkoIW2fRE=; b=HBvxbzK/865DISAhebRSmV1T1/ZvZOV1oEXITy9Z6RpOCOhXB8VZk7yBCFL1Y5Io10 skyKdjloWU6Br2locLCCFmvMXi4II94fkqhRsDci+yRSg6oDpgefzfismcq2ub0zGPpS yW5Eg2Me6rTzWCsBqUZKO0xRlYyaKIAS8lyy1fPHVZ+TVrRK6wzY1cwVkflT1VSfRpSs pOYRl5FSdzLrt+r3A1XiroYubl9pnSH7446Sv+nPyWGppu8HJjboxo5UUYyE9cmgMne5 CAGeGt7RItcwQIi4aT+uyHuqU3JrHeZMqPh5hNyesTKRc8N3/6LyARlgHffvjKQhvERw /RGg== X-Gm-Message-State: AOJu0Yx4hmDyYRdHud3Mz/gI4iQAOCEi/PjpKyAUfbJtGKzfhCXzTt0B 7qbUAMfgBkLSkqb06ImuUJ6yUz3nvwUpwngs9SQ2qg== X-Google-Smtp-Source: AGHT+IG2pHjwrkZpTGBwOEn0tdelUn0zS8W1wl+d/r2xggey/zn7gJ3ikUMHm9qe+crPEAvw95DvXQ== X-Received: by 2002:aa7:8502:0:b0:6ce:2731:d5cb with SMTP id v2-20020aa78502000000b006ce2731d5cbmr1949971pfn.60.1702315488983; Mon, 11 Dec 2023 09:24:48 -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.48 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 11 Dec 2023 09:24:48 -0800 (PST) From: Stephen Hemminger To: dev@dpdk.org Cc: Stephen Hemminger Subject: [PATCH 2/3] examples/l2fwd-keepalive: don't use EAL logtype Date: Mon, 11 Dec 2023 09:23:24 -0800 Message-ID: <20231211172437.61958-3-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 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 EAL logtype should be reserved for EAL library. This example is already using printf() so just print errors to stderr. Signed-off-by: Stephen Hemminger Acked-by: Huisong Li --- examples/l2fwd-keepalive/shm.c | 21 +++++++-------------- 1 file changed, 7 insertions(+), 14 deletions(-) diff --git a/examples/l2fwd-keepalive/shm.c b/examples/l2fwd-keepalive/shm.c index 7c7a9ea8ea3c..cbeeb511ef07 100644 --- a/examples/l2fwd-keepalive/shm.c +++ b/examples/l2fwd-keepalive/shm.c @@ -5,7 +5,6 @@ #include #include -#include #include #include "shm.h" @@ -28,28 +27,23 @@ struct rte_keepalive_shm *rte_keepalive_shm_create(void) fd = shm_open(RTE_KEEPALIVE_SHM_NAME, O_CREAT | O_TRUNC | O_RDWR, 0666); if (fd < 0) - RTE_LOG(INFO, EAL, - "Failed to open %s as SHM (%s)\n", - RTE_KEEPALIVE_SHM_NAME, - strerror(errno)); + fprintf(stderr, "Failed to open %s as SHM (%s)\n", + RTE_KEEPALIVE_SHM_NAME, strerror(errno)); else if (ftruncate(fd, sizeof(struct rte_keepalive_shm)) != 0) - RTE_LOG(INFO, EAL, - "Failed to resize SHM (%s)\n", strerror(errno)); + fprintf(stderr, "Failed to resize SHM (%s)\n", strerror(errno)); else { ka_shm = (struct rte_keepalive_shm *) mmap( 0, sizeof(struct rte_keepalive_shm), PROT_READ | PROT_WRITE, MAP_SHARED, fd, 0); close(fd); if (ka_shm == MAP_FAILED) - RTE_LOG(INFO, EAL, - "Failed to mmap SHM (%s)\n", strerror(errno)); + fprintf(stderr, "Failed to mmap SHM (%s)\n", strerror(errno)); else { memset(ka_shm, 0, sizeof(struct rte_keepalive_shm)); /* Initialize the semaphores for IPC/SHM use */ if (sem_init(&ka_shm->core_died, 1, 0) != 0) { - RTE_LOG(INFO, EAL, - "Failed to setup SHM semaphore (%s)\n", + fprintf(stderr, "Failed to setup SHM semaphore (%s)\n", strerror(errno)); munmap(ka_shm, sizeof(struct rte_keepalive_shm)); @@ -87,7 +81,7 @@ void rte_keepalive_relayed_state(struct rte_keepalive_shm *shm, * ka_agent is not active. */ if (sem_getvalue(&shm->core_died, &count) == -1) { - RTE_LOG(INFO, EAL, "Semaphore check failed(%s)\n", + fprintf(stderr, "Semaphore check failed(%s)\n", strerror(errno)); return; } @@ -95,8 +89,7 @@ void rte_keepalive_relayed_state(struct rte_keepalive_shm *shm, return; if (sem_post(&shm->core_died) != 0) - RTE_LOG(INFO, EAL, - "Failed to increment semaphore (%s)\n", + fprintf(stderr, "Failed to increment semaphore (%s)\n", strerror(errno)); } } From patchwork Mon Dec 11 17:23:25 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Stephen Hemminger X-Patchwork-Id: 135044 X-Patchwork-Delegate: david.marchand@redhat.com Return-Path: X-Original-To: patchwork@inbox.dpdk.org Delivered-To: patchwork@inbox.dpdk.org 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 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 Acked-by: David Hunt Acked-by: Huisong Li --- 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; }