diff options
Diffstat (limited to 'drivers/gpu/nvgpu/common/fifo/submit.c')
-rw-r--r-- | drivers/gpu/nvgpu/common/fifo/submit.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/drivers/gpu/nvgpu/common/fifo/submit.c b/drivers/gpu/nvgpu/common/fifo/submit.c index e0f31233..56512894 100644 --- a/drivers/gpu/nvgpu/common/fifo/submit.c +++ b/drivers/gpu/nvgpu/common/fifo/submit.c | |||
@@ -341,14 +341,14 @@ static int nvgpu_submit_channel_gpfifo(struct channel_gk20a *c, | |||
341 | return -ETIMEDOUT; | 341 | return -ETIMEDOUT; |
342 | } | 342 | } |
343 | 343 | ||
344 | if (!nvgpu_mem_is_valid(&c->gpfifo.mem)) { | ||
345 | return -ENOMEM; | ||
346 | } | ||
347 | |||
348 | if (c->usermode_submit_enabled) { | 344 | if (c->usermode_submit_enabled) { |
349 | return -EINVAL; | 345 | return -EINVAL; |
350 | } | 346 | } |
351 | 347 | ||
348 | if (!nvgpu_mem_is_valid(&c->gpfifo.mem)) { | ||
349 | return -ENOMEM; | ||
350 | } | ||
351 | |||
352 | /* fifo not large enough for request. Return error immediately. | 352 | /* fifo not large enough for request. Return error immediately. |
353 | * Kernel can insert gpfifo entries before and after user gpfifos. | 353 | * Kernel can insert gpfifo entries before and after user gpfifos. |
354 | * So, add extra_entries in user request. Also, HW with fifo size N | 354 | * So, add extra_entries in user request. Also, HW with fifo size N |