Bug 81704

Summary: [BYT Bisected]igt/kms_pipe_crc_basic causes system hang
Product: DRI Reporter: Guo Jinxian <jinxianx.guo>
Component: DRM/IntelAssignee: Ville Syrjala <ville.syrjala>
Status: CLOSED WORKSFORME QA Contact: Intel GFX Bugs mailing list <intel-gfx-bugs>
Severity: critical    
Priority: highest CC: intel-gfx-bugs
Version: unspecified   
Hardware: Other   
OS: All   
Whiteboard:
i915 platform: i915 features:
Attachments:
Description Flags
dmesg none

Description Guo Jinxian 2014-07-24 07:05:45 UTC
==System Environment==
--------------------------
Regression: Yes

Good commit on drm-next: 8d4ad9d4bb0a618c975a32d77087694ec6336f68

Non-working platforms: BYT

==kernel==
--------------------------
origin/drm-intel-nightly: af1aaba219fdd90ca1b30f9b8d8d19352224f170(fails)
    drm-intel-nightly: 2014y-07m-23d-20h-15m-10s integration manifest
origin/drm-intel-next-queued: 2b8ee5710915a244b807fbe3427299d007d19e89(works)
    drm/i915: Allow overlapping userptr objects  
origin/drm-intel-fixes: eedd10f45bdcb2a5b2afa35f845e080c3bc984f2(works)
    drm/i915: Simplify i915_gem_release_all_mmaps()
origin/drm-fixes: ec8a362f2e6e380e7a1f66a6c9a7f6c237ab3520(works)
    Merge branch 'drm-fixes-3.16' of git://people.freedesktop.org/~agd5f/linux into drm-fixes
origin/drm-mext:78660d5fb03f5d0e6a880dcd704702fd364d93f3(fails)
    Merge branch 'component-for-drm' of git://ftp.arm.linux.org.uk/~rmk/linux-arm into drm-next

==Bug detailed description==
-----------------------------
igt/kms_pipe_crc_basic causes system hang

Output:
root@x-bytm02:/GFX/Test/Intel_gpu_tools/intel-gpu-tools/tests# time ./kms_pipe_crc_basic
IGT-Version: 1.7-g70e6ed9 (x86_64) (Linux: 3.16.0-rc6_drm-intel-nightly_af1aab_20140724_debug+ x86_64)
Subtest bad-pipe: SUCCESS
Subtest bad-source: SUCCESS
Subtest bad-nb-words-1: SUCCESS
Subtest bad-nb-words-3: SUCCESS
read-crc-pipe-A: Testing connector eDP-1 using pipe A



Reproduce steps:
-------------------------
1. ./kms_pipe_crc_basic
Comment 1 lu hua 2014-07-24 07:43:44 UTC
Created attachment 103387 [details]
dmesg
Comment 2 Guo Jinxian 2014-08-04 06:58:28 UTC
f8bf63fdcb1f82459dae7a3f22ee5ce92f3ea727 is the first bad commit 
commit f8bf63fdcb1f82459dae7a3f22ee5ce92f3ea727 
Author: Ville Syrjälä <ville.syrjala@linux.intel.com> 
AuthorDate: Fri Jun 13 13:37:54 2014 +0300 
Commit: Daniel Vetter <daniel.vetter@ffwll.ch> 
CommitDate: Mon Jul 7 11:27:52 2014 +0200 

drm/i915: Kill duplicated cdclk readout code from i2c 

We have a slightly different way of readoing out the cdclk in 
gmbus_set_freq(). Kill that and just call .get_display_clock_speed(). 

Also need to remove the GMBUSFREQ update from intel_i2c_reset() since 
that gets called way too early. Let's do it in intel_modeset_init_hw() 
instead, and also pull the initial vlv_cdclk_freq update there from 
init_clock gating. 

Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> 
Reviewed-by: Jesse Barnes <jbarnes@virtuousgeek.org> 
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> 

:040000 040000 8929124f54d2ca2c16d6f179e288e22ba360b895 3e32e9591f25ba2264d38d3de38ed5230e9b1e30 M drivers 

The parents commit 7d007f40596670c8fddfae583952b091b02cf0eb doesn't causes system hang.

But revert the bad commit base on latest commit (f68d697eaf3278200a7fc3c8b1d95d72837b84d8), the test still causes system hang
Comment 3 Jani Nikula 2014-09-02 12:14:46 UTC
Please retest on current nightly.
Comment 4 Guo Jinxian 2014-09-03 05:30:39 UTC
This failure unable to reproduce on latest -nightly(2b1159961e4bc38a9090f8ec0ab6f16701dbdf81)

root@x-bytm02:/GFX/Test/Intel_gpu_tools/intel-gpu-tools/tests# ./kms_pipe_crc_basic
IGT-Version: 1.7-gf473a55 (x86_64) (Linux: 3.17.0-rc2_drm-intel-nightly_2b1159_20140903+ x86_64)
Subtest bad-pipe: SUCCESS
Subtest bad-source: SUCCESS
Subtest bad-nb-words-1: SUCCESS
Subtest bad-nb-words-3: SUCCESS
read-crc-pipe-A: Testing connector eDP-1 using pipe A
read-crc-pipe-A: Testing connector VGA-1 using pipe A
Subtest read-crc-pipe-A: SUCCESS
read-crc-pipe-A-frame-sequence: Testing connector eDP-1 using pipe A
read-crc-pipe-A-frame-sequence: Testing connector VGA-1 using pipe A
Subtest read-crc-pipe-A-frame-sequence: SUCCESS
rtcwake: assuming RTC uses UTC ...
rtcwake: wakeup from "mem" using /dev/rtc0 at Wed Sep  3 21:24:13 2014
suspend-read-crc-pipe-A: Testing connector eDP-1 using pipe A
suspend-read-crc-pipe-A: Testing connector VGA-1 using pipe A
Subtest suspend-read-crc-pipe-A: SUCCESS
hang-read-crc-pipe-A: Testing connector eDP-1 using pipe A
hang-read-crc-pipe-A: Testing connector VGA-1 using pipe A
Subtest hang-read-crc-pipe-A: SUCCESS
read-crc-pipe-B: Testing connector eDP-1 using pipe B
read-crc-pipe-B: Testing connector VGA-1 using pipe B
Subtest read-crc-pipe-B: SUCCESS
read-crc-pipe-B-frame-sequence: Testing connector eDP-1 using pipe B
read-crc-pipe-B-frame-sequence: Testing connector VGA-1 using pipe B
Subtest read-crc-pipe-B-frame-sequence: SUCCESS
rtcwake: assuming RTC uses UTC ...
rtcwake: wakeup from "mem" using /dev/rtc0 at Wed Sep  3 21:25:24 2014
suspend-read-crc-pipe-B: Testing connector eDP-1 using pipe B
Test assertion failure function igt_wait_for_vblank, file igt_kms.c:1589:
Failed assertion: drmWaitVBlank(drm_fd, &wait_vbl) == 0
Last errno: 16, Device or resource busy
Subtest suspend-read-crc-pipe-B: FAIL
hang-read-crc-pipe-B: Testing connector eDP-1 using pipe B
Test assertion failure function igt_wait_for_vblank, file igt_kms.c:1589:
Failed assertion: drmWaitVBlank(drm_fd, &wait_vbl) == 0
Last errno: 16, Device or resource busy
Subtest hang-read-crc-pipe-B: FAIL
Test requirement not met in function test_read_crc, file kms_pipe_crc_basic.c:211:
Test requirement: !(pipe >= data->display.n_pipes)
Last errno: 16, Device or resource busy
Subtest read-crc-pipe-C: SKIP
Test requirement not met in function test_read_crc, file kms_pipe_crc_basic.c:211:
Test requirement: !(pipe >= data->display.n_pipes)
Last errno: 16, Device or resource busy
Subtest read-crc-pipe-C-frame-sequence: SKIP
rtcwake: assuming RTC uses UTC ...
rtcwake: wakeup from "mem" using /dev/rtc0 at Wed Sep  3 21:26:17 2014
Test requirement not met in function test_read_crc, file kms_pipe_crc_basic.c:211:
Test requirement: !(pipe >= data->display.n_pipes)
Last errno: 16, Device or resource busy
Subtest suspend-read-crc-pipe-C: SKIP
Test requirement not met in function test_read_crc, file kms_pipe_crc_basic.c:211:
Test requirement: !(pipe >= data->display.n_pipes)
Subtest hang-read-crc-pipe-C: SKIP
Comment 5 Jani Nikula 2014-09-03 08:10:10 UTC
Ville, did we change something here that could've fixed this?
Comment 6 Ville Syrjala 2014-09-03 09:02:31 UTC
(In reply to comment #5)
> Ville, did we change something here that could've fixed this?

Frankly I have no idea what could have caused it in the first place.
Comment 7 Jani Nikula 2014-09-09 09:46:37 UTC
(In reply to comment #6)
> (In reply to comment #5)
> > Ville, did we change something here that could've fixed this?
> 
> Frankly I have no idea what could have caused it in the first place.

*shrug* closing, please reopen if the problem reappears.
Comment 8 Guo Jinxian 2014-09-12 05:02:47 UTC
Verified on latest -nightly(907d7b0519abe7b8eac453089decfe0fc5049171)

root@x-bytm02:/GFX/Test/Intel_gpu_tools/intel-gpu-tools/tests# time ./kms_pipe_crc_basic
IGT-Version: 1.8-g107151c (x86_64) (Linux: 3.17.0-rc4_drm-intel-nightly_907d7b_20140912+ x86_64)
Subtest bad-pipe: SUCCESS (0.000s)
Subtest bad-source: SUCCESS (0.000s)
Subtest bad-nb-words-1: SUCCESS (0.000s)
Subtest bad-nb-words-3: SUCCESS (0.000s)
read-crc-pipe-A: Testing connector eDP-1 using pipe A
read-crc-pipe-A: Testing connector VGA-1 using pipe A
Subtest read-crc-pipe-A: SUCCESS (6.653s)
read-crc-pipe-A-frame-sequence: Testing connector eDP-1 using pipe A
Test assertion failure function test_read_crc_for_output, file kms_pipe_crc_basic.c:188:
Failed assertion: igt_crc_equal(&crcs[j], &crcs[j + 1])
Subtest read-crc-pipe-A-frame-sequence: FAIL (5.516s)
rtcwake: assuming RTC uses UTC ...
rtcwake: wakeup from "mem" using /dev/rtc0 at Fri Sep 12 20:30:50 2014
suspend-read-crc-pipe-A: Testing connector eDP-1 using pipe A
Test assertion failure function igt_pipe_crc_new, file igt_debugfs.c:384:
Failed assertion: pipe_crc->crc_fd != -1
Last errno: 16, Device or resource busy
Subtest suspend-read-crc-pipe-A: FAIL (4.136s)
hang-read-crc-pipe-A: Testing connector eDP-1 using pipe A
Test assertion failure function igt_pipe_crc_new, file igt_debugfs.c:384:
Failed assertion: pipe_crc->crc_fd != -1
Last errno: 16, Device or resource busy
Subtest hang-read-crc-pipe-A: FAIL (6.747s)
read-crc-pipe-B: Testing connector eDP-1 using pipe B
Test assertion failure function test_read_crc_for_output, file kms_pipe_crc_basic.c:188:
Failed assertion: igt_crc_equal(&crcs[j], &crcs[j + 1])
Subtest read-crc-pipe-B: FAIL (27.501s)
read-crc-pipe-B-frame-sequence: Testing connector eDP-1 using pipe B
Test assertion failure function igt_pipe_crc_new, file igt_debugfs.c:384:
Failed assertion: pipe_crc->crc_fd != -1
Last errno: 16, Device or resource busy
Subtest read-crc-pipe-B-frame-sequence: FAIL (0.583s)
rtcwake: assuming RTC uses UTC ...
rtcwake: wakeup from "mem" using /dev/rtc0 at Fri Sep 12 20:31:59 2014
suspend-read-crc-pipe-B: Testing connector eDP-1 using pipe B
Test assertion failure function igt_pipe_crc_new, file igt_debugfs.c:384:
Failed assertion: pipe_crc->crc_fd != -1
Last errno: 16, Device or resource busy
Subtest suspend-read-crc-pipe-B: FAIL (21.517s)
hang-read-crc-pipe-B: Testing connector eDP-1 using pipe B
Test assertion failure function igt_pipe_crc_new, file igt_debugfs.c:384:
Failed assertion: pipe_crc->crc_fd != -1
Last errno: 16, Device or resource busy
Subtest hang-read-crc-pipe-B: FAIL (6.413s)
Test requirement not met in function test_read_crc, file kms_pipe_crc_basic.c:211:
Test requirement: !(pipe >= data->display.n_pipes)
Last errno: 16, Device or resource busy
Subtest read-crc-pipe-C: SKIP (0.000s)
Test requirement not met in function test_read_crc, file kms_pipe_crc_basic.c:211:
Test requirement: !(pipe >= data->display.n_pipes)
Last errno: 16, Device or resource busy
Subtest read-crc-pipe-C-frame-sequence: SKIP (0.000s)
rtcwake: assuming RTC uses UTC ...
rtcwake: wakeup from "mem" using /dev/rtc0 at Fri Sep 12 20:32:57 2014
Test requirement not met in function test_read_crc, file kms_pipe_crc_basic.c:211:
Test requirement: !(pipe >= data->display.n_pipes)
Last errno: 16, Device or resource busy
Subtest suspend-read-crc-pipe-C: SKIP (10.694s)
Test requirement not met in function test_read_crc, file kms_pipe_crc_basic.c:211:
Test requirement: !(pipe >= data->display.n_pipes)
Subtest hang-read-crc-pipe-C: SKIP (5.700s)

real    3m10.666s
user    0m0.080s
sys     0m0.561s
Comment 9 Jari Tahvanainen 2016-10-07 08:41:13 UTC
Closing verified+worksforme.

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.