Skip to contentSkip to conversation

USB-Audio: fix dsnoop args for Audiophile USB card

PATCH Applied Alexander Tsoy 2 participants 4 messages Jun 18, 2017 – Jun 20, 2017

lore
Share & tools
lore
#0 lore raw

PATCH 1/2 USB-Audio: fix dsnoop args for Audiophile USB card

Fixes a9b129955659 ("USB-Audio.conf: fix definition for M-Audio AudioP...")
---
 src/conf/cards/USB-Audio.conf | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
src/conf/cards/USB-Audio.conf +1 -1
index e365f297..f72ef121 100644
@@ -90,7 +90,7 @@ USB-Audio."Audiophile USB (tm)".pcm.default {
 		type plug
 		slave.pcm {
 			@func concat
-			strings [ "dsnoop:DEVICE=1,CARD=" $CARD ]
+			strings [ "dsnoop:DEV=1,CARD=" $CARD ]
 		}
 	}
 }
Signature · 1 line
2.13.0
#1 lore raw

PATCH 2/2 USB-Audio: allow custom definitions for "default" devices

Fixes a9b129955659 ("USB-Audio.conf: fix definition for M-Audio AudioP...")
---
 src/conf/cards/USB-Audio.conf | 77 ++++++++++++++++++++++++-------------------
 1 file changed, 44 insertions(+), 33 deletions(-)
src/conf/cards/USB-Audio.conf +44 -33
index f72ef121..cc8c718c 100644
@@ -67,7 +67,7 @@ USB-Audio.pcm.iec958_2_device {
 }
 
 
-# If a device requires non-standard definitions for front, surround40,
+# If a device requires non-standard definitions for front, default, surround40,
 # surround51, surround71 or iec958, they can be defined here.
 
 # M-Audio AudioPhile USB:
@@ -125,13 +125,13 @@ USB-Audio."Audio Advantage MicroII".pcm.iec958 {
 	@args.AES2 { type integer }
 	@args.AES3 { type integer }
 
-    type hooks
-    slave.pcm {
+	type hooks
+	slave.pcm {
 		type hw
 		card $CARD
-    }
+	}
 
-    hooks.0 {
+	hooks.0 {
 		type ctl_elems
 		hook_args [
 			{
@@ -174,41 +174,52 @@ USB-Audio.pcm.front.0 {
 		card $CARD
 		device 0
 	}
-}	
+}
 
 USB-Audio.pcm.default {
 	@args [ CARD ]
 	@args.CARD { type string }
-	type asym
-	playback.pcm {
-		type plug
-		slave.pcm {
-			@func refer
-			name {
-				@func concat
-				strings [
-					"cards.USB-Audio.pcm.default_playback_dmix_"
-					{
-						@func refer
-						name {
-							@func concat
-							strings [
-								"cards.USB-Audio.pcm.use_dmix."
-								{ @func card_name card $CARD }
-							]
+	@func refer
+	name {
+		@func concat
+		strings [
+			"cards.USB-Audio."
+			{ @func card_name card $CARD }
+			".pcm.default:CARD=" $CARD
+		]
+	}
+	default {
+		type asym
+		playback.pcm {
+			type plug
+			slave.pcm {
+				@func refer
+				name {
+					@func concat
+					strings [
+						"cards.USB-Audio.pcm.default_playback_dmix_"
+						{
+							@func refer
+							name {
+								@func concat
+								strings [
+									"cards.USB-Audio.pcm.use_dmix."
+									{ @func card_name card $CARD }
+								]
+							}
+							default yes
 						}
-						default yes
-					}
-					":CARD=" $CARD
-				]
+						":CARD=" $CARD
+					]
+				}
 			}
 		}
-	}
-	capture.pcm {
-		type plug
-		slave.pcm {
-			@func concat
-			strings [ "dsnoop:" $CARD ]
+		capture.pcm {
+			type plug
+			slave.pcm {
+				@func concat
+				strings [ "dsnoop:" $CARD ]
+			}
 		}
 	}
 }
Signature · 1 line
2.13.0
Applied
#2 lore raw

Re: [PATCH alsa-lib 2/2] USB-Audio: allow custom definitions for "default" devices

Quoted 3 lines · Alexander Tsoy
Fixes a9b129955659 ("USB-Audio.conf: fix definition for M-Audio AudioP...")

Applied, thanks.

Takashi

Quoted 124 lines
---
 src/conf/cards/USB-Audio.conf | 77 ++++++++++++++++++++++++-------------------
 1 file changed, 44 insertions(+), 33 deletions(-)
src/conf/cards/USB-Audio.conf +44 -33
index f72ef121..cc8c718c 100644
@@ -67,7 +67,7 @@ USB-Audio.pcm.iec958_2_device {
 }
 
 
-# If a device requires non-standard definitions for front, surround40,
+# If a device requires non-standard definitions for front, default, surround40,
 # surround51, surround71 or iec958, they can be defined here.
 
 # M-Audio AudioPhile USB:
@@ -125,13 +125,13 @@ USB-Audio."Audio Advantage MicroII".pcm.iec958 {
 	@args.AES2 { type integer }
 	@args.AES3 { type integer }
 
-    type hooks
-    slave.pcm {
+	type hooks
+	slave.pcm {
 		type hw
 		card $CARD
-    }
+	}
 
-    hooks.0 {
+	hooks.0 {
 		type ctl_elems
 		hook_args [
 			{
@@ -174,41 +174,52 @@ USB-Audio.pcm.front.0 {
 		card $CARD
 		device 0
 	}
-}	
+}
 
 USB-Audio.pcm.default {
 	@args [ CARD ]
 	@args.CARD { type string }
-	type asym
-	playback.pcm {
-		type plug
-		slave.pcm {
-			@func refer
-			name {
-				@func concat
-				strings [
-					"cards.USB-Audio.pcm.default_playback_dmix_"
-					{
-						@func refer
-						name {
-							@func concat
-							strings [
-								"cards.USB-Audio.pcm.use_dmix."
-								{ @func card_name card $CARD }
-							]
+	@func refer
+	name {
+		@func concat
+		strings [
+			"cards.USB-Audio."
+			{ @func card_name card $CARD }
+			".pcm.default:CARD=" $CARD
+		]
+	}
+	default {
+		type asym
+		playback.pcm {
+			type plug
+			slave.pcm {
+				@func refer
+				name {
+					@func concat
+					strings [
+						"cards.USB-Audio.pcm.default_playback_dmix_"
+						{
+							@func refer
+							name {
+								@func concat
+								strings [
+									"cards.USB-Audio.pcm.use_dmix."
+									{ @func card_name card $CARD }
+								]
+							}
+							default yes
 						}
-						default yes
-					}
-					":CARD=" $CARD
-				]
+						":CARD=" $CARD
+					]
+				}
 			}
 		}
-	}
-	capture.pcm {
-		type plug
-		slave.pcm {
-			@func concat
-			strings [ "dsnoop:" $CARD ]
+		capture.pcm {
+			type plug
+			slave.pcm {
+				@func concat
+				strings [ "dsnoop:" $CARD ]
+			}
 		}
 	}
 }
Signature · 6 lines
2.13.0

_______________________________________________
Alsa-devel mailing list
[email protected]
http://mailman.alsa-project.org/mailman/listinfo/alsa-devel
Applied
#3 lore raw
In reply to Alexander Tsoy
Quoted 3 lines · Alexander Tsoy
Fixes a9b129955659 ("USB-Audio.conf: fix definition for M-Audio AudioP...")

Applied, thanks.

Takashi

Quoted 25 lines
---
 src/conf/cards/USB-Audio.conf | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
src/conf/cards/USB-Audio.conf +1 -1
index e365f297..f72ef121 100644
@@ -90,7 +90,7 @@ USB-Audio."Audiophile USB (tm)".pcm.default {
 		type plug
 		slave.pcm {
 			@func concat
-			strings [ "dsnoop:DEVICE=1,CARD=" $CARD ]
+			strings [ "dsnoop:DEV=1,CARD=" $CARD ]
 		}
 	}
 }
Signature · 6 lines
2.13.0

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