Get name of kernel module in Driver Code - KBUILD_MODNAME

Kernel build system defines KBUILD_MODNAME automatically from each Makefile.

Following is the sample code which prints the name of module when loaded and unloaded.


Ouptut:


Comments

Popular posts from this blog

bb.utils.contains yocto

make config vs oldconfig vs defconfig vs menuconfig vs savedefconfig

PR, PN and PV Variable in Yocto