]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
selftests: mlxsw: sharedbuffer: Ensure no extra packets are counted
authorDanielle Ratson <danieller@nvidia.com>
Thu, 5 Dec 2024 16:36:01 +0000 (17:36 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 19 Dec 2024 17:08:53 +0000 (18:08 +0100)
commite9c208b29035946f72c4e3223e690608d7d54a9c
treec4041d300238a9b5b005e943cb0f0448aa27a3f5
parent4dcd14efb39a3f66bcd4810e6734bcfa5e7d238d
selftests: mlxsw: sharedbuffer: Ensure no extra packets are counted

[ Upstream commit 5f2c7ab15fd806043db1a7d54b5ec36be0bd93b1 ]

The test assumes that the packet it is sending is the only packet being
passed to the device.

However, it is not the case and so other packets are filling the buffers
as well. Therefore, the test sometimes fails because it is reading a
maximum occupancy that is larger than expected.

Add egress filters on $h1 and $h2 that will guarantee the above.

Fixes: a865ad999603 ("selftests: mlxsw: Add shared buffer traffic test")
Signed-off-by: Danielle Ratson <danieller@nvidia.com>
Reviewed-by: Ido Schimmel <idosch@nvidia.com>
Signed-off-by: Ido Schimmel <idosch@nvidia.com>
Signed-off-by: Petr Machata <petrm@nvidia.com>
Link: https://patch.msgid.link/64c28bc9b1cc1d78c4a73feda7cedbe9526ccf8b.1733414773.git.petrm@nvidia.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
tools/testing/selftests/drivers/net/mlxsw/sharedbuffer.sh