From 84a66e8e4f8324de38eb230b5e2539570b4d05a5 Mon Sep 17 00:00:00 2001 From: George Kennedy Date: Tue, 13 Sep 2022 15:53:09 +0000 Subject: executor: add NIC PCI pass-through VF support Add support for moving a NIC PCI pass-through VF into Syzkaller's network namespace so that it will tested. As DEVLINK support is triggered by setting the pass-through device to "addr=0x10", NIC PCI pass-through VF support will be triggered by setting the device to "addr=0x11". If a NIC PCI pass-through VF is detected in do_sandbox, setup a staging namespace before the fork() and transfer the NIC VF interface to it. After the fork() and in the child transfer the NIC VF interface to Syzkaller's network namespace and rename the interface to netpci0 so that it will be tested. Signed-off-by: George Kennedy --- pkg/ipc/ipc.go | 1 + 1 file changed, 1 insertion(+) (limited to 'pkg/ipc') diff --git a/pkg/ipc/ipc.go b/pkg/ipc/ipc.go index 5537ce0f8..33e87f706 100644 --- a/pkg/ipc/ipc.go +++ b/pkg/ipc/ipc.go @@ -43,6 +43,7 @@ const ( FlagEnableVhciInjection // setup and use /dev/vhci for hci packet injection FlagEnableWifi // setup and use mac80211_hwsim for wifi emulation FlagDelayKcovMmap // manage kcov memory in an optimized way + FlagEnableNicVF // setup NIC VF device ) // Per-exec flags for ExecOpts.Flags. -- cgit mrf-deployment