lib/alloc_phys: Remove allocation accounting
The page allocator has better allocation tracking and is used by all architectures, while the physical allocator is never used for allocating memory. Simplify the physical allocator by removing allocation accounting. This accomplishes two things: 1. It makes the allocator more useful, as the warning that was displayed for each allocation after the 256th is removed. That can become an issue if the allocator is used for creating the translation tables, for example. 2. It becomes trivial to add cache maintenance for the internal structures that the physical allocator maintains, which are now only four static variables. phys_alloc_show() has received a slight change in the way it displays the use and free regions: the end of the region is now non-inclusive, to allow phys_alloc_show() to express that no memory has been used, or no memory is free: in both cases, the start and the end adresses are equal. Reviewed-by:Andrew Jones <andrew.jones@linux.dev> Signed-off-by:
Alexandru Elisei <alexandru.elisei@arm.com>
Loading
Please register or sign in to comment