https://git.reactos.org/?p=reactos.git;a=commitdiff;h=40b2f65f0c8a2836bf9589...
commit 40b2f65f0c8a2836bf9589860d23377160eb3946 Author: Hervé Poussineau hpoussin@reactos.org AuthorDate: Fri Feb 7 23:48:22 2020 +0100 Commit: Hervé Poussineau hpoussin@reactos.org CommitDate: Fri Feb 7 23:48:53 2020 +0100
[ISAPNP] Correctly calculate checksum
See appendix B.2 of "Plug and Play ISA Specification 1.0a" --- drivers/bus/isapnp/hardware.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-)
diff --git a/drivers/bus/isapnp/hardware.c b/drivers/bus/isapnp/hardware.c index c578270379b..0e735f10312 100644 --- a/drivers/bus/isapnp/hardware.c +++ b/drivers/bus/isapnp/hardware.c @@ -178,10 +178,10 @@ HwDelay(VOID)
static inline -USHORT -NextLFSR(USHORT Lfsr, USHORT InputBit) +UCHAR +NextLFSR(UCHAR Lfsr, UCHAR InputBit) { - ULONG NextLfsr = Lfsr >> 1; + UCHAR NextLfsr = Lfsr >> 1;
NextLfsr |= (((Lfsr ^ NextLfsr) ^ InputBit)) << 7;
@@ -192,7 +192,7 @@ static VOID SendKey(VOID) { - USHORT i, Lfsr; + UCHAR i, Lfsr;
HwDelay(); WriteAddress(0x00); @@ -241,7 +241,7 @@ static USHORT IsaPnpChecksum(PISAPNP_IDENTIFIER Identifier) { - USHORT i,j, Lfsr, Byte; + UCHAR i, j, Lfsr, Byte;
Lfsr = ISAPNP_LFSR_SEED; for (i = 0; i < 8; i++)