]> git.baikalelectronics.ru Git - kernel.git/commit
selftests: forwarding: lib: Extract trap_{, un}install()
authorPetr Machata <petrm@mellanox.com>
Thu, 24 May 2018 14:27:35 +0000 (16:27 +0200)
committerDavid S. Miller <davem@davemloft.net>
Fri, 25 May 2018 02:26:19 +0000 (22:26 -0400)
commitac28f7fa50e711ca2e3d01193c3308202a72d875
treea00995d0755bc1dcb78605b344bbefb5264be48a
parent11205d4a360636028888911be379fd272dbf51cf
selftests: forwarding: lib: Extract trap_{, un}install()

A mirror-to-vlan test that's coming next needs to install the trap
unconditionally. Therefore extract from slow_path_trap_{,un}install()
a more generic functions trap_install() and trap_uninstall(), and covert
the former two to conditional wrappers around these.

Signed-off-by: Petr Machata <petrm@mellanox.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
tools/testing/selftests/net/forwarding/lib.sh