Skip to content
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

PKU support #566

Open
SchrodingerZhu opened this issue Oct 5, 2022 · 1 comment
Open

PKU support #566

SchrodingerZhu opened this issue Oct 5, 2022 · 1 comment

Comments

@SchrodingerZhu
Copy link
Contributor

https://www.man7.org/linux/man-pages/man7/pkeys.7.html

Just a discussion: could PKU/OSPKE possibily help snmalloc to remove the burden of notifying kernel of the permission changes?

@davidchisnall
Copy link
Collaborator

I see a couple of potential problems with using MPK:

  • It's a finite (and tiny) key space, so consuming any of the values in the allocator may break code that wants to use them.
  • We only change permissions for simulating Windows' no-lazy-commit behaviour on *NIX. Most of our system calls are returning physical pages to the system.
  • MPK still requires page table updates to change permissions on a page, it just makes it cheap (and insecure) to change the set of pages that you can access, so this wouldn't help us speed up marking pages as no-access.

Did you have a particular use in mind?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants