Bug 95427 - [IGT] gem_userptr_blits@mlocked-* fail or process killed
Summary: [IGT] gem_userptr_blits@mlocked-* fail or process killed
Status: RESOLVED WONTFIX
Alias: None
Product: DRI
Classification: Unclassified
Component: DRM/Intel (show other bugs)
Version: unspecified
Hardware: x86-64 (AMD64) Linux (All)
: medium normal
Assignee: Abdiel Janulgue
QA Contact: Intel GFX Bugs mailing list
URL:
Whiteboard:
Keywords:
Depends on: 101857
Blocks:
  Show dependency treegraph
 
Reported: 2016-05-16 13:19 UTC by cprigent
Modified: 2019-06-03 05:47 UTC (History)
1 user (show)

See Also:
i915 platform: BDW, CFL, CNL, GLK
i915 features: GEM/Other


Attachments
kbl_gem_userptr_blits-mlocked-_kern.log (399.00 KB, text/plain)
2016-05-16 13:19 UTC, cprigent
no flags Details
kbl_output-gem_userptr_blits-mlocked- (1.18 KB, text/plain)
2016-05-16 13:20 UTC, cprigent
no flags Details
BDW--gem_userptr_blits--mlocked--output (2.04 KB, text/plain)
2016-09-15 13:41 UTC, cprigent
no flags Details
BDW--gem_userptr_blits--mlocked--kern.log (364.45 KB, text/plain)
2016-09-15 13:41 UTC, cprigent
no flags Details
cnl dmesg (17.92 KB, text/plain)
2018-02-22 15:09 UTC, Armando Antonio
no flags Details
Proposed fix (1.38 KB, patch)
2018-06-05 10:49 UTC, Abdiel Janulgue
no flags Details | Splinter Review

Description cprigent 2016-05-16 13:19:00 UTC
Created attachment 123780 [details]
kbl_gem_userptr_blits-mlocked-_kern.log

Hardware
Platform: KABY LAKE-U
CPU : Intel(R) Core(TM) @ 2.60GHz
MCP : KBL-U G0 2+2 (ou ULT-G0)
QDF : QYQ8
Chipset PCH: SPT-LP C1
CRB : KABY LAKE U DDR3L RVP7 CRB FAB1

Software
BIOS : KBLSE2R1.R00.X015.B01.1511271314
ME FW : 11.5.0.1008
Ksc (EC FW): 1.20
Linux distribution: Ubuntu 16.04 64 bits
kernel drm-intel-nightly 4.6.0-rc7 61f856f from http://cgit.freedesktop.org/drm-intel/
  commit 61f856faa1e6ff9dddad214be1e372e8aacfc0f4
  Author: Ville Syrjälä <ville.syrjala@linux.intel.com>
  Date:   Mon May 9 19:24:21 2016 +0300
  drm-intel-nightly: 2016y-05m-09d-16h-24m-01s UTC integration manifest
libdrm-2.4.68 fc09c5a from git://anongit.freedesktop.org/mesa/drm
cairo: 1.15.2 db8a7f1 from git://anongit.freedesktop.org/cairo
IGT 1.14 cc24755 from http://anongit.freedesktop.org/git/xorg/app/intel-gpu-tools.git

Steps:
------
Execute commands:
cd <...>/intel-gpu-tools/tests
# ./gem_userptr_blits --run-subtest mlocked-normal-sync
# ./gem_userptr_blits --run-subtest mlocked-sync-interruptible
# ./gem_userptr_blits --run-subtest mlocked-unsync-interruptible
# ./gem_userptr_blits --run-subtest mlocked-unsync-normal

Actual results:
-------------
Processes are killed

Expected results:
-----------------
Tests are skip
Comment 1 cprigent 2016-05-16 13:20:47 UTC
Created attachment 123781 [details]
kbl_output-gem_userptr_blits-mlocked-
Comment 2 Humberto Israel Perez Rodriguez 2016-06-19 16:42:36 UTC
even with 16GB of ram in APL the following tests keeps failing :

Tests cases
=============
igt@gem_userptr_blits@mlocked-unsync-normal
igt@gem_userptr_blits@mlocked-normal-sync


output :
============
IGT-Version: 1.15-g3ce58b6 (x86_64) (Linux: 4.7.0-rc2-drm-intel-nightly-ww24-commit-55d1291+ x86_64)
(gem_userptr_blits:1332) drmtest-DEBUG: Test requirement passed: fd >= 0
(gem_userptr_blits:1332) ioctl-wrappers-DEBUG: Test requirement passed: !(ret == ENODEV && (flags & LOCAL_I915_USERPTR_UNSYNCHRONIZED) == 0 && !read_only)
(gem_userptr_blits:1332) DEBUG: Test requirement passed: !(ret == 0)
Aperture size is 268435456 MiB
Total RAM is 15,884 MiB
Not enough RAM to run test, reducing buffer count.
Testing unsynchronized mappings...
(gem_userptr_blits:1332) igt-core-DEBUG: Starting subtest: mlocked-unsync-normal
(gem_userptr_blits:1332) intel-os-DEBUG: Checking 256 surfaces of size 1,048,576 bytes (total 268,566,528) against RAM
(gem_userptr_blits:1332) intel-os-DEBUG: Test requirement passed: __intel_check_memory(count, size, mode, &required, &total)
(gem_userptr_blits:1332) igt-core-DEBUG: Test requirement passed: !igt_run_in_simulation()
(gem_userptr_blits:1332) DEBUG: Test requirement passed: pin > sz
(gem_userptr_blits:1332) DEBUG: Pinning [15,428, 15,684] MiB
Killed

relevant kernel messages:
=============================
kern  :err   : [Sat Jun 18 16:18:55 2016] 32 and 0 pages still available in the bound and unbound GPU page lists.
kern  :err   : [Sat Jun 18 16:18:55 2016] Out of memory: Kill process 1348 (gem_userptr_bli) score 1762 or sacrifice child
kern  :err   : [Sat Jun 18 16:18:55 2016] Killed process 1348 (gem_userptr_bli) total-vm:16169932kB, anon-rss:15988692kB, file-rss:4kB, shmem-rss:0kB


looks like that is something wrong in the test itself of the test needs much more memory ?
Comment 3 Emil Velikov 2016-06-19 17:45:15 UTC
Guys have you actually looked at the following line ?
Aperture size is 268435456 MiB -- That is 256 TiB !!!

That's rather impossible amount if you ask me. So there's either a bug in IGT's gem_aperture_size() or one of the two ioctls (I915_GEM_CONTEXT_GETPARAM I915_GEM_GET_APERTURE) that it uses.

With a couple of print statements you should be able to quickly track the exact offender. Good luck !
Comment 4 cprigent 2016-07-29 13:41:21 UTC
(In reply to Emil Velikov from comment #3)
> Guys have you actually looked at the following line ?
> Aperture size is 268435456 MiB -- That is 256 TiB !!!
> 
> That's rather impossible amount if you ask me. So there's either a bug in
> IGT's gem_aperture_size() or one of the two ioctls
> (I915_GEM_CONTEXT_GETPARAM I915_GEM_GET_APERTURE) that it uses.
> 
> With a couple of print statements you should be able to quickly track the
> exact offender. Good luck !

Yes, we saw it. The bug is reported to IGT (not to DRM/Intel). We propose the test should skip.

I just checked on our IVB platform with 32 GB of memory. Looks like we would need now 2 TB.

root@IVB102:/opt/X11R7/src/intel-gpu-tools/tests# ./gem_userptr_blits --run-subtest mlocked-normal-sync
IGT-Version: 1.15-ge3abb20 (x86_64) (Linux: 4.7.0-nightly+ x86_64)
Aperture size is 2048 MiB
Total RAM is 31,945 MiB
Testing unsynchronized mappings...
Testing synchronized mappings...
Killed
Comment 5 Chris Wilson 2016-07-29 16:17:17 UTC
(In reply to Emil Velikov from comment #3)
> Guys have you actually looked at the following line ?
> Aperture size is 268435456 MiB -- That is 256 TiB !!!
> 
> That's rather impossible amount if you ask me. So there's either a bug in
> IGT's gem_aperture_size() or one of the two ioctls

It is correct. The GTT size is 1<<48 bytes.
Comment 6 Chris Wilson 2016-07-29 16:25:13 UTC
(In reply to cprigent from comment #4)
> (In reply to Emil Velikov from comment #3)
> > Guys have you actually looked at the following line ?
> > Aperture size is 268435456 MiB -- That is 256 TiB !!!
> > 
> > That's rather impossible amount if you ask me. So there's either a bug in
> > IGT's gem_aperture_size() or one of the two ioctls
> > (I915_GEM_CONTEXT_GETPARAM I915_GEM_GET_APERTURE) that it uses.
> > 
> > With a couple of print statements you should be able to quickly track the
> > exact offender. Good luck !
> 
> Yes, we saw it. The bug is reported to IGT (not to DRM/Intel). We propose
> the test should skip.

Why? The test only allocates enough to fill RAM and then tests that the buffers are evicted for memory pressure. The messages are nothing to do with this test, just spam.
Comment 7 cprigent 2016-09-15 13:41:38 UTC
Created attachment 126552 [details]
BDW--gem_userptr_blits--mlocked--output

Thanks for the clarification. I move back the bug to drm/intel.

And I attach logs for BDW.

Platform: NUC5i7RYB
CPU: Intel(R) Core(TM) i7-5557U CPU @ 3.10GHz (Family 6, Model 61, Stepping 4)
Motherboard version: H73774-102
GPU: Intel® Iris™ Graphics 6100 - Intel Corporation Broadwell-U Integrated Graphics (rev 09)
Memory: two 4GB card Kingston 99U5469-045.A00LF
SSD: INTEL SSDSC2KW24

Software
Bios: RYBDWi35.86A.0358.2016.0606.1423 from https://downloadcenter.intel.com/downloads/eula/26081/BIOS-Update-RYBDWi35-86A-?httpDown=https%3A%2F%2Fdownloadmirror.intel.com%2F26081%2Feng%2FRY0358.bio
Linux distribution: Ubuntu 16.04 64 bits
Kernel: 4.8.0-rc5 bef9c1f from http://cgit.freedesktop.org/drm-intel/
  commit bef9c1f4afe24cfff578d386bde349add65673eb
  Author: Joonas Lahtinen <joonas.lahtinen@linux.intel.com>
  Date:   Mon Sep 12 11:35:34 2016 +0300
  drm-intel-nightly: 2016y-09m-12d-08h-35m-02s UTC integration manifest
libdrm-2.4.70-12 2d00869 from git://anongit.freedesktop.org/mesa/drm
mesa: mesa-11.2.2 3a9f628 from git://anongit.freedesktop.org/mesa/mesa
cairo 1.15.2 db8a7f1 from git://anongit.freedesktop.org/cairo
xorg-server-1.18.0-549 527c6ba from git://git.freedesktop.org/git/xorg/xserver
xf86-video-intel 2.99.917-703 15c5ff1 from git://git.freedesktop.org/git/xorg/driver/xf86-video-intel
libva-1.7.0-47 2ebf897 from git://git.freedesktop.org/git/vaapi/libva 
vaapi-intel-driver: 1.7.0-117 8c11f51 from git://git.freedesktop.org/git/vaapi/intel-driver
Intel-Gpu-Tools 1.16 f565b6c from http://anongit.freedesktop.org/git/xorg/app/intel-gpu-tools.git
Comment 8 cprigent 2016-09-15 13:41:55 UTC
Created attachment 126553 [details]
BDW--gem_userptr_blits--mlocked--kern.log
Comment 9 Luis Botello 2016-10-13 21:34:50 UTC
Issue still present over APL with the following config:

Software Config:
=====================================================
Kernel:
commit f35ed31aea66b3230c366fcba5f3456ae2cb956e
Author: Jani Nikula <jani.nikula@intel.com>
Date:   Mon Oct 10 14:29:09 2016 +0300
    drm-intel-nightly: 2016y-10m-10d-11h-28m-51s UTC integration manifest

drm:
  tag: libdrm-2.4.71
  commit: a44c9c31b7b38b3eedf3d26648f9e68dcc377c4c
mesa:
  tag: mesa-12.0.0
  commit: 8b06176f310f65628ce136b90a99005278ba5e0d
cairo:
  tag: 1.15.2
  commit: db8a7f1697c49ae4942d2aa49eed52dd73dd9c7a
xorg-server-macros:
  tag: util-macros-1.19.0-2-gd7acec2
  commit: d7acec2d3a3abe79814ceb72e2c0d4d95ed31d37
xserver:
  tag: xorg-server-1.18.99.901-76-g97a8353
  commit: 97a8353ec1192d8d3bd2ebb99e5687cb91427e09
xf86-video-intel:
  tag: 2.99.917-712-g696f58f
  commit: 696f58f69f2bac5717d19f7a1a2278fee50a083e
libva:
  tag: libva-1.7.2-38-g3b7e499
  commit: 3b7e4999950a04fabd42edbead8c2f24c6cdf3cf
vaapi-intel-driver:
  tag: 1.7.2-133-gdd73514
  commit: dd73514209d7942f2d8c8b0bbb541fe6884ea1bc

Hardware Config:
========================================================
Platform                        : BXT-P
Motherboard model               : Broxton P
Motherboard type                : NOTEBOOK Hand Held
Motherboard manufacturer        : Intel Corp.
CPU family                      : Other
CPU information                 : 06/5c
GPU Card                        : Intel Corporation Device 5a84 (rev 0a) (prog-if 00 [VGA controller])
Comment 10 Elio 2016-11-23 22:59:04 UTC
The problem is present in BYT as well with following configuration:

Platform BYT: Acer Aspire XC-603
CPU: Intel(R) Pentium(R) CPU  J2900  @ 2.41GHz (family 6, model 55, stepping 8)
Motherboard: Aspire XC-603
GPU: Intel® HD Graphics - Intel Corporation Atom Processor Z36xxx/Z37xxx Series Graphics & Display (rev 0e)

Software
Bios: P11-B2
Linux distribution: Ubuntu 16.04 64 bits

Kernel: 4.9.0-rc4 91e164f branch drm-intel-nightly from http://cgit.freedesktop.org/drm-intel/ 
  commit 91e164fea17d3e5366048b6eae3c6eea4e14e9fe
  Author: Ville Syrjälä <ville.syrjala@linux.intel.com>
  Date:   Mon Nov 14 16:31:06 2016 +0200
  drm-intel-nightly: 2016y-11m-14d-14h-30m-30s UTC integration manifest

libdrm-2.4.71-13 670f1e4 from git://anongit.freedesktop.org/mesa/drm
mesa: mesa-13.0.0 df1b0a5 from git://anongit.freedesktop.org/mesa/mesa
cairo 1.15.2 db8a7f1 from git://anongit.freedesktop.org/cairo
xorg-server-1.18.99.902-2 7513da4 from git://git.freedesktop.org/git/xorg/xserver
xf86-video-intel 2.99.917-731 d1d14f2 from git://git.freedesktop.org/git/xorg/driver/xf86-video-intel
libva-1.7.2-40 3a7547b from git://git.freedesktop.org/git/vaapi/libva 
vaapi-intel-driver: 1.7.2-157 55a538c from git://git.freedesktop.org/git/vaapi/intel-driver
intel-gpu-tools-1.16-132 773ac7c from http://anongit.freedesktop.org/git/xorg/app/intel-gpu-tools.git


Error:
Out of memory: Kill process 662 (snapd) score 0 or sacrifice child
[51212.544470] Killed process 662 (snapd) total-vm:276932kB, anon-rss:0kB, file-rss:0kB, shmem-rss:0kB
[51212.557765] oom_reaper: reaped process 662 (snapd), now anon-rss:0kB, file-rss:0kB, shmem-rss:0kB
Comment 11 maria guadalupe 2016-11-24 19:49:42 UTC
Issue still present over BSW with the following config:

tests failed
============================================
igt@gem_userptr_blits@mlocked-normal-sync
igt@gem_userptr_blits@mlocked-unsync-interruptible

 Software information
============================================
Kernel version                  : 4.9.0-rc6-nightly+
Linux distribution              : Ubuntu 16.04.1 LTS
Architecture                    : 64-bit
Gfx stack code                  : 2141224538
xf86-video-intel version        : 2.99.917
Xorg-Xserver version            : 1.18.4
DRM version                     : 2.4.73
Cairo version                   : 1.15.2
Intel GPU Tools version         : Tag [intel-gpu-tools-1.16-156-gcddf996] / Commit [cddf996]
Kernel driver in use            : i915
Bios revision                   : 0.33
Bios release date               : 08/12/2015
KSC revision                    : 0.16


 Hardware information
============================================
Platform                        : BSW
Motherboard model               : 10G9000NUS
Motherboard type                : BRASWELL Desktop
Motherboard manufacturer        : LENOVO
CPU family                      : Pentium
CPU information                 : Intel(R) Pentium(R) CPU  N3700  @ 1.60GHz
GPU Card                        : Intel Corporation Device 22b1 (rev 21) (prog-if 00 [VGA controller])
Memory ram                      : 8 GB
Maximum memory ram allowed      : 8 GB
CPU thread                      : 4
CPU core                        : 4
Hard drive capacity             : 476GiB (512GB)
Comment 12 maria guadalupe 2017-01-12 21:56:29 UTC
Issue still present over KBL with the following config:

tests failed
============================================
igt@gem_userptr_blits@mlocked-normal-sync

Software information
============================================
Kernel version                  : 4.10.0-rc2-drm-tip-qa-ww3-commit-eb5c556+
Linux distribution              : Ubuntu 16.10
Architecture                    : 64-bit
Gfx stack code                  : 979449066
Xorg-Xserver version            : 1.18.4
DRM version                     : 2.4.74
Cairo version                   : 1.15.5
Intel GPU Tools version         : Tag [intel-gpu-tools-1.17-109-ge2eefcc] / Commit [e2eefcc]
Kernel driver in use            : i915
Bios revision                   : 5.12
Bios release date               : 09/12/2016


 Hardware information
============================================
Platform                        : KBL-Nuc
Motherboard model               : MS-B142
Motherboard type                : MS-B1421 Desktop
Motherboard manufacturer        : Micro-StarInternationalCo.,Ltd.
CPU family                      : Core i7
CPU information                 : Intel(R) Core(TM) i7-7500U CPU @ 2.70GHz
GPU Card                        : Intel Corporation Device 5916 (rev 02) (prog-if 00 [VGA controller])
Memory ram                      : 16 GB
Maximum memory ram allowed      : 64 GB
CPU thread                      : 4
CPU core                        : 2
Hard drive capacity             : 111GiB (120GB)
Comment 13 Jari Tahvanainen 2017-05-23 10:44:08 UTC
removing KBL since on 4.11.0-drm-tip-ww18-commit-fb550f8+ (KBL-2-MS-B1421) all gem_userptr_blits@mlocked-* are pass
For BXT igt@gem_userptr_blits@mlocked-normal-sync is Fail, other are pass.
Comment 14 Jari Tahvanainen 2017-07-03 13:28:56 UTC
Adding KBL again due to fail on mlocked-normal-sync with 4.12.0-rc3-drm-tip-ww22-commit-2c9abf8e+ (KBL-R)
Comment 15 Ricardo Madrigal 2017-08-09 21:23:37 UTC
This issue is still present over BXT/BDW/IVB/BYT/BSW/KBL platforms with the latest kernel 4.13.0-rc4-drm-tip-ww32-commit-96c5eac+
Comment 16 Hector Velazquez 2017-08-25 19:35:32 UTC
The following tests Fail on HSW with this configuration

Tests List:

igt@gem_userptr_blits@mlocked-sync-interruptible
igt@gem_userptr_blits@mlocked-unsync-normal



This is my configuration:

**************************************************************
* * * * * * * * HARDWARE SPECIFICATIONS * * * * * * * * * * * 
**************************************************************
======================================
        Graphic stack
======================================

Component: drm
    tag: libdrm-2.4.81-51-gf19dbb7
    commit: f19dbb79fe54994ecd505ac67ad15d19f591933a

Component: cairo
    tag: 1.15.6-23-g74c6e3a
    commit: 74c6e3ae1d356e8bb4c7043cb9d3897c45cc0f79

Component: intel-gpu-tools
    tag: intel-gpu-tools-1.19-202-g37641a5
    commit: 37641a5032b2cb2dcdb04a28d3ac3cebd01b8363

Component: piglit
    tag: piglit-v1
    commit: 465dbc57b01cc60eb74880f161663644720a57f6


======================================
	     Software
======================================
kernel version              : 4.13.0-rc6-drm-tip-ww34-commit-428dc37+
hostname                    : gfx-desktop
architecture                : x86_64
os version                  : Ubuntu 17.04
os codename                 : zesty
kernel driver               : i915
bios revision               : 4.6
bios release date           : 03/02/2017
hardware acceleration       : [93monly available on X[0m
swap partition              : [92menabled[0m on (/dev/sda2)

======================================
	Graphic drivers
======================================
libdrm                      : 2.4.83
cairo                       : 1.15.7
intel-gpu-tools (tag)       : intel-gpu-tools-1.19-202-g37641a50
intel-gpu-tools (commit)    : 37641a50

======================================
	     Hardware
======================================
platform                   : Haswell-Nuc
motherboard id             : D54250WYK
form factor                : Desktop
cpu family                 : Core i5
cpu family id              : 6
cpu information            : Intel(R) Core(TM) i5-4250U CPU @ 1.30GHz
gpu card                   : Intel Corporation Haswell-ULT Integrated Graphics Controller (rev 09) (prog-if 00 [VGA controller])
memory ram                 : 1.83 GB
max memory ram             : 16 GB
cpu thread                 : 4
cpu core                   : 2
cpu model                  : 69
cpu stepping               : 1
socket                     : Socket LGA1150
signature                  : Type 0, Family 6, Model 69, Stepping 1
hard drive                 : 223GiB (240GB)
current cd clock frequency : 450000 kHz
maximum cd clock frequency : 450000 kHz
displays connected         : DP-1

======================================
	     Firmware
======================================

======================================
	     kernel parameters
======================================
quiet splash drm.debug=0x1e
Comment 17 Hector Velazquez 2017-09-05 18:52:46 UTC
The following tests FAIL on HSW 

Tests List:

igt@gem_userptr_blits@mlocked-sync-interruptible
igt@gem_userptr_blits@mlocked-unsync-interruptible
igt@gem_userptr_blits@mlocked-unsync-normal



This is my configuration:

======================================
        Graphic stack
======================================

Component: drm
    tag: libdrm-2.4.81-52-g05a830d
    commit: 05a830d382382905d87b55af90aa109fb76e4c16

Component: cairo
    tag: 1.15.6-30-gc29db4f
    commit: c29db4f0de52727406a8b62f4da9a382084b5a79

Component: intel-gpu-tools
    tag: intel-gpu-tools-1.19-234-g490b386
    commit: 490b386ae36d393cdea514882a2437c6e964c13f

Component: piglit
    tag: piglit-v1
    commit: dab15137044c34023b1a843e72e781b03b17548b

======================================
	     Software
======================================
kernel version              : 4.13.0-drm-tip-ww36-commit-9dd459e+
hostname                    : gfx-desktop
architecture                : x86_64
os version                  : Ubuntu 16.10
os codename                 : yakkety
kernel driver               : i915
bios revision               : 4.6
bios release date           : 03/02/2017
hardware acceleration       : disabled
swap partition              : enabled on (/dev/sda3)

======================================
	Graphic drivers
======================================
libdrm                      : 2.4.83
cairo                       : 1.15.9
intel-gpu-tools (tag)       : intel-gpu-tools-1.19-234-g490b386
intel-gpu-tools (commit)    : 490b386
Comment 18 Hector Velazquez 2017-09-07 14:46:48 UTC
The following tests Fail on SKL 

Tests List:

igt@gem_userptr_blits@mlocked-unsync-normal



======================================
        Output Sample
======================================
...
IGT-Version: 1.19-g4a1c8da (x86_64) (Linux: 4.13.0-drm-tip-ww36-commit-00f9b49+ x86_64)
(gem_userptr_blits:1542) drmtest-DEBUG: Test requirement passed: !(fd<0)
(gem_userptr_blits:1542) igt-debugfs-DEBUG: Opening debugfs directory '/sys/kernel/debug/dri/0'
(gem_userptr_blits:1542) drmtest-DEBUG: Test requirement passed: is_i915_device(fd) && has_known_intel_chipset(fd)
(gem_userptr_blits:1542) ioctl-wrappers-DEBUG: Test requirement passed: err == 0
Aperture size is 268435456 MiB
Total RAM is 15936 MiB
Not enough RAM to run test, reducing buffer count.
(gem_userptr_blits:1542) DEBUG: Test requirement passed: has_userptr(fd)
(gem_userptr_blits:1542) DEBUG: Test requirement passed: has_userptr(fd)
(gem_userptr_blits:1542) igt-core-DEBUG: Starting subtest: mlocked-unsync-normal
(gem_userptr_blits:1542) intel-os-DEBUG: Checking 256 surfaces of size 1048576 bytes (total 268566528) against RAM
(gem_userptr_blits:1542) drmtest-DEBUG: Test requirement passed: !(fd<0)
(gem_userptr_blits:1542) igt-debugfs-DEBUG: Opening debugfs directory '/sys/kernel/debug/dri/0'
(gem_userptr_blits:1542) intel-os-DEBUG: Test requirement passed: __intel_check_memory(count, size, mode, &required, &total)
(gem_userptr_blits:1542) igt-core-DEBUG: Test requirement passed: !igt_run_in_simulation()
(gem_userptr_blits:1542) drmtest-DEBUG: Test requirement passed: !(fd<0)
(gem_userptr_blits:1542) igt-debugfs-DEBUG: Opening debugfs directory '/sys/kernel/debug/dri/0'
(gem_userptr_blits:1542) DEBUG: Test requirement passed: pin > sz
(gem_userptr_blits:1542) DEBUG: Pinning [15423, 15679] MiB
Subtest mlocked-unsync-normal failed.
**** DEBUG ****
(gem_userptr_blits:1542) intel-os-DEBUG: Checking 256 surfaces of size 1048576 bytes (total 268566528) against RAM
(gem_userptr_blits:1542) drmtest-DEBUG: Test requirement passed: !(fd<0)
(gem_userptr_blits:1542) igt-debugfs-DEBUG: Opening debugfs directory '/sys/kernel/debug/dri/0'
(gem_userptr_blits:1542) intel-os-DEBUG: Test requirement passed: __intel_check_memory(count, size, mode, &required, &total)
(gem_userptr_blits:1542) igt-core-DEBUG: Test requirement passed: !igt_run_in_simulation()
(gem_userptr_blits:1542) drmtest-DEBUG: Test requirement passed: !(fd<0)
(gem_userptr_blits:1542) igt-debugfs-DEBUG: Opening debugfs directory '/sys/kernel/debug/dri/0'
(gem_userptr_blits:1542) DEBUG: Test requirement passed: pin > sz
(gem_userptr_blits:1542) DEBUG: Pinning [15423, 15679] MiB
****  END  ****
child 0 died with signal 9, Killed
Subtest mlocked-unsync-normal: FAIL (1.264s)
(gem_userptr_blits:1542) DEBUG: Test requirement passed: has_userptr(fd)
(gem_userptr_blits:1542) igt-core-DEBUG: Exiting with status code 137
(gem_userptr_blits:1542) igt-debugfs-DEBUG: Opening debugfs directory '/sys/kernel/debug/dri/0'
...

This is my configuration:

======================================
        Graphic stack
======================================

Component: drm
    tag: libdrm-2.4.81-53-gd55d080
    commit: d55d0804f9e37637d7510f38f97e07a50c6b7baa

Component: cairo
    tag: 1.15.6-30-gc29db4f
    commit: c29db4f0de52727406a8b62f4da9a382084b5a79

Component: intel-gpu-tools
    tag: intel-gpu-tools-1.19-244-g4a1c8da
    commit: 4a1c8daff2005e2cbfe980d63bc0a0fb09cb017d

Component: piglit
    tag: piglit-v1
    commit: dab15137044c34023b1a843e72e781b03b17548b



======================================
	     Software
======================================
kernel version              : 4.13.0-drm-tip-ww36-commit-00f9b49+
hostname                    : SKL-2-NUC6i5SYB
architecture                : x86_64
os version                  : Ubuntu 16.10
os codename                 : yakkety
kernel driver               : i915
bios revision               : 5.6
bios release date           : 05/27/2016
hardware acceleration       : disabled
swap partition              : enabled on (/dev/sda3)

======================================
	Graphic drivers
======================================
libdrm                      : 2.4.83
cairo                       : 1.15.9
intel-gpu-tools (tag)       : intel-gpu-tools-1.19-244-g4a1c8da
intel-gpu-tools (commit)    : 4a1c8da

======================================
	     Hardware
======================================
platform                   : Skylake-Nuc
motherboard id             : NUC6i5SYB
form factor                : Desktop
cpu family                 : Core i5
cpu family id              : 6
cpu information            : Intel(R) Core(TM) i5-6260U CPU @ 1.80GHz
gpu card                   : Intel Corporation Iris Graphics 540 (rev 0a) (prog-if 00 [VGA controller])
memory ram                 : 15.56 GB
max memory ram             : 32 GB
cpu thread                 : 4
cpu core                   : 2
cpu model                  : 78
cpu stepping               : 3
socket                     : None
signature                  : Type 0, Family 6, Model 78, Stepping 3
hard drive                 : 223GiB (240GB)
current cd clock frequency : 337500 kHz
maximum cd clock frequency : 675000 kHz
displays connected         : HDMI-A-1 DP-1

======================================
	     Firmware
======================================
dmc fw loaded             : yes
dmc version               : 1.26
guc fw loaded             : SUCCESS
guc version wanted        : 6.1
guc version found         : 6.1

======================================
	     kernel parameters
======================================
quiet drm.debug=0x1e pci=pcie_bus_safe intel_iommu=igfx_off auto panic=1 i915.alpha_support=1 i915.enable_guc_loading=2 i915.enable_guc_submission=2 nmi_watchdog=panic resume=/dev/sda3 fastboot
Comment 19 Hector Velazquez 2017-11-14 18:03:26 UTC
This tests have fail on CFL QA

igt@gem_userptr_blits@mlocked-normal-sync
igt@gem_userptr_blits@mlocked-sync-interruptible

====================================================
output sample
====================================================
**** DEBUG ****
(gem_userptr_blits:1657) intel-os-DEBUG: Checking 256 surfaces of size 1048576 bytes (total 268566528) against RAM
(gem_userptr_blits:1657) drmtest-DEBUG: Test requirement passed: !(fd<0)
(gem_userptr_blits:1657) igt-debugfs-DEBUG: Opening debugfs directory '/sys/kernel/debug/dri/0'
(gem_userptr_blits:1657) intel-os-DEBUG: Test requirement passed: __intel_check_memory(count, size, mode, &required, &total)
(gem_userptr_blits:1657) igt-core-DEBUG: Test requirement passed: !igt_run_in_simulation()
(gem_userptr_blits:1657) drmtest-DEBUG: Test requirement passed: !(fd<0)
(gem_userptr_blits:1657) igt-debugfs-DEBUG: Opening debugfs directory '/sys/kernel/debug/dri/0'
(gem_userptr_blits:1657) DEBUG: Test requirement passed: pin > sz
(gem_userptr_blits:1657) DEBUG: Pinning [31472, 31728] MiB
****  END  ****

This is my configuration:

======================================
	Graphic stack
======================================
Component: drm
    tag: libdrm-2.4.81-96-g931f019
    commit: 931f01964a2f2a75e8563feccc70ac2eb0296d99

Component: cairo
    tag: 1.15.6-82-g164be89
    commit: 164be896603ceb419c5bc47c7348781f791f70e4

Component: intel-gpu-tools
    tag: intel-gpu-tools-1.19-481-g7d75119
    commit: 7d75119b7f23fb49af52463da9bcd62e64fe6a6f

Component: piglit
    tag: piglit-v1
    commit: 733e3ab212fcce735f47ed9f8659ccdf6f625a70

======================================
	     Software
======================================
kernel version              : 4.14.0-rc8-drm-tip-ww45-commit-1342299+
hostname                    : gfx-desktop
architecture                : x86_64
os version                  : Ubuntu 16.10
os codename                 : yakkety
kernel driver               : i915
bios revision               : 98.0
bios release date           : 07/30/2017
ksc                         : 1.5
hardware acceleration       : disabled
swap partition              : enabled on (/dev/sda3)

======================================
	Graphic drivers
======================================
libdrm                      : 2.4.88
cairo                       : 1.15.9
intel-gpu-tools (tag)       : intel-gpu-tools-1.19-481-g7d75119
intel-gpu-tools (commit)    : 7d75119

======================================
	     Hardware
======================================
motherboard model          : CoffeeLakeClientPlatform
motherboard id             : CoffeeLakeHDDR4RVP
form factor                : Laptop
manufacturer               : IntelCorporation
cpu family                 : Other
cpu family id              : 6
cpu information            : Genuine Intel(R) CPU 0000 @ 2.80GHz
gpu card                   : Intel Corporation Device 3e9b (prog-if 00 [VGA controller])
memory ram                 : 31.3 GB
max memory ram             : 32 GB
cpu thread                 : 12
cpu core                   : 6
cpu model                  : 158
cpu stepping               : 10
socket                     : Other
hard drive                 : 74GiB (80GB)
current cd clock frequency : 337500 kHz
maximum cd clock frequency : 675000 kHz
displays connected         : DP-1 DP-2 DP-3

======================================
	     Firmware
======================================
dmc fw loaded             : yes
dmc version               : 1.1
guc fw loaded             : fetch SUCCESS, load SUCCESS
guc version wanted        : wanted 9.14, found 9.14
guc version found         : wanted 9.14, found 9.14

======================================
	     kernel parameters
======================================
quiet splash drm.debug=0xe intel_iommu=igfx_off i915.alpha_support=1 i915.enable_guc_loading=2 i915.enable_guc_submission=2 resume=/dev/sda3
Comment 20 Hector Velazquez 2017-11-21 15:38:16 UTC
This test was failing on GLK QA

igt@gem_userptr_blits@mlocked-normal-sync

====================================================
output
====================================================
**** DEBUG ****
(gem_userptr_blits:1644) intel-os-DEBUG: Checking 256 surfaces of size 1048576 bytes (total 268566528) against RAM
(gem_userptr_blits:1644) drmtest-DEBUG: Test requirement passed: !(fd<0)
(gem_userptr_blits:1644) igt-debugfs-DEBUG: Opening debugfs directory '/sys/kernel/debug/dri/0'
(gem_userptr_blits:1644) intel-os-DEBUG: Test requirement passed: __intel_check_memory(count, size, mode, &required, &total)
(gem_userptr_blits:1644) igt-core-DEBUG: Test requirement passed: !igt_run_in_simulation()
(gem_userptr_blits:1644) drmtest-DEBUG: Test requirement passed: !(fd<0)
(gem_userptr_blits:1644) igt-debugfs-DEBUG: Opening debugfs directory '/sys/kernel/debug/dri/0'
(gem_userptr_blits:1644) DEBUG: Test requirement passed: pin > sz
(gem_userptr_blits:1644) DEBUG: Pinning [7321, 7577] MiB
****  END  ****

This is my configuration:

======================================
	Graphic stack
======================================
Component: drm
    tag: libdrm-2.4.81-107-g18ffe48
    commit: 18ffe485cdfa41d48b6f2d3080cb990d28c27d57

Component: cairo
    tag: 1.15.6-83-g0c8070f
    commit: 0c8070f5bc74c124e6393b433a61807a8e4bee5d

Component: intel-gpu-tools
    tag: intel-gpu-tools-1.19-483-g88d6550
    commit: 88d6550795fad3974d77e4db2f563c5e2e8872e1

Component: piglit
    tag: piglit-v1
    commit: b6aee208234287380d2e55c17dc2d236931284fa
	
======================================
	     Software
======================================
kernel version              : 4.14.0-drm-tip-ww46-commit-1fc4fe8+
hostname                    : gfx-desktop
architecture                : x86_64
os version                  : Ubuntu 16.10
os codename                 : yakkety
kernel driver               : i915
bios revision               : 62.30
bios release date           : 08/22/2017
ksc                         : 1.48
hardware acceleration       : only available on X
swap partition              : enabled on (/dev/sda3)

======================================
	Graphic drivers
======================================
libdrm                      : 2.4.88
cairo                       : 1.15.9
intel-gpu-tools (tag)       : intel-gpu-tools-1.19-483-g88d6550
intel-gpu-tools (commit)    : 88d6550

======================================
	     Hardware
======================================
platform                   : Geminilake
motherboard model          : Geminilake
motherboard id             : GLKRVP1DDR4(05)
form factor                : Hand Held
manufacturer               : IntelCorp.
cpu family                 : Pentium
cpu family id              : 6
cpu information            : Intel(R) Pentium(R) Silver J5005 CPU @ 1.50GHz
gpu card                   : Intel Corporation Device 3184 (rev 03) (prog-if 00 [VGA controller])
memory ram                 : 7.64 GB
max memory ram             : 16 GB
cpu thread                 : 4
cpu core                   : 4
cpu model                  : 122
cpu stepping               : 1
socket                     : Other
signature                  : Type 0, Family 6, Model 122, Stepping 1
hard drive                 : 111GiB (120GB)
current cd clock frequency : 316800 kHz
maximum cd clock frequency : 316800 kHz
displays connected         : eDP-1 DP-1 HDMI-A-2

======================================
	     Firmware
======================================
dmc fw loaded             : yes
dmc version               : 1.4
guc fw loaded             : fetch SUCCESS, load SUCCESS
guc version wanted        : wanted 10.56, found 10.56
guc version found         : wanted 10.56, found 10.56

======================================
	     kernel parameters
======================================
quiet splash drm.debug=0xe intel_iommu=igfx_off i915.alpha_support=1 i915.enable_guc_loading=2 i915.enable_guc_submission=2 resume=/dev/sda3
Comment 21 Octavio 2018-01-02 18:22:05 UTC
The below test still fails on GLK 

igt@gem_userptr_blits@mlocked-unsync-interruptible

using IGT-Version: 1.20-gd86d53b (x86_64) (Linux: 4.15.0-rc6-drm-intel-qa-ww1-commit-cb4a985+ x86_64)
Comment 22 Hector Velazquez 2018-01-05 20:45:56 UTC
This tests has a fail with crash on CFL QA

igt@gem_userptr_blits@mlocked-sync-interruptible
igt@gem_userptr_blits@swapping-normal-sync

IGT-Version: 1.20-gd86d53b (x86_64) (Linux: 4.15.0-rc5-drm-tip-config-intel-turbo-ww1-commit-16432d3+ x86_64)
Comment 23 Antonio Argenziano 2018-02-05 19:05:07 UTC
(In reply to Chris Wilson from comment #6)
> (In reply to cprigent from comment #4)
> > (In reply to Emil Velikov from comment #3)
> > > Guys have you actually looked at the following line ?
> > > Aperture size is 268435456 MiB -- That is 256 TiB !!!
> > > 
> > > That's rather impossible amount if you ask me. So there's either a bug in
> > > IGT's gem_aperture_size() or one of the two ioctls
> > > (I915_GEM_CONTEXT_GETPARAM I915_GEM_GET_APERTURE) that it uses.
> > > 
> > > With a couple of print statements you should be able to quickly track the
> > > exact offender. Good luck !
> > 
> > Yes, we saw it. The bug is reported to IGT (not to DRM/Intel). We propose
> > the test should skip.
> 
> Why? The test only allocates enough to fill RAM and then tests that the
> buffers are evicted for memory pressure. The messages are nothing to do with
> this test, just spam.

Shouldn't the test should skip if it fails to determine if it can mlock or not? A while ago I had put together this: http://paste.debian.net/1008934/ to fix the test.

It is interesting that when I run the tests with "--r mlocked*" the first subtest is executed fine and passes but all the successive subtests skip. If I run them individually they seem to run fine most of the times. Are we leaking something?
Comment 24 Armando Antonio 2018-02-22 15:07:49 UTC
This issue is present on CNL with the following configuration:

======================================
             Software
======================================
kernel version              : 4.16.0-rc2-drm-tip-ww8-commit-e09e4db+
os version                  : Ubuntu 17.10
os codename                 : artful
bios revision               : 124.2
swap partition              : enabled on (/dev/nvme0n1p2)

======================================
        Graphic drivers
======================================
intel-gpu-tools (tag)       : intel-gpu-tools-1.21-124-g960e55a8

======================================
             Hardware
======================================
motherboard model          : CannonLakeClientPlatform
motherboard id             : CannonLakeYLPDDR4RVP
memory ram                 : 7.63 GB
max memory ram             : 8 GB
cpu thread                 : 4
cpu core                   : 2
cpu model                  : 102
cpu stepping               : 2

======================================
             Firmware
======================================
dmc fw loaded             : yes

======================================
             kernel parameters
======================================
splash i915.alpha_support=1 drm.debug=0x1e
Comment 25 Armando Antonio 2018-02-22 15:09:48 UTC
Created attachment 137531 [details]
cnl dmesg
Comment 26 Hector Velazquez 2018-03-02 15:03:38 UTC
This tests has a fail on BDW QA 
Tests List:

igt@gem_userptr_blits@mlocked-unsync-interruptible

output sample:
. . .
**** DEBUG ****
(gem_userptr_blits:30877) intel-os-DEBUG: Checking 256 surfaces of size 1048576 bytes (total 268566528) against RAM
(gem_userptr_blits:30877) drmtest-DEBUG: Test requirement passed: !(fd<0)
(gem_userptr_blits:30877) igt-debugfs-DEBUG: Opening debugfs directory '/sys/kernel/debug/dri/0'
(gem_userptr_blits:30877) intel-os-DEBUG: Test requirement passed: __intel_check_memory(count, size, mode, &required, &total)
(gem_userptr_blits:30877) igt-core-DEBUG: Test requirement passed: !igt_run_in_simulation()
(gem_userptr_blits:30877) drmtest-DEBUG: Test requirement passed: !(fd<0)
(gem_userptr_blits:30877) igt-debugfs-DEBUG: Opening debugfs directory '/sys/kernel/debug/dri/0'
(gem_userptr_blits:30877) DEBUG: Test requirement passed: pin > sz
(gem_userptr_blits:30877) DEBUG: Pinning [7438, 7694] MiB
****  END  ****. . .

This tests has a dmesg-warn on CFL QA 
Tests List:

igt@gem_userptr_blits@mlocked-unsync-normal

output sample:
. . .
**** DEBUG ****
(gem_userptr_blits:17493) intel-os-DEBUG: Checking 256 surfaces of size 1048576 bytes (total 268566528) against RAM
(gem_userptr_blits:17493) drmtest-DEBUG: Test requirement passed: !(fd<0)
(gem_userptr_blits:17493) igt-debugfs-DEBUG: Opening debugfs directory '/sys/kernel/debug/dri/0'
(gem_userptr_blits:17493) intel-os-DEBUG: Test requirement passed: __intel_check_memory(count, size, mode, &required, &total)
(gem_userptr_blits:17493) igt-core-DEBUG: Test requirement passed: !igt_run_in_simulation()
(gem_userptr_blits:17493) drmtest-DEBUG: Test requirement passed: !(fd<0)
(gem_userptr_blits:17493) igt-debugfs-DEBUG: Opening debugfs directory '/sys/kernel/debug/dri/0'
(gem_userptr_blits:17493) DEBUG: Test requirement passed: pin > sz
(gem_userptr_blits:17493) DEBUG: Pinning [15383, 15639] MiB
****  END  ****
. . .

This tests has a dmesg-warn on CNL QA 
Tests List:

igt@gem_userptr_blits@mlocked-unsync-normal

dmesg-warn sample:
. . .
**** DEBUG ****
(gem_userptr_blits:11160) intel-os-DEBUG: Checking 256 surfaces of size 1048576 bytes (total 268566528) against RAM
(gem_userptr_blits:11160) drmtest-DEBUG: Test requirement passed: !(fd<0)
(gem_userptr_blits:11160) igt-debugfs-DEBUG: Opening debugfs directory '/sys/kernel/debug/dri/0'
(gem_userptr_blits:11160) intel-os-DEBUG: Test requirement passed: __intel_check_memory(count, size, mode, &required, &total)
(gem_userptr_blits:11160) igt-core-DEBUG: Test requirement passed: !igt_run_in_simulation()
(gem_userptr_blits:11160) drmtest-DEBUG: Test requirement passed: !(fd<0)
(gem_userptr_blits:11160) igt-debugfs-DEBUG: Opening debugfs directory '/sys/kernel/debug/dri/0'
(gem_userptr_blits:11160) DEBUG: Test requirement passed: pin > sz
(gem_userptr_blits:11160) DEBUG: Pinning [7264, 7520] MiB
****  END  ****
. . .

software:
IGT-Version: 1.21-g1fb30f1 (x86_64) (Linux: 4.16.0-rc2-drm-intel-qa-ww8-commit-562dc33+ x86_64)

(removing GLK/KBL/BXT/BSW/HSW/IVB/BYT from the platform list, verified as fixed in last execution on GLK/KBL/BXT/BSW/HSW/IVB/BYT)
Comment 27 Hector Velazquez 2018-03-14 17:28:45 UTC
This tests has failing on GLK QA 
Tests List:
for igt@gem_userptr_blits@mlocked-unsync-normal

output sample:
. . .
**** DEBUG ****
(gem_userptr_blits:2152) intel-os-DEBUG: Checking 256 surfaces of size 1048576 bytes (total 268566528) against RAM
(gem_userptr_blits:2152) drmtest-DEBUG: Test requirement passed: !(fd<0)
(gem_userptr_blits:2152) igt-debugfs-DEBUG: Opening debugfs directory '/sys/kernel/debug/dri/0'
(gem_userptr_blits:2152) intel-os-DEBUG: Test requirement passed: __intel_check_memory(count, size, mode, &required, &total)
(gem_userptr_blits:2152) igt-core-DEBUG: Test requirement passed: !igt_run_in_simulation()
(gem_userptr_blits:2152) drmtest-DEBUG: Test requirement passed: !(fd<0)
(gem_userptr_blits:2152) igt-debugfs-DEBUG: Opening debugfs directory '/sys/kernel/debug/dri/0'
(gem_userptr_blits:2152) DEBUG: Test requirement passed: pin > sz
(gem_userptr_blits:2152) DEBUG: Pinning [3388, 3644] MiB
****  END  ****
. . .

software:
IGT-Version: 1.22-g89b915f (x86_64) (Linux: 4.16.0-rc5-drm-tip-ww11-commit-62a7da6+ x86_64)
Comment 28 Hector Velazquez 2018-03-23 22:38:49 UTC
This tests has a failed on CNL QA 
Tests List:
igt@gem_userptr_blits@mlocked-sync-interruptible
igt@gem_userptr_blits@mlocked-unsync-interruptible

software:
IGT-Version: 1.22-gc30e331 (x86_64) (Linux: 4.16.0-rc6-drm-intel-qa-ww12-commit-dff9ece+ x86_64)

Output sample:
. . .
**** DEBUG ****
(gem_userptr_blits:832) intel-os-DEBUG: Checking 256 surfaces of size 1048576 bytes (total 268566528) against RAM
(gem_userptr_blits:832) drmtest-DEBUG: Test requirement passed: !(fd<0)
(gem_userptr_blits:832) igt-debugfs-DEBUG: Opening debugfs directory '/sys/kernel/debug/dri/0'
(gem_userptr_blits:832) intel-os-DEBUG: Test requirement passed: __intel_check_memory(count, size, mode, &required, &total)
(gem_userptr_blits:832) igt-core-DEBUG: Test requirement passed: !igt_run_in_simulation()
(gem_userptr_blits:832) drmtest-DEBUG: Test requirement passed: !(fd<0)
(gem_userptr_blits:832) igt-debugfs-DEBUG: Opening debugfs directory '/sys/kernel/debug/dri/0'
(gem_userptr_blits:832) DEBUG: Test requirement passed: pin > sz
(gem_userptr_blits:832) DEBUG: Pinning [7306, 7562] MiB
****  END  ****
. . .
Comment 29 Jani Saarinen 2018-03-29 07:11:08 UTC
First of all. Sorry about spam.
This is mass update for our bugs. 

Sorry if you feel this annoying but with this trying to understand if bug still valid or not.
If bug investigation still in progress, please ignore this and I apologize!

If you think this is not anymore valid, please comment to the bug that can be closed.
If you haven't tested with our latest pre-upstream tree(drm-tip), can you do that also to see if issue is valid there still and if you cannot see issue there, please comment to the bug.
Comment 30 Elizabeth 2018-04-06 16:42:38 UTC
This assertion tents to appear sporadically in most of the platforms. It can take several runs until it happens again.

Results for igt@gem_userptr_blits@mlocked-unsync-interruptible
Result: fail

Out	
IGT-Version: 1.22-gda00bf8 (x86_64) (Linux: 4.16.0-rc7-drm-intel-qa-ww14-commit-29940f1+ x86_64)
Aperture size is 2048 MiB
Total RAM is 15918 MiB
child 0 died with signal 9, Killed
Subtest mlocked-unsync-interruptible: FAIL (1.498s)
Err	
Subtest mlocked-unsync-interruptible failed.
**** DEBUG ****
(gem_userptr_blits:7104) intel-os-DEBUG: Checking 256 surfaces of size 1048576 bytes (total 268566528) against RAM
(gem_userptr_blits:7104) drmtest-DEBUG: Test requirement passed: !(fd<0)
(gem_userptr_blits:7104) igt-debugfs-DEBUG: Opening debugfs directory '/sys/kernel/debug/dri/0'
(gem_userptr_blits:7104) intel-os-DEBUG: Test requirement passed: __intel_check_memory(count, size, mode, &required, &total)
(gem_userptr_blits:7104) igt-core-DEBUG: Test requirement passed: !igt_run_in_simulation()
(gem_userptr_blits:7104) drmtest-DEBUG: Test requirement passed: !(fd<0)
(gem_userptr_blits:7104) igt-debugfs-DEBUG: Opening debugfs directory '/sys/kernel/debug/dri/0'
(gem_userptr_blits:7104) DEBUG: Test requirement passed: pin > sz
(gem_userptr_blits:7104) DEBUG: Pinning [15433, 15689] MiB
****  END  ****
Comment 31 Elizabeth 2018-04-06 16:43:44 UTC
*tends
Comment 32 Abdiel Janulgue 2018-06-04 10:53:25 UTC
Had a stab at this problem. Crashes actually doesn't come from the i915 driver but rather core-mm triggering oom killer when the IGT process mlocks the whole available system memory.

In other words the kernel killed it for mlocking too much memory causing the test failure.

Now I understand that the purpose of test is to test i915's eviction mechanism. by forcing the creation BOs through a narrow memory window. I tried various memory locking size combos and it looks like we are still able to activate the eviction mechanism if we mlock the free system memory subtracted by 128MB.

Any thoughts Chris?
Comment 33 Abdiel Janulgue 2018-06-05 10:49:18 UTC
Created attachment 140031 [details] [review]
Proposed fix

Hi all,

Can someone try the attached IGT patch if it fixes the problem?
Comment 34 Francesco Balestrieri 2019-06-03 05:47:23 UTC
Given that there is no report from CI, and that based on Abdiel's comment the bug is not in the driver, I'm closing this.


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.