lkml.org 
[lkml]   [2021]   [Apr]   [28]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
From
Subject[PATCH] drm/i915: Use might_alloc()
Date
This maybe used lockdep through the fs_reclaim annotations.

Signed-off-by: Bernard Zhao <bernard@vivo.com>
---
drivers/gpu/drm/i915/i915_sw_fence.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/drivers/gpu/drm/i915/i915_sw_fence.c b/drivers/gpu/drm/i915/i915_sw_fence.c
index 2744558f3050..cc1b49cabb6c 100644
--- a/drivers/gpu/drm/i915/i915_sw_fence.c
+++ b/drivers/gpu/drm/i915/i915_sw_fence.c
@@ -341,7 +341,7 @@ static int __i915_sw_fence_await_sw_fence(struct i915_sw_fence *fence,
unsigned long flags;

debug_fence_assert(fence);
- might_sleep_if(gfpflags_allow_blocking(gfp));
+ might_alloc(gfp);

if (i915_sw_fence_done(signaler)) {
i915_sw_fence_set_error_once(fence, signaler->error);
@@ -477,7 +477,7 @@ int i915_sw_fence_await_dma_fence(struct i915_sw_fence *fence,
int ret;

debug_fence_assert(fence);
- might_sleep_if(gfpflags_allow_blocking(gfp));
+ might_alloc(gfp);

if (dma_fence_is_signaled(dma)) {
i915_sw_fence_set_error_once(fence, dma->error);
@@ -576,7 +576,7 @@ int i915_sw_fence_await_reservation(struct i915_sw_fence *fence,
int ret = 0, pending;

debug_fence_assert(fence);
- might_sleep_if(gfpflags_allow_blocking(gfp));
+ might_alloc(gfp);

if (write) {
struct dma_fence **shared;
--
2.31.0
\
 
 \ /
  Last update: 2021-04-29 04:52    [W:0.050 / U:0.156 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site