Skip to content

Commit

Permalink
pmm: remove unused find_max_avail_order
Browse files Browse the repository at this point in the history
Previously used but with the current pmm loop, there's no need for it.

Signed-off-by: Johannes Wikner <[email protected]>
  • Loading branch information
sktt committed Feb 17, 2024
1 parent 40f74b5 commit 4850686
Showing 1 changed file with 0 additions and 9 deletions.
9 changes: 0 additions & 9 deletions mm/pmm.c
Original file line number Diff line number Diff line change
Expand Up @@ -262,15 +262,6 @@ static inline void add_frame(mfn_t mfn, unsigned int order) {
list_add_tail(&frame->list, &free_frames[order]);
}

static inline unsigned int find_max_avail_order(size_t size) {
for (unsigned int order = MAX_PAGE_ORDER; order > PAGE_ORDER_4K; order--) {
if (ORDER_TO_SIZE(order) <= size)
return order;
}

return PAGE_ORDER_4K;
}

static unsigned find_first_avail_region(void) {
addr_range_t range;

Expand Down

0 comments on commit 4850686

Please sign in to comment.