[coreboot-gerrit] Change in coreboot[master]: mainboard/emulation/qemu-i440fx/fw_cfg: fix checksum for ACPI tables

Oleksii Kurochko (Code Review) gerrit at coreboot.org
Fri Apr 20 14:53:42 CEST 2018


Oleksii Kurochko has uploaded this change for review. ( https://review.coreboot.org/25753


Change subject: mainboard/emulation/qemu-i440fx/fw_cfg: fix checksum for ACPI tables
......................................................................

mainboard/emulation/qemu-i440fx/fw_cfg: fix checksum for ACPI tables

Current pacth fixes problem with validation of ACPI in Linux kernel:
ACPI BIOS Error (bug): A valid RSDP was not found (20180313/tbxfroot-210)
1. function acpi_checksum() return u8, so seems that is not good idea to
use write_le32().
2. at least RSDP (https://wiki.osdev.org/RSDP#Validating_the_RSDP) has
u8 Checksum.

Change-Id: I1fb29ef4e58982aab0c54b1f715c5658d2a663d8
Signed-off-by: Oleksii Kurochko <oleksii.kurochko at gmail.com>
---
M src/mainboard/emulation/qemu-i440fx/fw_cfg.c
1 file changed, 1 insertion(+), 1 deletion(-)



  git pull ssh://review.coreboot.org:29418/coreboot refs/changes/53/25753/1

diff --git a/src/mainboard/emulation/qemu-i440fx/fw_cfg.c b/src/mainboard/emulation/qemu-i440fx/fw_cfg.c
index 4db148c..7e33374 100644
--- a/src/mainboard/emulation/qemu-i440fx/fw_cfg.c
+++ b/src/mainboard/emulation/qemu-i440fx/fw_cfg.c
@@ -294,7 +294,7 @@
 			ptr = (uint8_t *)(addrs[dst] + s[i].cksum.offset);
 			cksum_data = (void *)(addrs[dst] + s[i].cksum.start);
 			cksum = acpi_checksum(cksum_data, s[i].cksum.length);
-			write_le32(ptr, cksum);
+			write_le8(ptr, cksum);
 			break;
 
 		default:

-- 
To view, visit https://review.coreboot.org/25753
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings

Gerrit-Project: coreboot
Gerrit-Branch: master
Gerrit-MessageType: newchange
Gerrit-Change-Id: I1fb29ef4e58982aab0c54b1f715c5658d2a663d8
Gerrit-Change-Number: 25753
Gerrit-PatchSet: 1
Gerrit-Owner: Oleksii Kurochko <oleksii.kurochko at gmail.com>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.coreboot.org/pipermail/coreboot-gerrit/attachments/20180420/d183a5a3/attachment.html>


More information about the coreboot-gerrit mailing list