gbm/dri: Check dri extension version before flush after unmap
authorThomas Hellstrom <thellstrom@vmware.com>
Thu, 30 Mar 2017 14:33:47 +0000 (16:33 +0200)
committerThomas Hellstrom <thellstrom@vmware.com>
Fri, 31 Mar 2017 08:25:46 +0000 (10:25 +0200)
commit18e2aa063ca8e2aeb22a72253891e6f8f5d0d96b
tree49990628c1c20d0ca4dc614fd076fb24f22c09d4
parent02112c3ef7716955c889b6d10fb569b028a33f0e
gbm/dri: Check dri extension version before flush after unmap

The commit mentioned below required the __DRI2FlushExtension to have
version 4 or above, for GBM functionality. That broke GBM with some
classic dri drivers. Relax that requirement so that we only flush
after unmap if we have version 4 or above. Drivers that require the flush
for correct functionality should implement the desired version.

Fixes: ba8df228 ("gbm/dri: Flush after unmap")
Cc: <mesa-stable@lists.freedesktop.org>
Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
Reviewed-by: Emil Velikov <emil.velikov@collabora.com>
Tested-by: Dylan Baker <dylan@pnwbakers.com>
src/gbm/backends/dri/gbm_dri.c