ASoC: xilinx: xlnx_spdif: Preserve devm_request_irq() error codes

devm_request_irq() can return various error codes, such as -EINVAL,
-ENOTCONN, -ENOMEM, -ENOSYS, and -EBUSY. However, the driver
overwrites all of them with -ENODEV, which hides the actual cause of
the failure.
Also, devm_request_irq() already reports failures internally, so the
additional dev_err() call is redundant.
Return the original error code and remove the duplicate error message.

Signed-off-by: bui duc phuc <phucduc.bui@gmail.com>
Reviewed-by: Michal Simek <michal.simek@amd.com>
Link: https://patch.msgid.link/20260710102138.29347-3-phucduc.bui@gmail.com
Signed-off-by: Mark Brown <broonie@kernel.org>
This commit is contained in:
bui duc phuc 2026-07-10 17:21:37 +07:00 committed by Mark Brown
parent 14b68141bc
commit cb32e3acb1
No known key found for this signature in database
GPG Key ID: 24D68B725D5487D0

View File

@ -274,10 +274,8 @@ static int xlnx_spdif_probe(struct platform_device *pdev)
ret = devm_request_irq(dev, ret,
xlnx_spdifrx_irq_handler,
0, "XLNX_SPDIF_RX", ctx);
if (ret) {
dev_err(dev, "spdif rx irq request failed\n");
return -ENODEV;
}
if (ret)
return ret;
init_waitqueue_head(&ctx->chsts_q);
dai_drv = &xlnx_spdif_rx_dai;