diff options
| -rw-r--r-- | .golangci.yml | 3 | ||||
| -rw-r--r-- | dashboard/app/bisect_test.go | 4 | ||||
| -rw-r--r-- | dashboard/app/jobs_test.go | 4 | ||||
| -rw-r--r-- | executor/stub.go | 2 | ||||
| -rw-r--r-- | pkg/ast/ast.go | 4 | ||||
| -rw-r--r-- | pkg/ifuzz/pseudo.go | 4 | ||||
| -rw-r--r-- | pkg/ipc/ipc.go | 6 | ||||
| -rw-r--r-- | pkg/symbolizer/symbolizer.go | 2 | ||||
| -rw-r--r-- | prog/hints.go | 5 | ||||
| -rw-r--r-- | syz-ci/syz-ci.go | 2 | ||||
| -rw-r--r-- | vm/vmimpl/console.go | 2 |
11 files changed, 20 insertions, 18 deletions
diff --git a/.golangci.yml b/.golangci.yml index 9a1ffcd3d..1b042eb4c 100644 --- a/.golangci.yml +++ b/.golangci.yml @@ -37,6 +37,7 @@ linters: - whitespace - nestif - goprintffuncname + - godot disable: - bodyclose - depguard @@ -75,6 +76,8 @@ linters-settings: min-occurrences: 4 nestif: min-complexity: 12 + godot: + check-all: true issues: exclude-use-default: false diff --git a/dashboard/app/bisect_test.go b/dashboard/app/bisect_test.go index ae9246700..00fa2e948 100644 --- a/dashboard/app/bisect_test.go +++ b/dashboard/app/bisect_test.go @@ -934,7 +934,7 @@ func TestBisectCauseReproSyz2(t *testing.T) { } } -// Test that bisection results show up on UI +// Test that bisection results show up on UI. func TestBugBisectionResults(t *testing.T) { c := NewCtx(t) defer c.Close() @@ -1037,7 +1037,7 @@ func TestBugBisectionResults(t *testing.T) { c.expectTrue(bytes.Contains(content, []byte("kernel: add a fix"))) } -// Test that bisection status shows up on main page +// Test that bisection status shows up on main page. func TestBugBisectionStatus(t *testing.T) { c := NewCtx(t) defer c.Close() diff --git a/dashboard/app/jobs_test.go b/dashboard/app/jobs_test.go index 06abc8957..32fe8c517 100644 --- a/dashboard/app/jobs_test.go +++ b/dashboard/app/jobs_test.go @@ -360,7 +360,7 @@ func TestJobRestrictedManager(t *testing.T) { c.expectEQ(pollResp.KernelRepo, "git://restricted.git/restricted.git") } -// Test that JobBisectFix is returned only after 30 days +// Test that JobBisectFix is returned only after 30 days. func TestBisectFixJob(t *testing.T) { c := NewCtx(t) defer c.Close() @@ -409,7 +409,7 @@ func TestBisectFixJob(t *testing.T) { c.client2.expectOK(c.client2.JobDone(done)) } -// Test that JobBisectFix jobs are re-tried if crash occurs on ToT +// Test that JobBisectFix jobs are re-tried if crash occurs on ToT. func TestBisectFixRetry(t *testing.T) { c := NewCtx(t) defer c.Close() diff --git a/executor/stub.go b/executor/stub.go index a85683ee3..9b6ab882e 100644 --- a/executor/stub.go +++ b/executor/stub.go @@ -2,6 +2,6 @@ // Use of this source code is governed by Apache 2 LICENSE that can be found in the LICENSE file. // Just to make cross-compilation tests work, -// otherwise they fail with "no buildable Go source files" +// otherwise they fail with "no buildable Go source files". package executor diff --git a/pkg/ast/ast.go b/pkg/ast/ast.go index 8cd7bef6e..60b984134 100644 --- a/pkg/ast/ast.go +++ b/pkg/ast/ast.go @@ -27,7 +27,7 @@ type Node interface { walk(cb func(Node)) } -// Top-level AST nodes: +// Top-level AST nodes. type NewLine struct { Pos Pos @@ -150,7 +150,7 @@ func (n *TypeDef) Info() (Pos, string, string) { return n.Pos, "type", n.Name.Name } -// Not top-level AST nodes: +// Not top-level AST nodes. type Ident struct { Pos Pos diff --git a/pkg/ifuzz/pseudo.go b/pkg/ifuzz/pseudo.go index 8ca8ef8d6..1bb171665 100644 --- a/pkg/ifuzz/pseudo.go +++ b/pkg/ifuzz/pseudo.go @@ -399,7 +399,7 @@ func (gen *generator) mov64(reg int, v uint64) { gen.imm64(v) } -// movl $v, off(%rsp) +// movl $v, off(%rsp). func (gen *generator) mov32toSPaddr(v uint32, off uint8) { gen.addr32() gen.operand32() @@ -565,7 +565,7 @@ var ports = []uint16{ 0x20, 0x21, 0xa0, 0xa1, 0x4d0, 0x4d1, // 8259 } -// sys/kvm.txt also knows this list +// sys/kvm.txt also knows this list. var msrs = []uint32{ 0x0, 0x1, 0x10, 0x11, 0x12, 0x13, 0x17, 0x1b, 0x20, 0x21, 0x28, 0x29, 0x2a, 0x2c, 0x33, 0x34, diff --git a/pkg/ipc/ipc.go b/pkg/ipc/ipc.go index 9ee7843d3..e5e6a2b30 100644 --- a/pkg/ipc/ipc.go +++ b/pkg/ipc/ipc.go @@ -27,7 +27,7 @@ import ( // Configuration flags for Config.Flags. type EnvFlags uint64 -// Note: New / changed flags should be added to parse_env_flags in executor.cc +// Note: New / changed flags should be added to parse_env_flags in executor.cc. const ( FlagDebug EnvFlags = 1 << iota // debug output from executor FlagSignal // collect feedback signals (coverage) @@ -43,7 +43,7 @@ const ( FlagEnableDevlinkPCI // setup devlink PCI device ) -// Per-exec flags for ExecOpts.Flags: +// Per-exec flags for ExecOpts.Flags. type ExecFlags uint64 const ( @@ -247,7 +247,7 @@ var rateLimit = time.NewTicker(1 * time.Second) // output: process output // info: per-call info // hanged: program hanged and was killed -// err0: failed to start the process or bug in executor itself +// err0: failed to start the process or bug in executor itself. func (env *Env) Exec(opts *ExecOpts, p *prog.Prog) (output []byte, info *ProgInfo, hanged bool, err0 error) { // Copy-in serialized program. progSize, err := p.SerializeForExec(env.in) diff --git a/pkg/symbolizer/symbolizer.go b/pkg/symbolizer/symbolizer.go index f6c6dbe78..f1f8478e9 100644 --- a/pkg/symbolizer/symbolizer.go +++ b/pkg/symbolizer/symbolizer.go @@ -1,7 +1,7 @@ // Copyright 2016 syzkaller project authors. All rights reserved. // Use of this source code is governed by Apache 2 LICENSE that can be found in the LICENSE file. -// TODO: strip " (discriminator N)", "constprop", "isra" from function names +// TODO: strip " (discriminator N)", "constprop", "isra" from function names. package symbolizer diff --git a/prog/hints.go b/prog/hints.go index be2b371f2..9163dd415 100644 --- a/prog/hints.go +++ b/prog/hints.go @@ -153,7 +153,7 @@ func checkDataArg(arg *DataArg, compMap CompMap, exec func()) { // Shrink and expand mutations model the cases when the syscall arguments // are casted to narrower (and wider) integer types. -// ====================================================================== +// // Motivation for shrink: // void f(u16 x) { // u8 y = (u8)x; @@ -169,7 +169,7 @@ func checkDataArg(arg *DataArg, compMap CompMap, exec func()) { // In this case we ignore such comparison because we couldn't come up with // any valid code example that does similar things. To avoid such comparisons // we check the sizes with leastSize(). -// ====================================================================== +// // Motivation for expand: // void f(i8 x) { // i16 y = (i16)x; @@ -180,7 +180,6 @@ func checkDataArg(arg *DataArg, compMap CompMap, exec func()) { // check the extension. // As with shrink we ignore cases when the other operand is wider. // Note that executor sign extends all the comparison operands to int64. -// ====================================================================== func shrinkExpand(v uint64, compMap CompMap, bitsize uint64) []uint64 { v = truncateToBitSize(v, bitsize) limit := uint64(1<<bitsize - 1) diff --git a/syz-ci/syz-ci.go b/syz-ci/syz-ci.go index 4afad46b1..10caf8bb8 100644 --- a/syz-ci/syz-ci.go +++ b/syz-ci/syz-ci.go @@ -4,7 +4,7 @@ // syz-ci is a continuous fuzzing system for syzkaller. // It runs several syz-manager's, polls and rebuilds images for managers // and polls and rebuilds syzkaller binaries. -// For usage instructions see: docs/ci.md +// For usage instructions see: docs/ci.md. package main // Implementation details: diff --git a/vm/vmimpl/console.go b/vm/vmimpl/console.go index cd47a43bc..fbc05942f 100644 --- a/vm/vmimpl/console.go +++ b/vm/vmimpl/console.go @@ -79,7 +79,7 @@ func (t *tty) Close() error { return nil } -// Open dmesg remotely +// Open dmesg remotely. func OpenRemoteConsole(bin string, args ...string) (rc io.ReadCloser, err error) { rpipe, wpipe, err := osutil.LongPipe() if err != nil { |
