Linux – How to relate a kernel config setting to the source files

configurationkernellinux-kernelsource

Here is an example that will explain better:

enter image description here

I have a selected the audio driver from the picture and i would like to browse through its source. How do i get to the path of the source files from here?

enter image description here

Best Answer

You have to use grep -r CONFIG_SND_SOC_MXS_SGTL5000.

Each of these config options just represents a #define macro. Many of them don't belong to a single file but instead are checked in multiple source files. CONFIG_64BIT for example appears in around 1k source code files.