Patrick Rudolph has uploaded this change for review. ( https://review.coreboot.org/c/coreboot/+/34140 )
Change subject: lib/bootmem: Prepare for OpenSBI ......................................................................
lib/bootmem: Prepare for OpenSBI
Add a new bootmem memory type OpenSBI. It's similar to BL31 on aarch.
Required for OpenSBI integration.
Change-Id: I5ceafd5a295f4284e99e12f7ea2aa4c6d1dbb188 Signed-off-by: Patrick Rudolph patrick.rudolph@9elements.com --- M src/include/bootmem.h M src/include/program_loading.h M src/include/symbols.h M src/lib/bootmem.c 4 files changed, 7 insertions(+), 2 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/40/34140/1
diff --git a/src/include/bootmem.h b/src/include/bootmem.h index c935cb9..c9c0490 100644 --- a/src/include/bootmem.h +++ b/src/include/bootmem.h @@ -39,8 +39,9 @@ BM_MEM_VENDOR_RSVD, /* Vendor Reserved */ BM_MEM_BL31, /* Arm64 BL31 exectuable */ BM_MEM_TABLE, /* Ram configuration tables are kept in */ + BM_MEM_OPENSBI, /* Risc-V OpenSBI */ /* Tags below this point are ignored for the OS table. */ - BM_MEM_OS_CUTOFF = BM_MEM_TABLE, + BM_MEM_OS_CUTOFF = BM_MEM_OPENSBI, BM_MEM_RAMSTAGE, BM_MEM_PAYLOAD, BM_MEM_LAST, /* Last entry in this list */ diff --git a/src/include/program_loading.h b/src/include/program_loading.h index 7be59e2..b10ab3a 100644 --- a/src/include/program_loading.h +++ b/src/include/program_loading.h @@ -38,6 +38,7 @@ PROG_BL31, PROG_BL32, PROG_POSTCAR, + PROG_OPENSBI, };
/* diff --git a/src/include/symbols.h b/src/include/symbols.h index b67286a..891585c 100644 --- a/src/include/symbols.h +++ b/src/include/symbols.h @@ -57,7 +57,7 @@ DECLARE_REGION(framebuffer) DECLARE_REGION(pdpt) DECLARE_REGION(bl31) - +DECLARE_REGION(opensbi) /* * Put this into a .c file accessing a linker script region to mark that region * as "optional". If it is defined in memlayout.ld (or anywhere else), the diff --git a/src/lib/bootmem.c b/src/lib/bootmem.c index 01ad3e8..b600ff3 100644 --- a/src/lib/bootmem.c +++ b/src/lib/bootmem.c @@ -61,6 +61,8 @@ return LB_MEM_VENDOR_RSVD; case BM_MEM_BL31: return LB_MEM_RESERVED; + case BM_MEM_OPENSBI: + return LB_MEM_RESERVED; case BM_MEM_TABLE: return LB_MEM_TABLE; default: @@ -147,6 +149,7 @@ { BM_MEM_UNUSABLE, "UNUSABLE" }, { BM_MEM_VENDOR_RSVD, "VENDOR RESERVED" }, { BM_MEM_BL31, "BL31" }, + { BM_MEM_OPENSBI, "OPENSBI" }, { BM_MEM_TABLE, "CONFIGURATION TABLES" }, { BM_MEM_RAMSTAGE, "RAMSTAGE" }, { BM_MEM_PAYLOAD, "PAYLOAD" },
Julius Werner has posted comments on this change. ( https://review.coreboot.org/c/coreboot/+/34140 )
Change subject: lib/bootmem: Prepare for OpenSBI ......................................................................
Patch Set 2: Code-Review+2
(1 comment)
https://review.coreboot.org/c/coreboot/+/34140/2/src/include/bootmem.h File src/include/bootmem.h:
https://review.coreboot.org/c/coreboot/+/34140/2/src/include/bootmem.h@40 PS2, Line 40: BM_MEM_BL31, /* Arm64 BL31 exectuable */ nit: why not insert here so we don't have to churn the cutoff line for every new type?
Hello Julius Werner, Philipp Deppenwiese, build bot (Jenkins), Philipp Hug, Xiang Wang,
I'd like you to reexamine a change. Please visit
https://review.coreboot.org/c/coreboot/+/34140
to look at the new patch set (#3).
Change subject: lib/bootmem: Prepare for OpenSBI ......................................................................
lib/bootmem: Prepare for OpenSBI
Add a new bootmem memory type OpenSBI. It's similar to BL31 on aarch64.
Required for OpenSBI integration.
Change-Id: I5ceafd5a295f4284e99e12f7ea2aa4c6d1dbb188 Signed-off-by: Patrick Rudolph patrick.rudolph@9elements.com --- M src/include/bootmem.h M src/include/program_loading.h M src/include/symbols.h M src/lib/bootmem.c 4 files changed, 6 insertions(+), 0 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/40/34140/3
Patrick Rudolph has posted comments on this change. ( https://review.coreboot.org/c/coreboot/+/34140 )
Change subject: lib/bootmem: Prepare for OpenSBI ......................................................................
Patch Set 3:
(1 comment)
https://review.coreboot.org/c/coreboot/+/34140/2/src/include/bootmem.h File src/include/bootmem.h:
https://review.coreboot.org/c/coreboot/+/34140/2/src/include/bootmem.h@40 PS2, Line 40: BM_MEM_BL31, /* Arm64 BL31 exectuable */
nit: why not insert here so we don't have to churn the cutoff line for every new type?
Done
Julius Werner has posted comments on this change. ( https://review.coreboot.org/c/coreboot/+/34140 )
Change subject: lib/bootmem: Prepare for OpenSBI ......................................................................
Patch Set 3: Code-Review+2
Philipp Deppenwiese has submitted this change and it was merged. ( https://review.coreboot.org/c/coreboot/+/34140 )
Change subject: lib/bootmem: Prepare for OpenSBI ......................................................................
lib/bootmem: Prepare for OpenSBI
Add a new bootmem memory type OpenSBI. It's similar to BL31 on aarch64.
Required for OpenSBI integration.
Change-Id: I5ceafd5a295f4284e99e12f7ea2aa4c6d1dbb188 Signed-off-by: Patrick Rudolph patrick.rudolph@9elements.com Reviewed-on: https://review.coreboot.org/c/coreboot/+/34140 Tested-by: build bot (Jenkins) no-reply@coreboot.org Reviewed-by: Julius Werner jwerner@chromium.org --- M src/include/bootmem.h M src/include/program_loading.h M src/include/symbols.h M src/lib/bootmem.c 4 files changed, 6 insertions(+), 0 deletions(-)
Approvals: build bot (Jenkins): Verified Julius Werner: Looks good to me, approved
diff --git a/src/include/bootmem.h b/src/include/bootmem.h index c935cb9..2e33fcd 100644 --- a/src/include/bootmem.h +++ b/src/include/bootmem.h @@ -37,6 +37,7 @@ BM_MEM_NVS, /* ACPI NVS Memory */ BM_MEM_UNUSABLE, /* Unusable address space */ BM_MEM_VENDOR_RSVD, /* Vendor Reserved */ + BM_MEM_OPENSBI, /* Risc-V OpenSBI */ BM_MEM_BL31, /* Arm64 BL31 exectuable */ BM_MEM_TABLE, /* Ram configuration tables are kept in */ /* Tags below this point are ignored for the OS table. */ diff --git a/src/include/program_loading.h b/src/include/program_loading.h index 5ac74bf..6dec192 100644 --- a/src/include/program_loading.h +++ b/src/include/program_loading.h @@ -38,6 +38,7 @@ PROG_BL31, PROG_BL32, PROG_POSTCAR, + PROG_OPENSBI, };
/* diff --git a/src/include/symbols.h b/src/include/symbols.h index b67286a..cc27275 100644 --- a/src/include/symbols.h +++ b/src/include/symbols.h @@ -56,6 +56,7 @@ DECLARE_REGION(soc_registers) DECLARE_REGION(framebuffer) DECLARE_REGION(pdpt) +DECLARE_REGION(opensbi) DECLARE_REGION(bl31)
/* diff --git a/src/lib/bootmem.c b/src/lib/bootmem.c index 01ad3e8..45f7fe261 100644 --- a/src/lib/bootmem.c +++ b/src/lib/bootmem.c @@ -59,6 +59,8 @@ return LB_MEM_UNUSABLE; case BM_MEM_VENDOR_RSVD: return LB_MEM_VENDOR_RSVD; + case BM_MEM_OPENSBI: + return LB_MEM_RESERVED; case BM_MEM_BL31: return LB_MEM_RESERVED; case BM_MEM_TABLE: @@ -147,6 +149,7 @@ { BM_MEM_UNUSABLE, "UNUSABLE" }, { BM_MEM_VENDOR_RSVD, "VENDOR RESERVED" }, { BM_MEM_BL31, "BL31" }, + { BM_MEM_OPENSBI, "OPENSBI" }, { BM_MEM_TABLE, "CONFIGURATION TABLES" }, { BM_MEM_RAMSTAGE, "RAMSTAGE" }, { BM_MEM_PAYLOAD, "PAYLOAD" },