diff options
author | Jonathan Gray <jsg@cvs.openbsd.org> | 2013-11-07 05:33:06 +0000 |
---|---|---|
committer | Jonathan Gray <jsg@cvs.openbsd.org> | 2013-11-07 05:33:06 +0000 |
commit | c2f6f798739f1aa62635f491a73fbe12f97d3999 (patch) | |
tree | f1e13571e059dd04289ba9cf50f0ba279be20512 /sys/dev/pci/drm/i915/i915_gem_context.c | |
parent | 112294b749006fd4d54f04de98d4d04e7747f839 (diff) |
add a simplistic version of WARN_ON_ONCE() that doesn't warn
reduces the diff to linux and avoids a clang warning brad mentioned
ok kettenis@ brad@
Diffstat (limited to 'sys/dev/pci/drm/i915/i915_gem_context.c')
-rw-r--r-- | sys/dev/pci/drm/i915/i915_gem_context.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/sys/dev/pci/drm/i915/i915_gem_context.c b/sys/dev/pci/drm/i915/i915_gem_context.c index 2323b4512b4..0290d072dca 100644 --- a/sys/dev/pci/drm/i915/i915_gem_context.c +++ b/sys/dev/pci/drm/i915/i915_gem_context.c @@ -1,4 +1,4 @@ -/* $OpenBSD: i915_gem_context.c,v 1.2 2013/10/05 07:30:06 jsg Exp $ */ +/* $OpenBSD: i915_gem_context.c,v 1.3 2013/11/07 05:33:05 jsg Exp $ */ /* * Copyright © 2011-2012 Intel Corporation * @@ -422,7 +422,7 @@ static int do_switch(struct i915_hw_context *to) if (!to->is_initialized || is_default_context(to)) hw_flags |= MI_RESTORE_INHIBIT; - else if (/*WARN_ON_ONCE*/(from_obj == to->obj)) /* not yet expected */ + else if (WARN_ON_ONCE(from_obj == to->obj)) /* not yet expected */ hw_flags |= MI_FORCE_RESTORE; ret = mi_set_context(ring, to, hw_flags); |