diff options
author | Angel Pons <th3fanbus@gmail.com> | 2021-11-10 17:47:22 +0100 |
---|---|---|
committer | Paul Fagerburg <pfagerburg@chromium.org> | 2021-11-11 22:44:18 +0000 |
commit | 1297b9c74d419e84d7764a4939d34768096de7b1 (patch) | |
tree | 29b25eac2b9c40ff04af658ecc9ac5dd92ae1dfd /src | |
parent | b7a6a1e4ac2bca3632a8dc00406d3bb77db2073c (diff) |
azalia_device: Report if codec verb loading failed
Handle the return value of `azalia_program_verb_table()` and print
different messages accordingly.
Change-Id: I99e9e1416217c5e67c529944736affb31f9c7d2f
Signed-off-by: Angel Pons <th3fanbus@gmail.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/59115
Reviewed-by: Arthur Heymans <arthur@aheymans.xyz>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Diffstat (limited to 'src')
-rw-r--r-- | src/device/azalia_device.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/src/device/azalia_device.c b/src/device/azalia_device.c index c3bb91b99f..c390db18fa 100644 --- a/src/device/azalia_device.c +++ b/src/device/azalia_device.c @@ -261,8 +261,11 @@ static void codec_init(struct device *dev, u8 *base, int addr) printk(BIOS_DEBUG, "azalia_audio: verb_size: %u\n", verb_size); /* 3 */ - azalia_program_verb_table(base, verb, verb_size); - printk(BIOS_DEBUG, "azalia_audio: verb loaded.\n"); + const int rc = azalia_program_verb_table(base, verb, verb_size); + if (rc < 0) + printk(BIOS_DEBUG, "azalia_audio: verb not loaded.\n"); + else + printk(BIOS_DEBUG, "azalia_audio: verb loaded.\n"); mainboard_azalia_program_runtime_verbs(base, reg32); } |