From b2f369e56e13dc135d57c53210ea7ab38b239e94 Mon Sep 17 00:00:00 2001 From: Marco Elver Date: Fri, 4 Oct 2019 13:43:02 +0200 Subject: executor, host, csource: Add support to enable KCSAN By default, the current KCSAN .config does not enable KCSAN during boot, since we encounter races during boot which would prevent syzkaller from ever executing. This adds support to detect if KCSAN is available, and enables it on the fuzzer host. --- pkg/host/host_linux.go | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'pkg/host/host_linux.go') diff --git a/pkg/host/host_linux.go b/pkg/host/host_linux.go index 25da4b016..da208bbad 100644 --- a/pkg/host/host_linux.go +++ b/pkg/host/host_linux.go @@ -395,6 +395,7 @@ func init() { checkFeature[FeatureLeakChecking] = checkLeakChecking checkFeature[FeatureNetworkInjection] = checkNetworkInjection checkFeature[FeatureNetworkDevices] = unconditionallyEnabled + checkFeature[FeatureKCSAN] = checkKCSAN } func checkCoverage() string { @@ -556,3 +557,10 @@ func checkDebugFS() string { } return "" } + +func checkKCSAN() string { + if err := osutil.IsAccessible("/proc/kcsaninfo"); err != nil { + return err.Error() + } + return "" +} -- cgit mrf-deployment