summaryrefslogtreecommitdiff
path: root/cmd/btrfs-rec/inspect/rebuildmappings/scan.go
diff options
context:
space:
mode:
authorLuke Shumaker <lukeshu@lukeshu.com>2023-03-17 02:28:54 -0400
committerLuke Shumaker <lukeshu@lukeshu.com>2023-03-17 02:52:07 -0400
commit1ea26f04701fa66e36b058f3efb3a6c7059cdc5c (patch)
tree9ba66e893d6f66096f6b06284d09c8eb3e50facc /cmd/btrfs-rec/inspect/rebuildmappings/scan.go
parent0cfc5d80855ee0a28329305cda13e7bff935a297 (diff)
tree-wide: Turn on all revive linters (with exceptions)
Diffstat (limited to 'cmd/btrfs-rec/inspect/rebuildmappings/scan.go')
-rw-r--r--cmd/btrfs-rec/inspect/rebuildmappings/scan.go6
1 files changed, 3 insertions, 3 deletions
diff --git a/cmd/btrfs-rec/inspect/rebuildmappings/scan.go b/cmd/btrfs-rec/inspect/rebuildmappings/scan.go
index f9c3bf3..b88f01c 100644
--- a/cmd/btrfs-rec/inspect/rebuildmappings/scan.go
+++ b/cmd/btrfs-rec/inspect/rebuildmappings/scan.go
@@ -103,7 +103,7 @@ func (scanner *deviceScanner) ScanStats() scanStats {
}
}
-func newDeviceScanner(ctx context.Context, sb btrfstree.Superblock, numBytes btrfsvol.PhysicalAddr, numSectors int) btrfsutil.DeviceScanner[scanStats, ScanOneDeviceResult] {
+func newDeviceScanner(_ context.Context, sb btrfstree.Superblock, _ btrfsvol.PhysicalAddr, numSectors int) btrfsutil.DeviceScanner[scanStats, ScanOneDeviceResult] {
scanner := new(deviceScanner)
scanner.alg = sb.ChecksumType
scanner.result.FoundNodes = make(map[btrfsvol.LogicalAddr][]btrfsvol.PhysicalAddr)
@@ -112,7 +112,7 @@ func newDeviceScanner(ctx context.Context, sb btrfstree.Superblock, numBytes btr
return scanner
}
-func (scanner *deviceScanner) ScanSector(ctx context.Context, dev *btrfs.Device, paddr btrfsvol.PhysicalAddr) error {
+func (scanner *deviceScanner) ScanSector(_ context.Context, dev *btrfs.Device, paddr btrfsvol.PhysicalAddr) error {
sum, err := btrfs.ChecksumPhysical(dev, scanner.alg, paddr)
if err != nil {
return err
@@ -190,7 +190,7 @@ func (scanner *deviceScanner) ScanNode(ctx context.Context, nodeRef *diskio.Ref[
return nil
}
-func (scanner *deviceScanner) ScanDone(ctx context.Context) (ScanOneDeviceResult, error) {
+func (scanner *deviceScanner) ScanDone(_ context.Context) (ScanOneDeviceResult, error) {
scanner.result.Checksums.Sums = btrfssum.ShortSum(scanner.sums.String())
return scanner.result, nil
}