Commit 5797d3c6 authored by Alexander Duyck's avatar Alexander Duyck Committed by Jakub Kicinski
Browse files

eth: fbnic: support listing tcam content via debugfs



The device has a handful of relatively small TCAM tables,
support dumping the driver state via debugfs.

  # ethtool -N eth0 flow-type tcp6 \
      dst-ip 1111::2222 dst-port $((0x1122)) \
      src-ip 3333::4444 src-port $((0x3344)) \
      action 2
  Added rule with ID 47

  # cd $dbgfs
  # cat ip_src
  Idx S TCAM Bitmap       V Addr/Mask
  ------------------------------------
  00  1 00020000,00000000 6 33330000000000000000000000004444
                            00000000000000000000000000000000
  ...
  # cat ip_dst
  Idx S TCAM Bitmap       V Addr/Mask
  ------------------------------------
  00  1 00020000,00000000 6 11110000000000000000000000002222
                            00000000000000000000000000000000
  ...

  # cat act_tcam
  Idx S Value/Mask                                              RSS  Dest
  ------------------------------------------------------------------------
  ...
  49  1 0000 0000 0000 0000 0000 0000 1122 3344 0000 9c00 0088  000f 00000212
        ffff ffff ffff ffff ffff ffff 0000 0000 ffff 23ff ff00
  ...

The ipo_* tables are for outer IP addresses.
The tce_* table is for directing/stealing traffic to NC-SI.

Signed-off-by: default avatarAlexander Duyck <alexanderduyck@meta.com>
Link: https://patch.msgid.link/20250206235334.1425329-8-kuba@kernel.org


Signed-off-by: default avatarJakub Kicinski <kuba@kernel.org>
parent d2348b4b
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment