* [PATCH] drm/i915: Catch attempting to use the aliasing_gtt's drm_mm
@ 2017-01-15 13:47 Chris Wilson
2017-01-15 14:24 ` ✓ Fi.CI.BAT: success for " Patchwork
2017-01-16 12:10 ` [PATCH] " Joonas Lahtinen
0 siblings, 2 replies; 4+ messages in thread
From: Chris Wilson @ 2017-01-15 13:47 UTC (permalink / raw)
To: intel-gfx; +Cc: Daniel Vetter
The aliasing_gtt is just that, an alias of the global GTT. We do not
populate it directly, instead we always use the global GTT. Catch any
attempt to incorrectly allocate ranges from the aliasing_gtt.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Cc: Joonas Lahtinen <joonas.lahtinen@linux.intel.com>
Cc: Daniel Vetter <daniel.vetter@intel.com>
---
drivers/gpu/drm/i915/i915_gem_gtt.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/drivers/gpu/drm/i915/i915_gem_gtt.c b/drivers/gpu/drm/i915/i915_gem_gtt.c
index 26a4460e16c3..9bc1788fac5b 100644
--- a/drivers/gpu/drm/i915/i915_gem_gtt.c
+++ b/drivers/gpu/drm/i915/i915_gem_gtt.c
@@ -3134,6 +3134,7 @@ int i915_gem_gtt_reserve(struct i915_address_space *vm,
GEM_BUG_ON(!IS_ALIGNED(size, I915_GTT_PAGE_SIZE));
GEM_BUG_ON(!IS_ALIGNED(offset, I915_GTT_MIN_ALIGNMENT));
GEM_BUG_ON(range_overflows(offset, size, vm->total));
+ GEM_BUG_ON(vm == &vm->i915->mm.aliasing_ppgtt->base);
node->size = size;
node->start = offset;
@@ -3229,6 +3230,7 @@ int i915_gem_gtt_insert(struct i915_address_space *vm,
GEM_BUG_ON(start >= end);
GEM_BUG_ON(start > 0 && !IS_ALIGNED(start, I915_GTT_PAGE_SIZE));
GEM_BUG_ON(end < U64_MAX && !IS_ALIGNED(end, I915_GTT_PAGE_SIZE));
+ GEM_BUG_ON(vm == &vm->i915->mm.aliasing_ppgtt->base);
if (unlikely(range_overflows(start, size, end)))
return -ENOSPC;
--
2.11.0
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
^ permalink raw reply related [flat|nested] 4+ messages in thread
* ✓ Fi.CI.BAT: success for drm/i915: Catch attempting to use the aliasing_gtt's drm_mm
2017-01-15 13:47 [PATCH] drm/i915: Catch attempting to use the aliasing_gtt's drm_mm Chris Wilson
@ 2017-01-15 14:24 ` Patchwork
2017-01-16 12:10 ` [PATCH] " Joonas Lahtinen
1 sibling, 0 replies; 4+ messages in thread
From: Patchwork @ 2017-01-15 14:24 UTC (permalink / raw)
To: Chris Wilson; +Cc: intel-gfx
== Series Details ==
Series: drm/i915: Catch attempting to use the aliasing_gtt's drm_mm
URL : https://patchwork.freedesktop.org/series/18022/
State : success
== Summary ==
Series 18022v1 drm/i915: Catch attempting to use the aliasing_gtt's drm_mm
https://patchwork.freedesktop.org/api/1.0/series/18022/revisions/1/mbox/
Test kms_pipe_crc_basic:
Subgroup bad-nb-words-1:
dmesg-warn -> PASS (fi-ivb-3770)
fi-bdw-5557u total:246 pass:232 dwarn:0 dfail:0 fail:0 skip:14
fi-bsw-n3050 total:246 pass:207 dwarn:0 dfail:0 fail:0 skip:39
fi-bxt-j4205 total:246 pass:224 dwarn:0 dfail:0 fail:0 skip:22
fi-bxt-t5700 total:82 pass:69 dwarn:0 dfail:0 fail:0 skip:12
fi-byt-j1900 total:246 pass:219 dwarn:0 dfail:0 fail:0 skip:27
fi-byt-n2820 total:246 pass:215 dwarn:0 dfail:0 fail:0 skip:31
fi-hsw-4770 total:246 pass:227 dwarn:0 dfail:0 fail:0 skip:19
fi-hsw-4770r total:246 pass:227 dwarn:0 dfail:0 fail:0 skip:19
fi-ivb-3520m total:246 pass:225 dwarn:0 dfail:0 fail:0 skip:21
fi-ivb-3770 total:246 pass:225 dwarn:0 dfail:0 fail:0 skip:21
fi-kbl-7500u total:246 pass:225 dwarn:0 dfail:0 fail:0 skip:21
fi-skl-6260u total:246 pass:233 dwarn:0 dfail:0 fail:0 skip:13
fi-skl-6700hq total:246 pass:226 dwarn:0 dfail:0 fail:0 skip:20
fi-skl-6700k total:246 pass:222 dwarn:3 dfail:0 fail:0 skip:21
fi-skl-6770hq total:246 pass:233 dwarn:0 dfail:0 fail:0 skip:13
fi-snb-2520m total:246 pass:215 dwarn:0 dfail:0 fail:0 skip:31
fi-snb-2600 total:246 pass:214 dwarn:0 dfail:0 fail:0 skip:32
af723422378a6d17bd5b632880b195f8443445b5 drm-tip: 2017y-01m-14d-16h-21m-06s UTC integration manifest
73925e3 drm/i915: Catch attempting to use the aliasing_gtt's drm_mm
== Logs ==
For more details see: https://intel-gfx-ci.01.org/CI/Patchwork_3522/
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] drm/i915: Catch attempting to use the aliasing_gtt's drm_mm
2017-01-15 13:47 [PATCH] drm/i915: Catch attempting to use the aliasing_gtt's drm_mm Chris Wilson
2017-01-15 14:24 ` ✓ Fi.CI.BAT: success for " Patchwork
@ 2017-01-16 12:10 ` Joonas Lahtinen
2017-01-16 12:30 ` Chris Wilson
1 sibling, 1 reply; 4+ messages in thread
From: Joonas Lahtinen @ 2017-01-16 12:10 UTC (permalink / raw)
To: Chris Wilson, intel-gfx; +Cc: Daniel Vetter
On su, 2017-01-15 at 13:47 +0000, Chris Wilson wrote:
> The aliasing_gtt is just that, an alias of the global GTT. We do not
> populate it directly, instead we always use the global GTT. Catch any
> attempt to incorrectly allocate ranges from the aliasing_gtt.
>
> Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
> Cc: Joonas Lahtinen <joonas.lahtinen@linux.intel.com>
> Cc: Daniel Vetter <daniel.vetter@intel.com>
Duh, I'm sure I sent this once, but obviously did not.
Reviewed-by: Joonas Lahtinen <joonas.lahtinen@linux.intel.com>
Regards, Joonas
--
Joonas Lahtinen
Open Source Technology Center
Intel Corporation
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] drm/i915: Catch attempting to use the aliasing_gtt's drm_mm
2017-01-16 12:10 ` [PATCH] " Joonas Lahtinen
@ 2017-01-16 12:30 ` Chris Wilson
0 siblings, 0 replies; 4+ messages in thread
From: Chris Wilson @ 2017-01-16 12:30 UTC (permalink / raw)
To: Joonas Lahtinen; +Cc: Daniel Vetter, intel-gfx
On Mon, Jan 16, 2017 at 02:10:33PM +0200, Joonas Lahtinen wrote:
> On su, 2017-01-15 at 13:47 +0000, Chris Wilson wrote:
> > The aliasing_gtt is just that, an alias of the global GTT. We do not
> > populate it directly, instead we always use the global GTT. Catch any
> > attempt to incorrectly allocate ranges from the aliasing_gtt.
> >
> > Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
> > Cc: Joonas Lahtinen <joonas.lahtinen@linux.intel.com>
> > Cc: Daniel Vetter <daniel.vetter@intel.com>
>
> Duh, I'm sure I sent this once, but obviously did not.
>
> Reviewed-by: Joonas Lahtinen <joonas.lahtinen@linux.intel.com>
Pushed all of the trivial ones. I've left the lib/prime_numbers.c to go
in via the drm-misc tree.
-Chris
--
Chris Wilson, Intel Open Source Technology Centre
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2017-01-16 12:30 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-01-15 13:47 [PATCH] drm/i915: Catch attempting to use the aliasing_gtt's drm_mm Chris Wilson
2017-01-15 14:24 ` ✓ Fi.CI.BAT: success for " Patchwork
2017-01-16 12:10 ` [PATCH] " Joonas Lahtinen
2017-01-16 12:30 ` Chris Wilson
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.