Skip to contentSkip to conversation

Add default config for tegra-alc5632 (as found on paz00)

PATCH In review Paul Fertser 5 participants 9 messages Feb 6, 2012 – Feb 27, 2012 Tegra architecture support

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 Add default config for tegra-alc5632 (as found on paz00)

This makes paz00 (aka Toshiba ac100, a popular arm-based netbook) use dmix/dsnoop by default since it doesn't support hw mixing.

---
Hi,

I haven't seen any other ASoC configs here so probably i'm missing something obvious. My reasoning is that when a person uses a regular notebook with HDA he gets DMix by default so it should be the case for this less common netbook too.

Rate is set to 44100 because it's unlikely a person will listen to Hi-Fi music and hence it avoids resampling for the most common usecase. Feel free to drop if that's inappropriate, the device works fine with 48000 too.

 src/conf/cards/Makefile.am        |    1 +
 src/conf/cards/tegra-alc5632.conf |   23 +++++++++++++++++++++++
 2 files changed, 24 insertions(+), 0 deletions(-)
 create mode 100644 src/conf/cards/tegra-alc5632.conf
src/conf/cards/Makefile.am +1 -0
index b7190e7..efed590 100644
@@ -44,6 +44,7 @@ cfg_files = aliases.conf \
 	RME9652.conf \
 	SI7018.conf \
 	SB-XFi.conf \
+	tegra-alc5632.conf \
 	TRID4DWAVENX.conf \
 	USB-Audio.conf \
 	YMF744.conf \
src/conf/cards/tegra-alc5632.conf new file +23 -0
new file mode 100644
index 0000000..371fe2a
@@ -0,0 +1,23 @@
+# default with dmix/dsnoop
+tegra-alc5632.pcm.default {
+	@args [ CARD ]
+	@args.CARD {
+		type string
+	}
+	type asym
+	playback.pcm {
+		type plug
+		slave.pcm {
+			@func concat
+			strings [ "dmix:CARD=" $CARD ",RATE=44100" ]
+		}
+	}
+	capture.pcm {
+		type plug
+		slave.pcm {
+			@func concat
+			strings [ "dsnoop:CARD=" $CARD ",RATE=44100" ]
+		}
+	}
+}
+
Signature · 1 line
1.7.3.4
#1 lore raw
Quoted 2 lines · Paul Fertser

This makes paz00 (aka Toshiba ac100, a popular arm-based netbook) use dmix/dsnoop by default since it doesn't support hw mixing.

This patch appears to match on card name being "tegra-alc5632", but the device tree code that just got checked in will name the card "Compal PAZ00" I believe. (and I believe this driver only supports DT not board files) Am I missing something?

Signature · 1 line
nvpublic
#2 lore raw
Quoted 8 lines · Stephen Warren
Quoted 2 lines · Paul Fertser

This makes paz00 (aka Toshiba ac100, a popular arm-based netbook) use dmix/dsnoop by default since it doesn't support hw mixing.

This patch appears to match on card name being "tegra-alc5632", but the device tree code that just got checked in will name the card "Compal PAZ00" I believe. (and I believe this driver only supports DT not board files) Am I missing something?

Stephen, Mark,
I want to raise our old question: "How do we need to call this card ? Do we need to call it tegra-alc5632, as was in pre-DT era ? Or do we need to call it "Compal PAZ00" as we introduced in DT patches ?".

The both names are applicable because "Compal PAZ00" is the name of notebook (hardware board) and tegra-alc5632 is the name of chips were used.

Quoted 7 lines

--
nvpublic
_______________________________________________
Alsa-devel mailing list
[email protected]
http://mailman.alsa-project.org/mailman/listinfo/alsa-devel

Signature · 6 lines
Leon Romanovsky | Independent Linux Consultant
        www.leon.nu | [email protected]
_______________________________________________
Alsa-devel mailing list
[email protected]
http://mailman.alsa-project.org/mailman/listinfo/alsa-devel
#3 lore raw
Quoted 7 lines · Leon Romanovsky

I want to raise our old question: "How do we need to call this card ? Do we need to call it tegra-alc5632, as was in pre-DT era ? Or do we need to call it "Compal PAZ00" as we introduced in DT patches ?".

The both names are applicable because "Compal PAZ00" is the name of notebook (hardware board) and tegra-alc5632 is the name of chips were used.

I really don't care.

#4 lore raw
In reply to Leon Romanovsky
Quoted 9 lines · Leon Romanovsky
Quoted 8 lines · Stephen Warren
Quoted 2 lines · Paul Fertser

This makes paz00 (aka Toshiba ac100, a popular arm-based netbook) use dmix/dsnoop by default since it doesn't support hw mixing.

This patch appears to match on card name being "tegra-alc5632", but the device tree code that just got checked in will name the card "Compal PAZ00" I believe. (and I believe this driver only supports DT not board files) Am I missing something?

Quoted 8 lines

Stephen, Mark,
I want to raise our old question: "How do we need to call this card ? Do we need to call it tegra-alc5632, as was in pre-DT era ? Or do we need to call it "Compal PAZ00" as we introduced in DT patches ?".

The both names are applicable because "Compal PAZ00" is the name of notebook (hardware board) and tegra-alc5632 is the name of chips were used.

Since alsa-lib config file describes how to best deal with the combination of chips rather than a particular notebook name (especially given same device can have different names from different vendors and at the same time some vendors are ill-minded enough to call different devices with the same name) it would seem more logical to stick to the chips' names.

Mark, do you have some idea how to solve the issue at hand (having dmix on this netbook by default) better? Is quantity of maximum simultaneous playback/record PCM streams already queryable by the userspace? Somehow it happened that adding per-device config file was ok during all these years, is there a better way now?

Signature · 2 lines
Be free, use free (http://www.gnu.org/philosophy/free-sw.html) software!
mailto:[email protected]
#5 lore raw
Quoted 6 lines · Paul Fertser

Since alsa-lib config file describes how to best deal with the combination of chips rather than a particular notebook name (especially given same device can have different names from different vendors and at the same time some vendors are ill-minded enough to call different devices with the same name) it would seem more logical to stick to the chips' names.

That needn't follow - especially as you move into the higher end the devices get much more flexible and system concerns have a major impact on the configuration so the board in use becomes more and more important.

Quoted 5 lines

Mark, do you have some idea how to solve the issue at hand (having dmix on this netbook by default) better? Is quantity of maximum simultaneous playback/record PCM streams already queryable by the userspace? Somehow it happened that adding per-device config file was ok during all these years, is there a better way now?

For almost all devices there's one stream supported in each direction, if we were assuming any default that'd be it.

#6 lore raw

Hi,

Quoted 9 lines · Mark Brown
Quoted 5 lines · Paul Fertser

Mark, do you have some idea how to solve the issue at hand (having dmix on this netbook by default) better? Is quantity of maximum simultaneous playback/record PCM streams already queryable by the userspace? Somehow it happened that adding per-device config file was ok during all these years, is there a better way now?

For almost all devices there's one stream supported in each direction, if we were assuming any default that'd be it.

Takashi, can you please provide some feedback on this thread?

Signature · 2 lines
Be free, use free (http://www.gnu.org/philosophy/free-sw.html) software!
mailto:[email protected]
#7 lore raw

At Fri, 24 Feb 2012 12:43:47 +0400,

Quoted 11 lines · Paul Fertser

Hi,

Quoted 7 lines · Mark Brown
Quoted 5 lines · Paul Fertser

Mark, do you have some idea how to solve the issue at hand (having dmix on this netbook by default) better? Is quantity of maximum simultaneous playback/record PCM streams already queryable by the userspace? Somehow it happened that adding per-device config file was ok during all these years, is there a better way now?

Quoted 4 lines
Quoted 2 lines

For almost all devices there's one stream supported in each direction, if we were assuming any default that'd be it.

Takashi, can you please provide some feedback on this thread?

The reason dmix is implemented in a white-list way in alsa-lib is that dmix isn't always working well. The support was limited on some architectures, and could be buggy when the buffer transfer isn't standard.

So, unless the situation doesn't change drastically, I don't think it's wise to change the policy for now. In your case, just apply tegra-alc5632, and define an alias of Compal PAZ00. This would be just a safer option.

Of course, if there are more hundreds of different drivers come up soon now with different card->driver name strings, and all of them must be set up with dmix, then we can reconsider.

thanks,

Takashi

#8 lore raw
In reply to Paul Fertser
Quoted 4 lines · Paul Fertser

I haven't seen any other ASoC configs here so probably i'm missing something obvious. My reasoning is that when a person uses a regular notebook with HDA he gets DMix by default so it should be the case for this less common netbook too.

It seems depressing that we'd need to go through and add this for every single card...