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 E8CC94541D; Thu, 13 Jun 2024 18:14:52 +0200 (CEST) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 7AF4D402E4; Thu, 13 Jun 2024 18:14:52 +0200 (CEST) Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) by mails.dpdk.org (Postfix) with ESMTP id 6F14A402CB for ; Thu, 13 Jun 2024 18:14:51 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1718295291; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=M35gY3V6IyIIjOZk7YeuDqLLS+9VtcGTfE+/a8jh4/I=; b=L9utWoC+hF+Ubdv1+H+MuWhn1TNWlypTk/DNbmSHtkFV6NuWZ19oFpzOewXkWSz3RZnsOY Bm2Qg96UUt33Pp7vXWKWgUKrCtZYGFCpOKJ0Rc5v1nnBJHoWRxRy35EGZiWEH+j4vr00nb Em4EwZwtPQtwu20+zBh72vbUvzNe9LI= Received: from mx-prod-mc-03.mail-002.prod.us-west-2.aws.redhat.com (ec2-54-186-198-63.us-west-2.compute.amazonaws.com [54.186.198.63]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-96-d7rRZ4UlOICMoz8QAgmYdw-1; Thu, 13 Jun 2024 12:14:46 -0400 X-MC-Unique: d7rRZ4UlOICMoz8QAgmYdw-1 Received: from mx-prod-int-02.mail-002.prod.us-west-2.aws.redhat.com (mx-prod-int-02.mail-002.prod.us-west-2.aws.redhat.com [10.30.177.15]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by mx-prod-mc-03.mail-002.prod.us-west-2.aws.redhat.com (Postfix) with ESMTPS id 18E7319560B8; Thu, 13 Jun 2024 16:14:45 +0000 (UTC) Received: from rh.redhat.com (unknown [10.39.192.36]) by mx-prod-int-02.mail-002.prod.us-west-2.aws.redhat.com (Postfix) with ESMTP id DAA231954AC1; Thu, 13 Jun 2024 16:14:36 +0000 (UTC) From: Kevin Traynor To: dev@dpdk.org Cc: david.marchand@redhat.com, Kevin Traynor , Tyler Retzlaff , Anatoly Burakov , Bruce Richardson , Marko Kovacevic Subject: [PATCH] eal: fix logs for '--lcores' Date: Thu, 13 Jun 2024 17:14:29 +0100 Message-ID: <20240613161429.168287-1-ktraynor@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 3.0 on 10.30.177.15 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Transfer-Encoding: 8bit Content-Type: text/plain; charset="US-ASCII"; x-default=true 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 The argument is '--lcores' but it is being logged as '--lcore' in several places. e.g. $ dpdk-testpmd -l 8,10,12 --lcores 8,10,12 EAL: Option --lcore is ignored, because (-l) is set! Fix the spelling in logs and tests. Fixes: 117eaa70584b ("eal: add error check for core options") Signed-off-by: Kevin Traynor --- app/test/test_eal_flags.c | 2 +- lib/eal/common/eal_common_options.c | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/app/test/test_eal_flags.c b/app/test/test_eal_flags.c index 6cb4b06757..71d8dba731 100644 --- a/app/test/test_eal_flags.c +++ b/app/test/test_eal_flags.c @@ -672,5 +672,5 @@ test_missing_c_flag(void) launch_proc(argv28) == 0 || launch_proc(argv30) == 0) { printf("Error - " - "process ran without error with invalid --lcore flag\n"); + "process ran without error with invalid --lcores flag\n"); return -1; } diff --git a/lib/eal/common/eal_common_options.c b/lib/eal/common/eal_common_options.c index e541f07939..f1a5e329a5 100644 --- a/lib/eal/common/eal_common_options.c +++ b/lib/eal/common/eal_common_options.c @@ -1688,5 +1688,5 @@ eal_parse_common_option(int opt, const char *optarg, EAL_LOG(ERR, "Option -c is ignored, because (%s) is set!", (core_parsed == LCORE_OPT_LST) ? "-l" : - (core_parsed == LCORE_OPT_MAP) ? "--lcore" : + (core_parsed == LCORE_OPT_MAP) ? "--lcores" : "-c"); return -1; @@ -1721,5 +1721,5 @@ eal_parse_common_option(int opt, const char *optarg, EAL_LOG(ERR, "Option -l is ignored, because (%s) is set!", (core_parsed == LCORE_OPT_MSK) ? "-c" : - (core_parsed == LCORE_OPT_MAP) ? "--lcore" : + (core_parsed == LCORE_OPT_MAP) ? "--lcores" : "-l"); return -1; @@ -1902,8 +1902,8 @@ eal_parse_common_option(int opt, const char *optarg, if (core_parsed) { - EAL_LOG(ERR, "Option --lcore is ignored, because (%s) is set!", + EAL_LOG(ERR, "Option --lcores is ignored, because (%s) is set!", (core_parsed == LCORE_OPT_LST) ? "-l" : (core_parsed == LCORE_OPT_MSK) ? "-c" : - "--lcore"); + "--lcores"); return -1; } -- 2.45.0