-
Notifications
You must be signed in to change notification settings - Fork 20
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
add VIRT_KERNEL_MAP memory area #240
Conversation
wipawel
commented
Jan 19, 2022
•
edited
Loading
edited
Signed-off-by: Pawel Wieczorkiewicz <[email protected]>
Signed-off-by: Pawel Wieczorkiewicz <[email protected]>
@@ -196,6 +212,19 @@ static inline void *kmap(mfn_t mfn, unsigned int order, | |||
l3_flags, l2_flags, l1_flags); | |||
} | |||
|
|||
static inline void *mmap(mfn_t mfn, unsigned int order, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Same here
name mmap
is misleading.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ok. Suggestions welcome.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
With VIRT_KERNEL_MAP I hope it's now ok.
The VIRT_KERNEL_MAP is currently located at the address 0xffff800000000000. The memory area should be used for high-address or large memory allocations. The VIRT_KERNEL_BASE area, while reachable from within the VIRT_IDENT_BASE area, does not have enough addressing space for high address allocations (base address overflow). All such allocations should go to the new area. Add mmap() helper (or its order size variants) to automatically use the VIRT_KERNEL_MAP area. The get_free_pages() gets a new flag GPF_KERNEL_MAP to use the area. Signed-off-by: Pawel Wieczorkiewicz <[email protected]>