net: hns3: Add "FD flow table" info query function
BugLink: https://bugs.launchpad.net/bugs/1810457
All the Flow Director rules are stored in tcam blocks.
For each bit of tcam entry, the match value
depends on two input value(x, y).
debugfs command:
echo dump fd tcam > cmd
Sample output:
root@(none)# echo dump fd tcam > cmd
hns3 0000:7d:00.0: read result tcam key x(31):
hns3 0000:7d:00.0:
00000000
hns3 0000:7d:00.0:
00000000
hns3 0000:7d:00.0:
00000000
hns3 0000:7d:00.0:
08000000
hns3 0000:7d:00.0:
00000600
hns3 0000:7d:00.0:
00000000
hns3 0000:7d:00.0:
00000000
hns3 0000:7d:00.0:
00000000
hns3 0000:7d:00.0:
00000000
hns3 0000:7d:00.0:
00000000
hns3 0000:7d:00.0:
00000000
hns3 0000:7d:00.0:
00000000
hns3 0000:7d:00.0:
00000000
hns3 0000:7d:00.0: read result tcam key y(31):
hns3 0000:7d:00.0:
00000000
hns3 0000:7d:00.0:
00000000
hns3 0000:7d:00.0:
00000000
hns3 0000:7d:00.0:
f7ff0000
hns3 0000:7d:00.0:
0000f900
hns3 0000:7d:00.0:
00000000
hns3 0000:7d:00.0:
00000000
hns3 0000:7d:00.0:
00000000
hns3 0000:7d:00.0:
00000000
hns3 0000:7d:00.0:
00000000
hns3 0000:7d:00.0:
00000000
hns3 0000:7d:00.0:
00000000
hns3 0000:7d:00.0:
0000fff8
root@(none)#
Signed-off-by: liuzhongzhu <liuzhongzhu@huawei.com>
Signed-off-by: Salil Mehta <salil.mehta@huawei.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
(cherry picked from commit
3c666b586af1c6ed6e352555aec38d2f9478cd47)
Signed-off-by: dann frazier <dann.frazier@canonical.com>
Acked-by: Stefan Bader <stefan.bader@canonical.com>
Acked-by: Kleber Sacilotto de Souza <kleber.souza@canonical.com>
Signed-off-by: Kleber Sacilotto de Souza <kleber.souza@canonical.com>