From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dpdk.org (dpdk.org [92.243.14.124]) by dpdk.space (Postfix) with ESMTP id 00213A0471 for ; Thu, 20 Jun 2019 11:46:26 +0200 (CEST) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 2B4D61D0A2; Thu, 20 Jun 2019 11:46:26 +0200 (CEST) Received: from mx1.redhat.com (mx1.redhat.com [209.132.183.28]) by dpdk.org (Postfix) with ESMTP id 406EA1D07A; Thu, 20 Jun 2019 11:46:25 +0200 (CEST) Received: from smtp.corp.redhat.com (int-mx05.intmail.prod.int.phx2.redhat.com [10.5.11.15]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id ABB39308FBAC; Thu, 20 Jun 2019 09:46:24 +0000 (UTC) Received: from [10.36.112.46] (ovpn-112-46.ams2.redhat.com [10.36.112.46]) by smtp.corp.redhat.com (Postfix) with ESMTPS id BD6EF54529; Thu, 20 Jun 2019 09:46:23 +0000 (UTC) To: Fan Zhang , dev@dpdk.org Cc: stable@dpdk.org References: <20190515161948.70498-1-roy.fan.zhang@intel.com> From: Maxime Coquelin Message-ID: Date: Thu, 20 Jun 2019 11:46:22 +0200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.6.1 MIME-Version: 1.0 In-Reply-To: <20190515161948.70498-1-roy.fan.zhang@intel.com> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 7bit X-Scanned-By: MIMEDefang 2.79 on 10.5.11.15 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.43]); Thu, 20 Jun 2019 09:46:24 +0000 (UTC) Subject: Re: [dpdk-dev] [PATCH] vhost/crypto: fix logically dead code 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 5/15/19 6:19 PM, Fan Zhang wrote: > This patch fixes a few same class bugs that causes the > logically dead code in vhost_crypto. > > Coverity issue: 277236 > Coverity issue: 277233 > Coverity issue: 277220 > Coverity issue: 277214 > > Fixes: 3bb595ecd682 ("vhost/crypto: add request handler") > Cc: stable@dpdk.org > > Signed-off-by: Fan Zhang > --- > lib/librte_vhost/vhost_crypto.c | 4 ++-- > 1 file changed, 2 insertions(+), 2 deletions(-) > > diff --git a/lib/librte_vhost/vhost_crypto.c b/lib/librte_vhost/vhost_crypto.c > index 0edf12d52..069b56108 100644 > --- a/lib/librte_vhost/vhost_crypto.c > +++ b/lib/librte_vhost/vhost_crypto.c > @@ -1024,7 +1024,7 @@ prepare_sym_chain_op(struct vhost_crypto *vcrypto, struct rte_crypto_op *op, > } > if (unlikely(copy_data(rte_pktmbuf_mtod(m_src, uint8_t *), > vc_req, &desc, chain->para.src_data_len, > - nb_descs, vq_size)) < 0) { > + nb_descs, vq_size) < 0)) { > ret = VIRTIO_CRYPTO_BADMSG; > goto error_exit; > } > @@ -1598,7 +1598,7 @@ rte_vhost_crypto_fetch_requests(int vid, uint32_t qid, > op->sym->m_dst->data_off = 0; > > if (unlikely(vhost_crypto_process_one_req(vcrypto, vq, > - op, head, desc_idx)) < 0) > + op, head, desc_idx) < 0)) > break; > } > > Reviewed-by: Maxime Coquelin Thanks, Maxime