From: "Jacob Gorm Hansen" Subject: When can ptes be written by Xen? Date: Fri, 30 Jun 2006 15:17:34 +0200 Message-ID: Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Return-path: Content-Disposition: inline List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xensource.com Errors-To: xen-devel-bounces@lists.xensource.com To: xen-devel@lists.xensource.com List-Id: xen-devel@lists.xenproject.org hi, I am having a weird consistency problem with a XenLinux page that changes even though it is mapped read-only. The offending page looks like a pte, and it has PG_foreign set in it's struct page. The page is zero-filled, but an 'invisible' write then changes it to contain a value like: 0x0c642067 -- which to me looks like a user-accessible mapping of the mfn 0xc642 (this is x86-32). However, the page is not listed in any pgd in the system, though it's mfn does map to a pfn belonging to the domain. Before I do anything I attempt to make sure writable page tables are flushed by executing a dummy mmu-update. I trap update_va_mapping() calls, so that should not be the source of the error. I can fix the problem by scanning the page array for all pages with the foreign bit set and giving these special treatment. However that will scale badly with the number of pages. Under what conditions would Xen write to a pte like above? Thanks in advance, Jacob