wwmm / easyeffects

Limiter, compressor, convolver, equalizer and auto volume and many other plugins for PipeWire applications
GNU General Public License v3.0
6.4k stars 267 forks source link

No audio on boot, until EasyEffects is restarted #2642

Closed 1player closed 11 months ago

1player commented 11 months ago

EasyEffects Version

7.1.0

What package are you using?

Flatpak (Flathub)

Distribution

Fedora Silverblue

Describe the bug

Upon booting the machine, there is no audio. I have to manually kill the Easy Effects process for it to work, and if I restart Easy Effects everything works as expected.

This is a regression of the past few weeks/months, not sure when it started happening, as I reboot my machine no more than once a week.

I've seen there are reports on similar issue after suspend/resume, but this is not the case here. It happens only on boot, and never again.

Expected Behavior

No response

Debug Log

No response

Additional Information

No response

HarshRaj2717 commented 11 months ago

Same issue with dnf package on Fedora 38 (easyeffects-7.1.0-1.fc38.x86_64) . No audio on boot unless easyeffects is stopped.

When starting easyeffects again, this error shows up - Failed to register: Timeout was reached

Edit: This error doesn't occur if easyeffects GUI client is opened manually, after opening once it works correctly. Probably there is issue with auto-starting of easyeffects in background but this still doesn't completely justify the timeout issue on restarting easyeffects.

wwmm commented 11 months ago

Probably there is issue with auto-starting of easyeffects in background

In the past a user suffered this problem and the only when to fix the issue in his system was delaying EasyEffects initialization by a few seconds through a custom script. But it is a very rare situation. Usually desktops start PipeWire very early.

As the problem only happens in the login you will have to set G_MESSAGES_DEBUG=easyeffects inside /etc/environment and reboot so that EasyEffects debug messages wil be present in your system log output.

wwmm commented 11 months ago

When starting easyeffects again, this error shows up - Failed to register: Timeout was reached

Thinking about it again I think there where cases where this message was related to gtk/dbus issues in the system installation.

HarshRaj2717 commented 11 months ago

Hi, it was some issue with pipewire only probably, I am not sure what it was but everything is working completely fine after updating pipewire to 0.3.81

Package: dnf

pipewire --version output:

pipewire
Compiled with libpipewire 0.3.81
Linked with libpipewire 0.3.81
violetmage commented 11 months ago

@wwmm close as fixed?

wwmm commented 11 months ago

close as fixed?

Probably as it definitely seems like a problem in PipeWire or some related library that goes away after a reboot/system update.

rscm commented 10 months ago

Same here

Ref: https://gitlab.freedesktop.org/pipewire/pipewire/-/issues/3615

Above you can see a report I made to pipewire, but I recently noticed that when I close easyeffects I get the audio back without restarting the pipewire service. I tried disabling and enabling every effect and nothing. I already added G_MESSAGES_DEBUG=easyeffects inside /etc/environment that way next time I will get that log.

System

Legion 5 15ARH05H Fedora Linux 39.20231103.n.0 (Silverblue) Linux 6.5.6-300.fc39.x86_64 Gnome 45.0 (WM: Wayland)

❯ pipewire --version pipewire Compiled with libpipewire 0.3.80 Linked with libpipewire 0.3.80

❯ rpm-ostree status 
State: idle
Deployments:
● fedora:fedora/39/x86_64/silverblue
                  Version: 39.20231103.n.0 (2023-11-03T01:13:08Z)
               BaseCommit: b34773f5071f21fd7f281f50e3486446e16887f28119bd435ecf7e60f6871d98
             GPGSignature: Valid signature by E8F23996F23218640CB44CBE75CF5AC418B8E74C
      RemovedBasePackages: firefox firefox-langpacks 119.0-2.fc39 gnome-software gnome-software-rpm-ostree 45.0-1.fc39
          LayeredPackages: akmod-nvidia android-tools distrobox gnome-tweaks kernel-tools pipewire-codec-aptx
                           printer-driver-brlaser rpmfusion-free-release rpmfusion-nonfree-release starship
                           steam-devices tailscale terminator xboxdrv xorg-x11-drv-nvidia

  fedora:fedora/39/x86_64/silverblue
                  Version: 39.20231103.n.0 (2023-11-03T01:13:08Z)
               BaseCommit: b34773f5071f21fd7f281f50e3486446e16887f28119bd435ecf7e60f6871d98
             GPGSignature: Valid signature by E8F23996F23218640CB44CBE75CF5AC418B8E74C
      RemovedBasePackages: firefox firefox-langpacks 119.0-2.fc39 gnome-software gnome-software-rpm-ostree 45.0-1.fc39
          LayeredPackages: akmod-nvidia android-tools distrobox gnome-tweaks kernel-tools pipewire-codec-aptx
                           printer-driver-brlaser rpmfusion-free-release rpmfusion-nonfree-release starship
                           steam-devices tailscale terminator xboxdrv xorg-x11-drv-nvidia

  fedora:fedora/38/x86_64/silverblue
                  Version: 38.20231028.0 (2023-10-28T02:35:21Z)
               BaseCommit: 47f696a1af532ec01243e412f728a6c7ff7f217096b64af5c514d5ccb5ffd972
             GPGSignature: Valid signature by 6A51BBABBA3D5467B6171221809A8D7CEB10B464
      RemovedBasePackages: firefox firefox-langpacks 119.0-1.fc38 gnome-software gnome-software-rpm-ostree 44.5-1.fc38
          LayeredPackages: akmod-nvidia android-tools distrobox gnome-tweaks kernel-tools pipewire-codec-aptx
                           printer-driver-brlaser rpmfusion-free-release rpmfusion-nonfree-release starship
                           steam-devices tailscale terminator xboxdrv xorg-x11-drv-nvidia
                   Pinned: yes
❯ lspci
00:00.0 Host bridge: Advanced Micro Devices, Inc. [AMD] Renoir/Cezanne Root Complex
00:00.2 IOMMU: Advanced Micro Devices, Inc. [AMD] Renoir/Cezanne IOMMU
00:01.0 Host bridge: Advanced Micro Devices, Inc. [AMD] Renoir PCIe Dummy Host Bridge
00:01.1 PCI bridge: Advanced Micro Devices, Inc. [AMD] Renoir PCIe GPP Bridge
00:01.2 PCI bridge: Advanced Micro Devices, Inc. [AMD] Renoir/Cezanne PCIe GPP Bridge
00:02.0 Host bridge: Advanced Micro Devices, Inc. [AMD] Renoir PCIe Dummy Host Bridge
00:02.1 PCI bridge: Advanced Micro Devices, Inc. [AMD] Renoir/Cezanne PCIe GPP Bridge
00:02.2 PCI bridge: Advanced Micro Devices, Inc. [AMD] Renoir/Cezanne PCIe GPP Bridge
00:08.0 Host bridge: Advanced Micro Devices, Inc. [AMD] Renoir PCIe Dummy Host Bridge
00:08.1 PCI bridge: Advanced Micro Devices, Inc. [AMD] Renoir Internal PCIe GPP Bridge to Bus
00:08.2 PCI bridge: Advanced Micro Devices, Inc. [AMD] Renoir Internal PCIe GPP Bridge to Bus
00:14.0 SMBus: Advanced Micro Devices, Inc. [AMD] FCH SMBus Controller (rev 51)
00:14.3 ISA bridge: Advanced Micro Devices, Inc. [AMD] FCH LPC Bridge (rev 51)
00:18.0 Host bridge: Advanced Micro Devices, Inc. [AMD] Renoir Device 24: Function 0
00:18.1 Host bridge: Advanced Micro Devices, Inc. [AMD] Renoir Device 24: Function 1
00:18.2 Host bridge: Advanced Micro Devices, Inc. [AMD] Renoir Device 24: Function 2
00:18.3 Host bridge: Advanced Micro Devices, Inc. [AMD] Renoir Device 24: Function 3
00:18.4 Host bridge: Advanced Micro Devices, Inc. [AMD] Renoir Device 24: Function 4
00:18.5 Host bridge: Advanced Micro Devices, Inc. [AMD] Renoir Device 24: Function 5
00:18.6 Host bridge: Advanced Micro Devices, Inc. [AMD] Renoir Device 24: Function 6
00:18.7 Host bridge: Advanced Micro Devices, Inc. [AMD] Renoir Device 24: Function 7
01:00.0 VGA compatible controller: NVIDIA Corporation TU106M [GeForce RTX 2060 Mobile] (rev a1)
01:00.1 Audio device: NVIDIA Corporation TU106 High Definition Audio Controller (rev a1)
01:00.2 USB controller: NVIDIA Corporation TU106 USB 3.1 Host Controller (rev a1)
01:00.3 Serial bus controller: NVIDIA Corporation TU106 USB Type-C UCSI Controller (rev a1)
02:00.0 Non-Volatile memory controller: Samsung Electronics Co Ltd NVMe SSD Controller SM981/PM981/PM983
03:00.0 Ethernet controller: Realtek Semiconductor Co., Ltd. RTL8111/8168/8411 PCI Express Gigabit Ethernet Controller (rev 15)
04:00.0 Network controller: Intel Corporation Wi-Fi 6 AX200 (rev 1a)
05:00.0 VGA compatible controller: Advanced Micro Devices, Inc. [AMD/ATI] Renoir (rev c6)
05:00.2 Encryption controller: Advanced Micro Devices, Inc. [AMD] Family 17h (Models 10h-1fh) Platform Security Processor
05:00.3 USB controller: Advanced Micro Devices, Inc. [AMD] Renoir/Cezanne USB 3.1
05:00.4 USB controller: Advanced Micro Devices, Inc. [AMD] Renoir/Cezanne USB 3.1
05:00.5 Multimedia controller: Advanced Micro Devices, Inc. [AMD] ACP/ACP3X/ACP6x Audio Coprocessor (rev 01)
05:00.6 Audio device: Advanced Micro Devices, Inc. [AMD] Family 17h/19h HD Audio Controller
06:00.0 SATA controller: Advanced Micro Devices, Inc. [AMD] FCH SATA Controller [AHCI mode] (rev 81)
06:00.1 SATA controller: Advanced Micro Devices, Inc. [AMD] FCH SATA Controller [AHCI mode] (rev 81)
❯ lsmod | grep snd
snd_usb_audio         462848  1
snd_usbmidi_lib        49152  1 snd_usb_audio
snd_ump                36864  1 snd_usb_audio
snd_rawmidi            57344  2 snd_usbmidi_lib,snd_ump
snd_seq_dummy          12288  0
snd_hrtimer            12288  1
snd_sof_amd_rembrandt    16384  0
snd_sof_amd_renoir     16384  0
snd_sof_amd_acp        57344  2 snd_sof_amd_rembrandt,snd_sof_amd_renoir
snd_sof_pci            24576  2 snd_sof_amd_rembrandt,snd_sof_amd_renoir
snd_sof_xtensa_dsp     16384  1 snd_sof_amd_acp
snd_sof               421888  2 snd_sof_amd_acp,snd_sof_pci
snd_sof_utils          16384  1 snd_sof
snd_soc_core          458752  1 snd_sof
snd_hda_codec_realtek   192512  1
snd_compress           28672  1 snd_soc_core
snd_hda_codec_generic   114688  1 snd_hda_codec_realtek
ac97_bus               12288  1 snd_soc_core
snd_hda_codec_hdmi     94208  1
snd_pcm_dmaengine      16384  1 snd_soc_core
ledtrig_audio          12288  1 snd_hda_codec_generic
snd_hda_intel          65536  2
snd_pci_ps             28672  0
snd_intel_dspcfg       36864  2 snd_hda_intel,snd_sof
snd_intel_sdw_acpi     16384  1 snd_intel_dspcfg
snd_hda_codec         225280  4 snd_hda_codec_generic,snd_hda_codec_hdmi,snd_hda_intel,snd_hda_codec_realtek
snd_rpl_pci_acp6x      16384  0
snd_hda_core          151552  5 snd_hda_codec_generic,snd_hda_codec_hdmi,snd_hda_intel,snd_hda_codec,snd_hda_codec_realtek
snd_pci_acp6x          20480  0
snd_hwdep              20480  2 snd_usb_audio,snd_hda_codec
snd_seq               131072  7 snd_seq_dummy
snd_seq_device         16384  3 snd_seq,snd_ump,snd_rawmidi
snd_pci_acp5x          16384  0
snd_pcm               184320  13 snd_sof_amd_acp,snd_hda_codec_hdmi,snd_pci_acp6x,snd_hda_intel,snd_usb_audio,snd_hda_codec,snd_sof,snd_compress,snd_soc_core,snd_sof_utils,snd_hda_core,snd_pci_ps,snd_pcm_dmaengine
snd_rn_pci_acp3x       24576  0
snd_acp_config         16384  6 snd_rn_pci_acp3x,snd_pci_acp6x,snd_pci_acp5x,snd_sof_amd_rembrandt,snd_pci_ps,snd_sof_amd_renoir
mc                     90112  5 videodev,snd_usb_audio,videobuf2_v4l2,uvcvideo,videobuf2_common
snd_timer              53248  3 snd_seq,snd_hrtimer,snd_pcm
snd_soc_acpi           12288  2 snd_sof_amd_acp,snd_acp_config
snd                   151552  25 snd_hda_codec_generic,snd_seq,snd_seq_device,snd_hda_codec_hdmi,snd_hwdep,snd_hda_intel,snd_usb_audio,snd_usbmidi_lib,snd_hda_codec,snd_hda_codec_realtek,snd_sof,snd_timer,snd_compress,snd_soc_core,snd_ump,snd_pcm,snd_rawmidi
snd_pci_acp3x          16384  0
soundcore              16384  1 snd

Easyeffects version (flatpak)

Captura desde 2023-11-07 00-15-22

pw-mon

when I tried to play a test wav file with aplay pw-mon.log

pw-dump

without audio after taking pw-mon pw-dump.log

Captures with Kooha

Using + and + I get the sound of the effect https://github.com/wwmm/easyeffects/assets/6588120/c611b758-de33-40f0-baab-e830632e6a85

Playing a wav with aplay, no audio output https://github.com/wwmm/easyeffects/assets/6588120/9959a727-074c-4b74-a2c5-6f2bffbd80fb

wwmm commented 10 months ago

but I recently noticed that when I close easyeffects I get the audio back without restarting the pipewire service.

Probably because the audio players were still being moved to EasyEffects virtual device. But if PipeWire died during the suspending process EasyEffects has to be manually restarted for it to work again. It can not automatically reload itself like PipeWire does. The only solution to this kind of problem is to figure out why PipeWire is dying.

rscm commented 7 months ago

what can I do to help fix this issue? because atm when I wake the computer is really frustrating not having audio until I close easyeffects. I finally gave up and I won't even open it.

1player commented 7 months ago

FWIW this has been fixed for me for a while

wwmm commented 7 months ago

what can I do to help fix this issue? because atm when I wake the computer is really frustrating not having audio until I close easyeffects. I finally gave up and I won't even open it.

We have an open issue about the suspension/hibernation problem. As discussed there its cause is still unknown and there is the possibility it can not be fixed on our side. PulseEffects had the same kind of problem on Pulseaudio even having a completely different code when compared to EasyEffects.

wwmm commented 7 months ago

We have an open issue about the suspension/hibernation problem. As discussed there its cause is still unknown and there is the possibility it can not be fixed on our side. PulseEffects had the same kind of problems on Pulseaudio even having a completely different code when compared to EasyEffects.

And to make things even harder suspending the computer somehow causes no problem here on my machine. I tested it now after using the gnome menu to suspend and audio came back fine on its own. I suspect that soundcard drivers or their interaction with the sound server may be related somehow.

rscm commented 7 months ago

We have an open issue about the suspension/hibernation problem. As discussed there its cause is still unknown and there is the possibility it can not be fixed on our side. PulseEffects had the same kind of problems on Pulseaudio even having a completely different code when compared to EasyEffects.

And to make things even harder suspending the computer somehow causes no problem here on my machine. I tested it now after using the gnome menu to suspend and audio came back fine on its own. I suspect that soundcard drivers or their interaction with the sound server may be related somehow.

btw if I suspend the laptop (closing the lid) and wait a few seconds the audio works... if I wait longer (minutes) I won't have audio

I will narrow the time testing it further

(to test the audio I use pw-play and a mp3 file)


the test:

to reset:

after 4 seconds of closing the lid the sound doesn't work before 4 seconds is too short to tell and sometimes the laptop doesn't even goes to sleep

imho that could mean that the problem is waking up


Handle 0x0033, DMI type 41, 11 bytes
Onboard Device
    Reference Designation: Realtek ALC701
    Type: Sound
    Status: Enabled
    Type Instance: 1
    Bus Address: 00ff:ff:1f.7
Audio:
  Device-1: NVIDIA TU106 High Definition Audio driver: snd_hda_intel v: kernel
    bus-ID: 01:00.1
  Device-2: AMD ACP/ACP3X/ACP6x Audio Coprocessor vendor: Lenovo driver: N/A
    bus-ID: 05:00.5
  Device-3: AMD Family 17h/19h HD Audio vendor: Lenovo driver: snd_hda_intel
    v: kernel bus-ID: 05:00.6
  API: ALSA v: k6.7.4-200.fc39.x86_64 status: kernel-api
❯ sudo lshw -c sound
  *-multimedia              
       description: Audio device
       product: TU106 High Definition Audio Controller
       vendor: NVIDIA Corporation
       physical id: 0.1
       bus info: pci@0000:01:00.1
       logical name: card0
       logical name: /dev/snd/controlC0
       logical name: /dev/snd/hwC0D0
       logical name: /dev/snd/pcmC0D3p
       logical name: /dev/snd/pcmC0D7p
       logical name: /dev/snd/pcmC0D8p
       logical name: /dev/snd/pcmC0D9p
       version: a1
       width: 32 bits
       clock: 33MHz
       capabilities: bus_master cap_list
       configuration: driver=snd_hda_intel latency=0
       resources: irq:101 memory:d1000000-d1003fff
  *-multimedia:0 UNCLAIMED
       description: Multimedia controller
       product: ACP/ACP3X/ACP6x Audio Coprocessor
       vendor: Advanced Micro Devices, Inc. [AMD]
       physical id: 0.5
       bus info: pci@0000:05:00.5
       version: 01
       width: 32 bits
       clock: 33MHz
       capabilities: cap_list
       configuration: latency=0
       resources: memory:d1580000-d15bffff
  *-multimedia:1
       description: Audio device
       product: Family 17h/19h HD Audio Controller
       vendor: Advanced Micro Devices, Inc. [AMD]
       physical id: 0.6
       bus info: pci@0000:05:00.6
       logical name: card1
       logical name: /dev/snd/controlC1
       logical name: /dev/snd/hwC1D0
       logical name: /dev/snd/pcmC1D0c
       logical name: /dev/snd/pcmC1D0p
       version: 00
       width: 32 bits
       clock: 33MHz
       capabilities: bus_master cap_list
       configuration: driver=snd_hda_intel latency=0
       resources: irq:63 memory:d15c0000-d15c7fff
wwmm commented 7 months ago

after 4 seconds of closing the lid the sound doesn't work before 4 seconds is too short to tell and sometimes the laptop doesn't even goes to sleep

I did not test on my laptop. But at least on my desktop what I did was waiting until the fans stopped spinning and all the rgb and fans leds were turned off. Sound still came back.

Is there any difference if you trigger the sleep in a different way? For example by using your desktop menu instead of closing the laptop lid.

wwmm commented 7 months ago

I made one more comment at #2480. It is better to keep this investigation there.

rscm commented 7 months ago

Is there any difference if you trigger the sleep in a different way? For example by using your desktop menu instead of closing the laptop lid.

no, there's no difference