treewide: remove redundant returns
Change-Id: I15f3f94273ffbb199dd47d7869de56196e1f4bd1
Reviewed-on: https://review.monogon.dev/c/monogon/+/3012
Vouch-Run-CI: Tim Windelschmidt <tim@monogon.tech>
Tested-by: Jenkins CI
Reviewed-by: Serge Bazanski <serge@monogon.tech>
diff --git a/cloud/agent/hwreport.go b/cloud/agent/hwreport.go
index 980dda1..31ccef4 100644
--- a/cloud/agent/hwreport.go
+++ b/cloud/agent/hwreport.go
@@ -64,7 +64,6 @@
}
c.node.MemoryInstalledBytes += int64(size)
}
- return
}
var memoryBlockRegexp = regexp.MustCompile("^memory[0-9]+$")
@@ -105,7 +104,6 @@
c.node.MemoryInstalledBytes += blockSize
}
}
- return
}
func parseCpuinfoAMD64(cpuinfoRaw []byte) (*api.CPU, []error) {
@@ -189,7 +187,6 @@
// Currently unimplemented, do nothing
c.errors = append(c.errors, fmt.Errorf("architecture %v unsupported by CPU gatherer", runtime.GOARCH))
}
- return
}
var FRUUnavailable = [16]byte{0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}
@@ -333,7 +330,6 @@
c.node.BlockDevice = append(c.node.BlockDevice, &bd)
}
}
- return
}
var speedModeRegexp = regexp.MustCompile("^([0-9]+)base")
@@ -401,7 +397,6 @@
}
c.node.NetworkInterface = append(c.node.NetworkInterface, &nif)
}
- return
}
func gatherHWReport() (*api.Node, []error) {
diff --git a/metropolis/node/core/panichandler.go b/metropolis/node/core/panichandler.go
index f1b4c6f..b336103 100644
--- a/metropolis/node/core/panichandler.go
+++ b/metropolis/node/core/panichandler.go
@@ -78,5 +78,4 @@
// initializing the crash handler, but there is no locking infrastructure
// for this so we have to take that risk.
overrideWrite = runtimeWrite
- return
}
diff --git a/metropolis/pkg/kmod/radix.go b/metropolis/pkg/kmod/radix.go
index 60e75f0..7dfc68c 100644
--- a/metropolis/pkg/kmod/radix.go
+++ b/metropolis/pkg/kmod/radix.go
@@ -55,7 +55,6 @@
matches[mi] = true
}
}
- return
}
// AddPattern adds a new pattern associated with a moduleIndex to the radix tree