Microphone not working after NixOS update

After updating my Framework Laptop 13 (AMD Ryzen AI 300 series) to a recent (unstable) revision of NixOS, the built-in microphone stopped working. I found a workaround and wrote about it in this nixos-hardware issue. I am opening this so that people with the same issue might come across it.

Not a framework user, but I also am the owner of a Legion 5 laptop with Ryzen AI 7 350 CPU, and have NixOS on it. My microphone is there but it doesn’t register any sound. It shows up as picking up something vary loud (going to max volume) all the time, but on playback, there’s silence.

Can confirm the fix is working for me, thanks!