Messages in this thread | | | Date | Thu, 12 Aug 1999 21:26:55 +0200 | From | Jakub Jelinek <> | Subject | Re: __init & __exit |
| |
> (2) There are some large structures in kernel > which are marked as __init/__initdata because > of they are used only at device initialization. > Because of some of them are `helper' functions > used by modules too, could not we introduce > concept of swappable kernel memory? Device > initialization occurs in specific contexts > (boottime or inside module initialization (or > cleanup, eventually)) where we could allow > swapping. Of course, probably not for 2.4, but > just idea... For example PCI bus scan, logo > drawing code (currently unavailable for modules), > videomode databasesare such things. And > for hotpluggable devices we then cannot > release __init section in most cases (as > device initialization lives in this section > in most cases).
I've posted a patch for init sections in modules several times during early 2.3.x development, but received no answer from Linus so I gave up on it. It has been widely tested in 2.1.xx series in VGER cvs, current modutils already support it for more than a year. For some drivers it is worth IMHO, e.g. some modules have some 512K of initdata if I remember well. Allowing swapping out those init sections instead of discarding them should be fun. One issue though is to write support for it just in a few instructions, so that not much memory is wasted on handling it. An open question is whether to allow that swap out/swap on a page by page basis and catch it in exception handling, or whether to swap the whole init/cleanup section of a module or of the main kernel at once.
Cheers, Jakub ___________________________________________________________________ Jakub Jelinek | jj@sunsite.mff.cuni.cz | http://sunsite.mff.cuni.cz Administrator of SunSITE Czech Republic, MFF, Charles University ___________________________________________________________________ UltraLinux | http://ultra.linux.cz/ | http://ultra.penguin.cz/ Linux version 2.3.13 on a sparc64 machine (1343.49 BogoMips) ___________________________________________________________________
- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.rutgers.edu Please read the FAQ at http://www.tux.org/lkml/
| |