summaryrefslogtreecommitdiff
path: root/src/lib
diff options
context:
space:
mode:
authorKyösti Mälkki <kyosti.malkki@gmail.com>2020-04-20 10:21:39 +0300
committerPatrick Georgi <pgeorgi@google.com>2020-05-26 15:04:08 +0000
commitfcbbb911162aa4dea1fc7fcc8794b22f86579fe8 (patch)
treee903cf984495a2e79be392dfb853f7f9161e867f /src/lib
parent1c3faabf2472c5eee9ceabc233896e7c28e0d863 (diff)
downloadcoreboot-fcbbb911162aa4dea1fc7fcc8794b22f86579fe8.tar.xz
Remove MAYBE_STATIC_BSS and ENV_STAGE_HAS_BSS_SECTION
After removal of CAR_MIGRATION there are no more reasons to carry around ENV_STAGE_HAS_BSS_SECTION=n case. Replace 'MAYBE_STATIC_BSS' with 'static' and remove explicit zero-initializers. Change-Id: I14dd9f52da5b06f0116bd97496cf794e5e71bc37 Signed-off-by: Kyösti Mälkki <kyosti.malkki@gmail.com> Reviewed-on: https://review.coreboot.org/c/coreboot/+/40535 Tested-by: build bot (Jenkins) <no-reply@coreboot.org> Reviewed-by: Arthur Heymans <arthur@aheymans.xyz> Reviewed-by: Duncan Laurie <dlaurie@chromium.org> Reviewed-by: Julius Werner <jwerner@chromium.org> Reviewed-by: Furquan Shaikh <furquan@google.com>
Diffstat (limited to 'src/lib')
-rw-r--r--src/lib/imd_cbmem.c2
-rw-r--r--src/lib/lzma.c2
-rw-r--r--src/lib/program.ld2
3 files changed, 3 insertions, 3 deletions
diff --git a/src/lib/imd_cbmem.c b/src/lib/imd_cbmem.c
index 2f065ff7d2..d06a9e9416 100644
--- a/src/lib/imd_cbmem.c
+++ b/src/lib/imd_cbmem.c
@@ -19,7 +19,7 @@ static struct imd imd;
void *cbmem_top(void)
{
if (ENV_ROMSTAGE) {
- MAYBE_STATIC_BSS void *top = NULL;
+ static void *top;
if (top)
return top;
top = cbmem_top_chipset();
diff --git a/src/lib/lzma.c b/src/lib/lzma.c
index 16b6e228fb..d2e3e4b45d 100644
--- a/src/lib/lzma.c
+++ b/src/lib/lzma.c
@@ -26,7 +26,7 @@ size_t ulzman(const void *src, size_t srcn, void *dst, size_t dstn)
int res;
CLzmaDecoderState state;
SizeT mallocneeds;
- MAYBE_STATIC_BSS unsigned char scratchpad[15980];
+ static unsigned char scratchpad[15980];
const unsigned char *cp;
if (srcn < data_offset) {
diff --git a/src/lib/program.ld b/src/lib/program.ld
index b56a400ceb..734f040fcd 100644
--- a/src/lib/program.ld
+++ b/src/lib/program.ld
@@ -112,7 +112,7 @@
}
#endif
-#if ENV_STAGE_HAS_BSS_SECTION && !ENV_CACHE_AS_RAM
+#if !ENV_CACHE_AS_RAM
.bss . : {
. = ALIGN(ARCH_POINTER_ALIGN_SIZE);
_bss = .;