From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from smtp-outbound-1.vmware.com (smtp-outbound-1.vmware.com [208.91.2.12]) by dpdk.org (Postfix) with ESMTP id EA6BF91F1 for ; Tue, 5 Jan 2016 03:37:58 +0100 (CET) Received: from sc9-mailhost3.vmware.com (sc9-mailhost3.vmware.com [10.113.161.73]) by smtp-outbound-1.vmware.com (Postfix) with ESMTP id EB19328FD5; Mon, 4 Jan 2016 18:37:56 -0800 (PST) Received: from prmh-edge-ivybridge-01.eng.vmware.com (unknown [10.24.235.72]) by sc9-mailhost3.vmware.com (Postfix) with ESMTP id E6207405C8; Mon, 4 Jan 2016 18:37:56 -0800 (PST) From: Yong Wang To: dev@dpdk.org Date: Mon, 4 Jan 2016 18:28:19 -0800 Message-Id: <1451960899-26881-5-git-send-email-yongwang@vmware.com> X-Mailer: git-send-email 1.9.1 In-Reply-To: <1451960899-26881-1-git-send-email-yongwang@vmware.com> References: <1451960899-26881-1-git-send-email-yongwang@vmware.com> Subject: [dpdk-dev] [PATCH v2 4/4] vmxnet3: announce device offload capability 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: Tue, 05 Jan 2016 02:37:59 -0000 Signed-off-by: Yong Wang --- drivers/net/vmxnet3/vmxnet3_ethdev.c | 16 ++++++++++++++-- 1 file changed, 14 insertions(+), 2 deletions(-) diff --git a/drivers/net/vmxnet3/vmxnet3_ethdev.c b/drivers/net/vmxnet3/vmxnet3_ethdev.c index c363bf6..8a40127 100644 --- a/drivers/net/vmxnet3/vmxnet3_ethdev.c +++ b/drivers/net/vmxnet3/vmxnet3_ethdev.c @@ -693,7 +693,8 @@ vmxnet3_dev_stats_get(struct rte_eth_dev *dev, struct rte_eth_stats *stats) } static void -vmxnet3_dev_info_get(__attribute__((unused))struct rte_eth_dev *dev, struct rte_eth_dev_info *dev_info) +vmxnet3_dev_info_get(__attribute__((unused))struct rte_eth_dev *dev, + struct rte_eth_dev_info *dev_info) { dev_info->max_rx_queues = VMXNET3_MAX_RX_QUEUES; dev_info->max_tx_queues = VMXNET3_MAX_TX_QUEUES; @@ -716,6 +717,17 @@ vmxnet3_dev_info_get(__attribute__((unused))struct rte_eth_dev *dev, struct rte_ .nb_min = VMXNET3_DEF_TX_RING_SIZE, .nb_align = 1, }; + + dev_info->rx_offload_capa = + DEV_RX_OFFLOAD_VLAN_STRIP | + DEV_RX_OFFLOAD_UDP_CKSUM | + DEV_RX_OFFLOAD_TCP_CKSUM; + + dev_info->tx_offload_capa = + DEV_TX_OFFLOAD_VLAN_INSERT | + DEV_TX_OFFLOAD_TCP_CKSUM | + DEV_TX_OFFLOAD_UDP_CKSUM | + DEV_TX_OFFLOAD_TCP_TSO; } /* return 0 means link status changed, -1 means not changed */ @@ -819,7 +831,7 @@ vmxnet3_dev_vlan_filter_set(struct rte_eth_dev *dev, uint16_t vid, int on) else VMXNET3_CLEAR_VFTABLE_ENTRY(hw->shadow_vfta, vid); - /* don't change active filter if in promiscious mode */ + /* don't change active filter if in promiscuous mode */ if (rxConf->rxMode & VMXNET3_RXM_PROMISC) return 0; -- 1.9.1