From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga11.intel.com (mga11.intel.com [192.55.52.93]) by dpdk.org (Postfix) with ESMTP id 74C8A2C5 for ; Tue, 31 Jul 2018 13:08:57 +0200 (CEST) X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from orsmga004.jf.intel.com ([10.7.209.38]) by fmsmga102.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 31 Jul 2018 04:08:53 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.51,427,1526367600"; d="scan'208";a="220545121" Received: from silpixa00399501.ir.intel.com ([10.237.223.69]) by orsmga004.jf.intel.com with ESMTP; 31 Jul 2018 04:08:52 -0700 From: Lee Daly To: pablo.de.lara.guarch@intel.com Cc: dev@dpdk.org, Lee Daly Date: Tue, 31 Jul 2018 12:08:36 +0100 Message-Id: <1533035316-63812-1-git-send-email-lee.daly@intel.com> X-Mailer: git-send-email 2.7.4 Subject: [dpdk-dev] [PATCH] compress/isal: fixes offset check 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: , X-List-Received-Date: Tue, 31 Jul 2018 11:08:57 -0000 This commit fixes an offset check in decompression which was checking destination offset size against dst data_len rather than checking against dst pkt_len as required. Fixes:788e748d3845 ("compress/isal: support chained mbufs") Signed-off-by: Lee Daly --- drivers/compress/isal/isal_compress_pmd.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/compress/isal/isal_compress_pmd.c b/drivers/compress/isal/isal_compress_pmd.c index e75f48d..aef56e3 100644 --- a/drivers/compress/isal/isal_compress_pmd.c +++ b/drivers/compress/isal/isal_compress_pmd.c @@ -483,7 +483,7 @@ process_isal_inflate(struct rte_comp_op *op, struct isal_comp_qp *qp) return -1; } - if (op->dst.offset > op->m_dst->data_len) { + if (op->dst.offset > op->m_dst->pkt_len) { ISAL_PMD_LOG(ERR, "Output mbuf not big enough for length and " "offset provided.\n"); op->status = RTE_COMP_OP_STATUS_INVALID_ARGS; -- 2.7.4