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

Synchronize satp & SPT #1

Closed
KuangjuX opened this issue Jan 29, 2023 · 2 comments
Closed

Synchronize satp & SPT #1

KuangjuX opened this issue Jan 29, 2023 · 2 comments
Labels
bug Something isn't working

Comments

@KuangjuX
Copy link
Owner

由于此时 satp 是作为 SPT(shadow page table) 的唯一标识,因此,有一种情况是:当操作系统的某进程被释放后,当前的 satp 所使用的根页表被释放,并在之后被其他进程所使用,但是此时 VMM 并不知道此时 satp 已经被替换,因此会造成错。所以,当 OS 请求向 VMM 写入 satp 时也需检查是否 satp 已经被替换。

@KuangjuX KuangjuX added the bug Something isn't working label Jan 29, 2023
@KuangjuX
Copy link
Owner Author

具体情况是当进程被 drop 掉后,该根目录地址是在 Guest OS 被分配到其他进程,由于在 Guest OS 中并没有将其他进程的用户页表设置为只读,因此 VMM 实际上并没有办法发现用户进程的页表已经被替换并且被重写了,造成了影子页表和用户页表的不一致。

@KuangjuX
Copy link
Owner Author

KuangjuX commented Feb 6, 2023

See issue: #2 fix this bug

@KuangjuX KuangjuX closed this as completed Feb 6, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant