Skip to content

Commit f8a4eba

Browse files
committed
Merge tag 'crc-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/ebiggers/linux
Pull CRC fixes from Eric Biggers: "Fix out-of-scope array bugs in arm and arm64's crc_t10dif_arch()" * tag 'crc-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/ebiggers/linux: arm64/crc-t10dif: fix use of out-of-scope array in crc_t10dif_arch() arm/crc-t10dif: fix use of out-of-scope array in crc_t10dif_arch()
2 parents 7288511 + d48b663 commit f8a4eba

File tree

2 files changed

+2
-6
lines changed

2 files changed

+2
-6
lines changed

arch/arm/lib/crc-t10dif-glue.c

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -44,9 +44,7 @@ u16 crc_t10dif_arch(u16 crc, const u8 *data, size_t length)
4444
crc_t10dif_pmull8(crc, data, length, buf);
4545
kernel_neon_end();
4646

47-
crc = 0;
48-
data = buf;
49-
length = sizeof(buf);
47+
return crc_t10dif_generic(0, buf, sizeof(buf));
5048
}
5149
}
5250
return crc_t10dif_generic(crc, data, length);

arch/arm64/lib/crc-t10dif-glue.c

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -45,9 +45,7 @@ u16 crc_t10dif_arch(u16 crc, const u8 *data, size_t length)
4545
crc_t10dif_pmull_p8(crc, data, length, buf);
4646
kernel_neon_end();
4747

48-
crc = 0;
49-
data = buf;
50-
length = sizeof(buf);
48+
return crc_t10dif_generic(0, buf, sizeof(buf));
5149
}
5250
}
5351
return crc_t10dif_generic(crc, data, length);

0 commit comments

Comments
 (0)