[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
__init question
dear all,
i was going to ask what __init does, but i found the answer on this list's
archives. btw, the archives are /fantastic/. any chance of making them
searchable?
anyway, there was a thread on the subject, and i'd like to ask a question
about some of the thread replies.
what exactly is the difference between __initfunc(int myfunc(void)) and
__init int myfunc(void)?
lastly, in the example code on the kernelnewbies website, i notice the
lines:
module_init(init_mmaptest);
module_exit(cleanup_mmaptest);
of course, there are definitions for the functions init_mmaptest and
cleanup_mmaptest. is this replacing the standard "modules begin with
init_module and exit with cleanup module"?
if we want to retain compatibility with 2.2 and 2.0, should i stick with
init_module/cleanup_module?
thanks!
pete
ps- the website/list is really great. with resources like these, linux is
sure to have an army of module writers who'll be able to write drivers
faster than companies can put out hardware. ;)
PGP signature