From: Christian Borntraeger Date: Tue, 20 Nov 2007 10:13:36 +0000 (+0100) Subject: [S390] Optimize storage key handling for anonymous pages X-Git-Tag: v2.6.24-rc4~108^2~5 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=ce7e9fae8db07af4080e868f4588f8f095f803dc;p=pandora-kernel.git [S390] Optimize storage key handling for anonymous pages page_mkclean used to call page_clear_dirty for every given page. This is different to all other architectures, where the dirty bit in the PTEs is only resetted, if page_mapping() returns a non-NULL pointer. We can move the page_test_dirty/page_clear_dirty sequence into the 2nd if to avoid unnecessary iske/sske sequences, which are expensive. This change also helps kvm for s390 as the host must transfer the dirty bit into the guest status bits. By moving the page_clear_dirty operation into the 2nd if, the vm will only call page_clear_dirty for pages where it walks the mapping anyway. There it calls ptep_clear_flush for writable ptes, so we can transfer the dirty bit to the guest. Signed-off-by: Christian Borntraeger Signed-off-by: Martin Schwidefsky --- Reading git-diff-tree failed