Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 948169 - media-video/pipewire-1.2.7 spa_alsa_init()] Could not determine card index, maybe set api.alsa.card
Summary: media-video/pipewire-1.2.7 spa_alsa_init()] Could not determine card index, m...
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal
Assignee: Sam James
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2025-01-16 03:07 UTC by Techwolf
Modified: 2025-01-18 17:11 UTC (History)
2 users (show)

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


Attachments
emerge --info media-video/pipewire (emerge_info.txt,11.63 KB, text/plain)
2025-01-16 03:07 UTC, Techwolf
Details
asound.conf (asound.conf,5.60 KB, text/plain)
2025-01-16 03:08 UTC, Techwolf
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Techwolf 2025-01-16 03:07:44 UTC
Created attachment 916657 [details]
emerge --info media-video/pipewire

Upgraded to 1.2.7 and notice I lost sound in the browser. Hour or two of troubleshooting resulted in downgrading to 1.2.6 to fix it.

When starting things manually, using gentoo-pipewire-launcher as a guide, to get terminal output.

/usr/bin/pipewire &

[E][16331.240401] spa.alsa     | [      alsa-pcm.c:  941 spa_alsa_init()] Could not determine card index, maybe set api.alsa.card
[E][16331.240542] pw.resource  | [      resource.c:  255 pw_resource_errorf_id()] can't create node: Invalid argument
[E][16331.240549] pw.conf      | [          conf.c:  845 create_object()] can't create object from factory adapter: Invalid argument
[E][16331.241369] default      | [      pipewire.c:  124 main()] failed to create context: Invalid argument

And exits/fails to start.

The cupric was down to a .conf setting

/etc/pipewire/pipewire.conf.d/alsa_lfe_dmix.conf

context.objects = [
    {   factory = adapter
        args = {
            factory.name            = api.alsa.pcm.sink
            node.name               = "alsa-out-lfe"
            node.description        = "Dmix Out"
            media.class             = "Audio/Sink"
            api.alsa.path           = "default"
        }
    }

]

Changing "default" to "hw:1,0" works, but lose the dmix path. Testing with just "dmix" also failed. Bypassing default and using "lferoute" that is configured in /etc/asound.conf also failed.

Downgrading to pipewire 1.2.6 has no errors with "default" setting.
Comment 1 Techwolf 2025-01-16 03:08:46 UTC
Created attachment 916658 [details]
asound.conf
Comment 3 Larry the Git Cow gentoo-dev 2025-01-16 18:41:39 UTC
The bug has been closed via the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=ddf7f65270b4cfb1117bdf1bde0e611b7e1417d6

commit ddf7f65270b4cfb1117bdf1bde0e611b7e1417d6
Author:     Sam James <sam@gentoo.org>
AuthorDate: 2025-01-16 18:40:52 +0000
Commit:     Sam James <sam@gentoo.org>
CommitDate: 2025-01-16 18:40:52 +0000

    media-video/pipewire: backport upstream fixes to 1.2.7
    
    From the 1.2 branch.
    
    Closes: https://bugs.gentoo.org/948169
    Signed-off-by: Sam James <sam@gentoo.org>

 ...sa-Fix-key-name-suggestion-in-log-message.patch |  28 ++
 ...pa-alsa-Don-t-assume-all-PCMs-have-a-card.patch | 128 +++++
 ...st-mark-the-pipewiresink-as-EARLY_PROCESS.patch |  29 ++
 .../0004-gst-add-rate-control-to-the-sink.patch    | 234 +++++++++
 .../1.2.7/0005-gst-add-slave-method-property.patch | 259 ++++++++++
 .../1.2.7/0006-spa-fix-some-param-type-info.patch  |  51 ++
 .../0007-filter-chain-handle-0-length-IR.patch     | 305 ++++++++++++
 ...0008-spa-initialize-all-fields-explicitly.patch |  47 ++
 media-video/pipewire/pipewire-1.2.7-r1.ebuild      | 527 +++++++++++++++++++++
 media-video/pipewire/pipewire-1.2.7.ebuild         |   2 +-
 10 files changed, 1609 insertions(+), 1 deletion(-)