Lines Matching full:get

33 /* Fetch and adjust GPU GET pointer
36 * value >= 0, the adjusted GET pointer
37 * -EINVAL if GET pointer currently outside main push buffer
49 /* reset counter as long as GET is still advancing, this is in READ_GET()
104 uint32_t get = nvif_rd32(chan->userd, 0x88); in nv50_dma_push_wait() local
105 if (get != prev_get) { in nv50_dma_push_wait()
106 prev_get = get; in nv50_dma_push_wait()
116 chan->dma.ib_free = get - chan->dma.ib_put; in nv50_dma_push_wait()
135 int get = READ_GET(chan, &prev_get, &cnt); in nv50_dma_wait() local
136 if (unlikely(get < 0)) { in nv50_dma_wait()
137 if (get == -EINVAL) in nv50_dma_wait()
140 return get; in nv50_dma_wait()
143 if (get <= chan->dma.cur) { in nv50_dma_wait()
150 get = READ_GET(chan, &prev_get, &cnt); in nv50_dma_wait()
151 if (unlikely(get < 0)) { in nv50_dma_wait()
152 if (get == -EINVAL) in nv50_dma_wait()
154 return get; in nv50_dma_wait()
156 } while (get == 0); in nv50_dma_wait()
161 chan->dma.free = get - chan->dma.cur - 1; in nv50_dma_wait()
171 int cnt = 0, get; in nouveau_dma_wait() local
177 get = READ_GET(chan, &prev_get, &cnt); in nouveau_dma_wait()
178 if (unlikely(get == -EBUSY)) in nouveau_dma_wait()
181 /* loop until we have a usable GET pointer. the value in nouveau_dma_wait()
186 * the other case we discard GET is while the GPU is fetching in nouveau_dma_wait()
190 if (unlikely(get == -EINVAL) || get < NOUVEAU_DMA_SKIPS) in nouveau_dma_wait()
193 if (get <= chan->dma.cur) { in nouveau_dma_wait()
195 * idle (GET == PUT) so we have free space up until in nouveau_dma_wait()
204 * GET==PUT, in which case the below conditional will in nouveau_dma_wait()
217 /* wait for GET to depart from the skips area. in nouveau_dma_wait()
218 * prevents writing GET==PUT and causing a race in nouveau_dma_wait()
223 get = READ_GET(chan, &prev_get, &cnt); in nouveau_dma_wait()
224 if (unlikely(get == -EBUSY)) in nouveau_dma_wait()
226 if (unlikely(get == -EINVAL)) in nouveau_dma_wait()
228 } while (get <= NOUVEAU_DMA_SKIPS); in nouveau_dma_wait()
239 * current GET pointer. the "- 1" is to ensure there's in nouveau_dma_wait()
241 * push buffer if we require it. we can never get GET == PUT in nouveau_dma_wait()
244 chan->dma.free = get - chan->dma.cur - 1; in nouveau_dma_wait()