Duncan Laurie has uploaded this change for review. ( https://review.coreboot.org/c/coreboot/+/46258 )
Change subject: acpigen: Make acpigen_write_opregion() argument const ......................................................................
acpigen: Make acpigen_write_opregion() argument const
This structure is not modified so it can be made const and allow the calling function to also declare it as a const structure.
Signed-off-by: Duncan Laurie dlaurie@google.com Change-Id: Id8cdfb4b3450a5ab2164ab048497324175b32269 --- M src/acpi/acpigen.c M src/include/acpi/acpigen.h 2 files changed, 2 insertions(+), 2 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/58/46258/1
diff --git a/src/acpi/acpigen.c b/src/acpi/acpigen.c index e2fe2cf..7b72584 100644 --- a/src/acpi/acpigen.c +++ b/src/acpi/acpigen.c @@ -408,7 +408,7 @@ * len is region length. * OperationRegion(regionname, regionspace, regionoffset, regionlength) */ -void acpigen_write_opregion(struct opregion *opreg) +void acpigen_write_opregion(const struct opregion *opreg) { /* OpregionOp */ acpigen_emit_ext_op(OPREGION_OP); diff --git a/src/include/acpi/acpigen.h b/src/include/acpi/acpigen.h index e0d95cd..d06d20c 100644 --- a/src/include/acpi/acpigen.h +++ b/src/include/acpi/acpigen.h @@ -429,7 +429,7 @@ * This function takes input region name, region space, region offset & region * length. */ -void acpigen_write_opregion(struct opregion *opreg); +void acpigen_write_opregion(const struct opregion *opreg); /* * Generate ACPI AML code for Mutex * This function takes mutex name and initial value.
Furquan Shaikh has posted comments on this change. ( https://review.coreboot.org/c/coreboot/+/46258 )
Change subject: acpigen: Make acpigen_write_opregion() argument const ......................................................................
Patch Set 2: Code-Review+2
Duncan Laurie has submitted this change. ( https://review.coreboot.org/c/coreboot/+/46258 )
Change subject: acpigen: Make acpigen_write_opregion() argument const ......................................................................
acpigen: Make acpigen_write_opregion() argument const
This structure is not modified so it can be made const and allow the calling function to also declare it as a const structure.
Signed-off-by: Duncan Laurie dlaurie@google.com Change-Id: Id8cdfb4b3450a5ab2164ab048497324175b32269 Reviewed-on: https://review.coreboot.org/c/coreboot/+/46258 Reviewed-by: Furquan Shaikh furquan@google.com Tested-by: build bot (Jenkins) no-reply@coreboot.org --- M src/acpi/acpigen.c M src/include/acpi/acpigen.h 2 files changed, 2 insertions(+), 2 deletions(-)
Approvals: build bot (Jenkins): Verified Furquan Shaikh: Looks good to me, approved
diff --git a/src/acpi/acpigen.c b/src/acpi/acpigen.c index e2fe2cf..7b72584 100644 --- a/src/acpi/acpigen.c +++ b/src/acpi/acpigen.c @@ -408,7 +408,7 @@ * len is region length. * OperationRegion(regionname, regionspace, regionoffset, regionlength) */ -void acpigen_write_opregion(struct opregion *opreg) +void acpigen_write_opregion(const struct opregion *opreg) { /* OpregionOp */ acpigen_emit_ext_op(OPREGION_OP); diff --git a/src/include/acpi/acpigen.h b/src/include/acpi/acpigen.h index e0d95cd..d06d20c 100644 --- a/src/include/acpi/acpigen.h +++ b/src/include/acpi/acpigen.h @@ -429,7 +429,7 @@ * This function takes input region name, region space, region offset & region * length. */ -void acpigen_write_opregion(struct opregion *opreg); +void acpigen_write_opregion(const struct opregion *opreg); /* * Generate ACPI AML code for Mutex * This function takes mutex name and initial value.