Realtek drivers on Linux, at least for some codecs, have this feature built-in, no malware needed. On my Dell XPS 13 9350, for example, I can use alsamixer or pavucontrol to choose between "Internal Mic," "Headset Mic," and "Headphone Mic."<p>The "Headphone Mic" setting is designed for connecting a microphone to the single multi-purpose 3.5mm jack, but it can also record audio from a pair of headphones just fine if you turn the gain up.