Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F101878652
D45136.id.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Flag For Later
Award Token
Size
1 KB
Referenced Files
None
Subscribers
None
D45136.id.diff
View Options
diff --git a/sys/dev/sound/pcm/sound.c b/sys/dev/sound/pcm/sound.c
--- a/sys/dev/sound/pcm/sound.c
+++ b/sys/dev/sound/pcm/sound.c
@@ -708,11 +708,9 @@
struct snddev_info *d;
struct pcm_channel *c;
- int j, ncards;
+ int j;
size_t i;
- ncards = 0;
-
strlcpy(si->product, si_product, sizeof(si->product));
strlcpy(si->version, si_version, sizeof(si->version));
si->versionnum = SOUND_VERSION;
@@ -720,7 +718,7 @@
/*
* Iterate over PCM devices and their channels, gathering up data
- * for the numaudios, ncards, and openedaudio fields.
+ * for the numaudios and openedaudio fields.
*/
si->numaudios = 0;
bzero((void *)&si->openedaudio, sizeof(si->openedaudio));
@@ -740,7 +738,6 @@
PCM_LOCK(d);
si->numaudios += PCM_CHANCOUNT(d);
- ++ncards;
CHN_FOREACH(c, d, channels.pcm) {
CHN_UNLOCKASSERT(c);
@@ -771,7 +768,7 @@
si->nummidis = 0;
si->numtimers = 0;
si->nummixers = mixer_count;
- si->numcards = ncards;
+ si->numcards = devclass_get_maxunit(pcm_devclass);
/* OSSv4 docs: Intended only for test apps; API doesn't
really have much of a concept of cards. Shouldn't be
used by applications. */
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Wed, Nov 6, 2:26 AM (30 m, 19 s)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
14476163
Default Alt Text
D45136.id.diff (1 KB)
Attached To
Mode
D45136: sound: Fix oss_sysinfo->numcards
Attached
Detach File
Event Timeline
Log In to Comment