diff options
author | Julius Werner <jwerner@chromium.org> | 2022-01-21 17:06:20 -0800 |
---|---|---|
committer | Julius Werner <jwerner@chromium.org> | 2022-02-07 23:29:09 +0000 |
commit | e9665959edeba6ae2d5364c4f7339704b6b6fd42 (patch) | |
tree | e3cd9e0e6e91c9b6bd5c6f586a9abee1d654b5dd /src/lib/cbmem_stage_cache.c | |
parent | 266041f0e62296737617cc2fcfa97f31e2b43aea (diff) | |
download | coreboot-e9665959edeba6ae2d5364c4f7339704b6b6fd42.tar.gz coreboot-e9665959edeba6ae2d5364c4f7339704b6b6fd42.tar.bz2 coreboot-e9665959edeba6ae2d5364c4f7339704b6b6fd42.zip |
treewide: Remove "ERROR: "/"WARN: " prefixes from log messages
Now that the console system itself will clearly differentiate loglevels,
it is no longer necessary to explicitly add "ERROR: " in front of every
BIOS_ERR message to help it stand out more (and allow automated tooling
to grep for it). Removing all these extra .rodata characters should save
us a nice little amount of binary size.
This patch was created by running
find src/ -type f -exec perl -0777 -pi -e 's/printk\(\s*BIOS_ERR,\s*"ERROR: /printk\(BIOS_ERR, "/gi' '{}' ';'
and doing some cursory review/cleanup on the result. Then doing the same
thing for BIOS_WARN with
's/printk\(\s*BIOS_WARNING,\s*"WARN(ING)?: /printk\(BIOS_WARNING, "/gi'
Signed-off-by: Julius Werner <jwerner@chromium.org>
Change-Id: I3d0573acb23d2df53db6813cb1a5fc31b5357db8
Reviewed-on: https://review.coreboot.org/c/coreboot/+/61309
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: HAOUAS Elyes <ehaouas@noos.fr>
Reviewed-by: Lance Zhao
Reviewed-by: Jason Glenesk <jason.glenesk@gmail.com>
Diffstat (limited to 'src/lib/cbmem_stage_cache.c')
-rw-r--r-- | src/lib/cbmem_stage_cache.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/lib/cbmem_stage_cache.c b/src/lib/cbmem_stage_cache.c index 28cc242f1cc3..b45c9505f8ae 100644 --- a/src/lib/cbmem_stage_cache.c +++ b/src/lib/cbmem_stage_cache.c @@ -13,7 +13,7 @@ void stage_cache_add(int stage_id, const struct prog *stage) meta = cbmem_add(CBMEM_ID_STAGEx_META + stage_id, sizeof(*meta)); if (meta == NULL) { - printk(BIOS_ERR, "Error: Can't add %x metadata to cbmem\n", + printk(BIOS_ERR, "Can't add %x metadata to cbmem\n", CBMEM_ID_STAGEx_META + stage_id); return; } @@ -23,7 +23,7 @@ void stage_cache_add(int stage_id, const struct prog *stage) c = cbmem_add(CBMEM_ID_STAGEx_CACHE + stage_id, prog_size(stage)); if (c == NULL) { - printk(BIOS_ERR, "Error: Can't add stage_cache %x to cbmem\n", + printk(BIOS_ERR, "Can't add stage_cache %x to cbmem\n", CBMEM_ID_STAGEx_CACHE + stage_id); return; } @@ -51,7 +51,7 @@ void stage_cache_get_raw(int stage_id, void **base, size_t *size) e = cbmem_entry_find(CBMEM_ID_STAGEx_RAW + stage_id); if (e == NULL) { - printk(BIOS_ERR, "Error: Can't find raw %x data in cbmem\n", + printk(BIOS_ERR, "Can't find raw %x data in cbmem\n", CBMEM_ID_STAGEx_RAW + stage_id); return; } @@ -72,7 +72,7 @@ void stage_cache_load_stage(int stage_id, struct prog *stage) meta = cbmem_find(CBMEM_ID_STAGEx_META + stage_id); if (meta == NULL) { - printk(BIOS_ERR, "Error: Can't find %x metadata in cbmem\n", + printk(BIOS_ERR, "Can't find %x metadata in cbmem\n", CBMEM_ID_STAGEx_META + stage_id); return; } @@ -80,7 +80,7 @@ void stage_cache_load_stage(int stage_id, struct prog *stage) e = cbmem_entry_find(CBMEM_ID_STAGEx_CACHE + stage_id); if (e == NULL) { - printk(BIOS_ERR, "Error: Can't find stage_cache %x in cbmem\n", + printk(BIOS_ERR, "Can't find stage_cache %x in cbmem\n", CBMEM_ID_STAGEx_CACHE + stage_id); return; } |