i915g: remove calls to pipe_sampler_view_release()

As with previous patches for svga, llvmpipe, swr drivers.
Compile tested only.

Reviewed-by: Roland Scheidegger <sroland@vmware.com>
Reviewed-by: Neha Bhende <bhenden@vmware.com>
Reviewed-by: Mathias Fröhlich <Mathias.Froehlich@web.de>
Reviewed-By: Jose Fonseca <jfonseca@vmware.com>
This commit is contained in:
Brian Paul 2019-03-08 15:20:16 -07:00
parent 768b770a86
commit c473090b09
1 changed files with 2 additions and 8 deletions

View File

@ -745,17 +745,11 @@ static void i915_set_fragment_sampler_views(struct pipe_context *pipe,
return;
for (i = 0; i < num; i++) {
/* Note: we're using pipe_sampler_view_release() here to work around
* a possible crash when the old view belongs to another context that
* was already destroyed.
*/
pipe_sampler_view_release(pipe, &i915->fragment_sampler_views[i]);
pipe_sampler_view_reference(&i915->fragment_sampler_views[i],
views[i]);
pipe_sampler_view_reference(&i915->fragment_sampler_views[i], views[i]);
}
for (i = num; i < i915->num_fragment_sampler_views; i++)
pipe_sampler_view_release(pipe, &i915->fragment_sampler_views[i]);
pipe_sampler_view_reference(&i915->fragment_sampler_views[i], NULL);
i915->num_fragment_sampler_views = num;