Ubuntu 20.04 - 'Support flow counters offset for bulk counters'

Bug #1922494 reported by Amir Tzin
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
linux (Ubuntu)
Incomplete
Undecided
Unassigned
Focal
Fix Released
Medium
Tim Gardner

Bug Description

[impact]
Add Support for flow counters offset for bulk counters on kernel side.
Currently Ubuntu 20.04 supports 'flow counters offset for bulk counters' on user space side only with these 3 rdma-core patches from v27.0
3956cf74 mlx5: Add support for bulk flow counters steering actions
65ed59c6 Update kernel headers
b32eee70 mlx5: Fix typos

[test case]
/* download and install dpdk from github (issue do not reproduce with inbox dpdk) */
$ git clone https://github.com/mellanox/dpdk.org
$ cd dpdk.org/

/* install dependencies if needed */
$ apt-get install -y python3-pyelftools python-pyelftools
$ apt install meson

$ meson build-meson
$ ninja -C build-meson/

/* run dpdk-testpmd with mellanox HCA (I used CX5) 0000:05:00.0, 0000:05:00.1 are pci id for the cx5 devices */

/<path to dpdk folder>/dpdk.org/build-meson/app/dpdk-testpmd -v -n 4 -w 0000:05:00.0,txq_inline=147,rx_vec_en=1 -w 0000:05:00.1,txq_inline=147,rx_vec_en=1 -- --mbcache=512 -i --nb-cores=7 --txd=8192 --rxd=8192 --burst=64

EAL: Detected 12 lcore(s)
EAL: Detected 2 NUMA nodes
EAL: RTE Version: 'DPDK 21.05.0-rc0'
Option -w, --pci-whitelist is deprecated, use -a, --allow option instead
Option -w, --pci-whitelist is deprecated, use -a, --allow option instead
EAL: Detected static linkage of DPDK
EAL: Multi-process socket /var/run/dpdk/rte/mp_socket
EAL: Selected IOVA mode 'VA'
EAL: Probing VFIO support...
EAL: VFIO support initialized
EAL: Probe PCI driver: mlx5_pci (15b3:101d) device: 0000:05:00.0 (socket 0)
mlx5_pci: txq_inline: deprecated parameter, converted to txq_inline_max
mlx5_pci: txq_inline: deprecated parameter, converted to txq_inline_max
mlx5_pci: Default miss action is not supported.
mlx5_pci: Unexpected error in counter offset support detection /* LINE INDICATING ERROR*/
EAL: Probe PCI driver: mlx5_pci (15b3:101d) device: 0000:05:00.1 (socket 0)
mlx5_pci: txq_inline: deprecated parameter, converted to txq_inline_max
mlx5_pci: txq_inline: deprecated parameter, converted to txq_inline_max
mlx5_pci: Default miss action is not supported.
mlx5_pci: Unexpected error in counter offset support detection /* LINE INDICATING ERROR*/
Interactive-mode selected
testpmd: create a new mbuf pool <mb_pool_0>: n=327680, size=2176, socket=0
testpmd: preferred mempool ops selected: ring_mp_mc
testpmd: create a new mbuf pool <mb_pool_1>: n=327680, size=2176, socket=1
testpmd: preferred mempool ops selected: ring_mp_mc
Configuring Port 0 (socket 0)
Port 0: 0C:42:A1:D1:D0:64
Configuring Port 1 (socket 0)
Port 1: 0C:42:A1:D1:D0:65
Checking link statuses...
Done
testpmd>

two lines indicates errors in counter offset supports detection.

[Fix]

the issue is fixed with the following upstream commit from v5.5-rc1 which cleanly applied above focal.
208d70f562e5 IB/mlx5: Support flow counters offset for bulk counters
Our QA-dpdk team tested the focal kernel with this patch and found no issues.

[regression potential]
function mlx5_ib devx _is_flow_counter (from the devx interface) signature has changed so anything that uses it like rdma-core might be impacted.

Thanks,
Amir

Amir Tzin (amirtz)
description: updated
Revision history for this message
Ubuntu Kernel Bot (ubuntu-kernel-bot) wrote : Missing required logs.

This bug is missing log files that will aid in diagnosing the problem. While running an Ubuntu kernel (not a mainline or third-party kernel) please enter the following command in a terminal window:

apport-collect 1922494

and then change the status of the bug to 'Confirmed'.

If, due to the nature of the issue you have encountered, you are unable to run this command, please add a comment stating that fact and change the bug status to 'Confirmed'.

This change has been made by an automated script, maintained by the Ubuntu Kernel Team.

Changed in linux (Ubuntu):
status: New → Incomplete
tags: added: focal
Tim Gardner (timg-tpi)
Changed in linux (Ubuntu Focal):
status: New → In Progress
importance: Undecided → Medium
assignee: nobody → Tim Gardner (timg-tpi)
Revision history for this message
Tim Gardner (timg-tpi) wrote :
Revision history for this message
Tim Gardner (timg-tpi) wrote :

Amit Tzin - commit 208d70f562e5 ("IB/mlx5: Support flow counters offset for bulk counters") extends an existing interface, correct ? Can you tell me what user space applications might be affected ? It doesn't look like it should impact ethtool.

Revision history for this message
Amir Tzin (amirtz) wrote :

Hi Tim,

It extends devx interface and might affects any user space application that uses rdma-core (which already has relevant patches), dpdk for instance.

Amir Tzin (amirtz)
description: updated
Tim Gardner (timg-tpi)
Changed in linux (Ubuntu Focal):
status: In Progress → Fix Committed
Revision history for this message
Ubuntu Kernel Bot (ubuntu-kernel-bot) wrote :

This bug is awaiting verification that the kernel in -proposed solves the problem. Please test the kernel and update this bug with the results. If the problem is solved, change the tag 'verification-needed-focal' to 'verification-done-focal'. If the problem still exists, change the tag 'verification-needed-focal' to 'verification-failed-focal'.

If verification is not done by 5 working days from today, this fix will be dropped from the source code, and this bug will be closed.

See https://wiki.ubuntu.com/Testing/EnableProposed for documentation how to enable and use -proposed. Thank you!

tags: added: verification-needed-focal
Revision history for this message
Tim Gardner (timg-tpi) wrote :

Hi Amir - please test. Marking verification done for now. Regression consequence is limited to the DPDK use case.

tags: added: verification-done-focal
removed: verification-needed-focal
Revision history for this message
Launchpad Janitor (janitor) wrote :
Download full text (34.3 KiB)

This bug was fixed in the package linux - 5.4.0-77.86

---------------
linux (5.4.0-77.86) focal; urgency=medium

  * UAF on CAN J1939 j1939_can_recv (LP: #1932209)
    - SAUCE: can: j1939: delay release of j1939_priv after synchronize_rcu

  * UAF on CAN BCM bcm_rx_handler (LP: #1931855)
    - SAUCE: can: bcm: delay release of struct bcm_op after synchronize_rcu

linux (5.4.0-76.85) focal; urgency=medium

  * focal/linux: 5.4.0-76.85 -proposed tracker (LP: #1932123)

  * Upstream v5.9 introduced 'module' patches that removed exported symbols
    (LP: #1932065)
    - SAUCE: Revert "modules: inherit TAINT_PROPRIETARY_MODULE"
    - SAUCE: Revert "modules: return licensing information from find_symbol"
    - SAUCE: Revert "modules: rename the licence field in struct symsearch to
      license"
    - SAUCE: Revert "modules: unexport __module_address"
    - SAUCE: Revert "modules: unexport __module_text_address"
    - SAUCE: Revert "modules: mark each_symbol_section static"
    - SAUCE: Revert "modules: mark find_symbol static"
    - SAUCE: Revert "modules: mark ref_module static"

linux (5.4.0-75.84) focal; urgency=medium

  * focal/linux: 5.4.0-75.84 -proposed tracker (LP: #1930032)

  * Packaging resync (LP: #1786013)
    - update dkms package versions

  * CVE-2021-33200
    - bpf: Wrap aux data inside bpf_sanitize_info container
    - bpf: Fix mask direction swap upon off reg sign change
    - bpf: No need to simulate speculative domain for immediates

  * Realtek USB hubs in Dell WD19SC/DC/TB fail to work after exiting s2idle
    (LP: #1928242)
    - USB: Verify the port status when timeout happens during port suspend

  * CVE-2020-26145
    - ath10k: drop fragments with multicast DA for SDIO
    - ath10k: add CCMP PN replay protection for fragmented frames for PCIe
    - ath10k: drop fragments with multicast DA for PCIe

  * CVE-2020-26141
    - ath10k: Fix TKIP Michael MIC verification for PCIe

  * CVE-2020-24588
    - mac80211: properly handle A-MSDUs that start with an RFC 1042 header
    - cfg80211: mitigate A-MSDU aggregation attacks
    - mac80211: drop A-MSDUs on old ciphers
    - ath10k: drop MPDU which has discard flag set by firmware for SDIO

  * CVE-2020-26139
    - mac80211: do not accept/forward invalid EAPOL frames

  * CVE-2020-24586 // CVE-2020-24587 // CVE-2020-24587 for such cases.
    - mac80211: extend protection against mixed key and fragment cache attacks

  * CVE-2020-24586 // CVE-2020-24587
    - mac80211: prevent mixed key and fragment cache attacks
    - mac80211: add fragment cache to sta_info
    - mac80211: check defrag PN against current frame
    - mac80211: prevent attacks on TKIP/WEP as well

  * CVE-2020-26147
    - mac80211: assure all fragments are encrypted

  * raid10: Block discard is very slow, causing severe delays for mkfs and
    fstrim operations (LP: #1896578)
    - md: add md_submit_discard_bio() for submitting discard bio
    - md/raid10: extend r10bio devs to raid disks
    - md/raid10: pull the code that wait for blocked dev into one function
    - md/raid10: improve raid10 discard request
    - md/raid10: improve discard request for far layout
    - dm raid: remove unnecessary discard limi...

Changed in linux (Ubuntu Focal):
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers