Feature #6571
closedSupport modules without or with non-standard approaches to provide init and exit functions
0%
Description
EMG always expect single init and single exit function given to module_init and module_exit macros.
Updated by Evgeny Novikov almost 9 years ago
- Subject changed from Support modules without or with the different implementation of init and exit to Support modules without or with non-standard approaches to provide init and exit functions
Updated by Alexey Khoroshilov almost 9 years ago
What kinds of non-standard approaches to provide init and exit functions do you mean?
Updated by Ilja Zakharov almost 9 years ago
I mean the other macros than "module_init". For example "console_initcall" macro. Header "include/linux/module.h" describes many of them, but the set strongly depends on kernel version. For example in the latest 4.4 kernel the majority of them are transformed into "module_init" still. By the way it makes sense to conduct experiments on 3.x kernels and determine drivers on which our current approach does not work.
P.S. To fix this it is just needed to add more macros to specific template file for Source Analyzer plugin.
Updated by Evgeny Novikov about 7 years ago
- Tracker changed from Bug to Feature
- Priority changed from Low to High
I guess that the issue was primarily connected with attempts to analyze modules compiled into the kernel since otherwise it looks like all modules have module_init either explicitly or via substituting one of specific macros to it (you can see mentioned by Ilja header for details).
The issue was implemented about a year ago by explicit enumeration of many initialization macros. I am just wondering why not get initialization functions from macro __define_initcall to which a lot of other initialization macros are substituted? This seems to be a more safe approach regarding different versions of the kernel (although I assume that the corresponding API doesn't change frequently/ever).
Updated by Ilja Zakharov over 6 years ago
- Status changed from New to Resolved
Currently I have implemented a configurable way to set macros for both modules and kernel initializations in 8066-abstract-translator. If necessary additional macros can be defined in configuration. At the moment both kernel and module initialization functions are supported and called by EMG.
Updated by Evgeny Novikov about 5 years ago
- Status changed from Resolved to Closed
It seems that the branch was merged to master a long ago, but issues were not closed at that time.