nvramtool: Fix CMOS checksum to match coreboot (and /dev/nvram)
Change-Id: I28b0dbad36403a31be83581107f40b3ca1332dcc Signed-off-by: Stefan Reinauer <reinauer@google.com> Reviewed-on: http://review.coreboot.org/287 Tested-by: build bot (Jenkins) Reviewed-by: Patrick Georgi <patrick@georgi-clan.de>
This commit is contained in:
parent
d1bc331855
commit
c31c4de681
|
@ -210,7 +210,7 @@ uint16_t cmos_checksum_compute(void)
|
||||||
for (i = cmos_checksum_start; i <= cmos_checksum_end; i++)
|
for (i = cmos_checksum_start; i <= cmos_checksum_end; i++)
|
||||||
sum += cmos_read_byte(i);
|
sum += cmos_read_byte(i);
|
||||||
|
|
||||||
return ~((uint16_t) (sum & 0xffff));
|
return (uint16_t)(sum & 0xffff);
|
||||||
}
|
}
|
||||||
|
|
||||||
/****************************************************************************
|
/****************************************************************************
|
||||||
|
|
Loading…
Reference in New Issue