From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-pf0-f169.google.com (mail-pf0-f169.google.com [209.85.192.169]) by dpdk.org (Postfix) with ESMTP id 25E282BD8 for ; Thu, 1 Jun 2017 00:52:23 +0200 (CEST) Received: by mail-pf0-f169.google.com with SMTP id m17so19788372pfg.3 for ; Wed, 31 May 2017 15:52:23 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=networkplumber-org.20150623.gappssmtp.com; s=20150623; h=date:from:to:cc:subject:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=dOGNID/H/+pGVjrmJowB950p8h56ua3EUboMOEOFSk0=; b=UMdVOA08E7/7jy4qmuUJh1e8HcUdzRAcSeKWnmHf5Yo1CndAVZlFzcKncjzKOzw3i1 Qv37d2psBo0KjdZPtVqAB9O27o837EFxBExtGzxcJ67BZ5hwMHr8CM6ZoTNn7siQyGNx +J8StkLKxL40LnU9xjWdAhQEQf4EkRSVEi+SdHaUQayJ2tkDA7sMeIheSusrT6OB4z4b +ohykjUUsZ9zvMQtdhY/GdFX5TMniSf7wSh/F6GZtNKrX4jMCW0oA657K4It5hcrPDW2 47h/CjZH5N3+1mLU4Nf86zv8pvJqB6YVhz6MeYOnq+7U8ygS/upLpOsh7E3c/lCg12/V euOQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=dOGNID/H/+pGVjrmJowB950p8h56ua3EUboMOEOFSk0=; b=IAVq8lE9zBk8n2BJZ5PXtVI2Z3+3kNwy6bfebU+01mPAkreAuoD0STVeRPofV3KPoZ JF8TYCoX2+neP8neMIpDqLeQazsCo8OA8G1ny5OFI6/0yfsSDUrSIOYi0uMofW2P2rSt 8ubtnrFIM2k1NSDSVluFDxdp0eOYsWMr96TD0NQtLNzbg1eSA705TFur6YorXr9BUIZ1 s7xjUrP1kcpEUrjZKlRZNzPRUm1AiHnbJZpvo07ASb5Dr+2djSjG86b590AoYtly3L11 zo5JDX/aavUCHNtp8gpkyVDveYvoNEchVz2tbCItYVnXdtgIisiX+YEthpkDMS+tCaVP Sbow== X-Gm-Message-State: AODbwcAlHgKSMRbRfsjlbQgK5jq54QGQG63ed9N+mcEWiUTm5WONQb9B 0kGez1jeF6zEyjf3 X-Received: by 10.98.218.72 with SMTP id w8mr32784837pfl.155.1496271143123; Wed, 31 May 2017 15:52:23 -0700 (PDT) Received: from xeon-e3 (76-14-207-240.or.wavecable.com. [76.14.207.240]) by smtp.gmail.com with ESMTPSA id y5sm26259745pgb.4.2017.05.31.15.52.22 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Wed, 31 May 2017 15:52:23 -0700 (PDT) Date: Wed, 31 May 2017 15:52:14 -0700 From: Stephen Hemminger To: Pablo de Lara Cc: declan.doherty@intel.com, dev@dpdk.org, stable@dpdk.org Message-ID: <20170531155214.3758e616@xeon-e3> In-Reply-To: <20170531134443.39911-1-pablo.de.lara.guarch@intel.com> References: <20170531134443.39911-1-pablo.de.lara.guarch@intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Subject: Re: [dpdk-stable] [dpdk-dev] [PATCH] crypto/aesni_mb: fix assert check 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: , X-List-Received-Date: Wed, 31 May 2017 22:52:24 -0000 On Wed, 31 May 2017 14:44:43 +0100 Pablo de Lara wrote: > Fixes: 0f548b50a160 ("crypto/aesni_mb: process crypto op on dequeue") > CC: stable@dpdk.org > > Signed-off-by: Pablo de Lara > --- > drivers/crypto/aesni_mb/rte_aesni_mb_pmd.c | 4 ++-- > 1 file changed, 2 insertions(+), 2 deletions(-) > > diff --git a/drivers/crypto/aesni_mb/rte_aesni_mb_pmd.c b/drivers/crypto/aesni_mb/rte_aesni_mb_pmd.c > index 45b25c9..dde60c0 100644 > --- a/drivers/crypto/aesni_mb/rte_aesni_mb_pmd.c > +++ b/drivers/crypto/aesni_mb/rte_aesni_mb_pmd.c > @@ -494,7 +494,7 @@ static inline void > verify_digest(JOB_AES_HMAC *job, struct rte_crypto_op *op) { > struct rte_mbuf *m_dst = (struct rte_mbuf *)job->user_data2; > > - RTE_ASSERT(m_dst == NULL); > + RTE_ASSERT(m_dst != NULL); > > /* Verify digest if required */ > if (memcmp(job->auth_tag_output, op->sym->auth.digest.data, > @@ -522,7 +522,7 @@ post_process_mb_job(struct aesni_mb_qp *qp, JOB_AES_HMAC *job) > > struct aesni_mb_session *sess; > > - RTE_ASSERT(op == NULL); > + RTE_ASSERT(op != NULL); > > if (unlikely(op->status == RTE_CRYPTO_OP_STATUS_ENQUEUED)) { > switch (job->status) { These kind of asserts are actually meaningless. In real world, it really doesn't matter if application panics because of assert (sigabort) or because of segfault on null pointer dereference. In either case it causes a crash. If you have built in a real signal handler and backtracing, or enabled core dumps then data is available. If not then the application just dies.