I have seen that when I do
lsmod in petalinux , I get "not tainted" message.
Is there any alternative for
lsmod then ?
As most Unix commands,
lsmod(8) keeps silent when it has nothing interesting to report. In your case, it means you don't have any modules loaded.
The Linux kernel can configure many parts as modules (to be loaded/unloaded at runtime) or builtin. Most distributions configure as much as possible as modules, there is a tiny performance penalty but a huge win in flexibility. It is certainly possible to tailor a kernel to a particular machine, with no modules. It might make sense to disable module loading completely, as ways of loading foreign code open a security risk.
Why this is so in your particular case, with that distribution, depends on the distribution's policies (I don't know about it) and your exact setup.
If the output from
/proc/modules does not show you anything, then the likely conclusion would be that your distro was potentially built with all the modules compiled into the kernel, and so there aren't any modules to see.
I'd encourage you to take a look at the PetaLinux website that's part of Xilinx's site, there's a FAQ which has the following topic: "How do I add kernel modules to my PetaLinux root file system?". The answer to this FAQ, Answer Record 55997.
That answer shows how to load the prebuilt kernel modules for your particular targeted architecture (Microblaze, ARM, etc.).
lsmod command read from same kernel interfaces. The most common reason for tainting is loading a module which declares a license other than GPL. All official kernel modules have a GPL license.
I think the reason why your lsmod output is empty because during kernel compilation time, you didn't compile anything with modules support. You can refer to
/boot/config-$(uname -r). I dont think you will get entry like