diff options
author | Angel Pons <th3fanbus@gmail.com> | 2018-10-02 11:58:28 +0200 |
---|---|---|
committer | Martin Roth <martinroth@google.com> | 2018-10-05 01:45:46 +0000 |
commit | cc335c756720ad8ba345e593a028761394443972 (patch) | |
tree | 5bee6974398462089a17a10f6a271688388fe90b /src/lib | |
parent | 00b539452ba44b4cac4b73dd97841ec87ba1d964 (diff) | |
download | coreboot-cc335c756720ad8ba345e593a028761394443972.tar.xz |
src/lib/edid.c: Replace #if 1 with something useful
Since `#if 1` is rather useless, and the code inside it is just several
`printk(BIOS_SPEW)`, using `if (console_log_level(BIOS_SPEW))` instead
seems more reasonable.
Change-Id: I93dcab3db958480626fea6d99ab5289ebff04e8f
Signed-off-by: Angel Pons <th3fanbus@gmail.com>
Reviewed-on: https://review.coreboot.org/28872
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Julius Werner <jwerner@chromium.org>
Diffstat (limited to 'src/lib')
-rw-r--r-- | src/lib/edid.c | 13 |
1 files changed, 7 insertions, 6 deletions
diff --git a/src/lib/edid.c b/src/lib/edid.c index 9cf9b8a1ed..37939eb081 100644 --- a/src/lib/edid.c +++ b/src/lib/edid.c @@ -204,12 +204,13 @@ detailed_block(struct edid *result_edid, unsigned char *x, int in_extension, { struct edid *out = &tmp_edid; int i; -#if 1 - printk(BIOS_SPEW, "Hex of detail: "); - for (i = 0; i < 18; i++) - printk(BIOS_SPEW, "%02x", x[i]); - printk(BIOS_SPEW, "\n"); -#endif + + if (console_log_level(BIOS_SPEW)) { + printk(BIOS_SPEW, "Hex of detail: "); + for (i = 0; i < 18; i++) + printk(BIOS_SPEW, "%02x", x[i]); + printk(BIOS_SPEW, "\n"); + } /* Result might already have some valid fields like mode_is_supported */ *out = *result_edid; |