From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga09.intel.com (mga09.intel.com [134.134.136.24]) by dpdk.org (Postfix) with ESMTP id D1C847F74 for ; Thu, 20 Nov 2014 11:39:41 +0100 (CET) Received: from orsmga002.jf.intel.com ([10.7.209.21]) by orsmga102.jf.intel.com with ESMTP; 20 Nov 2014 02:47:56 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.07,423,1413270000"; d="scan'208";a="640333323" Received: from irvmail001.ir.intel.com ([163.33.26.43]) by orsmga002.jf.intel.com with ESMTP; 20 Nov 2014 02:50:08 -0800 Received: from sivswdev02.ir.intel.com (sivswdev02.ir.intel.com [10.237.217.46]) by irvmail001.ir.intel.com (8.14.3/8.13.6/MailSET/Hub) with ESMTP id sAKAo7dP009998 for ; Thu, 20 Nov 2014 10:50:07 GMT Received: from sivswdev02.ir.intel.com (localhost [127.0.0.1]) by sivswdev02.ir.intel.com with ESMTP id sAKAo7hd005234 for ; Thu, 20 Nov 2014 10:50:07 GMT Received: (from pdelarax@localhost) by sivswdev02.ir.intel.com with id sAKAo7K3005230 for dev@dpdk.org; Thu, 20 Nov 2014 10:50:07 GMT From: Pablo de Lara To: dev@dpdk.org Date: Thu, 20 Nov 2014 10:50:07 +0000 Message-Id: <1416480607-5198-1-git-send-email-pablo.de.lara.guarch@intel.com> X-Mailer: git-send-email 1.7.4.1 Subject: [dpdk-dev] [PATCH] examples/dpdk_qat: Fix reference to old mbuf field "data" X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: patches and discussions about DPDK List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 20 Nov 2014 10:39:42 -0000 DPDK QAT app was using the old "data" field in mbuf, so it has been subtituted with rte_pktmbuf_mtod function. Signed-off-by: Pablo de Lara --- examples/dpdk_qat/crypto.c | 6 +++--- 1 files changed, 3 insertions(+), 3 deletions(-) diff --git a/examples/dpdk_qat/crypto.c b/examples/dpdk_qat/crypto.c index 318d47c..f49408a 100644 --- a/examples/dpdk_qat/crypto.c +++ b/examples/dpdk_qat/crypto.c @@ -183,7 +183,7 @@ struct glob_keys g_crypto_hash_keys = { * */ #define PACKET_DATA_START_PHYS(p) \ - ((p)->buf_physaddr + ((char *)p->data - (char *)p->buf_addr)) + ((p)->buf_physaddr + (p)->data_off) /* * A fixed offset to where the crypto is to be performed, which is the first @@ -773,7 +773,7 @@ enum crypto_result crypto_encrypt(struct rte_mbuf *rte_buff, enum cipher_alg c, enum hash_alg h) { CpaCySymDpOpData *opData = - (CpaCySymDpOpData *) ((char *) (rte_buff->data) + (CpaCySymDpOpData *) (rte_pktmbuf_mtod(rte_buff, char *) + CRYPTO_OFFSET_TO_OPDATA); uint32_t lcore_id; @@ -848,7 +848,7 @@ enum crypto_result crypto_decrypt(struct rte_mbuf *rte_buff, enum cipher_alg c, enum hash_alg h) { - CpaCySymDpOpData *opData = (void*) (((char *) rte_buff->data) + CpaCySymDpOpData *opData = (void*) (rte_pktmbuf_mtod(rte_buff, char *) + CRYPTO_OFFSET_TO_OPDATA); uint32_t lcore_id; -- 1.7.4.1