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 11AA12C13 for ; Wed, 28 Jun 2017 17:50:37 +0200 (CEST) Received: from fmsmga001.fm.intel.com ([10.253.24.23]) by fmsmga102.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 28 Jun 2017 08:50:37 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.40,276,1496127600"; d="scan'208";a="1165700360" Received: from fyigit-mobl1.ger.corp.intel.com (HELO [10.237.220.91]) ([10.237.220.91]) by fmsmga001.fm.intel.com with ESMTP; 28 Jun 2017 08:50:36 -0700 To: Shreyansh Jain , dev@dpdk.org Cc: hemant.agrawal@nxp.com References: <1497591668-3320-1-git-send-email-shreyansh.jain@nxp.com> <1497591668-3320-37-git-send-email-shreyansh.jain@nxp.com> From: Ferruh Yigit Message-ID: <93a8a45b-01d1-608d-f3df-92551df6e476@intel.com> Date: Wed, 28 Jun 2017 16:50:35 +0100 User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:52.0) Gecko/20100101 Thunderbird/52.2.1 MIME-Version: 1.0 In-Reply-To: <1497591668-3320-37-git-send-email-shreyansh.jain@nxp.com> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 8bit Subject: Re: [dpdk-dev] [PATCH 36/38] net/dpaa: add support for checksum offload 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: Wed, 28 Jun 2017 15:50:38 -0000 On 6/16/2017 6:41 AM, Shreyansh Jain wrote: > Signed-off-by: Hemant Agrawal > Signed-off-by: Shreyansh Jain <...> > @@ -363,6 +439,18 @@ dpaa_eth_queue_tx(void *q, struct rte_mbuf **bufs, uint16_t nb_bufs) > } > rte_pktmbuf_free(mbuf); > } > + if (mbuf->ol_flags & DPAA_TX_CKSUM_OFFLOAD_MASK) { > + if (mbuf->data_off < DEFAULT_TX_ICEOF + > + sizeof(struct dpaa_eth_parse_results_t)) { > + PMD_DRV_LOG(DEBUG, "Checksum offload Err: " > + "Not enough Headroom " > + "space for correct Checksum offload." > + "So Calculating checksum in Software."); > + dpaa_checksum(mbuf); > + } else > + dpaa_checksum_offload(mbuf, &fd_arr[loop], > + mbuf->buf_addr); > + } There is a tx_pkt_prepare() dev_ops. Does it make sense to move this calculations to that function? > } else { > PMD_DRV_LOG(DEBUG, "Number of Segments not supported"); > /* Set frames_to_send & nb_bufs so that <...>