svn commit: r259908 - head/sys/vm

Konstantin Belousov kostikbel at gmail.com
Sun Dec 29 20:13:21 UTC 2013


On Sun, Dec 29, 2013 at 01:15:22PM -0600, Alan Cox wrote:
> On 12/29/2013 03:00, Konstantin Belousov wrote:
> > BTW, I do not easily see why the current amd64 implementation needs
> > the pmap being current.  I do not see accesses to recursive page table
> > mappings in the code.
> 
> The amd64 implementation doesn't load and clear the PTEs atomically, so
> the dirty bit could be set by another processor after the PTE was loaded
> but before it was cleared.

But then, the check at the start of the function is not sufficient.
Other thread in the process or rforked child could still operate on
the address space.

I think it is mostly enough since pmap_remove_pages() is (was) only
called for the last reference on the vmspace going away, so accidentally
the check is good enough. But IMO it definitely does not reflect the
cause for the restriction.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 834 bytes
Desc: not available
URL: <http://lists.freebsd.org/pipermail/svn-src-head/attachments/20131229/7d5d0307/attachment.sig>


More information about the svn-src-head mailing list