Bug 57963 - [Regression IVB]intel_do_flush_locked failed with call trace
Summary: [Regression IVB]intel_do_flush_locked failed with call trace
Status: CLOSED FIXED
Alias: None
Product: DRI
Classification: Unclassified
Component: DRM/Intel (show other bugs)
Version: XOrg git
Hardware: All Linux (All)
: high major
Assignee: Mika Kuoppala
QA Contact: Intel GFX Bugs mailing list
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2012-12-07 01:41 UTC by lu hua
Modified: 2017-10-06 14:47 UTC (History)
2 users (show)

See Also:
i915 platform:
i915 features:


Attachments
dmesg (72.15 KB, text/plain)
2012-12-07 01:41 UTC, lu hua
no flags Details
Customize i915_gpu_idle() for seqno wrapping (1.43 KB, patch)
2012-12-07 08:49 UTC, Chris Wilson
no flags Details | Splinter Review

Description lu hua 2012-12-07 01:41:05 UTC
Created attachment 71108 [details]
dmesg

System Environment:
--------------------------
Arch:             x86_64
Platform:         Ivybridge
Libdrm:	(master)libdrm-2.4.40-3-g0980633afd9c7eecc0c75ef3bea4d3c6b7aa1898
Mesa:	(master)77b26564c3f0395bf3e744abbf6d0e7aa9d2c8da
Xserver:(master)xorg-server-1.13.0-188-gb51a1bd2766e7dc975ca8f1cacc3f8bd0e1a68a3
Xf86_video_intel:(master)2.20.15-8-g0040eb84c9187476a75202ebb251dd74354e4fc7
Cairo:	(master)ba4a4eae051cd932e59e3092ef36d4f6cded0159
Libva:	(staging)38c94cd922473095814ed9a9f99ad98fcc9c285d
Libva_intel_driver:(staging)c0ef9d99df37ae45589fecb898727be495e50304
Kernel:	(drm-intel-nightly) f5cf609370e9560c505faed2dafb06833ec15e11

Bug detailed description:
-------------------------
When run some Oglc cases, appears 'intel_do_flush_locked failed: Device or resource busy'
It happens on Ivybridge with -nightly kernel. It doesn't happen on -fixes kernel.

The last known good commit:6233f397d2e861c1ac06bb4591158b5f9ccadc3e(Merge: 1d1d829 e548a83)
The last known bad commit:f5cf609370e9560c505faed2dafb06833ec15e11(Merge: 92b18fe e548a83)

case: colramp(basic.blueComponent)
output:
Intel OpenGL Conformance Test
Version ENG (Dec  6 2012 16:25:03)

CLI options echo:
oglconform -z -suite all -v 2 -D 113 -test colramp basic.blueComponent

Window will be recreated 1 times.
  Window 0 will run 1 testcases on config with id 113.
Total of 1 testcases will be executed.

Setup Report.
    Verbose level = 2.
    Path inactive.

Visual Report for ID 113 (32 bits).
ID      |ACCELERA|DB      |REND_T  |SURF_T  |C_BUF_T |BUF_S   |RED_S   |
     113|       1|       1|      gl|  wipbpx|    rgba|      32|       8|

GREEN_S |BLUE_S  |ALPHA_S |DEPTH_S |STENC_S |ACCUM_S |SPL_BUF |SAMPLES |
       8|       8|       8|      24|       8|      64|       0|       0|

SRGB    |TEX_RGB |TEX_RGBA|CAVEAT  |SWAP    |M_PBUF_W|M_PBUF_H|M_PBUF_P
       0|       0|       0|    slow|   undef|       0|       0|       0

OpenGL Report.
    Vendor - 'Intel Open Source Technology Center'
    Renderer - 'Mesa DRI Intel(R) Ivybridge Mobile '
    Version - '3.0 Mesa 9.1-devel (git-77b2656)' (3.0)
    GLSL Version - '1.30'
    Context Flags - None

>> Color Ramp (colramp)  test:
intel_do_flush_locked failed: Device or resource busy

dmesg:
[  539.056632] WARNING: at drivers/gpu/drm/i915/i915_gem.c:3458 i915_gem_object_pin+0x38/0x505 [i915]()
[  539.056634] Hardware name: N46VM
[  539.056635] Modules linked in: lockd uvcvideo videobuf2_core videodev videobuf2_vmalloc videobuf2_memops snd_hda_codec_realtek coretemp kvm_intel kvm snd_hda_intel snd_hda_codec iTCO_wdt iTCO_vendor_support snd_hwdep snd_seq snd_seq_device microcode snd_pcm sg pcspkr i2c_i801 serio_raw snd_timer r8169 snd lpc_ich soundcore mii mfd_core snd_page_alloc xhci_hcd uinput battery ac sunrpc ipv6 autofs4 ext3 jbd mbcache sr_mod cdrom sd_mod ehci_hcd i915 nouveau ttm drm_kms_helper drm hwmon i2c_algo_bit mxm_wmi wmi i2c_core video button dm_mirror dm_region_hash dm_log dm_mod
[  539.056669] Pid: 3534, comm: X Tainted: G        W    3.7.0-rc7_unstable_20121206+ #1
[  539.056670] Call Trace:
[  539.056673]  [<ffffffff8102b2ef>] ? warn_slowpath_common+0x78/0x8c
[  539.056683]  [<ffffffffa0191fab>] ? i915_gem_object_pin+0x38/0x505 [i915]
[  539.056686]  [<ffffffff811d6081>] ? swiotlb_map_sg_attrs+0xda/0x100
[  539.056689]  [<ffffffff81284353>] ? ahci_qc_prep+0xc2/0x108
[  539.056698]  [<ffffffffa0194395>] ? do_switch+0x42/0x296 [i915]
[  539.056707]  [<ffffffffa01909c6>] ? i915_gpu_idle+0x2f/0x4f [i915]
[  539.056717]  [<ffffffffa0190a4f>] ? i915_gem_get_seqno+0x69/0xdc [i915]
[  539.056727]  [<ffffffffa01bd42a>] ? intel_ring_begin+0x3c/0x58 [i915]
[  539.056736]  [<ffffffffa019446d>] ? do_switch+0x11a/0x296 [i915]
[  539.056745]  [<ffffffffa01909c6>] ? i915_gpu_idle+0x2f/0x4f [i915]
[  539.056754]  [<ffffffffa0190a4f>] ? i915_gem_get_seqno+0x69/0xdc [i915]
[  539.056774]  [<ffffffffa01bd42a>] ? intel_ring_begin+0x3c/0x58 [i915]
[  539.056790]  [<ffffffffa019446d>] ? do_switch+0x11a/0x296 [i915]
[  539.056806]  [<ffffffffa01909c6>] ? i915_gpu_idle+0x2f/0x4f [i915]
[  539.056821]  [<ffffffffa0190a4f>] ? i915_gem_get_seqno+0x69/0xdc [i915]
[  539.056837]  [<ffffffffa01bd42a>] ? intel_ring_begin+0x3c/0x58 [i915]
[  539.056851]  [<ffffffffa019446d>] ? do_switch+0x11a/0x296 [i915]
[  539.056858]  [<ffffffffa01909c6>] ? i915_gpu_idle+0x2f/0x4f [i915]
[  539.056866]  [<ffffffffa0190a4f>] ? i915_gem_get_seqno+0x69/0xdc [i915]
[  539.056874]  [<ffffffffa01bd42a>] ? intel_ring_begin+0x3c/0x58 [i915]
[  539.056881]  [<ffffffffa019446d>] ? do_switch+0x11a/0x296 [i915]
[  539.056889]  [<ffffffffa01909c6>] ? i915_gpu_idle+0x2f/0x4f [i915]
[  539.056896]  [<ffffffffa0190a4f>] ? i915_gem_get_seqno+0x69/0xdc [i915]
[  539.056904]  [<ffffffffa01bd42a>] ? intel_ring_begin+0x3c/0x58 [i915]
[  539.056911]  [<ffffffffa019446d>] ? do_switch+0x11a/0x296 [i915]
[  539.056918]  [<ffffffffa01909c6>] ? i915_gpu_idle+0x2f/0x4f [i915]
[  539.056926]  [<ffffffffa0190a4f>] ? i915_gem_get_seqno+0x69/0xdc [i915]
[  539.056934]  [<ffffffffa01bd42a>] ? intel_ring_begin+0x3c/0x58 [i915]
[  539.056941]  [<ffffffffa019446d>] ? do_switch+0x11a/0x296 [i915]
[  539.056948]  [<ffffffffa01909c6>] ? i915_gpu_idle+0x2f/0x4f [i915]
[  539.056956]  [<ffffffffa0190a4f>] ? i915_gem_get_seqno+0x69/0xdc [i915]
[  539.056964]  [<ffffffffa01bd42a>] ? intel_ring_begin+0x3c/0x58 [i915]
[  539.056971]  [<ffffffffa019446d>] ? do_switch+0x11a/0x296 [i915]
[  539.056978]  [<ffffffffa01909c6>] ? i915_gpu_idle+0x2f/0x4f [i915]
[  539.056986]  [<ffffffffa0190a4f>] ? i915_gem_get_seqno+0x69/0xdc [i915]
[  539.056994]  [<ffffffffa01bd42a>] ? intel_ring_begin+0x3c/0x58 [i915]
[  539.057001]  [<ffffffffa019446d>] ? do_switch+0x11a/0x296 [i915]
[  539.057008]  [<ffffffffa01909c6>] ? i915_gpu_idle+0x2f/0x4f [i915]
[  539.057016]  [<ffffffffa0190a4f>] ? i915_gem_get_seqno+0x69/0xdc [i915]
[  539.057024]  [<ffffffffa01bd42a>] ? intel_ring_begin+0x3c/0x58 [i915]
[  539.057031]  [<ffffffffa019446d>] ? do_switch+0x11a/0x296 [i915]
[  539.057038]  [<ffffffffa01909c6>] ? i915_gpu_idle+0x2f/0x4f [i915]
[  539.057045]  [<ffffffffa0190a4f>] ? i915_gem_get_seqno+0x69/0xdc [i915]
[  539.057054]  [<ffffffffa01bd42a>] ? intel_ring_begin+0x3c/0x58 [i915]
[  539.057061]  [<ffffffffa019446d>] ? do_switch+0x11a/0x296 [i915]
[  539.057068]  [<ffffffffa01909c6>] ? i915_gpu_idle+0x2f/0x4f [i915]
[  539.057075]  [<ffffffffa0190a4f>] ? i915_gem_get_seqno+0x69/0xdc [i915]
[  539.057083]  [<ffffffffa01bd42a>] ? intel_ring_begin+0x3c/0x58 [i915]
[  539.057091]  [<ffffffffa019446d>] ? do_switch+0x11a/0x296 [i915]
[  539.057098]  [<ffffffffa01909c6>] ? i915_gpu_idle+0x2f/0x4f [i915]
[  539.057114]  [<ffffffffa0190a4f>] ? i915_gem_get_seqno+0x69/0xdc [i915]
[  539.057130]  [<ffffffffa01bd42a>] ? intel_ring_begin+0x3c/0x58 [i915]
[  539.057145]  [<ffffffffa019446d>] ? do_switch+0x11a/0x296 [i915]
[  539.057160]  [<ffffffffa01909c6>] ? i915_gpu_idle+0x2f/0x4f [i915]
[  539.057176]  [<ffffffffa0190a4f>] ? i915_gem_get_seqno+0x69/0xdc [i915]
[  539.057190]  [<ffffffffa01bd42a>] ? intel_ring_begin+0x3c/0x58 [i915]
[  539.057197]  [<ffffffffa019446d>] ? do_switch+0x11a/0x296 [i915]
[  539.057205]  [<ffffffffa01909c6>] ? i915_gpu_idle+0x2f/0x4f [i915]
[  539.057212]  [<ffffffffa0190a4f>] ? i915_gem_get_seqno+0x69/0xdc [i915]
[  539.057220]  [<ffffffffa01bd42a>] ? intel_ring_begin+0x3c/0x58 [i915]
[  539.057227]  [<ffffffffa019446d>] ? do_switch+0x11a/0x296 [i915]
[  539.057235]  [<ffffffffa01909c6>] ? i915_gpu_idle+0x2f/0x4f [i915]
[  539.057242]  [<ffffffffa0190a4f>] ? i915_gem_get_seqno+0x69/0xdc [i915]
[  539.057250]  [<ffffffffa01bd42a>] ? intel_ring_begin+0x3c/0x58 [i915]
[  539.057259]  [<ffffffffa01be121>] ? gen7_render_ring_flush+0xa8/0x11f [i915]
[  539.057267]  [<ffffffffa01be8d2>] ? intel_ring_invalidate_all_caches+0x1d/0x2b [i915]
[  539.057275]  [<ffffffffa0196096>] ? i915_gem_do_execbuffer+0xbbb/0xf1d [i915]
[  539.057278]  [<ffffffff810d69fe>] ? __pollwait+0xce/0xce
[  539.057286]  [<ffffffffa01968e3>] ? i915_gem_execbuffer2+0x164/0x1f9 [i915]
[  539.057293]  [<ffffffffa003f503>] ? drm_ioctl+0x28f/0x34a [drm]
[  539.057300]  [<ffffffffa019677f>] ? i915_gem_execbuffer+0x387/0x387 [i915]
[  539.057303]  [<ffffffff810447a8>] ? __remove_hrtimer+0x2a/0x7f
[  539.057307]  [<ffffffff810d60f8>] ? do_vfs_ioctl+0x43f/0x480
[  539.057310]  [<ffffffff81035f57>] ? recalc_sigpending+0x12/0x3f
[  539.057313]  [<ffffffff8103682a>] ? __set_task_blocked+0x5d/0x64
[  539.057316]  [<ffffffff810d618d>] ? sys_ioctl+0x54/0x7b
[  539.057319]  [<ffffffff810384c8>] ? sys_rt_sigprocmask+0x9c/0xb3
[  539.057323]  [<ffffffff813944d2>] ? system_call_fastpath+0x16/0x1b
[  539.057324] ---[ end trace 18aa5e6e293d864b ]---

Reproduce steps:
----------------------------
1. xinit
2. ./oglconform -z -suite all -v 2 -D 113 -test colramp basic.blueComponent
Comment 1 Daniel Vetter 2012-12-07 07:57:31 UTC
I've taken out some of Mika's seqno wrap patches since they've caused issues. Can you please retest on latest trees? If they're still broken, please bisect, thanks.
Comment 2 Chris Wilson 2012-12-07 08:49:22 UTC
Created attachment 71118 [details] [review]
Customize i915_gpu_idle() for seqno wrapping
Comment 3 Jesse Barnes 2012-12-11 19:35:56 UTC
More wrapping stuff landed, can you test and confirm?
Comment 4 Chris Wilson 2012-12-11 21:44:51 UTC
commit 107f27a5df8ad33a351d6e82fe95ff92b428f72e
Author: Chris Wilson <chris@chris-wilson.co.uk>
Date:   Mon Dec 10 13:56:17 2012 +0200

    drm/i915: Open-code i915_gpu_idle() for handling seqno wrapping
    
    The complication is that during seqno wrapping we must be extremely
    careful not to write to any ring as that will require a new seqno, and
    so would recurse back into the seqno wrap handler. So we cannot call
    i915_gpu_idle() as that does additional work beyond simply retiring the
    current set of requests, and instead must do the minimal work ourselves
    during seqno wrapping.
    
    Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
    Reviewed-by: Mika Kuoppala <mika.kuoppala@intel.com>
    Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Comment 5 lu hua 2012-12-12 01:31:52 UTC
Verified. Fixed on the latest -queued kernel.
Comment 6 Elizabeth 2017-10-06 14:47:31 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.