[Mesa-dev] [PATCH] loader/dri3: Avoid freeing renderbuffers in use
Kenneth Graunke
kenneth at whitecape.org
Thu Jan 11 23:01:49 UTC 2018
On Thursday, January 11, 2018 1:53:48 AM PST Thomas Hellstrom wrote:
> Upon reception of an event that lowered the number of active back buffers,
> the code would immediately try to free all back buffers with an id equal to or
> higher than the new number of active back buffers.
>
> However, that could lead to an active or to-be-active back buffer being freed,
> since the old number of back buffers was used when obtaining an idle back
> buffer for use.
>
> This lead to crashes when lowering the number of active back buffers by
> transitioning from page-flipping to non-page-flipping presents.
>
> Fix this by computing the number of active back buffers only when trying to
> obtain a new back buffer.
>
> Fixes: 15e208c4cc ("loader/dri3: Don't accidently free buffer holding new back content")
> Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=104214
> Cc: "17.3" <mesa-stable at lists.freedesktop.org>
> Signed-off-by: Thomas Hellstrom <thellstrom at vmware.com>
> ---
> src/loader/loader_dri3_helper.c | 6 +++---
> 1 file changed, 3 insertions(+), 3 deletions(-)
Thanks for fixing this, Thomas!
--Ken
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 833 bytes
Desc: This is a digitally signed message part.
URL: <https://lists.freedesktop.org/archives/mesa-dev/attachments/20180111/f38badf5/attachment.sig>
More information about the mesa-dev
mailing list