From: Thomas Hellstrom <thellstrom@vmware.com>
To: Daniel Vetter <daniel@ffwll.ch>
Cc: Thomas Hellstrom <thellstrom@vmware.com>,
linux-graphics-maintainer@vmware.com,
dri-devel@lists.freedesktop.org
Subject: Re: [PATCH] drm/vma-manager: Don't unmap COW'd pages when zapping bo ptes
Date: Wed, 20 Nov 2013 23:35:31 +0100 [thread overview]
Message-ID: <528D3933.2090906@vmware.com> (raw)
In-Reply-To: <20131120142445.GB27344@phenom.ffwll.local>
On 11/20/2013 03:24 PM, Daniel Vetter wrote:
> On Wed, Nov 20, 2013 at 01:55:49AM -0800, Thomas Hellstrom wrote:
>> Not sure if there are any user-space users of private bo mappings, but
>> if there are, or will be, zapping the COW'd pages when, for example,
>> moving a bo would confuse the user immensely since the net effect for the
>> user would be that pages written to would lose their contents.
>>
>> Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
> Presuming I'm not horribly confused about that all the vm slang in the
> kerneldoc means this changes is
>
> Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch>
>
> Now I still hold that userspace creating anynomous bo mappings is rather
> crazy, but meh ;-) I guess the real question is whether we have anyone
> relying on this out there (or planing to), in which case we either need to
> funnel this through stable kernels or whack a drm feature flag onto
> drivers/kernels with this fixed. But I seriously hope the answer is no.
>
> Cheers, Daniel
>
Thanks for reviewing. I don't think there's a need to take this through
stable, since I don't know of anyone using private VMAs,
Actually I'll need to hold off on this for a while since on some archs
this may cause
ptes of shared pages to not be zapped. If the arch doesn't have
PTE_SPECIAL, shared pages on MIXEDMAP vmas will come through as
vm_normal_page, and since page->mapping is usually (un)set to NULL by
our drivers, this will result in false positives for COW'ed pages.
So that test is buggy, or us not setting page->mapping to the mapping we
use is buggy. It's too late in the day to decide which.
/Thomas
next prev parent reply other threads:[~2013-11-20 22:35 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-11-20 9:55 [PATCH] drm/vma-manager: Don't unmap COW'd pages when zapping bo ptes Thomas Hellstrom
2013-11-20 10:14 ` David Herrmann
2013-11-20 10:38 ` Thomas Hellstrom
2013-11-20 14:24 ` Daniel Vetter
2013-11-20 22:35 ` Thomas Hellstrom [this message]
2013-11-21 8:18 ` Daniel Vetter
2013-11-21 8:29 ` Thomas Hellstrom
2013-11-21 9:15 ` Daniel Vetter
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=528D3933.2090906@vmware.com \
--to=thellstrom@vmware.com \
--cc=daniel@ffwll.ch \
--cc=dri-devel@lists.freedesktop.org \
--cc=linux-graphics-maintainer@vmware.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.