pipe_buffer_map_range makes stricter assertions, and would have saved us
grief detecting a bug in svga user buffer uploads.
struct pipe_transfer *transfer = NULL;
const char *map = NULL;
- map = (const char *)pipe_buffer_map(upload->pipe,
- inbuf,
- PIPE_TRANSFER_READ,
- &transfer);
+ map = (const char *)pipe_buffer_map_range(upload->pipe,
+ inbuf,
+ offset, size,
+ PIPE_TRANSFER_READ,
+ &transfer);
if (map == NULL) {
ret = PIPE_ERROR_OUT_OF_MEMORY;
ret = u_upload_data( upload,
min_out_offset,
size,
- map + offset,
+ map,
out_offset,
outbuf, flushed );