From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-io0-f169.google.com (mail-io0-f169.google.com [209.85.223.169]) by dpdk.org (Postfix) with ESMTP id 14C847CB3 for ; Thu, 4 May 2017 15:04:09 +0200 (CEST) Received: by mail-io0-f169.google.com with SMTP id p24so21855295ioi.0 for ; Thu, 04 May 2017 06:04:09 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=infinite-io.20150623.gappssmtp.com; s=20150623; h=mime-version:from:date:message-id:subject:to; bh=t8FbpQubRxDIcHWnyHOcqYwtCbRinJue/1LRZw/+N4I=; b=kfz9BtNKUNE/k6dwLUihVfADbLAbbP3bti3HyqJuAqoMKFeOHIXVb6OGdGsEV6dlBU u3xQgIR1x86e4Dme2ItdGjycv9N632WbGm6HRkkQC0iKcULA0awHK6ng6agPfCx000D/ J5gF34Gu2UG++sxyh2kGDpOYexpqgNdTVNZ1q04xCDLSgdltHe2TJmYcKDa4iGhicgXB EOnhvqtn1KPvxoXQtTT2SM8qpSfJ2BcW9D1j2iZerhKqMmgN5j6FnmjkaoaZpTP2qlOO 9SQNXyVvoOjTgkENPl18P+e/birH3oq9ZZC47XRRnfWScWu+rjdlYwwodBsnB+zXe31U ZaoQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:from:date:message-id:subject:to; bh=t8FbpQubRxDIcHWnyHOcqYwtCbRinJue/1LRZw/+N4I=; b=HFqRybUeP9OzYvuDvGKwvoh4/kNzWCKJdkv0C3vrx8tHLTp/VQc5OO+0fqzu71/7El xEbtZGmYb3VIWXgOS7ahja8WiE8yWBTexpKWPxlUuPPW2RSq1B/H5PRrOCH6BDUQdpCP wSjCf28KUyxbNN+TyJKF8VYlLjvmzAXbJb1g3s0vDgyh1afGQS84RAmeAwBStQyvkID+ xpXCYtGI+iiSvEwUTrEOD+Ctui34htO+50t0DMR8VkEmS++Lw7PD7L2P8mxCh/N8XXIT zFhG083p2xm6cBbXLyxCexIGHBOZXTHmtPt0PcMrHob4r1+svSnHpnbV7NUfdT7WN0ZE 93Pg== X-Gm-Message-State: AN3rC/503k6b+MMdipV2fwMF6eRydDv08H7OKFBnfG11G+Mr88Q8whv4 5Z8pS3KcdsW1LrULky5ns97lzs40OAuZ X-Received: by 10.107.58.135 with SMTP id h129mr37837521ioa.70.1493903048811; Thu, 04 May 2017 06:04:08 -0700 (PDT) MIME-Version: 1.0 Received: by 10.107.44.23 with HTTP; Thu, 4 May 2017 06:04:08 -0700 (PDT) From: Matt Laswell Date: Thu, 4 May 2017 08:04:08 -0500 Message-ID: To: "dev@dpdk.org" Content-Type: text/plain; charset=UTF-8 X-Content-Filtered-By: Mailman/MimeDel 2.1.15 Subject: [dpdk-dev] Occasional instability in RSS Hashes/Queues from X540 NIC 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: Thu, 04 May 2017 13:04:10 -0000 Hey Folks, I'm seeing some strange behavior with regard to the RSS hash values in my applications and was hoping somebody might have some pointers on where to look. In my application, I'm using RSS to divide work among multiple cores, each of which services a single RX queue. When dealing with a single long-lived TCP connection, I occasionally see packets going to the wrong core. That is, almost all of the packets in the connection go to core 5 in this case, but every once in a while, one goes to core 0 instead. Upon further investigation, I find two problems are occurring. The first is that problem packets have the RSS hash value in the mbuf incorrectly set to zero. They are therefore put in queue zero, where they are read by core zero. Other packets from the same connection that occur immediately before and after the packet in question have the correct hash value and therefore go to a different core. The second problem is that we sometimes see packets in which the RSS hash in the mbuf appears correct, but the packets are incorrectly put into queue zero. As with the first, this results in the wrong core getting the packet. Either one of these confuses the state tracking we're doing per-core. A few details: - Using an Intel X540-AT2 NIC and the igb_uio driver - DPDK 16.04 - A particular packet in our workflow always encounters this problem. - Retransmissions of the packet in question also encounter the problem - The packet is IPv4, with header length of 20 (so no options), no fragmentation. - The only differences I can see in the IP header between packets that get the right hash value and those that get the wrong one are in the IP ID, total length, and checksum fields. - Using ETH_RSS_IPV4 - The packet is TCP with about 100 bytes of payload - it's not a jumbo or a runt - We fill the key in with 0x6d5a to get symmetric hashing of both sides of the connection - We only configure RSS information at boot; things like the key or header fields are not being changed dynamically - Traffic load is light when the problem occurs Is anybody aware of an errata, either in the NIC or the PMD's configuration of it that might explain something like this? Failing that, if you ran into this sort of behavior, how would you approach finding the reason for the error? Every failure mode I can think of would tend to affect all of the packets in the connection consistently, even if incorrectly. Thanks in advance for any ideas. -- Matt Laswell laswell@infinite.io