On Tue, Aug 09, 2016 at 01:39:02PM +0300, Joonas Lahtinen wrote: > On su, 2016-08-07 at 15:45 +0100, Chris Wilson wrote: > > Only those objects pinned to the display have semi-permanent pins of a > > global nature (other pins are transient within their local vm). Simplify > > i915_gem_pinned to only show the pertinent information about the pinned > > objects within the GGTT. > > > > Signed-off-by: Chris Wilson <chris@xxxxxxxxxxxxxxxxxx> > > --- > > drivers/gpu/drm/i915/i915_debugfs.c | 11 ++--------- > > 1 file changed, 2 insertions(+), 9 deletions(-) > > > > diff --git a/drivers/gpu/drm/i915/i915_debugfs.c b/drivers/gpu/drm/i915/i915_debugfs.c > > index 8de458dcffaa..9911594acbc9 100644 > > --- a/drivers/gpu/drm/i915/i915_debugfs.c > > +++ b/drivers/gpu/drm/i915/i915_debugfs.c > > @@ -40,12 +40,6 @@ > > #include > > #include "i915_drv.h" > > > > -enum { > > - ACTIVE_LIST, > > - INACTIVE_LIST, > > - PINNED_LIST, > > -}; > > - > > /* As the drm_debugfs_init() routines are called before dev->dev_private is > > * allocated we need to hook into the minor for release. */ > > static int > > @@ -537,7 +531,6 @@ static int i915_gem_gtt_info(struct seq_file *m, void *data) > > { > > struct drm_info_node *node = m->private; > > struct drm_device *dev = node->minor->dev; > > - uintptr_t list = (uintptr_t) node->info_ent->data; > > struct drm_i915_private *dev_priv = to_i915(dev); > > struct drm_i915_gem_object *obj; > > u64 total_obj_size, total_gtt_size; > > @@ -549,7 +542,7 @@ static int i915_gem_gtt_info(struct seq_file *m, void *data) > > > > total_obj_size = total_gtt_size = count = 0; > > list_for_each_entry(obj, &dev_priv->mm.bound_list, global_list) { > > - if (list == PINNED_LIST && !i915_gem_obj_is_pinned(obj)) > > + if (!obj->pin_display) > > continue; > > > > seq_puts(m, " "); > > @@ -5327,7 +5320,7 @@ static const struct drm_info_list i915_debugfs_list[] = { > > {"i915_capabilities", i915_capabilities, 0}, > > {"i915_gem_objects", i915_gem_object_info, 0}, > > {"i915_gem_gtt", i915_gem_gtt_info, 0}, > > - {"i915_gem_pinned", i915_gem_gtt_info, 0, (void *) PINNED_LIST}, > > + {"i915_gem_pinned", i915_gem_gtt_info, 0, 0}, > > "i915_gem_pin_display" then? Otherwise it's a fragile change. Sure. Sold with that change? -Chris -- Chris Wilson, Intel Open Source Technology Centre _______________________________________________ Intel-gfx mailing list Intel-gfx@xxxxxxxxxxxxxxxxxxxxx https://lists.freedesktop.org/mailman/listinfo/intel-gfx