egl/dri2: implement query surface hook
This makes better guarantee that the values we return are
in sync what the underlying drawable currently has.
Together with dEQP change in bug #98327 this fixes following test:
dEQP-EGL.functional.resize.surface_size.grow
v2: avoid unnecessary x11 roundtrips (Chad Versace)
Signed-off-by: Tapani Pälli <tapani.palli@intel.com>
Tested-by: Mark Janes <mark.a.janes@intel.com>
Reviewed-by: Chad Versace <chadversary@chromium.org>
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=98327