|   | 
      | 
  
  
      | 
      | 
  
 
     | 
    | 
  
  
     | 
    | 
  
  
    |   | 
      | 
  
  
    | 
         
xen-devel
[Xen-devel] Re: xsd_kva mmap
 
* Keir Fraser (Keir.Fraser@xxxxxxxxxxxx) wrote:
> 
> On 6 Mar 2006, at 19:11, Chris Wright wrote:
> 
> >>Also, your patch would need to set vma->vm_pgoff before calling
> >>remap_pfn_range(), or the unmap code will incorrectly mess with page
> >>reference counts (because the skanky VM_PFNMAP check in vm_normal_page
> >>would not trigger and so that function will return non-NULL).
> >
> >Thanks for the eyes, esp. considering that's what the original fix was
> >all about ;-)
> 
> Actually, now I look again, it appears that remap_pfn_range() deals 
> with the re-setting of vm_pgoff itself (conditional on 
> is_cow_mapping(), and prefixed with an enormous comment). So re-setting 
> in the caller is unnecessary and your patch is just fine.
Well, I did test it for the page count problem, and it passed.  But started
to question my read of the code based on your original comments above.
> I think there are one or two other places in Xen code that I munge 
> vm_pgoff, so I guess I can clean up a little now. :-)
> 
> Sorry about that...
No problem, thanks for the clarification.
-chris
_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel
 
 |   
 
 | 
    | 
  
  
    |   | 
    |