Similar to
1387d1d4, this offset was being applied twice (once in
translate_generic, and once when the buffer is mapped).
This fixes 7972, which was initially thought to be an endianness
specific issue.
CC: mesa-stable
Tested-by: Filip Gawin <filip@gawin.net>
Reviewed-by: Karol Herbst <kherbst@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/20468>
if (info->index_size) {
if (!info->has_user_indices)
ctx.idxbuf = nouveau_resource_map_offset(&nv30->base,
- nv04_resource(info->index.resource), draw->start * info->index_size,
+ nv04_resource(info->index.resource), 0,
NOUVEAU_BO_RD);
else
- ctx.idxbuf = (char*)info->index.user + draw->start * info->index_size;
+ ctx.idxbuf = (char*)info->index.user;
if (!ctx.idxbuf) {
nv30_state_release(nv30);
return;