drm-intel-collector - update
Subsystems (2)
cover drm-intel-collector - update
This is another drm-intel-collector updated notice:
http://cgit.freedesktop.org/~vivijim/drm-intel/log/?h=drm-intel-collector
Here goes the update list in order for better reviewers assignment:
Patch drm/i915: Only use read-back pipe config - Reviewer:
Patch drm/i915: Dump the contents of the GTT - Reviewer:
Overall Process:
drm-intel-collector - review request
1. Daniel pushs drm-intel-testing (every 2 weeks)
2. I rebase drm-intel-collector onto drm-intel-testing
3. Add Reviewer: tag with voluntered reviewers. If you don't believe you should be assigned on a particular patch please don't get mad just tell you wont review or volunteer someone else.
4. I resubmit remaining patches for review without picking any new (drm-intel-collector - review request)
drm-intel-collector - updated
5. One week later I collect all simple (1-2) patches that wasn't yet reviewed and not queued by Daniel from one testing update until another.
6. Request automated QA's PRTS automated i-g-t tests comparing drm-intel-testing x drm-intel-collector
7. If tests are ok I send the update notification or the patches as a series to intel-gfx mailing list for better tracking and to be reviewed. (drm-intel-collector - updated)
8. Let me know volunteers for review new patches and also let me know if I've picked any patch that I shouldn't.
There are some reasons that some patches can be left behind:
1. Your patch didn't applied cleanly and I couldn't easily solve the conflicts.
2. Kernel didn't compiled with your patch.
3. I simply missed it. If you believe this is the case please warn me.
Please help me to get these patches reviewed and queued by Daniel.
Also, please let me know if you have further ideas how to improve this process.
Thanks in advance,
Rodrigo.
Chris Wilson (1):
drm/i915: Dump the contents of the GTT
Daniel Vetter (1):
drm/i915: Only use read-back pipe config
drivers/gpu/drm/i915/i915_debugfs.c | 72 +++++++++++++++++++++++++++++++++++- drivers/gpu/drm/i915/intel_display.c | 3 ++ 2 files changed, 74 insertions(+), 1 deletion(-)
Signature · 1 line
1.8.3.1
PATCH 1/2 drm/i915: Only use read-back pipe config
From: Daniel Vetter <[email protected]>
This way we'll catch bugs in our code where we depend upon pipe config state not (yet) read out much quicker, through a simple dpms on/off cycle.
This will blow up all over the place for now, hence just a quick idea to toss out there.
--- drivers/gpu/drm/i915/intel_display.c | 3 +++ 1 file changed, 3 insertions(+)
drivers/gpu/drm/i915/intel_display.c +3 -0
@@ -9517,6 +9517,9 @@ check_crtc_state(struct drm_device *dev)intel_dump_pipe_config (crtc, &crtc->config,"[sw state]" ); } + +/* Make sure our code only depends upon stuff we read back. */ +memcpy (&pipe_config, &crtc->config,sizeof (pipe_config)); } }
Signature · 1 line
1.8.3.1
PATCH 2/2 drm/i915: Dump the contents of the GTT
In reply to Rodrigo ViviFrom: Chris Wilson <[email protected]>
Chasing wild speculation that we may be writing the wrong addresses into the GTT for stolen objects, I would like to inspect those values. Also to aide debugging ENOSPC issues with fragmentation, order the object list by ascending GTT order so that holes are more easily seen.
--- drivers/gpu/drm/i915/i915_debugfs.c | 72 ++++++++++++++++++++++++++++++++++++- 1 file changed, 71 insertions(+), 1 deletion(-)
drivers/gpu/drm/i915/i915_debugfs.c +71 -1
@@ -435,6 +435,61 @@ static int i915_gem_object_info(struct seq_file *m, void* data)return 0 ; } +static int i915_gem_gtt_contents (struct seq_file *m,struct drm_device *dev) +{ +struct drm_i915_private *dev_priv = dev->dev_private; +gen6_gtt_pte_t __iomem *gtt_entries; +gen6_gtt_pte_t scratch_pte; +gen6_gtt_pte_t zero[8 ] = {}; +int i, j, last_zero =0 ; +int ret; + +if (INTEL_INFO (dev)->gen <6 ) +return 0 ; + + ret =mutex_lock_interruptible (&dev->struct_mutex); +if (ret) +return ret; + + gtt_entries = (gen6_gtt_pte_t __iomem *)dev_priv->gtt.gsm; + scratch_pte = dev_priv->gtt.base.pte_encode (dev_priv->gtt.base.scratch.addr,I915_CACHE_LLC , true); +for (i =0 ; i <gtt_total_entries (dev_priv->gtt); i +=8 ) { +gen6_gtt_pte_t pte[8 ]; +int this_zero; + +for (j =0 ; j <8 ; j++) { + pte[j] =ioread32 (>t_entries[i+j]); +if (pte[j] == scratch_pte) + pte[j] =0 ; +if ((pte[j] &1 ) ==0 ) + pte[j] =0 ; + } + + this_zero =memcmp (pte, zero,sizeof (pte)) ==0 ; +if (last_zero && this_zero) { +if (last_zero++ ==1 ) +seq_puts (m,"...\n" ); +continue ; + } + +seq_printf (m,"[%08x] %08x %08x %08x %08x %08x %08x %08x %08x\n" , + i, pte[0 ], pte[1 ], pte[2 ], pte[3 ], pte[4 ], pte[5 ], pte[6 ], pte[7 ]); + last_zero = this_zero; + } + +mutex_unlock (&dev->struct_mutex); + +return 0 ; +} + +static int obj_rank_by_ggtt (void *priv,struct list_head *A ,struct list_head *B ) +{ +struct drm_i915_gem_object *a =list_entry (A ,typeof (*a), obj_exec_link); +struct drm_i915_gem_object *b =list_entry (B ,typeof (*b), obj_exec_link); + +return i915_gem_obj_ggtt_offset (a) -i915_gem_obj_ggtt_offset (b); +} +static int i915_gem_gtt_info (struct seq_file *m,void *data) {struct drm_info_node *node = (struct drm_info_node *) m->private;
@@ -442,6 +497,7 @@ static int i915_gem_gtt_info(struct seq_file *m, void *data)uintptr_t list = (uintptr_t ) node->info_ent->data;struct drm_i915_private *dev_priv = dev->dev_private;struct drm_i915_gem_object *obj; +struct list_head sorted;size_t total_obj_size, total_gtt_size;int count, ret;
@@ -449,11 +505,22 @@ static int i915_gem_gtt_info(struct seq_file *m, void *data)if (ret)return ret; +INIT_LIST_HEAD (&sorted); + 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))continue ; +list_add (&obj->obj_exec_link, &sorted); + } + +list_sort (NULL , &sorted, obj_rank_by_ggtt); + +while (!list_empty (&sorted)) { + obj =list_first_entry (&sorted,typeof (*obj), obj_exec_link); +list_del_init (&obj->obj_exec_link); +seq_puts (m," " );describe_obj (m, obj);seq_putc (m,'\n' );
@@ -467,7 +534,10 @@ static int i915_gem_gtt_info(struct seq_file *m, void *data)seq_printf (m,"Total %d objects, %zu bytes, %zu GTT size\n" , count, total_obj_size, total_gtt_size); -return 0 ; +if (list ==PINNED_LIST ) +return 0 ; + +return i915_gem_gtt_contents (m, dev); }static int i915_gem_pageflip_info (struct seq_file *m,void *data)
Signature · 1 line
1.8.3.1