Bug 94241

Summary: Blanks screen on hibernation but does not switch off the machine
Product: Drivers Reporter: Martin Steigerwald (Martin)
Component: Video(DRI - Intel)Assignee: intel-gfx-bugs (intel-gfx-bugs)
Status: CLOSED UNREPRODUCIBLE    
Severity: normal CC: imre.deak, intel-gfx-bugs, itumaykin+kernel, rui.zhang, stefan.hoelldampf, ville.syrjala
Priority: P1    
Hardware: All   
OS: Linux   
Kernel Version: 4.0-rc2 Subsystem:
Regression: No Bisected commit-id:
Attachments: compressed kern.log with the traces not wordwrapped
kernel diff as I had the results from comment #4 with
acer-gen5.patch

Description Martin Steigerwald 2015-03-04 10:26:59 UTC
After I had [1] with 3.18 and 3.19 upto rc7, with 4.0-rc2 I get a different issue:

The ThinkPad T520 does not hibernate at all anymore. It blanks the screen, has some disk accesses, but then stays there. It stays on. It even seems to continue to have some disk accesses. But its not possible to switch on the display anymore. I tried the usual Ctrl-Alt-F1 to switch to TTY1 thing.

Expected results:

It goes to console as I have "no_console_suspend", tells me it will hibernate, gives out the 10% step progress report on saving the image, completes saving the image and switches off.


I am back on 3.19-rc7 as I need the machine for work. I do not foresee having time to bisect this at the moment. I may try with kernel 4.0-rc2 again and try to SSH into the machine from a different box. Maybe I can still log in to it in that black screen state.

This is on Debian Sid with systemd and the following hardware and software configuration:

martin@merkaba:~> phoronix-test-suite system-info

Phoronix Test Suite v5.2.1
System Information

Hardware:
Processor: Intel Core i5-2520M @ 3.20GHz (4 Cores), Motherboard: LENOVO 42433WG, Chipset: Intel 2nd Generation Core Family DRAM, Memory: 16384MB, Disk: 300GB INTEL SSDSA2CW30 + 480GB Crucial_CT480M50, Graphics: Intel HD 3000 (1300MHz), Audio: Intel 6 /C200, Network: Intel 82579LM Gigabit Connection + Intel Centrino Advanced-N 6205

Software:
OS: Debian 8.0, Kernel: 3.19.0-rc7-tp520+ (x86_64), Desktop: KDE 4.14.2, Display Server: X Server 1.16.4, Display Driver: intel 2.21.15, OpenGL: 3.3 Mesa 10.4.2, Compiler: GCC 4.9.2, File-System: btrfs, Screen Resolution: 1920x1080


[1] [Bug 86565] New: black screen after resume from hibernation since linux kernel 3.18
https://bugs.freedesktop.org/show_bug.cgi?id=86565

Thanks,
Martin
Comment 1 Jani Nikula 2015-03-04 11:23:58 UTC
Please try http://patchwork.freedesktop.org/patch/43731 or drm-intel-nightly branch of http://cgit.freedesktop.org/drm-intel.
Comment 2 Martin Steigerwald 2015-03-04 16:21:42 UTC
Patch does as applied on top of 4.0-rc2 not work. Screen still blanks and machine does not hibernate.

Can´t choose to reopen the bug, Bugzilla doesn´t offer me this option.
Comment 3 Ville Syrjala 2015-03-04 19:37:03 UTC
You have an snb so that patch is a nop actually.

Try this on top:

diff --git a/drivers/gpu/drm/i915/i915_drv.c b/drivers/gpu/drm/i915/i915_drv.c
index 15f58d0..cb281ec 100644
--- a/drivers/gpu/drm/i915/i915_drv.c
+++ b/drivers/gpu/drm/i915/i915_drv.c
@@ -656,7 +656,7 @@ static int i915_drm_suspend_late(struct drm_device *drm_dev, bool hibernation)
         */
        if (!(hibernation &&
              drm_dev->pdev->subsystem_vendor == PCI_VENDOR_ID_LENOVO &&
-             INTEL_INFO(dev_priv)->gen == 4))
+             INTEL_INFO(dev_priv)->gen < 7))
                pci_set_power_state(drm_dev->pdev, PCI_D3hot);
 
        return 0;

Although if the disk keeps going that would potentially indicate that the problem is somewhere else. If the patch fails, try to wait for at least 10 minutes after it appears to hang to see if it eventually finishes. I've occasioanlly had hibernate take approximately forever on my Lenovo X1 Carbon (ivb) and some specific kernel version. It would finish eventually though. Never had the time to figure out what was going on there.
Comment 4 Martin Steigerwald 2015-03-05 08:18:51 UTC
With 4.0-rc2 and the patch from comment #3 added on top of the patch from comment #1 the machine hibernates nicely. On resuming I still get[1] tough so that bug is not yet fixed. I will add info there as well.

But still this is not production ready. When I try to open my work related X session in addition to the private one by using Plasma new session feature which brings up a kdm display manager on tty8, I get a black screen and

Mar  5 08:57:41 merkaba kernel: [  858.106735] ------------[ cut here ]------------
Mar  5 08:57:41 merkaba kernel: [  858.106753] WARNING: CPU: 2 PID: 1765 at drivers/gpu/drm/i915/i915_gem.c:4284 i915_gem_object_unpin_fence+0x54/0x73()
Mar  5 08:57:41 merkaba kernel: [  858.106757] WARN_ON(dev_priv->fence_regs[obj->fence_reg].pin_count <= 0)
Mar  5 08:57:41 merkaba kernel: [  858.106837] Modules linked in: binfmt_misc bnep bluetooth cpufreq_userspace cpufreq_stats cpufreq_powersave cpufreq_conservative msr ext4 crc16 mbcache jbd2 snd_usb_audio snd_usbmidi_lib snd_rawmidi snd_seq_device x86_pkg_temp_thermal intel_powerclamp kvm_intel snd_hda_codec_hdmi kvm crct10dif_pclmul crc32_pclmul snd_hda_codec_conexant snd_hda_codec_generic ghash_clmulni_intel iwldvm mac80211 snd_hda_intel snd_hda_controller aesni_intel aes_x86_64 snd_hda_codec iwlwifi lrw gf128mul snd_hwdep psmouse pcspkr glue_helper serio_raw i2c_i801 ablk_helper cryptd snd_pcm thinkpad_acpi snd_timer nvram cfg80211 snd rfkill tpm_tis lpc_ich mfd_core soundcore shpchp battery ac tpm evdev joydev processor sbs sbshc coretemp hdaps(O) tp_smapi(O) thinkpad_ec(O) loop firewire_sbp2 fuse ecryptfs autofs4 md_mod btrfs xor raid6_pq microcode dm_mirror dm_region_hash dm_log dm_mod sg sr_mod cdrom sd_mod hid_generic usbhid hid crc32c_intel firewire_ohci sata_sil24 ahci sdhci_pci sdhci libahci firewire_core mmc_core crc_itu_t libata scsi_mod ehci_pci ehci_hcd e1000e usbcore ptp pps_core usb_common thermal
Mar  5 08:57:41 merkaba kernel: [  858.106879] CPU: 2 PID: 1765 Comm: Xorg Tainted: G           O    4.0.0-rc2-tp520-btrfs-trim-i915-hib2+ #22
Mar  5 08:57:41 merkaba kernel: [  858.106881] Hardware name: LENOVO 42433WG/42433WG, BIOS 8AET63WW (1.43 ) 05/08/2013
Mar  5 08:57:41 merkaba kernel: [  858.106887]  0000000000000009 ffff8803ffe476c8 ffffffff814c01db 0000000080000000
Mar  5 08:57:41 merkaba kernel: [  858.106891]  ffff8803ffe47718 ffff8803ffe47708 ffffffff81040ce5 ffff8803ffe476f8
Mar  5 08:57:41 merkaba kernel: [  858.106895]  ffffffff8131ed9c ffff880409cb0000 ffff880409c69180 ffffffff8168a9b0
Mar  5 08:57:41 merkaba kernel: [  858.106897] Call Trace:
Mar  5 08:57:41 merkaba kernel: [  858.106907]  [<ffffffff814c01db>] dump_stack+0x4f/0x7b
Mar  5 08:57:41 merkaba kernel: [  858.106915]  [<ffffffff81040ce5>] warn_slowpath_common+0x9c/0xb6
Mar  5 08:57:41 merkaba kernel: [  858.106922]  [<ffffffff8131ed9c>] ? i915_gem_object_unpin_fence+0x54/0x73
Mar  5 08:57:41 merkaba kernel: [  858.106927]  [<ffffffff81040d40>] warn_slowpath_fmt+0x41/0x43
Mar  5 08:57:41 merkaba kernel: [  858.106933]  [<ffffffff8131ed9c>] i915_gem_object_unpin_fence+0x54/0x73
Mar  5 08:57:41 merkaba kernel: [  858.106939]  [<ffffffff8134a5aa>] intel_unpin_fb_obj+0x36/0x42
Mar  5 08:57:41 merkaba kernel: [  858.106945]  [<ffffffff81353cb6>] intel_cleanup_plane_fb+0x5e/0x6b
Mar  5 08:57:41 merkaba kernel: [  858.106953]  [<ffffffff812d8c99>] drm_plane_helper_commit+0x1ca/0x22a
Mar  5 08:57:41 merkaba kernel: [  858.106958]  [<ffffffff812d8daf>] drm_plane_helper_update+0xb6/0xc5
Mar  5 08:57:41 merkaba kernel: [  858.106964]  [<ffffffff8134dd81>] __intel_set_mode+0x7af/0x84f
Mar  5 08:57:41 merkaba kernel: [  858.106971]  [<ffffffff81353960>] intel_crtc_set_config+0xa2b/0xb85
Mar  5 08:57:41 merkaba kernel: [  858.106978]  [<ffffffff812dda88>] ? drm_atomic_helper_plane_set_property+0x6e/0xa7
Mar  5 08:57:41 merkaba kernel: [  858.106985]  [<ffffffff812edee5>] drm_mode_set_config_internal+0x57/0xe3
Mar  5 08:57:41 merkaba kernel: [  858.106991]  [<ffffffff812df167>] restore_fbdev_mode+0xb5/0xcf
Mar  5 08:57:41 merkaba kernel: [  858.106998]  [<ffffffff812e0a4b>] drm_fb_helper_restore_fbdev_mode_unlocked+0x22/0x59
Mar  5 08:57:41 merkaba kernel: [  858.107004]  [<ffffffff812e0ab3>] drm_fb_helper_set_par+0x31/0x35
Mar  5 08:57:41 merkaba kernel: [  858.107009]  [<ffffffff8135f6e9>] intel_fbdev_set_par+0x15/0x58
Mar  5 08:57:41 merkaba kernel: [  858.107015]  [<ffffffff812df765>] ? drm_fb_helper_pan_display+0xd3/0xd3
Mar  5 08:57:41 merkaba kernel: [  858.107020]  [<ffffffff81262b45>] fb_set_var+0x29b/0x38d
Mar  5 08:57:41 merkaba kernel: [  858.107026]  [<ffffffff81064710>] ? task_group_account_field+0x3b/0x42
Mar  5 08:57:41 merkaba kernel: [  858.107033]  [<ffffffff810bfeb7>] ? acct_account_cputime+0x17/0x19
Mar  5 08:57:41 merkaba kernel: [  858.107037]  [<ffffffff810649dd>] ? account_system_time+0xf7/0x127
Mar  5 08:57:41 merkaba kernel: [  858.107046]  [<ffffffff8125ac70>] fbcon_blank+0x7e/0x1ef
Mar  5 08:57:41 merkaba kernel: [  858.107052]  [<ffffffff8105eae6>] ? wake_up_nohz_cpu+0x24/0x4f
Mar  5 08:57:41 merkaba kernel: [  858.107061]  [<ffffffff812b4315>] do_unblank_screen+0xd3/0x141
Mar  5 08:57:41 merkaba kernel: [  858.107065]  [<ffffffff812abe73>] complete_change_console+0x52/0xc2
Mar  5 08:57:41 merkaba kernel: [  858.107069]  [<ffffffff812acdd1>] vt_ioctl+0xeee/0x1183
Mar  5 08:57:41 merkaba kernel: [  858.107074]  [<ffffffff812e8e41>] ? drm_dropmaster_ioctl+0x6b/0x77
Mar  5 08:57:41 merkaba kernel: [  858.107080]  [<ffffffff812a2cd3>] tty_ioctl+0xa4d/0xac4
Mar  5 08:57:41 merkaba kernel: [  858.107086]  [<ffffffff81072ffe>] ? cpuacct_account_field+0x56/0x5f
Mar  5 08:57:41 merkaba kernel: [  858.107091]  [<ffffffff81072ffe>] ? cpuacct_account_field+0x56/0x5f
Mar  5 08:57:41 merkaba kernel: [  858.107098]  [<ffffffff8114c4a3>] do_vfs_ioctl+0x372/0x420
Mar  5 08:57:41 merkaba kernel: [  858.107104]  [<ffffffff81224f5f>] ? __this_cpu_preempt_check+0x13/0x15
Mar  5 08:57:41 merkaba kernel: [  858.107109]  [<ffffffff811543a2>] ? __fget_light+0x28/0x4a
Mar  5 08:57:41 merkaba kernel: [  858.107113]  [<ffffffff8114c5a6>] SyS_ioctl+0x55/0x7a
Mar  5 08:57:41 merkaba kernel: [  858.107119]  [<ffffffff814c516e>] ? int_check_syscall_exit_work+0x34/0x3d
Mar  5 08:57:41 merkaba kernel: [  858.107123]  [<ffffffff814c4f52>] system_call_fastpath+0x12/0x17
Mar  5 08:57:41 merkaba kernel: [  858.107127] ---[ end trace d1be13ce503177cf ]---
Mar  5 08:57:41 merkaba kernel: [  858.107148] ------------[ cut here ]------------
Mar  5 08:57:41 merkaba kernel: [  858.107150] kernel BUG at drivers/gpu/drm/i915/i915_gem.c:4256!
Mar  5 08:57:41 merkaba kernel: [  858.107155] invalid opcode: 0000 [#1] PREEMPT SMP 
Mar  5 08:57:41 merkaba kernel: [  858.107216] Modules linked in: binfmt_misc bnep bluetooth cpufreq_userspace cpufreq_stats cpufreq_powersave cpufreq_conservative msr ext4 crc16 mbcache jbd2 snd_usb_audio snd_usbmidi_lib snd_rawmidi snd_seq_device x86_pkg_temp_thermal intel_powerclamp kvm_intel snd_hda_codec_hdmi kvm crct10dif_pclmul crc32_pclmul snd_hda_codec_conexant snd_hda_codec_generic ghash_clmulni_intel iwldvm mac80211 snd_hda_intel snd_hda_controller aesni_intel aes_x86_64 snd_hda_codec iwlwifi lrw gf128mul snd_hwdep psmouse pcspkr glue_helper serio_raw i2c_i801 ablk_helper cryptd snd_pcm thinkpad_acpi snd_timer nvram cfg80211 snd rfkill tpm_tis lpc_ich mfd_core soundcore shpchp battery ac tpm evdev joydev processor sbs sbshc coretemp hdaps(O) tp_smapi(O) thinkpad_ec(O) loop firewire_sbp2 fuse ecryptfs autofs4 md_mod btrfs xor raid6_pq microcode dm_mirror dm_region_hash dm_log dm_mod sg sr_mod cdrom sd_mod hid_generic usbhid hid crc32c_intel firewire_ohci sata_sil24 ahci sdhci_pci sdhci libahci firewire_core mmc_core crc_itu_t libata scsi_mod ehci_pci ehci_hcd e1000e usbcore ptp pps_core usb_common thermal
Mar  5 08:57:41 merkaba kernel: [  858.107247] CPU: 2 PID: 1765 Comm: Xorg Tainted: G        W  O    4.0.0-rc2-tp520-btrfs-trim-i915-hib2+ #22
Mar  5 08:57:41 merkaba kernel: [  858.107249] Hardware name: LENOVO 42433WG/42433WG, BIOS 8AET63WW (1.43 ) 05/08/2013
Mar  5 08:57:41 merkaba kernel: [  858.107251] task: ffff8800ce0a9890 ti: ffff8803ffe44000 task.ti: ffff8803ffe44000
Mar  5 08:57:41 merkaba kernel: [  858.107258] RIP: 0010:[<ffffffff813227e0>]  [<ffffffff813227e0>] i915_gem_object_ggtt_unpin+0x2c/0x76
Mar  5 08:57:41 merkaba kernel: [  858.107260] RSP: 0018:ffff8803ffe47750  EFLAGS: 00010246
Mar  5 08:57:41 merkaba kernel: [  858.107262] RAX: ffff88040a78fb00 RBX: ffff880409c69100 RCX: ffff88040a78fb80
Mar  5 08:57:41 merkaba kernel: [  858.107264] RDX: ffff880409cb7e08 RSI: 00000000ffffffff RDI: ffff880409c69240
Mar  5 08:57:41 merkaba kernel: [  858.107266] RBP: ffff8803ffe47770 R08: 0000000000000000 R09: 0000000000000000
Mar  5 08:57:41 merkaba kernel: [  858.107268] R10: 0000000000000864 R11: ffffffff81bf1d44 R12: ffff880409c69100
Mar  5 08:57:41 merkaba kernel: [  858.107270] R13: ffff880409c69180 R14: ffff88040a78fb00 R15: 0000000000000010
Mar  5 08:57:41 merkaba kernel: [  858.107273] FS:  00007f7b3b62f980(0000) GS:ffff88041e300000(0000) knlGS:0000000000000000
Mar  5 08:57:41 merkaba kernel: [  858.107276] CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
Mar  5 08:57:41 merkaba kernel: [  858.107278] CR2: 00007f307ad3a000 CR3: 00000004025e5000 CR4: 00000000000406e0
Mar  5 08:57:41 merkaba kernel: [  858.107280] Stack:
Mar  5 08:57:41 merkaba kernel: [  858.107284]  ffff880409c69180 ffff880409c69180 ffffffff8168a9b0 ffff8800c7d24b40
Mar  5 08:57:41 merkaba kernel: [  858.107287]  ffff8803ffe47788 ffffffff81323393 ffff880409c69180 ffff8803ffe477a8
Mar  5 08:57:41 merkaba kernel: [  858.107291]  ffffffff8134a5b2 ffff88040bbc7000 ffff880409c71060 ffff8803ffe477c8
Mar  5 08:57:41 merkaba kernel: [  858.107292] Call Trace:
Mar  5 08:57:41 merkaba kernel: [  858.107298]  [<ffffffff81323393>] i915_gem_object_unpin_from_display_plane+0xd/0x3a
Mar  5 08:57:41 merkaba kernel: [  858.107303]  [<ffffffff8134a5b2>] intel_unpin_fb_obj+0x3e/0x42
Mar  5 08:57:41 merkaba kernel: [  858.107308]  [<ffffffff81353cb6>] intel_cleanup_plane_fb+0x5e/0x6b
Mar  5 08:57:41 merkaba kernel: [  858.107313]  [<ffffffff812d8c99>] drm_plane_helper_commit+0x1ca/0x22a
Mar  5 08:57:41 merkaba kernel: [  858.107318]  [<ffffffff812d8daf>] drm_plane_helper_update+0xb6/0xc5
Mar  5 08:57:41 merkaba kernel: [  858.107324]  [<ffffffff8134dd81>] __intel_set_mode+0x7af/0x84f
Mar  5 08:57:41 merkaba kernel: [  858.107331]  [<ffffffff81353960>] intel_crtc_set_config+0xa2b/0xb85
Mar  5 08:57:41 merkaba kernel: [  858.107337]  [<ffffffff812dda88>] ? drm_atomic_helper_plane_set_property+0x6e/0xa7
Mar  5 08:57:41 merkaba kernel: [  858.107342]  [<ffffffff812edee5>] drm_mode_set_config_internal+0x57/0xe3
Mar  5 08:57:41 merkaba kernel: [  858.107348]  [<ffffffff812df167>] restore_fbdev_mode+0xb5/0xcf
Mar  5 08:57:41 merkaba kernel: [  858.107354]  [<ffffffff812e0a4b>] drm_fb_helper_restore_fbdev_mode_unlocked+0x22/0x59
Mar  5 08:57:41 merkaba kernel: [  858.107360]  [<ffffffff812e0ab3>] drm_fb_helper_set_par+0x31/0x35
Mar  5 08:57:41 merkaba kernel: [  858.107364]  [<ffffffff8135f6e9>] intel_fbdev_set_par+0x15/0x58
Mar  5 08:57:41 merkaba kernel: [  858.107369]  [<ffffffff812df765>] ? drm_fb_helper_pan_display+0xd3/0xd3
Mar  5 08:57:41 merkaba kernel: [  858.107373]  [<ffffffff81262b45>] fb_set_var+0x29b/0x38d
Mar  5 08:57:41 merkaba kernel: [  858.107377]  [<ffffffff81064710>] ? task_group_account_field+0x3b/0x42
Mar  5 08:57:41 merkaba kernel: [  858.107383]  [<ffffffff810bfeb7>] ? acct_account_cputime+0x17/0x19
Mar  5 08:57:41 merkaba kernel: [  858.107387]  [<ffffffff810649dd>] ? account_system_time+0xf7/0x127
Mar  5 08:57:41 merkaba kernel: [  858.107394]  [<ffffffff8125ac70>] fbcon_blank+0x7e/0x1ef
Mar  5 08:57:41 merkaba kernel: [  858.107398]  [<ffffffff8105eae6>] ? wake_up_nohz_cpu+0x24/0x4f
Mar  5 08:57:41 merkaba kernel: [  858.107406]  [<ffffffff812b4315>] do_unblank_screen+0xd3/0x141
Mar  5 08:57:41 merkaba kernel: [  858.107409]  [<ffffffff812abe73>] complete_change_console+0x52/0xc2
Mar  5 08:57:41 merkaba kernel: [  858.107413]  [<ffffffff812acdd1>] vt_ioctl+0xeee/0x1183
Mar  5 08:57:41 merkaba kernel: [  858.107418]  [<ffffffff812e8e41>] ? drm_dropmaster_ioctl+0x6b/0x77
Mar  5 08:57:41 merkaba kernel: [  858.107422]  [<ffffffff812a2cd3>] tty_ioctl+0xa4d/0xac4
Mar  5 08:57:41 merkaba kernel: [  858.107426]  [<ffffffff81072ffe>] ? cpuacct_account_field+0x56/0x5f
Mar  5 08:57:41 merkaba kernel: [  858.107431]  [<ffffffff81072ffe>] ? cpuacct_account_field+0x56/0x5f
Mar  5 08:57:41 merkaba kernel: [  858.107436]  [<ffffffff8114c4a3>] do_vfs_ioctl+0x372/0x420
Mar  5 08:57:41 merkaba kernel: [  858.107440]  [<ffffffff81224f5f>] ? __this_cpu_preempt_check+0x13/0x15
Mar  5 08:57:41 merkaba kernel: [  858.107445]  [<ffffffff811543a2>] ? __fget_light+0x28/0x4a
Mar  5 08:57:41 merkaba kernel: [  858.107449]  [<ffffffff8114c5a6>] SyS_ioctl+0x55/0x7a
Mar  5 08:57:41 merkaba kernel: [  858.107453]  [<ffffffff814c516e>] ? int_check_syscall_exit_work+0x34/0x3d
Mar  5 08:57:41 merkaba kernel: [  858.107458]  [<ffffffff814c4f52>] system_call_fastpath+0x12/0x17
Mar  5 08:57:41 merkaba kernel: [  858.107501] Code: 48 89 e5 41 56 41 55 49 89 fd 41 54 53 e8 94 fc ff ff 48 85 c0 49 89 c6 75 02 0f 0b 8a 98 c0 00 00 00 41 88 dc 41 80 e4 0f 75 02 <0f> 0b 49 8b 45 08 31 d2 4c 89 ef 48 8b 70 28 48 81 c6 08 7e 00 
Mar  5 08:57:41 merkaba kernel: [  858.107506] RIP  [<ffffffff813227e0>] i915_gem_object_ggtt_unpin+0x2c/0x76
Mar  5 08:57:41 merkaba kernel: [  858.107507]  RSP <ffff8803ffe47750>
Mar  5 08:57:41 merkaba kernel: [  858.107556] ---[ end trace d1be13ce503177d0 ]---

I was able to SSH into the machine, but an

export DISPLAY=:0
xbacklight -get

didn´t return to the shell prompt anymore.

With 3.19-rc7 its no problem to open a second Plasma/KDE session, so back at this version once again.

I remember some other more low level blacklight related command, but didn´t remember its exact name so I just did a apt-cache search backlight and came up with xbacklight.


Do you want me to open a new bug report about this one? Or do we handle it here still?

I think thats even another issue and I suggest you try to get a hold of a used Intel based ThinkPad T520 at Intel Open Source center as it can help you to find and close three bugs already. Okay, one of it apparently seems closed with the both patches in there.

Next time I can test another patch would not be before tomorrow morning.

[1] [Bug 86565] New: black screen after resume from hibernation since linux kernel 3.18
https://bugs.freedesktop.org/show_bug.cgi?id=86565
Comment 5 Martin Steigerwald 2015-03-05 08:32:12 UTC
Created attachment 169171 [details]
compressed kern.log with the traces not wordwrapped

As bugzilla thinks its a wise idea to word-wrap the kernel log I add it here as attachment.

This also contains some interesting traces from yesterday as I suspended the 3.19-rc7 kernel. But it also contains the traces I posted a comment ago with the 4.0-rc2 kernel. I will post the exact diff against linus 4.0-rc2 in next comment for reference.
Comment 6 Martin Steigerwald 2015-03-05 08:34:14 UTC
Created attachment 169181 [details]
kernel diff as I had the results from comment #4 with

This is the diff that produced the result I described in comment #4. Except for a BTRFS SSD trimming fix it carries the patches I mentioned in comment #4.
Comment 7 Martin Steigerwald 2015-03-09 16:26:18 UTC
Any idea regarding the issue in comment #4?

Not sure whether its the same bug, as the hibernating worked with the kernel diff from comment #6.
Comment 8 Coacher 2015-03-27 02:23:26 UTC
Created attachment 172481 [details]
acer-gen5.patch

Hello.

I also experience this issue since 3.19.0 on my machine, which is the Acer Aspire 1830T laptop with Ironlake i3-330UM. The symptoms are exactly as described in the comment #0 or at http://lists.freedesktop.org/archives/intel-gfx/2015-February/060633.html.

I've adjusted the solution from http://patchwork.freedesktop.org/patch/43731/ to cover my hardware (Gen5 + PCI_VENDOR_ID_AI) and I can confirm that the hibernation/thaw cycle works properly with it. I do not have any problems similar to those described in the comment #4, but an error appears in dmesg during the hibernation:

kern  :info  : [ 1108.276140] PM: Syncing filesystems ...
kern  :err   : [ 1108.292664] [drm:ironlake_irq_handler [i915]] *ERROR* PCH transcoder A FIFO underrun
kern  :warn  : [ 1108.391303] done.
kern  :warn  : [ 1108.391315] Freezing user space processes ... (elapsed 0.407 seconds) done.

The rest of the hibernation process completes without any errors or warnings. I've attached the patch (against linux-stable:v3.19.3) I've used though it is very simple.
Comment 9 Martin Steigerwald 2015-03-27 10:16:56 UTC
Hello Ilya, thanks for your comment. Does this also work for you with 4.0? I am still on 3.19 due to issue in comment #4. I have seen some drm fixes pulls for 4.0. I would try 4.0 + your patch if there is a realistic chance that it can work. So if 4.0 + your patch works nicely for you, I think I give it a try. Thanks, Martin
Comment 10 Coacher 2015-03-27 15:53:16 UTC
(In reply to Martin Steigerwald from comment #9)
> Hello Ilya, thanks for your comment. Does this also work for you with 4.0? I
> am still on 3.19 due to issue in comment #4. I have seen some drm fixes
> pulls for 4.0. I would try 4.0 + your patch if there is a realistic chance
> that it can work. So if 4.0 + your patch works nicely for you, I think I
> give it a try. Thanks, Martin

I have not tested it with 4.0, but I will try during the weekend. Also I don't think my patch would help you. And here is why. Changes from http://patchwork.freedesktop.org/patch/43731/ introduced a workaround for Lenovo machines with Gen4 Intel graphics. My patch simply extends this workaround to be applied for Acer machines with Gen5 Intel graphics as well. From the discussion above I can see that you have a Lenovo laptop with non-Gen4 Intel graphics, so unfortunately my patch cannot help you in any way.
Comment 11 Coacher 2015-04-13 11:19:07 UTC
(In reply to Ilya Tumaykin from comment #8)
> Created attachment 172481 [details]
> acer-gen5.patch

This patch also successfully applies on top of 4.0 vanilla kernel. Can it be merged into mainline kernel, please?
Comment 12 Martin Steigerwald 2015-04-25 12:41:29 UTC
I still have this issue with 4.0 vanilla kernel. But I am not allowed to reopen this, this is still not solved.

Is there any patch I can try? Is there any information you are still missing?
Comment 13 Imre Deak 2015-06-17 17:29:39 UTC
(In reply to Martin Steigerwald from comment #12)
> I still have this issue with 4.0 vanilla kernel. But I am not allowed to
> reopen this, this is still not solved.
> 
> Is there any patch I can try? Is there any information you are still missing?

Martin, could you double check if the patch from comment #3 makes a difference for you? Based on your reports you may have unrelated issues preventing hibernate, so I'd like to know if the one fixed by the above patch is really affecting you. Based on your answer we could limit the workaround to <GEN7 or <GEN6.

Thanks.
Comment 14 Martin Steigerwald 2015-06-18 18:58:29 UTC
Imre, thank you for your follow-up.

I don´t see this issue since some time, now using 4.1-rc8. So I bet it has been fixed meanwhile.