Quick potential fix for crackling/buzzing audio issues
Check values of these two files:
cat /sys/class/rtc/rtc0/max_user_freq
cat /proc/sys/dev/hpet/max-user-freq
If they have defaulted back to 64
for whatever resaon, that's likely causing your crackling. You can fix it by running the following commands
sudo -i
echo 2048 > /sys/class/rtc/rtc0/max_user_freq
echo 2048 > /proc/sys/dev/hpet/max-user-freq
then restart pipewire with
systemctl --user restart pipewire.service
(or you can reboot if that's easier)
This should fix the crackling!
That's a good question.
Another question is: if these values are necessary, why aren't they the default? And: if it's too difficult to find a default that works for all machines, then why are they reset after customization?
Maybe the answer is simply that the values should be changed through other means to be persisted. I'd prefer not to have to make my own systemd unit.
Edit:
https://www.kernel.org/doc/html/v6.10/admin-guide/rtc.html explains why
64
: higher values might have adverse effects on a slow 386 🙀Less sure why it describes this API as "readonly" though: