diff options
Diffstat (limited to 'drivers/gpu/nvgpu/common/pramin.c')
-rw-r--r-- | drivers/gpu/nvgpu/common/pramin.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/drivers/gpu/nvgpu/common/pramin.c b/drivers/gpu/nvgpu/common/pramin.c index b9216309..aa732368 100644 --- a/drivers/gpu/nvgpu/common/pramin.c +++ b/drivers/gpu/nvgpu/common/pramin.c | |||
@@ -88,7 +88,8 @@ void nvgpu_pramin_access_batched(struct gk20a *g, struct mem_desc *mem, | |||
88 | u32 byteoff, start_reg, until_end, n; | 88 | u32 byteoff, start_reg, until_end, n; |
89 | 89 | ||
90 | alloc = get_vidmem_page_alloc(mem->sgt->sgl); | 90 | alloc = get_vidmem_page_alloc(mem->sgt->sgl); |
91 | list_for_each_entry(chunk, &alloc->alloc_chunks, list_entry) { | 91 | nvgpu_list_for_each_entry(chunk, &alloc->alloc_chunks, |
92 | page_alloc_chunk, list_entry) { | ||
92 | if (offset >= chunk->length) | 93 | if (offset >= chunk->length) |
93 | offset -= chunk->length; | 94 | offset -= chunk->length; |
94 | else | 95 | else |
@@ -113,7 +114,8 @@ void nvgpu_pramin_access_batched(struct gk20a *g, struct mem_desc *mem, | |||
113 | size -= n; | 114 | size -= n; |
114 | 115 | ||
115 | if (n == (chunk->length - offset)) { | 116 | if (n == (chunk->length - offset)) { |
116 | chunk = list_next_entry(chunk, list_entry); | 117 | chunk = nvgpu_list_next_entry(chunk, page_alloc_chunk, |
118 | list_entry); | ||
117 | offset = 0; | 119 | offset = 0; |
118 | } else { | 120 | } else { |
119 | offset += n / sizeof(u32); | 121 | offset += n / sizeof(u32); |