summaryrefslogtreecommitdiff
path: root/kern/kmem.h
AgeCommit message (Collapse)Author
2019-05-22Add a log print function type for information reportingRichard Braun
This type allows the use of either printf-based or log-based functions when reporting information.
2018-02-24Don't use reserved identifiersRichard Braun
2017-07-13Switch to initialization operationsRichard Braun
2017-02-04Clean up compilationRichard Braun
Instead of mixing standard headers and internal redefinitions of standard types, completely rely on the compiler for what is guaranteed for a free standing environment. This results in the removal of kern/stddef.h and kern/stdint.h. The kern/types.h header is reintroduced for the different (and saner) purpose of defining types not specified in standard C, namely ssize_t for now.
2017-01-11kern/kmem: rework slab allocationRichard Braun
Allocating slabs from the page allocator only is likely to cause fragmentation. Instead, allocate larger-than-page slabs from kernel virtual memory, and page-sized slabs from the page allocator.
2014-12-10kern/kmem: directmap updateRichard Braun
The main impact of the direct physical mapping on the kmem module is the slab size computation. The page allocator requires the allocation size to be a power-of-two above the page size since it uses the buddy memory allocation algorithm. Custom slab allocation functions are no longer needed since the only user was the kentry area, which has been removed recently. The KMEM_CACHE_NOCPUPOOL flag is also no longer needed since CPU pools, which are allocated from a kmem cache, can now always be allocated out of the direct physical mapping.
2014-11-17kern/kmem: minor interface updatesRichard Braun
Make allocation functions accept and return pointers instead of integers for convenience.
2013-06-09kern/kmem: rename constructor typeRichard Braun
2013-04-19kern/kmem: move internal data to kmem_i.hRichard Braun
As it's done for other modules, this separation makes the public interface easy to identify.
2013-04-17kern/kmem: replace spin locks with mutexesRichard Braun
2012-12-11kern/kmem: add locksRichard Braun
2012-12-07kern/kmem: rework buffer-to-slab lookupRichard Braun
Instead of using a red-black tree, rely on the VM system to store kmem specific private data.
2012-12-01Normalize the spelling of CPU in commentsRichard Braun
2012-12-01kern/kmem: merge kmem_bootstrap into kmem_setupRichard Braun
2012-12-01kern/kmem: remove the KMEM_CACHE_NORECLAIM flagRichard Braun
Don't encourage anyone to use non reclaimable pools of resources, it's a Bad Thing To Do.
2012-11-29vm/vm_map: make the kentry cache reclaimableRichard Braun
This change adds a preallocated table that describes all the slabs in the kentry area. This makes it possible to release kernel map entry slabs back. Unused slabs are inserted in a free list for fast allocation.
2012-11-03Merge lib into kernRichard Braun
There are no precise enough criteria to justify the separation of these two directories.
2012-09-30Initial commitRichard Braun