Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
No sound on fresh install using pipewire
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Multimedia
View previous topic :: View next topic  
Author Message
sirlark
Guru
Guru


Joined: 25 Oct 2004
Posts: 314
Location: Limerick, Ireland

PostPosted: Fri Apr 04, 2025 5:39 pm    Post subject: No sound on fresh install using pipewire Reply with quote

Hi folks. I have a fresh gentoo install on a Tuxedo Pulse 14 Gen 1 laptop, and I can't get sound to work. It worked fine with the default Tuxedo OS install, so it's not a hardware issue. I've been fighting with this for a couple of days now, and I'm thoroughly confused

I've got the kernel bits set up, as indicated by the following

Code:

$ lspci | grep Audio
04:00.1 Audio device: Advanced Micro Devices, Inc. [AMD/ATI] Renoir Radeon High Definition Audio Controller
04:00.5 Multimedia controller: Advanced Micro Devices, Inc. [AMD] ACP/ACP3X/ACP6x Audio Coprocessor (rev 01)
04:00.6 Audio device: Advanced Micro Devices, Inc. [AMD] Family 17h/19h/1ah HD Audio Controller

$ aplay -l
**** List of PLAYBACK Hardware Devices ****
card 0: Generic [HD-Audio Generic], device 3: HDMI 0 [HDMI 0]
  Subdevices: 1/1
  Subdevice #0: subdevice #0
card 1: Generic_1 [HD-Audio Generic], device 0: Generic Analog [Generic Analog]
  Subdevices: 1/1
  Subdevice #0: subdevice #0


And I've got the following pipewire config

Code:

$ cat /etc/pipewire/pipewire.conf.d/builtin-cards.conf
context.objects = [
  # This creates a new Source node. It will have input ports
  # that you can link, to provide audio for this source.
  { factory = adapter
      args = {
          factory.name     = support.null-audio-sink
          node.name        = "my-mic"
          node.description = "Microphone"
          media.class      = "Audio/Source/Virtual"
          audio.position   = "FL,FR"
          monitor.passthrough = true
      }
  }

  # This creates a single PCM source device for the given
  # alsa device path hw:0. You can change source to sink
  # to make a sink in the same way.
  { factory = adapter
      args = {
          factory.name           = api.alsa.pcm.source
          node.name              = "alsa-source"
          node.description       = "PCM Source"
          media.class            = "Audio/Source"
          api.alsa.path          = "hw:1"
          api.alsa.period-size   = 1024
          api.alsa.headroom      = 0
          api.alsa.disable-mmap  = false
          api.alsa.disable-batch = false
          audio.format           = "S16LE"
          audio.rate             = 48000
          audio.channels         = 2
          audio.position         = "FL,FR"
      }
  }

  # This creates a single PCM source device for the given
  # alsa device path hw:0. You can change source to sink
  # to make a sink in the same way.
  { factory = adapter
      args = {
          factory.name           = api.alsa.pcm.sink
          node.name              = "alsa-sink"
          node.description       = "PCM Sink"
          media.class            = "Audio/Sink"
          api.alsa.path          = "hw:1"
          api.alsa.period-size   = 1024
          api.alsa.headroom      = 0
          api.alsa.disable-mmap  = false
          api.alsa.disable-batch = false
          audio.format           = "S16LE"
          audio.rate             = 48000
          audio.channels         = 2
          audio.position         = "FL,FR"
      }
  }
]


I have non-root user (setup) for use while I setup the laptop, which is a member of the following groups

Code:
lp wheel audio video input lpadmin pipewire setup


The `audio` group is included because the alsa devices in `/dev/snd` were owned by root:audio, and didn't show up in `wpctl status`. Now it shows

Code:

$ wpctl status
PipeWire 'pipewire-0' [1.4.1, setup@giobhniu, cookie:3982878448]
 └─ Clients:
        35. wpctl                               [1.4.1, setup@giobhniu, pid:12706]

Audio
 ├─ Devices:
 │ 
 ├─ Sinks:
 │      33. PCM Sink                            [vol: 1.00]
 │ 
 ├─ Sources:
 │      31. Microphone                          [vol: 1.00]
 │      32. PCM Source                          [vol: 1.00]
 │ 
 ├─ Filters:
 │ 
 └─ Streams:

Video
 ├─ Devices:
 │ 
 ├─ Sinks:
 │ 
 ├─ Sources:
 │ 
 ├─ Filters:
 │ 
 └─ Streams:

Settings
 └─ Default Configured Devices:


At this point, I would expect `aplay /user/share/sounds/alsa/Front_Center.wav` to produce some sound, but it doesn't. It doesn't crash, there's just no noise. I suspect this has to do with the pipewire config using 'hw:1'. Pipewire doesn't start if I use 'hw:0', and nor does aplay or alsamixer. I think hw:1 is probably routing to the HDMI device, but I can't find any link between device names and alsa, the the names used in piepwire config.

EDIT: I'm using systemd, and the Wayfire WM. I've got pipewire being launched as a systemd user service. It appears to be running

Code:

$ ps aux | grep pipewire
setup      47347  0.0  0.0  32616  9352 ?        S<sl 12:03   0:00 /usr/bin/pipewire
setup      47349  0.0  0.0  20256  6508 ?        S<sl 12:03   0:00 /usr/bin/pipewire-pulse
root       49207  0.0  0.0   7116  2408 pts/0    S+   12:16   0:00 grep --color=auto pipewire


I've got the sound-server USE flag set too

Code:
$ emerge -pv pipewire
[ebuild   R    ] media-video/pipewire-1.4.1:0/0.4::gentoo  USE="X bluetooth dbus echo-cancel extra ffmpeg gstreamer liblc3 lv2 man pipewire-alsa readline sound-server ssl systemd v4l zeroconf -doc (-elogind) -flatpak -gsettings -ieee1394 -jack-client -jack-sdk -loudness -modemmanager -roc (-selinux) (-system-service) -test" 0 KiB

_________________
Adopt an unanswered post today


Last edited by sirlark on Sun Apr 06, 2025 11:23 am; edited 1 time in total
Back to top
View user's profile Send private message
5eggs
n00b
n00b


Joined: 30 Mar 2025
Posts: 4

PostPosted: Sun Apr 06, 2025 2:34 am    Post subject: Reply with quote

What DE/WM are you using? What init system? Did you launch pipewire with gentoo-pipewire-launcher? Do you have sound-server USE flag enabled for pipewire?
Back to top
View user's profile Send private message
sirlark
Guru
Guru


Joined: 25 Oct 2004
Posts: 314
Location: Limerick, Ireland

PostPosted: Sun Apr 06, 2025 11:21 am    Post subject: Reply with quote

Hey. thanks for the response. I'm using systemd, and the Wayfire WM. I've got pipewire being launched as a systemd user service. It appears to be running

Code:

$ ps aux | grep pipewire
setup      47347  0.0  0.0  32616  9352 ?        S<sl 12:03   0:00 /usr/bin/pipewire
setup      47349  0.0  0.0  20256  6508 ?        S<sl 12:03   0:00 /usr/bin/pipewire-pulse
root       49207  0.0  0.0   7116  2408 pts/0    S+   12:16   0:00 grep --color=auto pipewire


I've got the sound-server USE flag set too

Code:
$ emerge -pv pipewire
[ebuild   R    ] media-video/pipewire-1.4.1:0/0.4::gentoo  USE="X bluetooth dbus echo-cancel extra ffmpeg gstreamer liblc3 lv2 man pipewire-alsa readline sound-server ssl systemd v4l zeroconf -doc (-elogind) -flatpak -gsettings -ieee1394 -jack-client -jack-sdk -loudness -modemmanager -roc (-selinux) (-system-service) -test" 0 KiB


I've also edited my original post to add this info.
_________________
Adopt an unanswered post today
Back to top
View user's profile Send private message
skellr
l33t
l33t


Joined: 18 Jun 2005
Posts: 994
Location: The Village, Portmeirion

PostPosted: Sun Apr 06, 2025 11:59 am    Post subject: Re: No sound on fresh install using pipewire Reply with quote

sirlark wrote:

I've got the kernel bits set up, as indicated by the following


Custom kernel? You will want these for AMD audio.

CONFIG_SND_HDA_INTEL
CONFIG_SND_HDA_CODEC_REALTEK

Just to make sure, as it's easy to skip them in the kernel config, they don't seem like something you would need for AMD audio...
Back to top
View user's profile Send private message
sirlark
Guru
Guru


Joined: 25 Oct 2004
Posts: 314
Location: Limerick, Ireland

PostPosted: Tue Apr 08, 2025 11:06 am    Post subject: Reply with quote

Ah, I'd missed the RALTEK one, I've added it and rebooted. Now I've got it enabled (see below), but still no sound.

Code:
$ zgrep CONFIG_SND_HDA /proc/config.gz
CONFIG_SND_HDA=y
CONFIG_SND_HDA_GENERIC_LEDS=y
CONFIG_SND_HDA_INTEL=y
# CONFIG_SND_HDA_HWDEP is not set
CONFIG_SND_HDA_RECONFIG=y
CONFIG_SND_HDA_INPUT_BEEP=y
CONFIG_SND_HDA_INPUT_BEEP_MODE=1
CONFIG_SND_HDA_PATCH_LOADER=y
CONFIG_SND_HDA_CIRRUS_SCODEC=y
CONFIG_SND_HDA_SCODEC_CS35L41=y
CONFIG_SND_HDA_CS_DSP_CONTROLS=y
CONFIG_SND_HDA_SCODEC_COMPONENT=y
CONFIG_SND_HDA_SCODEC_CS35L41_I2C=y
CONFIG_SND_HDA_SCODEC_CS35L41_SPI=y
CONFIG_SND_HDA_SCODEC_CS35L56=y
CONFIG_SND_HDA_SCODEC_CS35L56_I2C=y
CONFIG_SND_HDA_SCODEC_CS35L56_SPI=y
CONFIG_SND_HDA_SCODEC_TAS2781_I2C=y
CONFIG_SND_HDA_SCODEC_TAS2781_SPI=y
CONFIG_SND_HDA_CODEC_REALTEK=y
CONFIG_SND_HDA_CODEC_ANALOG=y
CONFIG_SND_HDA_CODEC_SIGMATEL=y
CONFIG_SND_HDA_CODEC_VIA=y
CONFIG_SND_HDA_CODEC_HDMI=y
CONFIG_SND_HDA_CODEC_CIRRUS=y
# CONFIG_SND_HDA_CODEC_CS8409 is not set
CONFIG_SND_HDA_CODEC_CONEXANT=y
CONFIG_SND_HDA_CODEC_SENARYTECH=y
CONFIG_SND_HDA_CODEC_CA0110=y
CONFIG_SND_HDA_CODEC_CA0132=y
CONFIG_SND_HDA_CODEC_CA0132_DSP=y
CONFIG_SND_HDA_CODEC_CMEDIA=y
# CONFIG_SND_HDA_CODEC_SI3054 is not set
CONFIG_SND_HDA_GENERIC=y
CONFIG_SND_HDA_POWER_SAVE_DEFAULT=0
# CONFIG_SND_HDA_INTEL_HDMI_SILENT_STREAM is not set
# CONFIG_SND_HDA_CTL_DEV_ID is not set
CONFIG_SND_HDA_CORE=y
CONFIG_SND_HDA_DSP_LOADER=y
CONFIG_SND_HDA_COMPONENT=y
CONFIG_SND_HDA_EXT_CORE=y
CONFIG_SND_HDA_PREALLOC_SIZE=0

_________________
Adopt an unanswered post today
Back to top
View user's profile Send private message
pietinger
Moderator
Moderator


Joined: 17 Oct 2006
Posts: 5567
Location: Bavaria

PostPosted: Tue Apr 08, 2025 1:11 pm    Post subject: Reply with quote

I always recommend for a manual kernel configuration to boot with our GentooLiveCD BEFORE and then check with “lsmod” which modules have been loaded.

Unfortunately there is one small thing to note here: NOT all options of the kernel are configured as <M>modules in the dist-kernel. Some options are statically <*> configured in the kernel and are therefore not visible when queried with “lsmod”. Now try this option:
https://wiki.gentoo.org/wiki/User:Pietinger/Experimental/Manual_Configuring_Current_Kernel#Serial_Bus_Multi_Instantiate

If this was not the case, we need your complete kernel .config. Please note the reference to wgetpaste here:
https://wiki.gentoo.org/wiki/User:Pietinger/Overview_of_System_Information
_________________
https://wiki.gentoo.org/wiki/User:Pietinger
Back to top
View user's profile Send private message
sirlark
Guru
Guru


Joined: 25 Oct 2004
Posts: 314
Location: Limerick, Ireland

PostPosted: Thu Apr 10, 2025 11:09 am    Post subject: Reply with quote

No luck so far :( Thanks for the help so far though. Here's the complete kernel config, lmk if you need any other info. Here's my dmesg too, just in case
_________________
Adopt an unanswered post today
Back to top
View user's profile Send private message
szatox
Advocate
Advocate


Joined: 27 Aug 2013
Posts: 3591

PostPosted: Thu Apr 10, 2025 11:50 am    Post subject: Reply with quote

First things first: all sound servers, including pipewire, run on top of ALSA.
So, does your sound work with ALSA alone?
_________________
Make Computing Fun Again
Back to top
View user's profile Send private message
sirlark
Guru
Guru


Joined: 25 Oct 2004
Posts: 314
Location: Limerick, Ireland

PostPosted: Thu Apr 10, 2025 12:57 pm    Post subject: Reply with quote

Not fully. ALSA detects the cards, and alsamixer works. But wavplay complains that there is no /dev/dsp
_________________
Adopt an unanswered post today
Back to top
View user's profile Send private message
szatox
Advocate
Advocate


Joined: 27 Aug 2013
Posts: 3591

PostPosted: Thu Apr 10, 2025 1:58 pm    Post subject: Reply with quote

/dev/dsp belongs to OSS. It's what we've been using before ALSA came around, and nobody has it those days anymore.

Are you able to get sound out to the speakers? You can try speaker-test, audacity, or even just this should make some noise with your analog audio
aplay -v -D hw:1,0 /dev/urandom -f S16_LE -c 2
_________________
Make Computing Fun Again
Back to top
View user's profile Send private message
sirlark
Guru
Guru


Joined: 25 Oct 2004
Posts: 314
Location: Limerick, Ireland

PostPosted: Thu Apr 10, 2025 4:39 pm    Post subject: Reply with quote

That works! Sound produced. So, I'm guessing it's a pipewire config thing.
_________________
Adopt an unanswered post today
Back to top
View user's profile Send private message
szatox
Advocate
Advocate


Joined: 27 Aug 2013
Posts: 3591

PostPosted: Thu Apr 10, 2025 6:52 pm    Post subject: Reply with quote

Great, so that's one possible problem area ruled out.

Now, does your aplay -L report pipewire playback device? You should have a gentoo-provided config snippet in /etc/alsa/conf.d/50-pipewire.conf which creates a bridge from ALSA to PW.
I also use an extra bit which makes this pipewire bridge the default playback device for all those ALSA-only clients that can't be configured
Code:
 cat /etc/alsa/conf.d/99-default.conf
pcm.!default {
    type plug
    slave { pcm "pipewire" }
}


One thing that stands out to me in your post is USE='-elogind'. I >think< (don't quote me on this, it would be nice if someone could confirm or correct) elogind is involved in session setup for applications, and having it disabled prevents them from finding pipewire's sockets. AFAIR we had a similar topic some time ago where this turned out to be the problem.
If you don't want to or can't flip this flag, it might be possible to fix it by setting variables manually, but I I don't know what those variables would be.
_________________
Make Computing Fun Again
Back to top
View user's profile Send private message
5eggs
n00b
n00b


Joined: 30 Mar 2025
Posts: 4

PostPosted: Thu Apr 10, 2025 7:31 pm    Post subject: Reply with quote

szatox wrote:
One thing that stands out to me in your post is USE='-elogind'. I >think< (don't quote me on this, it would be nice if someone could confirm or correct) elogind is involved in session setup for applications, and having it disabled prevents them from finding pipewire's sockets.

He uses systemd, so elogind is not the problem here.
Back to top
View user's profile Send private message
sirlark
Guru
Guru


Joined: 25 Oct 2004
Posts: 314
Location: Limerick, Ireland

PostPosted: Thu Apr 10, 2025 8:05 pm    Post subject: Reply with quote

Here's my aplay output, everything look to be in order; pipewire exists and the default is pointing to it, unless there's a difference between sound server and media server?

Code:

$ aplay -L
null
    Discard all samples (playback) or generate zero samples (capture)
pipewire
    PipeWire Sound Server
default
    Default ALSA Output (currently PipeWire Media Server)
hdmi:CARD=Generic,DEV=0
    HD-Audio Generic, HDMI 0
    HDMI Audio Output
sysdefault:CARD=Generic_1
    HD-Audio Generic, ALC269VC Analog
    Default Audio Device
front:CARD=Generic_1,DEV=0
    HD-Audio Generic, ALC269VC Analog
    Front output / input
...


Quote:

He uses systemd, so elogind is not the problem here.


Yup, I use systemd. Although, I don't run a DE. I'm using qtgreet and wayfire. Very minimal. So there might indeed be some session startup config missing.
_________________
Adopt an unanswered post today
Back to top
View user's profile Send private message
szatox
Advocate
Advocate


Joined: 27 Aug 2013
Posts: 3591

PostPosted: Thu Apr 10, 2025 10:30 pm    Post subject: Reply with quote

Should be fine. Though if it was, you wouldn't have created this topic... Anyway; launch this in terminal:
pw-link -miol
and try to play something. And see if it appears in the log. This is an example of a working machine:
Code:
+ alsa_playback.speaker-test:output_FL
+ alsa_playback.speaker-test:output_FR
+ alsa_playback.speaker-test:output_FL -> easyeffects_sink:playback_FL
+ alsa_playback.speaker-test:output_FR -> easyeffects_sink:playback_FR
- alsa_playback.speaker-test:output_FL -> easyeffects_sink:playback_FL
- alsa_playback.speaker-test:output_FL
- alsa_playback.speaker-test:output_FR -> easyeffects_sink:playback_FR
- alsa_playback.speaker-test:output_FR

_________________
Make Computing Fun Again
Back to top
View user's profile Send private message
5eggs
n00b
n00b


Joined: 30 Mar 2025
Posts: 4

PostPosted: Fri Apr 11, 2025 12:34 am    Post subject: Re: No sound on fresh install using pipewire Reply with quote

sirlark wrote:
I have non-root user (setup) for use while I setup the laptop, which is a member of the following groups

Code:
lp wheel audio video input lpadmin pipewire setup

Maybe (I'm just guessing) the combination of alsa and pipewire groups is causing the issue. Can you try to remove your user from one group and relogin each time and test if you can play a sound.
Back to top
View user's profile Send private message
alecStewart1
Apprentice
Apprentice


Joined: 03 Jul 2022
Posts: 186

PostPosted: Fri Apr 11, 2025 3:37 am    Post subject: Reply with quote

Following along since I'm also having sound issues.

Running pw-link -miol and then running speaker-test I get the following:

Code:

+ alsa_playback.speaker-test:output_FL -> alsa_output.pci-0000_03_00.1.pro-output-3:playback_AUX0
+ alsa_playback.speaker-test:output_FR -> alsa_output.pci-0000_03_00.1.pro-output-3:playback_AUX1
- alsa_playback.speaker-test:output_FL -> alsa_output.pci-0000_03_00.1.pro-output-3:playback_AUX0
- alsa_playback.speaker-test:output_FL
- alsa_playback.speaker-test:output_FR -> alsa_output.pci-0000_03_00.1.pro-output-3:playback_AUX1
- alsa_playback.speaker-test:output_FR


Not relevant to OP, but there's a chance our situations are similar. I don't have any extra pipewire configurations, and I get no sound.

EDIT: I'm also on OpenRC, so may not be a systemd or OpenRC issue.
Back to top
View user's profile Send private message
sirlark
Guru
Guru


Joined: 25 Oct 2004
Posts: 314
Location: Limerick, Ireland

PostPosted: Fri Apr 11, 2025 9:37 am    Post subject: Reply with quote

I suspect we've found the problem...

Code:
$ pw-link -miol
can't connect: Host is down

_________________
Adopt an unanswered post today
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Multimedia All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum