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 E25DBA0093 for ; Thu, 28 May 2020 18:25:54 +0200 (CEST) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id D94191DC10; Thu, 28 May 2020 18:25:54 +0200 (CEST) Received: from us-smtp-1.mimecast.com (us-smtp-delivery-1.mimecast.com [207.211.31.120]) by dpdk.org (Postfix) with ESMTP id 8AE241DC18 for ; Thu, 28 May 2020 18:25:53 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1590683153; 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: in-reply-to:in-reply-to:references:references; bh=Qt6pVeOxLnZ3FmoXj28dGxF2OL14Rxtoeerv+Q7tSy8=; b=UYIrbzQ+I8NHOr4BE9in098JfWqpdrlm2whO/NuRm5iRC7piFSCbWt/jjZOXew0ZOmkhEm QwL6r/O7hBDbVm8BmJGLIMN8sZojj+OgHBdB95SD4nS1IxOEqSbGPToSV1kFs9u3KqW+s5 Sx9/r4PRI/sQln4xs6dYwfv7Tbrk2yI= Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-109-amFzyaq-OFiOa1_RzLab8A-1; Thu, 28 May 2020 12:25:49 -0400 X-MC-Unique: amFzyaq-OFiOa1_RzLab8A-1 Received: from smtp.corp.redhat.com (int-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.12]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id 6A6ED108BD0F; Thu, 28 May 2020 16:25:48 +0000 (UTC) Received: from rh.redhat.com (unknown [10.33.36.235]) by smtp.corp.redhat.com (Postfix) with ESMTP id B0C7660C05; Thu, 28 May 2020 16:25:47 +0000 (UTC) From: Kevin Traynor To: Ferruh Yigit Cc: dpdk stable Date: Thu, 28 May 2020 17:22:58 +0100 Message-Id: <20200528162322.7863-71-ktraynor@redhat.com> In-Reply-To: <20200528162322.7863-1-ktraynor@redhat.com> References: <20200528162322.7863-1-ktraynor@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.12 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 8bit Subject: [dpdk-stable] patch 'net/null: remove redundant check' has been queued to LTS release 18.11.9 X-BeenThere: stable@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: patches for DPDK stable branches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: stable-bounces@dpdk.org Sender: "stable" Hi, FYI, your patch has been queued to LTS release 18.11.9 Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet. It will be pushed if I get no objections before 06/03/20. So please shout if anyone has objections. Also note that after the patch there's a diff of the upstream commit vs the patch applied to the branch. This will indicate if there was any rebasing needed to apply to the stable branch. If there were code changes for rebasing (ie: not only metadata diffs), please double check that the rebase was correctly done. Queued patches are on a temporary branch at: https://github.com/kevintraynor/dpdk-stable-queue This queued commit can be viewed at: https://github.com/kevintraynor/dpdk-stable-queue/commit/4fcd7720f7e126eb36ee1367956e184f5f44cac2 Thanks. Kevin. --- >From 4fcd7720f7e126eb36ee1367956e184f5f44cac2 Mon Sep 17 00:00:00 2001 From: Ferruh Yigit Date: Mon, 2 Mar 2020 17:36:42 +0000 Subject: [PATCH] net/null: remove redundant check [ upstream commit c21a276bd8f3d4c5210ccd2074f7a87a7d00b3e4 ] There is no need to check if the argument exist or not, `rte_kvargs_process` returns success if the argument is not provided at all. Fixes: c743e50c475f ("null: new poll mode driver") Signed-off-by: Ferruh Yigit --- drivers/net/null/rte_eth_null.c | 25 ++++++++++--------------- 1 file changed, 10 insertions(+), 15 deletions(-) diff --git a/drivers/net/null/rte_eth_null.c b/drivers/net/null/rte_eth_null.c index 95314982c3..1de26b0f69 100644 --- a/drivers/net/null/rte_eth_null.c +++ b/drivers/net/null/rte_eth_null.c @@ -640,21 +640,16 @@ rte_pmd_null_probe(struct rte_vdev_device *dev) return -1; - if (rte_kvargs_count(kvlist, ETH_NULL_PACKET_SIZE_ARG) == 1) { + ret = rte_kvargs_process(kvlist, + ETH_NULL_PACKET_SIZE_ARG, + &get_packet_size_arg, &packet_size); + if (ret < 0) + goto free_kvlist; - ret = rte_kvargs_process(kvlist, - ETH_NULL_PACKET_SIZE_ARG, - &get_packet_size_arg, &packet_size); - if (ret < 0) - goto free_kvlist; - } - if (rte_kvargs_count(kvlist, ETH_NULL_PACKET_COPY_ARG) == 1) { - - ret = rte_kvargs_process(kvlist, - ETH_NULL_PACKET_COPY_ARG, - &get_packet_copy_arg, &packet_copy); - if (ret < 0) - goto free_kvlist; - } + ret = rte_kvargs_process(kvlist, + ETH_NULL_PACKET_COPY_ARG, + &get_packet_copy_arg, &packet_copy); + if (ret < 0) + goto free_kvlist; } -- 2.21.3 --- Diff of the applied patch vs upstream commit (please double-check if non-empty: --- --- - 2020-05-28 17:13:02.768601162 +0100 +++ 0071-net-null-remove-redundant-check.patch 2020-05-28 17:12:59.152555246 +0100 @@ -1 +1 @@ -From c21a276bd8f3d4c5210ccd2074f7a87a7d00b3e4 Mon Sep 17 00:00:00 2001 +From 4fcd7720f7e126eb36ee1367956e184f5f44cac2 Mon Sep 17 00:00:00 2001 @@ -5,0 +6,2 @@ +[ upstream commit c21a276bd8f3d4c5210ccd2074f7a87a7d00b3e4 ] + @@ -11 +12,0 @@ -Cc: stable@dpdk.org @@ -19 +20 @@ -index 87a29b8535..beedd5f4b2 100644 +index 95314982c3..1de26b0f69 100644 @@ -22 +23 @@ -@@ -611,21 +611,16 @@ rte_pmd_null_probe(struct rte_vdev_device *dev) +@@ -640,21 +640,16 @@ rte_pmd_null_probe(struct rte_vdev_device *dev)