* [PATCH] ASoC: codecs-ac97: make selectable in config
@ 2015-05-09 22:12 Maciej S. Szmigiero
2015-05-12 17:58 ` Mark Brown
2015-05-22 12:41 ` Mark Brown
0 siblings, 2 replies; 11+ messages in thread
From: Maciej S. Szmigiero @ 2015-05-09 22:12 UTC (permalink / raw)
To: alsa-devel
Cc: Liam Girdwood, Mark Brown, Jaroslav Kysela, Takashi Iwai,
Lars-Peter Clausen, Brian Austin, Bard Liao, Oder Chiou,
Wolfram Sang, linux-kernel, Fabio Estevam
Make generic ASoC AC'97 CODEC selectable in config.
This way this driver can be used for platforms which don't need
specialized AC'97 CODEC drivers but which are not directly
selectable in config themselves (for example DT based ones).
Signed-off-by: Maciej Szmigiero <mail@maciej.szmigiero.name>
--- a/sound/soc/codecs/Kconfig
+++ b/sound/soc/codecs/Kconfig
@@ -16,7 +16,7 @@ config SND_SOC_ALL_CODECS
select SND_SOC_88PM860X if MFD_88PM860X
select SND_SOC_L3
select SND_SOC_AB8500_CODEC if ABX500_CORE
- select SND_SOC_AC97_CODEC if SND_SOC_AC97_BUS
+ select SND_SOC_AC97_CODEC
select SND_SOC_AD1836 if SPI_MASTER
select SND_SOC_AD193X_SPI if SPI_MASTER
select SND_SOC_AD193X_I2C if I2C
@@ -212,8 +212,9 @@ config SND_SOC_AB8500_CODEC
tristate
config SND_SOC_AC97_CODEC
- tristate
+ tristate "Build generic ASoC AC97 CODEC driver"
select SND_AC97_CODEC
+ select SND_SOC_AC97_BUS
config SND_SOC_AD1836
tristate
^ permalink raw reply [flat|nested] 11+ messages in thread
* Re: [PATCH] ASoC: codecs-ac97: make selectable in config
2015-05-09 22:12 [PATCH] ASoC: codecs-ac97: make selectable in config Maciej S. Szmigiero
@ 2015-05-12 17:58 ` Mark Brown
2015-05-13 20:57 ` Maciej S. Szmigiero
2015-05-22 12:41 ` Mark Brown
1 sibling, 1 reply; 11+ messages in thread
From: Mark Brown @ 2015-05-12 17:58 UTC (permalink / raw)
To: Maciej S. Szmigiero
Cc: alsa-devel, Liam Girdwood, Jaroslav Kysela, Takashi Iwai,
Lars-Peter Clausen, Brian Austin, Bard Liao, Oder Chiou,
Wolfram Sang, linux-kernel, Fabio Estevam
[-- Attachment #1: Type: text/plain, Size: 580 bytes --]
On Sun, May 10, 2015 at 12:12:04AM +0200, Maciej S. Szmigiero wrote:
> @@ -16,7 +16,7 @@ config SND_SOC_ALL_CODECS
> select SND_SOC_88PM860X if MFD_88PM860X
> select SND_SOC_L3
> select SND_SOC_AB8500_CODEC if ABX500_CORE
> - select SND_SOC_AC97_CODEC if SND_SOC_AC97_BUS
> + select SND_SOC_AC97_CODEC
> select SND_SOC_AD1836 if SPI_MASTER
> select SND_SOC_AD193X_SPI if SPI_MASTER
> select SND_SOC_AD193X_I2C if I2C
No, you're missing the point of what _ALL_CODECS does - it builds
everything possible. This will break the build for systems without
AC'97 support.
[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 473 bytes --]
^ permalink raw reply [flat|nested] 11+ messages in thread
* Re: [PATCH] ASoC: codecs-ac97: make selectable in config
2015-05-12 17:58 ` Mark Brown
@ 2015-05-13 20:57 ` Maciej S. Szmigiero
2015-05-14 17:53 ` Mark Brown
0 siblings, 1 reply; 11+ messages in thread
From: Maciej S. Szmigiero @ 2015-05-13 20:57 UTC (permalink / raw)
To: Mark Brown
Cc: alsa-devel, Liam Girdwood, Jaroslav Kysela, Takashi Iwai,
Lars-Peter Clausen, Brian Austin, Bard Liao, Oder Chiou,
Wolfram Sang, linux-kernel, Fabio Estevam
Thanks for looking into the patch.
W dniu 12.05.2015 19:58, Mark Brown pisze:
> On Sun, May 10, 2015 at 12:12:04AM +0200, Maciej S. Szmigiero wrote:
>
>> @@ -16,7 +16,7 @@ config SND_SOC_ALL_CODECS
>> select SND_SOC_88PM860X if MFD_88PM860X
>> select SND_SOC_L3
>> select SND_SOC_AB8500_CODEC if ABX500_CORE
>> - select SND_SOC_AC97_CODEC if SND_SOC_AC97_BUS
>> + select SND_SOC_AC97_CODEC
>> select SND_SOC_AD1836 if SPI_MASTER
>> select SND_SOC_AD193X_SPI if SPI_MASTER
>> select SND_SOC_AD193X_I2C if I2C
>
> No, you're missing the point of what _ALL_CODECS does - it builds
> everything possible. This will break the build for systems without
> AC'97 support.
How?
In the second hunk of the patch I've made SND_SOC_AC97_CODEC select
SND_SOC_AC97_BUS.
ASoC AC'97 CODEC uses only AC'97 symbols defined in
pci/ac97/ac97_codec.c, pci/ac97/ac97_pcm.c and sound/soc/soc-ac97.c.
pci/ac97/ac97_codec.c, pci/ac97/ac97_pcm.c will be built via
SND_SOC_ALL_CODECS -> SND_SOC_AC97_CODEC -> SND_AC97_CODEC dependency.
sound/soc/soc-ac97.c will be build via SND_SOC_ALL_CODECS ->
SND_SOC_AC97_CODEC -> SND_SOC_AC97_BUS dependency.
Best regards,
Maciej Szmigiero
^ permalink raw reply [flat|nested] 11+ messages in thread
* Re: [PATCH] ASoC: codecs-ac97: make selectable in config
2015-05-13 20:57 ` Maciej S. Szmigiero
@ 2015-05-14 17:53 ` Mark Brown
2015-05-14 18:46 ` Lars-Peter Clausen
0 siblings, 1 reply; 11+ messages in thread
From: Mark Brown @ 2015-05-14 17:53 UTC (permalink / raw)
To: Maciej S. Szmigiero
Cc: alsa-devel, Liam Girdwood, Jaroslav Kysela, Takashi Iwai,
Lars-Peter Clausen, Brian Austin, Bard Liao, Oder Chiou,
Wolfram Sang, linux-kernel, Fabio Estevam
[-- Attachment #1: Type: text/plain, Size: 914 bytes --]
On Wed, May 13, 2015 at 10:57:24PM +0200, Maciej S. Szmigiero wrote:
> W dniu 12.05.2015 19:58, Mark Brown pisze:
> > On Sun, May 10, 2015 at 12:12:04AM +0200, Maciej S. Szmigiero wrote:
> >> @@ -16,7 +16,7 @@ config SND_SOC_ALL_CODECS
> >> select SND_SOC_88PM860X if MFD_88PM860X
> >> select SND_SOC_L3
> >> select SND_SOC_AB8500_CODEC if ABX500_CORE
> >> - select SND_SOC_AC97_CODEC if SND_SOC_AC97_BUS
> >> + select SND_SOC_AC97_CODEC
> >> select SND_SOC_AD1836 if SPI_MASTER
> >> select SND_SOC_AD193X_SPI if SPI_MASTER
> >> select SND_SOC_AD193X_I2C if I2C
> > No, you're missing the point of what _ALL_CODECS does - it builds
> > everything possible. This will break the build for systems without
> > AC'97 support.
> How?
> In the second hunk of the patch I've made SND_SOC_AC97_CODEC select
> SND_SOC_AC97_BUS.
select doesn't respect dependencies, it'll just force on the selected
symbol.
[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 473 bytes --]
^ permalink raw reply [flat|nested] 11+ messages in thread
* Re: [PATCH] ASoC: codecs-ac97: make selectable in config
2015-05-14 17:53 ` Mark Brown
@ 2015-05-14 18:46 ` Lars-Peter Clausen
2015-05-14 19:10 ` Mark Brown
0 siblings, 1 reply; 11+ messages in thread
From: Lars-Peter Clausen @ 2015-05-14 18:46 UTC (permalink / raw)
To: Mark Brown, Maciej S. Szmigiero
Cc: alsa-devel, Liam Girdwood, Jaroslav Kysela, Takashi Iwai,
Brian Austin, Bard Liao, Oder Chiou, Wolfram Sang, linux-kernel,
Fabio Estevam
On 05/14/2015 07:53 PM, Mark Brown wrote:
> On Wed, May 13, 2015 at 10:57:24PM +0200, Maciej S. Szmigiero wrote:
>> W dniu 12.05.2015 19:58, Mark Brown pisze:
>>> On Sun, May 10, 2015 at 12:12:04AM +0200, Maciej S. Szmigiero wrote:
>
>>>> @@ -16,7 +16,7 @@ config SND_SOC_ALL_CODECS
>>>> select SND_SOC_88PM860X if MFD_88PM860X
>>>> select SND_SOC_L3
>>>> select SND_SOC_AB8500_CODEC if ABX500_CORE
>>>> - select SND_SOC_AC97_CODEC if SND_SOC_AC97_BUS
>>>> + select SND_SOC_AC97_CODEC
>>>> select SND_SOC_AD1836 if SPI_MASTER
>>>> select SND_SOC_AD193X_SPI if SPI_MASTER
>>>> select SND_SOC_AD193X_I2C if I2C
>
>>> No, you're missing the point of what _ALL_CODECS does - it builds
>>> everything possible. This will break the build for systems without
>>> AC'97 support.
>
>> How?
>> In the second hunk of the patch I've made SND_SOC_AC97_CODEC select
>> SND_SOC_AC97_BUS.
>
> select doesn't respect dependencies, it'll just force on the selected
> symbol.
The patch works fine, neither SND_SOC_AC97_BUS nor the symbols selected by
SND_SOC_AC97_BUS have any dependencies.
Although one might argue that only AC97 host driver should select
SND_SOC_AC97_BUS and the CODEC drivers should depend on it.
- Lars
^ permalink raw reply [flat|nested] 11+ messages in thread
* Re: [PATCH] ASoC: codecs-ac97: make selectable in config
2015-05-14 18:46 ` Lars-Peter Clausen
@ 2015-05-14 19:10 ` Mark Brown
2015-05-14 19:24 ` Lars-Peter Clausen
0 siblings, 1 reply; 11+ messages in thread
From: Mark Brown @ 2015-05-14 19:10 UTC (permalink / raw)
To: Lars-Peter Clausen
Cc: Maciej S. Szmigiero, alsa-devel, Liam Girdwood, Jaroslav Kysela,
Takashi Iwai, Brian Austin, Bard Liao, Oder Chiou, Wolfram Sang,
linux-kernel, Fabio Estevam
[-- Attachment #1: Type: text/plain, Size: 480 bytes --]
On Thu, May 14, 2015 at 08:46:09PM +0200, Lars-Peter Clausen wrote:
> On 05/14/2015 07:53 PM, Mark Brown wrote:
> >select doesn't respect dependencies, it'll just force on the selected
> >symbol.
> The patch works fine, neither SND_SOC_AC97_BUS nor the symbols selected by
> SND_SOC_AC97_BUS have any dependencies.
Does the select from SND_SOC_AC97_BUS actually happen if it is selected
by SND_SOC_ALL_CODECS? That's the issue, if it works now it's a
relatively recent thing.
[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 473 bytes --]
^ permalink raw reply [flat|nested] 11+ messages in thread
* Re: [PATCH] ASoC: codecs-ac97: make selectable in config
2015-05-14 19:10 ` Mark Brown
@ 2015-05-14 19:24 ` Lars-Peter Clausen
2015-05-14 19:28 ` Mark Brown
0 siblings, 1 reply; 11+ messages in thread
From: Lars-Peter Clausen @ 2015-05-14 19:24 UTC (permalink / raw)
To: Mark Brown
Cc: Maciej S. Szmigiero, alsa-devel, Liam Girdwood, Jaroslav Kysela,
Takashi Iwai, Brian Austin, Bard Liao, Oder Chiou, Wolfram Sang,
linux-kernel, Fabio Estevam
On 05/14/2015 09:10 PM, Mark Brown wrote:
> On Thu, May 14, 2015 at 08:46:09PM +0200, Lars-Peter Clausen wrote:
>> On 05/14/2015 07:53 PM, Mark Brown wrote:
>
>>> select doesn't respect dependencies, it'll just force on the selected
>>> symbol.
>
>> The patch works fine, neither SND_SOC_AC97_BUS nor the symbols selected by
>> SND_SOC_AC97_BUS have any dependencies.
>
> Does the select from SND_SOC_AC97_BUS actually happen if it is selected
> by SND_SOC_ALL_CODECS? That's the issue, if it works now it's a
> relatively recent thing.
I'm not sure I fully understand what you mean.
The Kconfig entry for the CODEC has no 'depends on'. It does a 'select
SND_SOC_AC97_BUS', which means all built time dependencies are pulled in
this way. So if SND_SOC_ALL_CODECS selects the CODEC unconditionally that
should work fine, since no dependencies are bypassed.
^ permalink raw reply [flat|nested] 11+ messages in thread
* Re: [PATCH] ASoC: codecs-ac97: make selectable in config
2015-05-14 19:24 ` Lars-Peter Clausen
@ 2015-05-14 19:28 ` Mark Brown
2015-05-14 19:38 ` Lars-Peter Clausen
0 siblings, 1 reply; 11+ messages in thread
From: Mark Brown @ 2015-05-14 19:28 UTC (permalink / raw)
To: Lars-Peter Clausen
Cc: Maciej S. Szmigiero, alsa-devel, Liam Girdwood, Jaroslav Kysela,
Takashi Iwai, Brian Austin, Bard Liao, Oder Chiou, Wolfram Sang,
linux-kernel, Fabio Estevam
[-- Attachment #1: Type: text/plain, Size: 750 bytes --]
On Thu, May 14, 2015 at 09:24:15PM +0200, Lars-Peter Clausen wrote:
> On 05/14/2015 09:10 PM, Mark Brown wrote:
> >Does the select from SND_SOC_AC97_BUS actually happen if it is selected
> >by SND_SOC_ALL_CODECS? That's the issue, if it works now it's a
> >relatively recent thing.
> I'm not sure I fully understand what you mean.
> The Kconfig entry for the CODEC has no 'depends on'. It does a 'select
> SND_SOC_AC97_BUS', which means all built time dependencies are pulled in
> this way. So if SND_SOC_ALL_CODECS selects the CODEC unconditionally that
> should work fine, since no dependencies are bypassed.
No, it's not just dependencies but also selects that get ignored (or
used to anyway like I say) - a select just forces the symbol on.
[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 473 bytes --]
^ permalink raw reply [flat|nested] 11+ messages in thread
* Re: [PATCH] ASoC: codecs-ac97: make selectable in config
2015-05-14 19:28 ` Mark Brown
@ 2015-05-14 19:38 ` Lars-Peter Clausen
2015-05-14 19:43 ` Mark Brown
0 siblings, 1 reply; 11+ messages in thread
From: Lars-Peter Clausen @ 2015-05-14 19:38 UTC (permalink / raw)
To: Mark Brown
Cc: Maciej S. Szmigiero, alsa-devel, Liam Girdwood, Jaroslav Kysela,
Takashi Iwai, Brian Austin, Bard Liao, Oder Chiou, Wolfram Sang,
linux-kernel, Fabio Estevam
On 05/14/2015 09:28 PM, Mark Brown wrote:
> On Thu, May 14, 2015 at 09:24:15PM +0200, Lars-Peter Clausen wrote:
>> On 05/14/2015 09:10 PM, Mark Brown wrote:
>
>>> Does the select from SND_SOC_AC97_BUS actually happen if it is selected
>>> by SND_SOC_ALL_CODECS? That's the issue, if it works now it's a
>>> relatively recent thing.
>
>> I'm not sure I fully understand what you mean.
>
>> The Kconfig entry for the CODEC has no 'depends on'. It does a 'select
>> SND_SOC_AC97_BUS', which means all built time dependencies are pulled in
>> this way. So if SND_SOC_ALL_CODECS selects the CODEC unconditionally that
>> should work fine, since no dependencies are bypassed.
>
> No, it's not just dependencies but also selects that get ignored (or
> used to anyway like I say) - a select just forces the symbol on.
>
select forces a symbol on regardless of whether its dependencies are met or
not. But for any symbol that is on, no matter whether it was manually
selected or selected by a 'select' from another symbol, any symbols selected
by that symbol will be turned on. It's been that way as long as I can remember.
^ permalink raw reply [flat|nested] 11+ messages in thread
* Re: [PATCH] ASoC: codecs-ac97: make selectable in config
2015-05-14 19:38 ` Lars-Peter Clausen
@ 2015-05-14 19:43 ` Mark Brown
0 siblings, 0 replies; 11+ messages in thread
From: Mark Brown @ 2015-05-14 19:43 UTC (permalink / raw)
To: Lars-Peter Clausen
Cc: Maciej S. Szmigiero, alsa-devel, Liam Girdwood, Jaroslav Kysela,
Takashi Iwai, Brian Austin, Bard Liao, Oder Chiou, Wolfram Sang,
linux-kernel, Fabio Estevam
[-- Attachment #1: Type: text/plain, Size: 504 bytes --]
On Thu, May 14, 2015 at 09:38:55PM +0200, Lars-Peter Clausen wrote:
> select forces a symbol on regardless of whether its dependencies are met or
> not. But for any symbol that is on, no matter whether it was manually
> selected or selected by a 'select' from another symbol, any symbols selected
> by that symbol will be turned on. It's been that way as long as I can
> remember.
Ah, good - that's not always been the case (or perhaps not always
reliably been the case which is about the same thing).
[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 473 bytes --]
^ permalink raw reply [flat|nested] 11+ messages in thread
* Re: [PATCH] ASoC: codecs-ac97: make selectable in config
2015-05-09 22:12 [PATCH] ASoC: codecs-ac97: make selectable in config Maciej S. Szmigiero
2015-05-12 17:58 ` Mark Brown
@ 2015-05-22 12:41 ` Mark Brown
1 sibling, 0 replies; 11+ messages in thread
From: Mark Brown @ 2015-05-22 12:41 UTC (permalink / raw)
To: Maciej S. Szmigiero
Cc: alsa-devel, Liam Girdwood, Jaroslav Kysela, Takashi Iwai,
Lars-Peter Clausen, Brian Austin, Bard Liao, Oder Chiou,
Wolfram Sang, linux-kernel, Fabio Estevam
[-- Attachment #1: Type: text/plain, Size: 141 bytes --]
On Sun, May 10, 2015 at 12:12:04AM +0200, Maciej S. Szmigiero wrote:
> Make generic ASoC AC'97 CODEC selectable in config.
Applied, thanks.
[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 473 bytes --]
^ permalink raw reply [flat|nested] 11+ messages in thread
end of thread, other threads:[~2015-05-22 13:06 UTC | newest]
Thread overview: 11+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-05-09 22:12 [PATCH] ASoC: codecs-ac97: make selectable in config Maciej S. Szmigiero
2015-05-12 17:58 ` Mark Brown
2015-05-13 20:57 ` Maciej S. Szmigiero
2015-05-14 17:53 ` Mark Brown
2015-05-14 18:46 ` Lars-Peter Clausen
2015-05-14 19:10 ` Mark Brown
2015-05-14 19:24 ` Lars-Peter Clausen
2015-05-14 19:28 ` Mark Brown
2015-05-14 19:38 ` Lars-Peter Clausen
2015-05-14 19:43 ` Mark Brown
2015-05-22 12:41 ` Mark Brown
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox