summaryrefslogtreecommitdiff
path: root/sound/soc/xilinx
diff options
context:
space:
mode:
authorLad Prabhakar <prabhakar.mahadev-lad.rj@bp.renesas.com>2021-12-21 17:00:59 +0000
committerMark Brown <broonie@kernel.org>2021-12-21 18:05:42 +0000
commitc2efaf8f2d53ffa2ecc487e21c62d13bbb8d88c3 (patch)
treea4af80e06b5568f3e7b93f2456171a03c54ccb93 /sound/soc/xilinx
parent15443f6cab25762272312373226d3fd2a742404f (diff)
ASoC: xlnx: Use platform_get_irq() to get the interrupt
platform_get_resource(pdev, IORESOURCE_IRQ, ..) relies on static allocation of IRQ resources in DT core code, this causes an issue when using hierarchical interrupt domains using "interrupts" property in the node as this bypasses the hierarchical setup and messes up the irq chaining. In preparation for removal of static setup of IRQ resource from DT core code use platform_get_irq(). Signed-off-by: Lad Prabhakar <prabhakar.mahadev-lad.rj@bp.renesas.com> Link: https://lore.kernel.org/r/20211221170100.27423-2-prabhakar.mahadev-lad.rj@bp.renesas.com Signed-off-by: Mark Brown <broonie@kernel.org>
Diffstat (limited to 'sound/soc/xilinx')
-rw-r--r--sound/soc/xilinx/xlnx_spdif.c10
1 files changed, 3 insertions, 7 deletions
diff --git a/sound/soc/xilinx/xlnx_spdif.c b/sound/soc/xilinx/xlnx_spdif.c
index e2ca087adee6..cba0e868a7d7 100644
--- a/sound/soc/xilinx/xlnx_spdif.c
+++ b/sound/soc/xilinx/xlnx_spdif.c
@@ -237,7 +237,6 @@ MODULE_DEVICE_TABLE(of, xlnx_spdif_of_match);
static int xlnx_spdif_probe(struct platform_device *pdev)
{
int ret;
- struct resource *res;
struct snd_soc_dai_driver *dai_drv;
struct spdif_dev_data *ctx;
@@ -273,13 +272,10 @@ static int xlnx_spdif_probe(struct platform_device *pdev)
if (ctx->mode) {
dai_drv = &xlnx_spdif_tx_dai;
} else {
- res = platform_get_resource(pdev, IORESOURCE_IRQ, 0);
- if (!res) {
- dev_err(dev, "No IRQ resource found\n");
- ret = -ENODEV;
+ ret = platform_get_irq(pdev, 0);
+ if (ret < 0)
goto clk_err;
- }
- ret = devm_request_irq(dev, res->start,
+ ret = devm_request_irq(dev, ret,
xlnx_spdifrx_irq_handler,
0, "XLNX_SPDIF_RX", ctx);
if (ret) {