From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dpdk.org (dpdk.org [92.243.14.124]) by inbox.dpdk.org (Postfix) with ESMTP id 21D0CA0540; Mon, 13 Jul 2020 10:16:45 +0200 (CEST) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 6D3B41D509; Mon, 13 Jul 2020 10:16:44 +0200 (CEST) Received: from us-smtp-delivery-1.mimecast.com (us-smtp-1.mimecast.com [205.139.110.61]) by dpdk.org (Postfix) with ESMTP id 3EBBD1D41A for ; Mon, 13 Jul 2020 10:16:42 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1594628201; 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: in-reply-to:in-reply-to:references:references; bh=HhnPf0K19EHyfbysTXb0oUz+V5vtHVzv+wb8gZ7lCcM=; b=GYw0K1hBudckNmciUMs9/RnYoTJ83jDe5tqW5jIlIc+/oqxQ0lI80VEKORM6+dvJ7IY2jr lsqdWGGOgFwCAAESTrPIKwjPTMThE5jhfG5dVX+CWNeW4PGWVWFpTeh433RlNhPplBg1ZR K5ywrtQCoJHc8FoEwPvr6KcnPAqu1a0= Received: from mail-ua1-f69.google.com (mail-ua1-f69.google.com [209.85.222.69]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-292-SvxuvdoDOsOZ1tdBuPl6WA-1; Mon, 13 Jul 2020 04:16:37 -0400 X-MC-Unique: SvxuvdoDOsOZ1tdBuPl6WA-1 Received: by mail-ua1-f69.google.com with SMTP id n4so6240043uaq.17 for ; Mon, 13 Jul 2020 01:16:37 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=HhnPf0K19EHyfbysTXb0oUz+V5vtHVzv+wb8gZ7lCcM=; b=mkkgza21AAxi6qyBLO+D7USkCvAhNLR1Wyb9I6z6TBmncFUOE3/JNn81B1oUoicMJD WlLz+1XE7g1+3v11dPPJL4uGBWRmvmoAJQuOzk4ELoAL0+0AaX1HrJO4pOfhJJxUj3N9 vSwII6nvP5DS2oKfIxFuMgFaRy9t4DRrvm9W9mbYsjyqsJs/JLltFxOCGZODzqFdi2m7 +ZKB/hshWPOOmmloqTIuth1xdK7Jv+ab3qgGHTFTfoliOBw4WLSutbCSqOWLh69n69lc KHhfB7bhIqmDSdoa02KvABwSA/UkW1K/G7YeBJj29zFmtwUnHMKTCARIamuVAIJ9Zu1p 98RQ== X-Gm-Message-State: AOAM532ITljbSQlLr7iP6kRDuiWh6eXGkuucclQ6rkopnixCdEQMDICx ekLfarFDmBl/v9wdwXlIqvR74PC/sJWS4sQkU+eC6vTg+O6WKNsJ756JQreol4W/2BLA/eg1HfP 9miRSAJ+eVqXo1CFz3Ic= X-Received: by 2002:ab0:2c3:: with SMTP id 61mr56320220uah.87.1594628197253; Mon, 13 Jul 2020 01:16:37 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzah0E/Uvg57YE4Ys0v1D/J9Ti29aFw/VtiELBpMbCavC8WuXQYISzsddX+7WcmCTJBXJXWVvzYs7h0VY+J6bk= X-Received: by 2002:ab0:2c3:: with SMTP id 61mr56320205uah.87.1594628196967; Mon, 13 Jul 2020 01:16:36 -0700 (PDT) MIME-Version: 1.0 References: <20200713062842.49166-1-chenxux.di@intel.com> In-Reply-To: <20200713062842.49166-1-chenxux.di@intel.com> From: David Marchand Date: Mon, 13 Jul 2020 10:16:26 +0200 Message-ID: To: Chenxu Di Cc: dev , Beilei Xing , Wenzhuo Lu X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Type: text/plain; charset="UTF-8" Subject: Re: [dpdk-dev] [PATCH] app/testpmd: fix display issue in flow query X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" On Mon, Jul 13, 2020 at 8:39 AM Chenxu Di wrote: > > This patch fix the error line break in the display info of flow query > > Fixes: bdb1d61690f7 ("app/testpmd: support RSS config in flow query") > > Signed-off-by: Chenxu Di > --- > app/test-pmd/config.c | 5 ++++- > 1 file changed, 4 insertions(+), 1 deletion(-) > > diff --git a/app/test-pmd/config.c b/app/test-pmd/config.c > index fcbe6b6f7..7b254e484 100644 > --- a/app/test-pmd/config.c > +++ b/app/test-pmd/config.c > @@ -1425,7 +1425,10 @@ rss_config_display(struct rte_flow_action_rss *rss_conf) > if (rss_conf->queue_num == 0) > printf("none\n"); > for (i = 0; i < rss_conf->queue_num; i++) > - printf("%d\n", rss_conf->queue[i]); > + if (i == rss_conf->queue_num - 1) > + printf("%d\n", rss_conf->queue[i]); > + else > + printf("%d ", rss_conf->queue[i]); > > printf(" function: "); > switch (rss_conf->func) { > -- > 2.17.1 > What do you think of this (untested) alternative? diff --git a/app/test-pmd/config.c b/app/test-pmd/config.c index fcbe6b6f74..30bee33248 100644 --- a/app/test-pmd/config.c +++ b/app/test-pmd/config.c @@ -1421,11 +1421,12 @@ rss_config_display(struct rte_flow_action_rss *rss_conf) } printf("RSS:\n" - " queues: "); + " queues:"); if (rss_conf->queue_num == 0) - printf("none\n"); + printf(" none"); for (i = 0; i < rss_conf->queue_num; i++) - printf("%d\n", rss_conf->queue[i]); + printf(" %d", rss_conf->queue[i]); + printf("\n"); printf(" function: "); switch (rss_conf->func) { -- David Marchand