Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 157011 - Need pcm_multi patch added to alsa-lib
Summary: Need pcm_multi patch added to alsa-lib
Status: RESOLVED UPSTREAM
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Library (show other bugs)
Hardware: x86 Linux
: High minor
Assignee: Gentoo ALSA team [DISABLED]
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2006-12-03 11:18 UTC by eric west
Modified: 2006-12-03 12:20 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description eric west 2006-12-03 11:18:32 UTC
Please add the pcm_multi patch to alsa-lib.  This patch
is needed in order to get two soundcards to work simultaneously
with jackd.  I have tried it and it works.

Thanks.

Here is the patch:
<cut here>--------------------------------
--- alsa-lib/src/pcm/pcm_multi.c    2005-12-03 20:10:58.000000000 +0000
+++ alsa-lib/src/pcm/pcm_multi.c    2005-12-03 20:20:56.000000000 +0000
@@ -597,7 +597,7 @@ static int snd_pcm_multi_resume(snd_pcm_
    return err;
 }

-static int snd_pcm_multi_link_fd_failed(snd_pcm_t *pcm, int fd)
+/* static int snd_pcm_multi_link_fd_failed(snd_pcm_t *pcm, int fd)
 {
    snd_pcm_multi_t *multi = pcm->private_data;
    unsigned int i;
@@ -638,7 +638,7 @@ static int snd_pcm_multi_unlink(snd_pcm_
        multi->slaves[i].linked = 0;
    }
    return 0;
-}
+} */

 static snd_pcm_sframes_t snd_pcm_multi_mmap_commit(snd_pcm_t *pcm,
                           snd_pcm_uframes_t offset,
@@ -726,9 +726,9 @@ static snd_pcm_fast_ops_t snd_pcm_multi_
    .rewind = snd_pcm_multi_rewind,
    .forward = snd_pcm_multi_forward,
    .resume = snd_pcm_multi_resume,
-   .link_fd = snd_pcm_multi_link_fd,
+// .link_fd = snd_pcm_multi_link_fd,
    .link = snd_pcm_generic_link2,
-   .unlink = snd_pcm_multi_unlink,
+// .unlink = snd_pcm_multi_unlink,
    .avail_update = snd_pcm_multi_avail_update,
    .mmap_commit = snd_pcm_multi_mmap_commit,
    .poll_descriptors_count = snd_pcm_multi_poll_descriptors_count,
<end>--------------------------------------------------------------
Comment 1 Diego Elio Pettenò (RETIRED) gentoo-dev 2006-12-03 12:20:58 UTC
Well, not sure about the *needing* of it, besides the patch sounds like a nasty hack to me (comment out functions is no-no).

Please just get ALSA upstream to fix this.