Bug 50522

Summary: [IVB]I-G-T/ZZ_hangman fails(*ERROR* render ring initialization failed)
Product: DRI Reporter: Guang Yang <guang.a.yang>
Component: DRM/IntelAssignee: Daniel Vetter <daniel>
Status: CLOSED FIXED QA Contact:
Severity: normal    
Priority: medium CC: ben, chris, daniel, jbarnes
Version: unspecified   
Hardware: Other   
OS: All   
Whiteboard:
i915 platform: i915 features:
Attachments:
Description Flags
running ZZ_hangman dmesg info
none
debug patch
none
runwithpatch's dmesg info
none
hold forcewake while reiniting the ring
none
running ZZ_hangman with two patches dmesg info
none
hold forcewake while reiniting the ring, final patch
none
dmesg info after running ZZ_hangman
none
move RING_START init down
none
dmesg info with patch:move RING_START init down none

Description Guang Yang 2012-05-30 21:33:42 UTC
Created attachment 62311 [details]
running ZZ_hangman dmesg info

System Environment:
--------------------------
Platform:        Ivybridge
Kernel: (drm-intel-next-queued)eeafaaca763408c099d2ade3a69e0716f296a97b
Bug detailed description:
-------------------------
   On IVY platform ,running ZZ_hangman of the Intel-gpu-tools will
fail.
   In the dmesg can catch :
 *ERROR* render ring initialization failed ctl 0001f001 head 00000000 tail 00000000 start 00000000
Comment 1 Daniel Vetter 2012-05-31 00:00:55 UTC
Hm, that one's pretty bad - I've seen cases where this happens on my ivb, too. But then it always succeeded on the 2nd try at resetting the chip. How reliably can you reproduce this on your machine?
Comment 2 Yi Sun 2012-05-31 00:55:01 UTC
(In reply to comment #1)
> Hm, that one's pretty bad - I've seen cases where this happens on my ivb, too.
> But then it always succeeded on the 2nd try at resetting the chip. How reliably
> can you reproduce this on your machine?

We reproduce this issue each time running ZZ_hangman. The X still start up after trigger this issue.
The lspci output is:

00:02.0 VGA compatible controller: Intel Corporation Device 0162 (rev 04)
Comment 3 Daniel Vetter 2012-05-31 02:38:36 UTC
Created attachment 62321 [details] [review]
debug patch

Can you please apply this quick debug patch and then reattach dmesg?
Comment 4 Guang Yang 2012-05-31 20:13:02 UTC
Created attachment 62354 [details]
runwithpatch's dmesg info

(In reply to comment #3)
> Created attachment 62321 [details] [review] [review]
> debug patch
> 
> Can you please apply this quick debug patch and then reattach dmesg?
Here is the dmesg with that patch.
Comment 5 Daniel Vetter 2012-06-01 00:19:33 UTC
Created attachment 62359 [details] [review]
hold forcewake while reiniting the ring

On a hunch, this might help ... please test this patch on top of the other one.
Comment 6 Guang Yang 2012-06-03 20:25:28 UTC
Created attachment 62484 [details]
running ZZ_hangman with two patches dmesg info

(In reply to comment #5)
> Created attachment 62359 [details] [review] [review]
> hold forcewake while reiniting the ring
> 
> On a hunch, this might help ... please test this patch on top of the other one.
I try these two patches and attach the dmesg.
Comment 7 Daniel Vetter 2012-06-04 00:56:33 UTC
> --- Comment #6 from yangguang <guang.a.yang@intel.com> 2012-06-03 20:25:28 PDT ---
> Created attachment 62484 [details]
>   --> https://bugs.freedesktop.org/attachment.cgi?id=62484
> running ZZ_hangman with two patches dmesg info
> 
> (In reply to comment #5)
> > Created attachment 62359 [details] [review] [review]
> > hold forcewake while reiniting the ring
> > 
> > On a hunch, this might help ... please test this patch on top of the other one.
> I try these two patches and attach the dmesg.

Ok, I don't see the *Error* message in dmesg any more. Can you confirm
that the system now works correcty after running tests/ZZ_hangman and
doesn't reset right away if you run a gpu workload (like it did without
this patch)?

Meanwhile I'll make a rea patch out of this quick hack.
Comment 8 Daniel Vetter 2012-06-04 01:37:25 UTC
Created attachment 62491 [details] [review]
hold forcewake while reiniting the ring, final patch

Please test again with this final patch (and the debug patches removed) to confirm that the patch still works.
Comment 9 Guang Yang 2012-06-04 01:47:27 UTC
(In reply to comment #7)
> > --- Comment #6 from yangguang <guang.a.yang@intel.com> 2012-06-03 20:25:28 PDT ---
> > Created attachment 62484 [details]
> >   --> https://bugs.freedesktop.org/attachment.cgi?id=62484
> > running ZZ_hangman with two patches dmesg info
> > 
> > (In reply to comment #5)
> > > Created attachment 62359 [details] [review] [review] [review]
> > > hold forcewake while reiniting the ring
> > > 
> > > On a hunch, this might help ... please test this patch on top of the other one.
> > I try these two patches and attach the dmesg.
> 
> Ok, I don't see the *Error* message in dmesg any more. Can you confirm
> that the system now works correcty after running tests/ZZ_hangman and
> doesn't reset right away if you run a gpu workload (like it did without
> this patch)?
> 
> Meanwhile I'll make a rea patch out of this quick hack.
yes, the  *Error* disappears,and the system work well after running ZZ_hangman as I start X and run the glxgears.
Comment 10 Guang Yang 2012-06-04 02:31:43 UTC
(In reply to comment #8)
> Created attachment 62491 [details] [review] [review]
> hold forcewake while reiniting the ring, final patch
> 
> Please test again with this final patch (and the debug patches removed) to
> confirm that the patch still works.
I try the final patch,it can work well.
Comment 11 Chris Wilson 2012-06-06 04:06:14 UTC
commit b7884eb45ec98c0d34c7f49005ae9d4b4b4e38f6
Author: Daniel Vetter <daniel.vetter@ffwll.ch>
Date:   Mon Jun 4 11:18:15 2012 +0200

    drm/i915: hold forcewake around ring hw init
Comment 12 Guang Yang 2012-07-19 01:57:03 UTC
Created attachment 64372 [details]
dmesg info after running ZZ_hangman

  On IVB platform , the issue occurs again,
 I can catch the  :*ERROR* render ring initialization failed ctl 0001f001 head 00000000 tail 00000000 start 00000000  from the dmesg,  and I try with the Kernel: 
(drm-intel-next-queued)1ecdd7feb6cd736c21bdd5459ec6045dcfcc7712.
 The system work well after running ZZ_hangman as I start X and run the glxgears
 The lspci shows:
00:02.0 VGA compatible controller: Intel Corporation Ivy Bridge Graphics Controller (rev 09)
  I attach the dmesg info.
Comment 13 Daniel Vetter 2012-08-06 09:29:48 UTC
Created attachment 65160 [details] [review]
move RING_START init down

Please test this patch, thanks.
Comment 14 Guang Yang 2012-08-07 03:18:23 UTC
Created attachment 65216 [details]
dmesg info with patch:move RING_START init down

(In reply to comment #13)
> Created attachment 65160 [details] [review] [review]
> move RING_START init down
> 
> Please test this patch, thanks.
with this patch , the error is gone, and I attach the dmesg.
Comment 15 Daniel Vetter 2012-08-08 08:26:59 UTC
Patch merged to -fixes:

commit 0d8957c8a90bbb5d34fab9a304459448a5131e06
Author: Daniel Vetter <daniel.vetter@ffwll.ch>
Date:   Tue Aug 7 09:54:14 2012 +0200

    drm/i915: correctly order the ring init sequence
Comment 16 Guang Yang 2012-08-09 02:50:12 UTC
(In reply to comment #15)
> Patch merged to -fixes:
> 
> commit 0d8957c8a90bbb5d34fab9a304459448a5131e06
> Author: Daniel Vetter <daniel.vetter@ffwll.ch>
> Date:   Tue Aug 7 09:54:14 2012 +0200
> 
>     drm/i915: correctly order the ring init sequence
confirmed, verified this bug.
Comment 17 Elizabeth 2017-10-06 14:50:00 UTC
Closing old verified.

Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.