Skip to contentSkip to conversation

KVM MMU: allow more shadow pages become asynchronous

PATCH Applied Xiao Guangrong 3 participants 3 messages Apr 28, 2010 KVM

v3 of 4 Applied Latest is v4 →

lore
Share & tools
lore
#0 lore raw

v3 cover KVM MMU: allow more shadow pages become asynchronous

Changlog v3:

Those changes all form Avi's suggestion, thanks.

- use smart way to fix the bug in patch 1
- remove duplicates code in patch 5
- check error code and fix forgot release page in patch 9
- sync shadow pages in a batch instead of one by one

And, there is one TODO thing:
Marker shadow page as unsync at create time avoid write-protect, this idea is from Avi:

|Another interesting case is to create new shadow pages in the unsync state.
|That can help when the guest starts a short lived process: we can avoid write
|protecting its pagetables completely

I'll send the patch out after this patchset applied.

Changlog v2:

- when level is PT_DIRECTORY_LEVEL, the 'offset' should be 'role.quadrant << 8', thanks Avi for point it out

- keep invlpg code in paging_tmpl.h address Avi's suggestion

- split kvm_sync_page() into kvm_sync_page() and kvm_sync_page_transient() to clarify the code address Avi's suggestion

#2 lore raw
In reply to Xiao Guangrong
Quoted 21 lines · Xiao Guangrong

Changlog v3:

Those changes all form Avi's suggestion, thanks.

- use smart way to fix the bug in patch 1
- remove duplicates code in patch 5
- check error code and fix forgot release page in patch 9
- sync shadow pages in a batch instead of one by one

And, there is one TODO thing:
Marker shadow page as unsync at create time avoid write-protect, this idea is from Avi:

|Another interesting case is to create new shadow pages in the unsync state.
|That can help when the guest starts a short lived process: we can avoid write
|protecting its pagetables completely

I'll send the patch out after this patchset applied.

Changlog v2:

Quoted 7 lines

- when level is PT_DIRECTORY_LEVEL, the 'offset' should be 'role.quadrant << 8', thanks Avi for point it out

- keep invlpg code in paging_tmpl.h address Avi's suggestion

- split kvm_sync_page() into kvm_sync_page() and kvm_sync_page_transient() to clarify the code address Avi's suggestion

Applied, thanks.