diff options
Diffstat (limited to 'fs/btrfs/scrub.c')
-rw-r--r-- | fs/btrfs/scrub.c | 15 |
1 files changed, 0 insertions, 15 deletions
diff --git a/fs/btrfs/scrub.c b/fs/btrfs/scrub.c index bc015f77f3ea..4f76fc3f8e89 100644 --- a/fs/btrfs/scrub.c +++ b/fs/btrfs/scrub.c | |||
@@ -1257,12 +1257,6 @@ static int scrub_checksum_data(struct scrub_block *sblock) | |||
1257 | if (memcmp(csum, on_disk_csum, sdev->csum_size)) | 1257 | if (memcmp(csum, on_disk_csum, sdev->csum_size)) |
1258 | fail = 1; | 1258 | fail = 1; |
1259 | 1259 | ||
1260 | if (fail) { | ||
1261 | spin_lock(&sdev->stat_lock); | ||
1262 | ++sdev->stat.csum_errors; | ||
1263 | spin_unlock(&sdev->stat_lock); | ||
1264 | } | ||
1265 | |||
1266 | return fail; | 1260 | return fail; |
1267 | } | 1261 | } |
1268 | 1262 | ||
@@ -1335,15 +1329,6 @@ static int scrub_checksum_tree_block(struct scrub_block *sblock) | |||
1335 | if (memcmp(calculated_csum, on_disk_csum, sdev->csum_size)) | 1329 | if (memcmp(calculated_csum, on_disk_csum, sdev->csum_size)) |
1336 | ++crc_fail; | 1330 | ++crc_fail; |
1337 | 1331 | ||
1338 | if (crc_fail || fail) { | ||
1339 | spin_lock(&sdev->stat_lock); | ||
1340 | if (crc_fail) | ||
1341 | ++sdev->stat.csum_errors; | ||
1342 | if (fail) | ||
1343 | ++sdev->stat.verify_errors; | ||
1344 | spin_unlock(&sdev->stat_lock); | ||
1345 | } | ||
1346 | |||
1347 | return fail || crc_fail; | 1332 | return fail || crc_fail; |
1348 | } | 1333 | } |
1349 | 1334 | ||