ASoC: fsl_sai: add IRQF_SHARED
Subsystems (3)
PATCH 1/1 ASoC: fsl_sai: add IRQF_SHARED
The LS1028A SoC uses the same interrupt line for adjacent SAIs. Use IRQF_SHARED to be able to use these SAIs simultaneously.
--- sound/soc/fsl/fsl_sai.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)
sound/soc/fsl/fsl_sai.c +2 -1
@@ -958,7 +958,8 @@ static int fsl_sai_probe(struct platform_device *pdev)if (irq <0 )return irq; - ret =devm_request_irq (&pdev->dev, irq, fsl_sai_isr,0 , np->name, sai); + ret =devm_request_irq (&pdev->dev, irq, fsl_sai_isr,IRQF_SHARED , + np->name, sai);if (ret) {dev_err (&pdev->dev,"failed to claim irq %u\n" , irq);return ret;
Signature · 1 line
2.20.1
Hi Michael,
Quoted 3 lines · Michael Walle
The LS1028A SoC uses the same interrupt line for adjacent SAIs. Use
IRQF_SHAREDto be able to use these SAIs simultaneously.
On i.MX8M SAI5 and SAI6 share the same interrupt number too:
Thanks
Quoted 4 lines · Michael Walle
The LS1028A SoC uses the same interrupt line for adjacent SAIs. Use
IRQF_SHAREDto be able to use these SAIs simultaneously.Signed-off-by Michael Walle <[email protected]>
Thanks
Quoted 21 lines
--- sound/soc/fsl/fsl_sai.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)sound/soc/fsl/fsl_sai.c +2
-1@@ -958,7 +958,8 @@ static int fsl_sai_probe(struct platform_device *pdev)if (irq <0 )return irq; - ret =devm_request_irq (&pdev->dev, irq, fsl_sai_isr,0 , np->name, sai); + ret =devm_request_irq (&pdev->dev, irq, fsl_sai_isr,IRQF_SHARED , + np->name, sai);if (ret) {dev_err (&pdev->dev,"failed to claim irq %u\n" , irq);return ret;Signature · 1 line
2.20.1
Quoted 3 lines · Michael Walle
The LS1028A SoC uses the same interrupt line for adjacent SAIs. Use
IRQF_SHAREDto be able to use these SAIs simultaneously.
Hi Michael,
Thanks for the patch. We have a similar change inside our internal tree (it is on my long TODO list to upstream :D).
We add the shared flag conditionally on a dts property.
Do you think it is a good idea to always add shared flag? I'm thinking on SAI IP integrations where the interrupt is edge triggered.
AFAIK edge triggered interrupts do not get along very well with sharing an interrupt line.
Hi Daniel,
Am 2019-12-05 09:43, schrieb Daniel Baluta:
Quoted 7 lines · Michael Walle
Quoted 3 lines
The LS1028A SoC uses the same interrupt line for adjacent SAIs. Use
IRQF_SHAREDto be able to use these SAIs simultaneously.Hi Michael,
Quoted 7 lines
Thanks for the patch. We have a similar change inside our internal tree (it is on my long TODO list to upstream :D).
We add the shared flag conditionally on a dts property.
Do you think it is a good idea to always add shared flag? I'm thinking on SAI IP integrations where the interrupt is edge triggered.
Mhh, I don't really get the point to make the flag conditionally. If there is only one user, the flag won't hurt, correct?
If there are two users, we need the flag anyway.
Quoted 2 lines
AFAIK edge triggered interrupts do not get along very well with sharing an interrupt line.
So in that case you shouldn't use shared edge triggered interrupts in the SoC in the first place, I guess.
-michael
Daniel Baluta
Acked-byQuoted 23 lines · Michael Walle
Hi Daniel,
Am 2019-12-05 09:43, schrieb Daniel Baluta:
Quoted 8 lines
Quoted 3 lines · Michael Walle
The LS1028A SoC uses the same interrupt line for adjacent SAIs. Use
IRQF_SHAREDto be able to use these SAIs simultaneously.Hi Michael,
Quoted 7 lines
Thanks for the patch. We have a similar change inside our internal tree (it is on my long TODO list to upstream :D).
We add the shared flag conditionally on a dts property.
Do you think it is a good idea to always add shared flag? I'm thinking on SAI IP integrations where the interrupt is edge triggered.
Mhh, I don't really get the point to make the flag conditionally. If there is only one user, the flag won't hurt, correct?
Quoted 8 lines
If there are two users, we need the flag anyway.
Quoted 2 lines
AFAIK edge triggered interrupts do not get along very well with sharing an interrupt line.
So in that case you shouldn't use shared edge triggered interrupts in the
SoC in the first place, I guess.
I think you make a good point. I was thinking that it would hurt the single user case. But it is fine.
Thanks for the patch.
Mark Brown
maintainerApplied "ASoC: fsl_sai: add IRQF_SHARED" to the asoc tree
In reply to Michael WalleThe patch
ASoC: fsl_sai: add IRQF_SHARED
has been applied to the asoc tree at
https://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound.git for-5.6
All being well this means that it will be integrated into the linux-next tree (usually sometime in the next 24 hours) and sent to Linus during the next merge window (or sooner if it is a bug fix), however if problems are discovered then the patch may be dropped or reverted.
You may get further e-mails resulting from automated or manual testing and review of the tree, please engage with people reporting problems and send followup patches addressing any issues that are reported if needed.
If any updates are required or you are submitting further changes they should be sent as incremental updates against current git, existing patches will not be replaced.
Please add any relevant lists and maintainers to the CCs when replying to this mail.
Thanks,
Mark
From 2eb2d314a80eb8bb1a6faf2a74321d4497e1687d Mon Sep 17 00:00:00 2001
From: Michael Walle <[email protected]>
Date: Thu, 28 Nov 2019 23:38:02 +0100
Subject: [PATCH] ASoC: fsl_sai: add IRQF_SHARED
The LS1028A SoC uses the same interrupt line for adjacent SAIs. Use IRQF_SHARED to be able to use these SAIs simultaneously.
--- sound/soc/fsl/fsl_sai.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)
sound/soc/fsl/fsl_sai.c +2 -1
@@ -958,7 +958,8 @@ static int fsl_sai_probe(struct platform_device *pdev)if (irq <0 )return irq; - ret =devm_request_irq (&pdev->dev, irq, fsl_sai_isr,0 , np->name, sai); + ret =devm_request_irq (&pdev->dev, irq, fsl_sai_isr,IRQF_SHARED , + np->name, sai);if (ret) {dev_err (&pdev->dev,"failed to claim irq %u\n" , irq);return ret;
Signature · 1 line
2.20.1