virgl: Deduplicate resource mapping
Normal mapping of buffers and textures uses almost identical logic. Extract and use this logic in the form of virgl_resource_transfer_map.
Signed-off-by: Alexandros Frantzis alexandros.frantzis@collabora.com
Edited by Alexandros Frantzis