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 19709A04FF; Thu, 24 Mar 2022 06:31:33 +0100 (CET) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id A8EE941151; Thu, 24 Mar 2022 06:31:32 +0100 (CET) Received: from mail-wr1-f53.google.com (mail-wr1-f53.google.com [209.85.221.53]) by mails.dpdk.org (Postfix) with ESMTP id 238C7410FC for ; Thu, 24 Mar 2022 06:31:32 +0100 (CET) Received: by mail-wr1-f53.google.com with SMTP id u3so5030130wrg.3 for ; Wed, 23 Mar 2022 22:31:32 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=emumba-com.20210112.gappssmtp.com; s=20210112; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=8CWuYz/4nDkTOl1Bpo5+e7LvVJBZ7N3knuesuygi63k=; b=7LVicvbzx+hv6hj/baaq+hyJH2lZHtIFYwP7GVwXRRIot58+LIpC4aXVGnwYsP9uJm 7m836Z5XnKdBztwSG1Okq7F1lYgi/T3y5CN2mP0t/CaeuYTpct9qVOB5RpMD182m2LYq Lehw8o7lJgnLVN37wyMA5SKpzHBDYB+mreiTEIVa/TaROGY1ohmqpanBaPR6l9AOEr0T 1d/NqCO2uS9V/PGUpNoJzyuciclMJ4XOrIqSz79HeNtfWeQy94FJjaK43iR+kSN3xLlT izysxFDOjhdTIHBUlO/far4ION6i3qAoxfGSGzfhC7KNgqM7OZYC90YvRxxc9tBr7SHN 6Xxg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=8CWuYz/4nDkTOl1Bpo5+e7LvVJBZ7N3knuesuygi63k=; b=JYjD33o/8RjG6RxhlvD6j2saiXzaDzJbrQZLMUHdREPvhMaVOFLDNox+eUN2F2QECx r/VYabUy+esKvBIzzpDjGsgMZJhNLoGLXdBhQNaxn32twVEcrQSL4ysNMhJNSPoczjPS +uHnIOqSxNAKSO6y2rXKxYPfZ3qNM0RyB9IJkLyBop6OuNtgP1GKWvfujA0C/PtGUmHZ kg5zlgW/6ZgcUFm2/GEaywpypBxRCdLUBgdqGxG0/0j/NHgktVlEGDqZAn+6vT5so4S8 MBiAXgYVTUpUcsf0Ig5lHjT8/eLdrgBSyvi0opMA+QMDfnnb1iCfvhIN17jWl5byRbgC R2PA== X-Gm-Message-State: AOAM532XmqNIFHRkyOvNyDShwvWRgPNrAkVd9xWcQiQtwyJ6Z7O/eQr4 2vHjzmAemORnZoWUCQvfdIqK5VcoR0CQg7e9 X-Google-Smtp-Source: ABdhPJyL7ZN20kMbn6Rtvfi2BmjvIzmp74n0KKIskWui98Gt5ip7iSems0stMkvcvXQE8NjSY2CsxA== X-Received: by 2002:adf:ee0d:0:b0:203:d8d8:2183 with SMTP id y13-20020adfee0d000000b00203d8d82183mr2998901wrn.303.1648099891507; Wed, 23 Mar 2022 22:31:31 -0700 (PDT) Received: from localhost.localdomain ([182.188.119.184]) by smtp.gmail.com with ESMTPSA id l11-20020a5d674b000000b0020402c09067sm1557350wrw.50.2022.03.23.22.31.29 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 23 Mar 2022 22:31:31 -0700 (PDT) From: "huzaifa.rahman" To: dev@dpdk.org Cc: "huzaifa.rahman" Subject: [PATCH] ethtool: correct format strings according to the arguments Date: Thu, 24 Mar 2022 10:31:24 +0500 Message-Id: <20220324053124.8085-1-huzaifa.rahman@emumba.com> X-Mailer: git-send-email 2.25.1 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 The corrected format strings are not consistent with the given arguments. So they are changed accordingly. Signed-off-by: huzaifa.rahman --- examples/ethtool/ethtool-app/main.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/examples/ethtool/ethtool-app/main.c b/examples/ethtool/ethtool-app/main.c index 1f011a9321..ea8332e49c 100644 --- a/examples/ethtool/ethtool-app/main.c +++ b/examples/ethtool/ethtool-app/main.c @@ -208,7 +208,7 @@ static int worker_main(__rte_unused void *ptr_data) &ptr_port->mac_addr); if (ret != 0) { rte_spinlock_unlock(&ptr_port->lock); - printf("Failed to get MAC address (port %u): %s", + printf("Failed to get MAC address (port %i): %s", ptr_port->idx_port, rte_strerror(-ret)); return ret; @@ -284,11 +284,11 @@ int main(int argc, char **argv) rte_exit(EXIT_FAILURE, "rte_eal_init(): Failed"); cnt_ports = rte_eth_dev_count_avail(); - printf("Number of NICs: %i\n", cnt_ports); + printf("Number of NICs: %u\n", cnt_ports); if (cnt_ports == 0) rte_exit(EXIT_FAILURE, "No available NIC ports!\n"); if (cnt_ports > MAX_PORTS) { - printf("Info: Using only %i of %i ports\n", + printf("Info: Using only %u of %i ports\n", cnt_ports, MAX_PORTS ); cnt_ports = MAX_PORTS; -- 2.25.1