kernel: recover module_init/exit() functions
It's quite complicated to record which functions are the module_init/exit()
functions.
I first find a static symbol, then I look in that scope until I find an
__inittest() or __exittest() function. Those functions do:
static inline int __inittest(void) { return xyz_init; }
This still doesn't help find the caller because the module->init pointer is
passed as a function parameter to another function and Smatch doesn't
track it that far yet.
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>