Skip to contentSkip to conversation

ALSA: ctxfi: Bump playback substreams to 256

PATCH In review Maarten Lankhorst 2 participants 2 messages Aug 23, 2011 – Aug 24, 2011 Sound

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 ALSA: ctxfi: Bump playback substreams to 256

There are references in the code to 256 sources, so I tested it with 256 aplays, of which the first and last with real data and the rest playing /dev/zero .

Also increase amount of page tables, so the default aplay size works.

---

sound/pci/ctxfi/ctpcm.c +1 -1
index 457d211..2c86226 100644
@@ -404,7 +404,7 @@ int ct_alsa_pcm_create(struct ct_atc *atc,
 	int err;
 	int playback_count, capture_count;
 
-	playback_count = (IEC958 == device) ? 1 : 8;
+	playback_count = (IEC958 == device) ? 1 : 256;
 	capture_count = (FRONT == device) ? 1 : 0;
 	err = snd_pcm_new(atc->card, "ctxfi", device,
 			  playback_count, capture_count, &pcm);
sound/pci/ctxfi/ctsrc.c +1 -1
index c749fa7..e134b3a 100644
@@ -20,7 +20,7 @@
 #include "cthardware.h"
 #include <linux/slab.h>
 
-#define SRC_RESOURCE_NUM	64
+#define SRC_RESOURCE_NUM	256
 #define SRCIMP_RESOURCE_NUM	256
 
 static unsigned int conj_mask;
sound/pci/ctxfi/ctvmem.h +1 -1
index b23adfc..e6da60e 100644
@@ -18,7 +18,7 @@
 #ifndef CTVMEM_H
 #define CTVMEM_H
 
-#define CT_PTP_NUM	1	/* num of device page table pages */
+#define CT_PTP_NUM	4	/* num of device page table pages */
 
 #include <linux/mutex.h>
 #include <linux/list.h>
#1 lore raw

At Wed, 24 Aug 2011 00:48:59 +0200,

Quoted 7 lines · Maarten Lankhorst

There are references in the code to 256 sources, so I tested it with 256 aplays, of which the first and last with real data and the rest playing /dev/zero .

Also increase amount of page tables, so the default aplay size works.

Applied now. Thanks.

Takashi

Quoted 41 lines

---

sound/pci/ctxfi/ctpcm.c +1 -1
index 457d211..2c86226 100644
@@ -404,7 +404,7 @@ int ct_alsa_pcm_create(struct ct_atc *atc,
 	int err;
 	int playback_count, capture_count;
 
-	playback_count = (IEC958 == device) ? 1 : 8;
+	playback_count = (IEC958 == device) ? 1 : 256;
 	capture_count = (FRONT == device) ? 1 : 0;
 	err = snd_pcm_new(atc->card, "ctxfi", device,
 			  playback_count, capture_count, &pcm);
sound/pci/ctxfi/ctsrc.c +1 -1
index c749fa7..e134b3a 100644
@@ -20,7 +20,7 @@
 #include "cthardware.h"
 #include <linux/slab.h>
 
-#define SRC_RESOURCE_NUM	64
+#define SRC_RESOURCE_NUM	256
 #define SRCIMP_RESOURCE_NUM	256
 
 static unsigned int conj_mask;
sound/pci/ctxfi/ctvmem.h +1 -1
index b23adfc..e6da60e 100644
@@ -18,7 +18,7 @@
 #ifndef CTVMEM_H
 #define CTVMEM_H
 
-#define CT_PTP_NUM	1	/* num of device page table pages */
+#define CT_PTP_NUM	4	/* num of device page table pages */
 
 #include <linux/mutex.h>
 #include <linux/list.h>