[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <tip-32d8206725bcf6e3ce7832ac39e61a6ecfd558db@git.kernel.org>
Date: Tue, 19 May 2015 00:20:07 -0700
From: tip-bot for David Hildenbrand <tipbot@...or.com>
To: linux-tip-commits@...r.kernel.org
Cc: dahi@...ux.vnet.ibm.com, linux-kernel@...r.kernel.org,
mingo@...nel.org, torvalds@...ux-foundation.org, hpa@...or.com,
tglx@...utronix.de, peterz@...radead.org
Subject: [tip:sched/core] mm/fault, drm/i915: Use pagefault_disabled()
to check for disabled pagefaults
Commit-ID: 32d8206725bcf6e3ce7832ac39e61a6ecfd558db
Gitweb: http://git.kernel.org/tip/32d8206725bcf6e3ce7832ac39e61a6ecfd558db
Author: David Hildenbrand <dahi@...ux.vnet.ibm.com>
AuthorDate: Mon, 11 May 2015 17:52:12 +0200
Committer: Ingo Molnar <mingo@...nel.org>
CommitDate: Tue, 19 May 2015 08:39:15 +0200
mm/fault, drm/i915: Use pagefault_disabled() to check for disabled pagefaults
Now that the pagefault disabled counter is in place, we can replace
the in_atomic() check by a pagefault_disabled() checks.
Reviewed-and-tested-by: Thomas Gleixner <tglx@...utronix.de>
Signed-off-by: David Hildenbrand <dahi@...ux.vnet.ibm.com>
Signed-off-by: Peter Zijlstra (Intel) <peterz@...radead.org>
Cc: David.Laight@...LAB.COM
Cc: Linus Torvalds <torvalds@...ux-foundation.org>
Cc: Peter Zijlstra <peterz@...radead.org>
Cc: Thomas Gleixner <tglx@...utronix.de>
Cc: airlied@...ux.ie
Cc: akpm@...ux-foundation.org
Cc: benh@...nel.crashing.org
Cc: bigeasy@...utronix.de
Cc: borntraeger@...ibm.com
Cc: daniel.vetter@...el.com
Cc: heiko.carstens@...ibm.com
Cc: herbert@...dor.apana.org.au
Cc: hocko@...e.cz
Cc: hughd@...gle.com
Cc: mst@...hat.com
Cc: paulus@...ba.org
Cc: ralf@...ux-mips.org
Cc: schwidefsky@...ibm.com
Cc: yang.shi@...driver.com
Link: http://lkml.kernel.org/r/1431359540-32227-8-git-send-email-dahi@linux.vnet.ibm.com
Signed-off-by: Ingo Molnar <mingo@...nel.org>
---
drivers/gpu/drm/i915/i915_gem_execbuffer.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/drivers/gpu/drm/i915/i915_gem_execbuffer.c b/drivers/gpu/drm/i915/i915_gem_execbuffer.c
index a3190e79..cc552a4 100644
--- a/drivers/gpu/drm/i915/i915_gem_execbuffer.c
+++ b/drivers/gpu/drm/i915/i915_gem_execbuffer.c
@@ -32,6 +32,7 @@
#include "i915_trace.h"
#include "intel_drv.h"
#include <linux/dma_remapping.h>
+#include <linux/uaccess.h>
#define __EXEC_OBJECT_HAS_PIN (1<<31)
#define __EXEC_OBJECT_HAS_FENCE (1<<30)
@@ -465,7 +466,7 @@ i915_gem_execbuffer_relocate_entry(struct drm_i915_gem_object *obj,
}
/* We can't wait for rendering with pagefaults disabled */
- if (obj->active && in_atomic())
+ if (obj->active && pagefault_disabled())
return -EFAULT;
if (use_cpu_reloc(obj))
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists