mirror of
https://github.com/AsahiLinux/u-boot
synced 2024-11-10 15:14:43 +00:00
x86: sound: Correct error handling
A few functions have changed to return pin numbers or I2C addresses. The error checking for some of the callers is therefore wrong. Fix them. Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Bin Meng <bmeng.cn@gmail.com>
This commit is contained in:
parent
a0ed800376
commit
dd30c5bb57
2 changed files with 3 additions and 3 deletions
|
@ -54,13 +54,13 @@ static int da7219_acpi_fill_ssdt(const struct udevice *dev,
|
|||
acpigen_write_name(ctx, "_CRS");
|
||||
acpigen_write_resourcetemplate_header(ctx);
|
||||
ret = acpi_device_write_i2c_dev(ctx, dev);
|
||||
if (ret)
|
||||
if (ret < 0)
|
||||
return log_msg_ret("i2c", ret);
|
||||
|
||||
/* Use either Interrupt() or GpioInt() */
|
||||
ret = acpi_device_write_interrupt_or_gpio(ctx, (struct udevice *)dev,
|
||||
"req-gpios");
|
||||
if (ret)
|
||||
if (ret < 0)
|
||||
return log_msg_ret("irq_gpio", ret);
|
||||
acpigen_write_resourcetemplate_footer(ctx);
|
||||
|
||||
|
|
|
@ -69,7 +69,7 @@ static int max98357a_acpi_fill_ssdt(const struct udevice *dev,
|
|||
acpigen_write_name(ctx, "_CRS");
|
||||
acpigen_write_resourcetemplate_header(ctx);
|
||||
ret = acpi_device_write_gpio_desc(ctx, &priv->sdmode_gpio);
|
||||
if (ret)
|
||||
if (ret < 0)
|
||||
return log_msg_ret("gpio", ret);
|
||||
acpigen_write_resourcetemplate_footer(ctx);
|
||||
|
||||
|
|
Loading…
Reference in a new issue