From mboxrd@z Thu Jan 1 00:00:00 1970 From: Shahaf Shuler Subject: [PATCH] net/mlx5: fix CRC strip cap query Date: Thu, 1 Feb 2018 20:53:53 +0200 Message-ID: <20180201185353.93449-1-shahafs@mellanox.com> Mime-Version: 1.0 Content-Type: text/plain Cc: dev@dpdk.org, alexr@mellanox.com, stable@dpdk.org To: yskoh@mellanox.com, nelio.laranjeiro@6wind.com, adrien.mazarguil@6wind.com Return-path: List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" IBV_WQ_FLAGS_SCATTER_FCS is a WQ flag to be used to configure the CRC strip on a queue upon creation. Using IBV_RAW_PACKET_CAP_SCATTER_FCS instead to query to capability. Even though this is RAW_QP capability, it is being used by rdma-core to indicate for both RAW_QP and WQ. Fixes: 43e9d9794cde ("net/mlx5: support upstream rdma-core") Cc: stable@dpdk.org Reported-by: Alex Rosenbaum Signed-off-by: Shahaf Shuler --- drivers/net/mlx5/mlx5.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/drivers/net/mlx5/mlx5.c b/drivers/net/mlx5/mlx5.c index 544599b01..02082c107 100644 --- a/drivers/net/mlx5/mlx5.c +++ b/drivers/net/mlx5/mlx5.c @@ -895,9 +895,8 @@ mlx5_pci_probe(struct rte_pci_driver *pci_drv, struct rte_pci_device *pci_dev) DEBUG("VLAN stripping is %ssupported", (config.hw_vlan_strip ? "" : "not ")); - config.hw_fcs_strip = - !!(device_attr_ex.orig_attr.device_cap_flags & - IBV_WQ_FLAGS_SCATTER_FCS); + config.hw_fcs_strip = !!(device_attr_ex.raw_packet_caps & + IBV_RAW_PACKET_CAP_SCATTER_FCS); DEBUG("FCS stripping configuration is %ssupported", (config.hw_fcs_strip ? "" : "not ")); -- 2.12.0