st/mesa: do uploads earlier in try_pbo_upload_common
authorNicolai Hähnle <nicolai.haehnle@amd.com>
Wed, 3 Feb 2016 16:54:33 +0000 (17:54 +0100)
committerNicolai Hähnle <nicolai.haehnle@amd.com>
Fri, 5 Feb 2016 14:21:27 +0000 (09:21 -0500)
commit13e21e3ec58903a9974093423f9cef5e6edb668e
tree9b31ca21aea4f96b9de0bf4cec28af6b95ebb403
parenteb9cf3cfc99db0cff0a5a584941e8be43ac9b961
st/mesa: do uploads earlier in try_pbo_upload_common

While rather unlikely, uploads _can_ fail. Doing them earlier means
we'll have to restore less state when they do fail, and it's slightly
easier to check the restore code.

Reviewed-by: Alex Deucher <alexander.deucher@amd.com>
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
src/mesa/state_tracker/st_cb_texture.c