[coreboot-gerrit] Change in coreboot[master]: [WIP]acpigen: Always return buffer with requested size
Patrick Rudolph (Code Review)
gerrit at coreboot.org
Wed May 2 19:10:40 CEST 2018
Patrick Rudolph has uploaded this change for review. ( https://review.coreboot.org/25999
Change subject: [WIP]acpigen: Always return buffer with requested size
......................................................................
[WIP]acpigen: Always return buffer with requested size
Pad a buffer with zero bytes to return the exact requested size.
Might be requied for nouveau.
Needs test on real hardware.
Change-Id: I3f0ecc42a21945f66eb67f73e511bd516acf0fa9
Signed-off-by: Patrick Rudolph <siro at das-labor.org>
---
M src/arch/x86/acpigen.c
1 file changed, 10 insertions(+), 3 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/99/25999/1
diff --git a/src/arch/x86/acpigen.c b/src/arch/x86/acpigen.c
index fc6cc66..d73f03a 100644
--- a/src/arch/x86/acpigen.c
+++ b/src/arch/x86/acpigen.c
@@ -1340,6 +1340,8 @@
* Store (0x1000, Local1)
* }
*
+ * Store (Local1, Local3)
+ *
* If (LGreater (Local0, 0x10000))
* {
* Return(Buffer(Local1){0})
@@ -1354,7 +1356,7 @@
* }
* }
*
- * Name (ROM1, Buffer (Local1) {0})
+ * Name (ROM1, Buffer (Local3) {0})
*
* Multiply (Local0, 0x08, Local0)
* Multiply (Local1, 0x08, Local1)
@@ -1416,6 +1418,11 @@
/* Pop if */
acpigen_pop_len();
+ /* Store (Local1, Local3) */
+ acpigen_write_store();
+ acpigen_emit_byte(LOCAL1_OP);
+ acpigen_emit_byte(LOCAL3_OP);
+
/* If (LGreater (Local0, length)) */
acpigen_write_if();
acpigen_emit_byte(LGREATER_OP);
@@ -1462,11 +1469,11 @@
/* Pop if */
acpigen_pop_len();
- /* Name (ROM1, Buffer (Local1) {0}) */
+ /* Name (ROM1, Buffer (Local3) {0}) */
acpigen_write_name("ROM1");
acpigen_emit_byte(BUFFER_OP);
acpigen_write_len_f();
- acpigen_emit_byte(LOCAL1_OP);
+ acpigen_emit_byte(LOCAL3_OP);
acpigen_emit_byte(0);
acpigen_pop_len();
--
To view, visit https://review.coreboot.org/25999
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: I3f0ecc42a21945f66eb67f73e511bd516acf0fa9
Gerrit-Change-Number: 25999
Gerrit-PatchSet: 1
Gerrit-Owner: Patrick Rudolph <siro at das-labor.org>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.coreboot.org/pipermail/coreboot-gerrit/attachments/20180502/763314ee/attachment-0001.html>
More information about the coreboot-gerrit
mailing list