How to troubleshoot sleep issues

Hi all,
I’m having difficulty reliably suspending to RAM on OpenSUSE 15.0 x64 on my Thinkpad T440p. Every 1 in 10 attempts, it sleeps properly. I have tried sleeping through KDE, systemctl suspend, and closing the lid. Suspending to disk/hibernating works fine every time.

When I try to put the machine to sleep, the screen goes to black (backlight still on) and the mouse is the only thing showing. Then a few seconds or even minutes later the mouse disappears but the machine is still on. If I press a key at this time, then it takes a minute or two but the machine will go to the KDE lockscreen and act as if it had been sleeping (it even prompts to re-unlock GPG for WiFi passwords).

I’m not sure how to begin troubleshooting this. Will anything show up in the systemctl journal/log? What should I look for?

Thanks!
DaAwesomeP

Usually a graphics-related issue. Graphics hardware and driver details?

Thank you for your response! Here’s some info I’ve gathered:

CPU info (only the first thread):


$ cat /proc/cpuinfo
processor       : 0
vendor_id       : GenuineIntel
cpu family      : 6
model           : 60
model name      : Intel(R) Core(TM) i7-4600M CPU @ 2.90GHz
stepping        : 3
microcode       : 0x25
cpu MHz         : 2893.582
cache size      : 4096 KB
physical id     : 0
siblings        : 4
core id         : 0
cpu cores       : 2
apicid          : 0
initial apicid  : 0
fpu             : yes
fpu_exception   : yes
cpuid level     : 13
wp              : yes
flags           : fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 clflush dts acpi mmx fxsr sse sse2 ss ht tm pbe syscall nx pdpe1gb rdtscp lm constant_tsc arch_perfmon pebs bts rep_good nopl xtopology nonstop_tsc cpuid aperfmperf pni pclmulqdq dtes64 monitor ds_cpl vmx smx est tm2 ssse3 sdbg fma cx16 xtpr pdcm pcid sse4_1 sse4_2 x2apic movbe popcnt tsc_deadline_timer aes xsave avx f16c rdrand lahf_lm abm cpuid_fault epb invpcid_single pti ssbd ibrs ibpb stibp tpr_shadow vnmi flexpriority ept vpid fsgsbase tsc_adjust bmi1 avx2 smep bmi2 erms invpcid xsaveopt dtherm ida arat pln pts flush_l1d
bugs            : cpu_meltdown spectre_v1 spectre_v2 spec_store_bypass l1tf
bogomips        : 5787.16
clflush size    : 64
cache_alignment : 64
address sizes   : 39 bits physical, 48 bits virtual
power management:

...

From lspci:


00:02.0 VGA compatible controller: Intel Corporation 4th Gen Core Processor Integrated Graphics Controller (rev 06) (prog-if 00 [VGA controller])
        Subsystem: Lenovo ThinkPad T440p
        Flags: bus master, fast devsel, latency 0, IRQ 29
        Memory at e0000000 (64-bit, non-prefetchable) [size=4]
        Memory at c0000000 (64-bit, prefetchable) [size=512]
        I/O ports at 3000 [size=64]
        [virtual] Expansion ROM at 000c0000 [disabled] [size=128]
        Capabilities: <access denied>
        Kernel driver in use: i915
        Kernel modules: i915

Relevant packages (at least that I know of):


intel-vaapi-driver-2.0.0-lp150.1.7.x86_64

modinfo for i915:


# modinfo -p i915
modeset:Use kernel modesetting [KMS] (0=disable, 1=on, -1=force vga console preference [default]) (int)
panel_ignore_lid:Override lid status (0=autodetect, 1=autodetect disabled [default], -1=force lid closed, -2=force lid open) (int)
enable_dc:Enable power-saving display C-states. (-1=auto [default]; 0=disable; 1=up to DC5; 2=up to DC6) (int)
enable_fbc:Enable frame buffer compression for power savings (default: -1 (use per-chip default)) (int)
lvds_channel_mode:Specify LVDS channel mode (0=probe BIOS [default], 1=single-channel, 2=dual-channel) (int)
panel_use_ssc:Use Spread Spectrum Clock with panels [LVDS/eDP] (default: auto from VBT) (int)
vbt_sdvo_panel_type:Override/Ignore selection of SDVO panel mode in the VBT (-2=ignore, -1=auto [default], index in VBT BIOS table) (int)
reset:Attempt GPU resets (0=disabled, 1=full gpu reset, 2=engine reset [default]) (int)
vbt_firmware:Load VBT from specified file under /lib/firmware (charp)
error_capture:Record the GPU state following a hang. This information in /sys/class/drm/card<N>/error is vital for triaging and debugging hangs. (bool)
enable_hangcheck:Periodically check GPU activity for detecting hangs. WARNING: Disabling this can cause system wide hangs. (default: true) (bool)
enable_ppgtt:Override PPGTT usage. (-1=auto [default], 0=disabled, 1=aliasing, 2=full, 3=full with extended address space) (int)
enable_psr:Enable PSR (0=disabled, 1=enabled - link mode chosen per-platform, 2=force link-standby mode, 3=force link-off mode) Default: -1 (use per-chip default) (int)
alpha_support:Enable alpha quality driver support for latest hardware. See also CONFIG_DRM_I915_ALPHA_SUPPORT. (bool)
disable_power_well:Disable display power wells when possible (-1=auto [default], 0=power wells always on, 1=power wells disabled when possible) (int)
enable_ips:Enable IPS (default: true) (int)
fastboot:Try to skip unnecessary mode sets at boot time (default: false) (bool)
prefault_disable:Disable page prefaulting for pread/pwrite/reloc (default:false). For developers only. (bool)
load_detect_test:Force-enable the VGA load detect code for testing (default:false). For developers only. (bool)
force_reset_modeset_test:Force a modeset during gpu reset for testing (default:false). For developers only. (bool)
invert_brightness:Invert backlight brightness (-1 force normal, 0 machine defaults, 1 force inversion), please report PCI device ID, subsystem vendor and subsystem device ID to dri-devel@lists.freedesktop.org, if your machine needs it. It will then be included in an upcoming module version. (int)
disable_display:Disable display (default: false) (bool)
enable_cmd_parser:Enable command parsing (true=enabled [default], false=disabled) (bool)
mmio_debug:Enable the MMIO debug code for the first N failures (default: off). This may negatively affect performance. (int)
verbose_state_checks:Enable verbose logs (ie. WARN_ON()) in case of unexpected hw state conditions. (bool)
nuclear_pageflip:Force enable atomic functionality on platforms that don't have full support yet. (bool)
edp_vswing:Ignore/Override vswing pre-emph table selection from VBT (0=use value from vbt [default], 1=low power swing(200mV),2=default swing(400mV)) (int)
enable_guc:Enable GuC load for GuC submission and/or HuC load. Required functionality can be selected using bitmask values. (-1=auto, 0=disable [default], 1=GuC submission, 2=HuC load) (int)
guc_log_level:GuC firmware logging level (-1:disabled (default), 0-3:enabled) (int)
guc_firmware_path:GuC firmware path to use instead of the default one (charp)
huc_firmware_path:HuC firmware path to use instead of the default one (charp)
enable_dp_mst:Enable multi-stream transport (MST) for new DisplayPort sinks. (default: true) (bool)
inject_load_failure:Force an error after a number of failure check points (0:disabled (default), N:force failure at the Nth failure check point) (uint)
enable_dpcd_backlight:Enable support for DPCD backlight control (default:false) (bool)
enable_gvt:Enable support for Intel GVT-g graphics virtualization host support(default:false) (bool)

sysinfo for i915:


$ systool -m i915 -av
Module = "i915"

  Attributes:
    coresize            = "1953792"
    initsize            = "0"
    initstate           = "live"
    refcnt              = "33"
    srcversion          = "DD27E5B31C2E6B533941188"
    taint               = ""
    uevent              = <store method only>

  Parameters:
    enable_hangcheck    = "Y"

  Sections:
    .altinstr_aux       = "0x0000000000000000"
    .altinstr_replacement= "0x0000000000000000"
    .altinstructions    = "0x0000000000000000"
    .bss                = "0x0000000000000000"
    .data..cacheline_aligned= "0x0000000000000000"
    .data..read_mostly  = "0x0000000000000000"
    .data.unlikely      = "0x0000000000000000"
    .data               = "0x0000000000000000"
    .exit.text          = "0x0000000000000000"
    .fixup              = "0x0000000000000000"
    .gnu.linkonce.this_module= "0x0000000000000000"
    .init.text          = "0x0000000000000000"
    .note.gnu.build-id  = "0x0000000000000000"
    .orc_unwind         = "0x0000000000000000"
    .orc_unwind_ip      = "0x0000000000000000"
    .parainstructions   = "0x0000000000000000"
    .ref.data           = "0x0000000000000000"
    .rodata.str1.1      = "0x0000000000000000"
    .rodata.str1.8      = "0x0000000000000000"
    .rodata             = "0x0000000000000000"
    .smp_locks          = "0x0000000000000000"
    .strtab             = "0x0000000000000000"
    .symtab             = "0x0000000000000000"
    .text               = "0x0000000000000000"
    .text.unlikely      = "0x0000000000000000"
    __bug_table         = "0x0000000000000000"
    __ex_table          = "0x0000000000000000"
    __jump_table        = "0x0000000000000000"
    __kcrctab_gpl       = "0x0000000000000000"
    __ksymtab_gpl       = "0x0000000000000000"
    __ksymtab_strings   = "0x0000000000000000"
    __mcount_loc        = "0x0000000000000000"
    __param             = "0x0000000000000000"
    __tracepoints_ptrs  = "0x0000000000000000"
    __tracepoints       = "0x0000000000000000"
    __tracepoints_strings= "0x0000000000000000"
    __verbose           = "0x0000000000000000"
    _ftrace_events      = "0x0000000000000000"

That’s everything that I could think of. Let me know if you need anything else.[/size][/size][/size][/size]

That’s everything that I could think of. Let me know if you need anything else.

Perhaps these…

cat /proc/cmdline
dmesg|grep acpi

Sure!


$ cat /proc/cmdline
BOOT_IMAGE=/boot/vmlinuz-4.12.14-lp150.12.16-default root=/dev/mapper/system-root resume=/dev/system/swap splash=silent quiet showopts


$ dmesg|grep acpi
    0.000000] ACPI: LAPIC_NMI (acpi_id[0x00] high edge lint[0x1])
    0.000000] ACPI: LAPIC_NMI (acpi_id[0x01] high edge lint[0x1])
    0.105934] acpiphp: ACPI Hot Plug PCI Controller Driver version: 0.5
    0.127012] acpi LNXIOBAY:00: ACPI dock station (docks/bays count: 1)
    0.130543] acpi PNP0A08:00: _OSC: OS supports [ExtendedConfig ASPM ClockPM Segments MSI]
    0.130680] acpi PNP0A08:00: _OSC: platform does not support [PCIeCapability]
    0.130742] acpi PNP0A08:00: _OSC: not requesting control; platform does not support [PCIeCapability]
    0.130744] acpi PNP0A08:00: _OSC: OS requested [PCIeHotplug PME AER PCIeCapability]
    0.130745] acpi PNP0A08:00: _OSC: platform willing to grant [PCIeHotplug PME AER]
    0.130746] acpi PNP0A08:00: _OSC failed (AE_SUPPORT); disabling ASPM
    0.187599] clocksource: acpi_pm: mask: 0xffffff max_cycles: 0xffffff, max_idle_ns: 2085701024 ns
    1.680425] acpi device:2c: hash matches
    6.482943] thinkpad_acpi: ThinkPad ACPI Extras v0.25
    6.482944] thinkpad_acpi: http://ibm-acpi.sf.net/
    6.482945] thinkpad_acpi: ThinkPad BIOS GLET96WW (2.50 ), EC unknown
    6.482946] thinkpad_acpi: Lenovo ThinkPad T440p, model 20ANCTO1WW
    6.484111] thinkpad_acpi: radio switch found; radios are enabled
    6.484126] thinkpad_acpi: This ThinkPad has standard ACPI backlight brightness control, supported by the ACPI video driver
    6.484127] thinkpad_acpi: Disabling thinkpad-acpi brightness events by default...
    6.498122] thinkpad_acpi: rfkill switch tpacpi_bluetooth_sw: radio is unblocked
    6.532683] input: ThinkPad Extra Buttons as /devices/platform/thinkpad_acpi/input/input11
[11789.728211] thinkpad_acpi: EC reports that Thermal Table has changed
[13144.493219] thinkpad_acpi: EC reports that Thermal Table has changed
[15219.303778] acpi LNXPOWER:02: Turning OFF
[15244.403130] thinkpad_acpi: EC reports that Thermal Table has changed
[15245.950162] acpi LNXPOWER:02: Turning OFF
[26916.233255] acpi LNXPOWER:02: Turning OFF
[30183.267972] acpi LNXPOWER:02: Turning OFF
[30905.482093] acpi LNXPOWER:02: Turning OFF
[30905.497417]  arc4 iwlmvm intel_rapl msr mac80211 x86_pkg_temp_thermal intel_powerclamp coretemp kvm_intel iwlwifi snd_hda_codec_hdmi kvm snd_hda_codec_realtek irqbypass snd_hda_codec_generic rtsx_pci_ms crct10dif_pclmul cfg80211 memstick iTCO_wdt iTCO_vendor_support crc32_pclmul ghash_clmulni_intel snd_hda_intel pcbc snd_hda_codec snd_hda_core snd_hwdep aesni_intel mei_wdt snd_pcm snd_timer thinkpad_acpi aes_x86_64 crypto_simd glue_helper cryptd joydev pcspkr i2c_i801 snd ac rfkill lpc_ich shpchp battery e1000e wmi soundcore mei_me ie31200_edac mei ptp pps_core thermal btrfs xor raid6_pq hid_generic usbhid rtsx_pci_sdmmc mmc_core i915 i2c_algo_bit video serio_raw drm_kms_helper button rtsx_pci syscopyarea sysfillrect sysimgblt ehci_pci fb_sys_fops ehci_hcd drm drm_panel_orientation_quirks ahci libahci
[30905.497556]  arc4 iwlmvm intel_rapl msr mac80211 x86_pkg_temp_thermal intel_powerclamp coretemp kvm_intel iwlwifi snd_hda_codec_hdmi kvm snd_hda_codec_realtek irqbypass snd_hda_codec_generic rtsx_pci_ms crct10dif_pclmul cfg80211 memstick iTCO_wdt iTCO_vendor_support crc32_pclmul ghash_clmulni_intel snd_hda_intel pcbc snd_hda_codec snd_hda_core snd_hwdep aesni_intel mei_wdt snd_pcm snd_timer thinkpad_acpi aes_x86_64 crypto_simd glue_helper cryptd joydev pcspkr i2c_i801 snd ac rfkill lpc_ich shpchp battery e1000e wmi soundcore mei_me ie31200_edac mei ptp pps_core thermal btrfs xor raid6_pq hid_generic usbhid rtsx_pci_sdmmc mmc_core i915 i2c_algo_bit video serio_raw drm_kms_helper button rtsx_pci syscopyarea sysfillrect sysimgblt ehci_pci fb_sys_fops ehci_hcd drm drm_panel_orientation_quirks ahci libahci
[37404.481939] acpi LNXPOWER:02: Turning OFF
[38011.017104] thinkpad_acpi: EC reports that Thermal Table has changed
[38012.246791] acpi LNXPOWER:02: Turning OFF

Here’s something interesting from dmesg after a failed suspend:


[41313.339989] PM: Preparing system for sleep (mem)
[41313.340481] Freezing user space processes ... 
[41333.346303] Freezing of tasks failed after 20.005 seconds (1 tasks refusing to freeze, wq_busy=0):
[41333.346315] QuotaManager IO D    0  3226   2391 0x00000004
[41333.346318] Call Trace:
[41333.346326]  ? __schedule+0x23f/0x860
[41333.346328]  schedule+0x28/0x80
[41333.346334]  request_wait_answer+0x8a/0x1c0 [fuse]
[41333.346337]  ? wait_woken+0x80/0x80
[41333.346339]  __fuse_request_send+0x78/0x80 [fuse]
[41333.346342]  fuse_simple_request+0xbd/0x190 [fuse]
[41333.346344]  fuse_lookup_name+0xf3/0x1f0 [fuse]
[41333.346347]  fuse_lookup+0x3a/0xf0 [fuse]
[41333.346351]  lookup_slow+0x99/0x150
[41333.346353]  walk_component+0x19d/0x440
[41333.346355]  ? path_init+0x177/0x2f0
[41333.346357]  path_lookupat+0x75/0x1d0
[41333.346359]  filename_lookup+0xa7/0x160
[41333.346361]  ? getname_flags+0x6a/0x1e0
[41333.346363]  ? SyS_access+0x95/0x210
[41333.346365]  SyS_access+0x95/0x210
[41333.346368]  do_syscall_64+0x7b/0x150
[41333.346370]  entry_SYSCALL_64_after_hwframe+0x3d/0xa2
[41333.346371] RIP: 0033:0x7f130891ccba
[41333.346372] RSP: 002b:00007f12d4d32f08 EFLAGS: 00000246 ORIG_RAX: 0000000000000015
[41333.346373] RAX: ffffffffffffffda RBX: 00007f12c8d8f1c0 RCX: 00007f130891ccba
[41333.346374] RDX: 00007f12fd5502c0 RSI: 0000000000000000 RDI: 00007f12b4f78f0c
[41333.346375] RBP: 00007f12d4d32f20 R08: 0000000000000000 R09: 00007f130928cea5
[41333.346375] R10: 00000000000000ac R11: 0000000000000246 R12: 00007f12d4d32f64
[41333.346376] R13: 00007f12d4d32fb0 R14: 00007f12d4d32f65 R15: 00007f12fd137ea8
[41333.346390] OOM killer enabled.
[41333.346391] Restarting tasks ... done.
[41333.396814] PM: Syncing filesystems ... done.
[41333.407761] PM: Preparing system for sleep (freeze)
[41333.407951] Freezing user space processes ... 
[41353.415248] Freezing of tasks failed after 20.007 seconds (1 tasks refusing to freeze, wq_busy=0):
[41353.415260] QuotaManager IO D    0  3226   2391 0x00000004
[41353.415262] Call Trace:
[41353.415270]  ? __schedule+0x23f/0x860
[41353.415272]  schedule+0x28/0x80
[41353.415278]  request_wait_answer+0x8a/0x1c0 [fuse]
[41353.415281]  ? wait_woken+0x80/0x80
[41353.415283]  __fuse_request_send+0x78/0x80 [fuse]
[41353.415286]  fuse_simple_request+0xbd/0x190 [fuse]
[41353.415289]  fuse_dentry_revalidate+0x141/0x2b0 [fuse]
[41353.415293]  lookup_fast+0x2a3/0x2b0
[41353.415295]  walk_component+0x38/0x440
[41353.415297]  ? path_init+0x177/0x2f0
[41353.415298]  path_lookupat+0x75/0x1d0
[41353.415301]  ? update_load_avg+0x567/0x6c0
[41353.415302]  ? update_curr+0xe1/0x1a0
[41353.415304]  filename_lookup+0xa7/0x160
[41353.415306]  ? __schedule+0x247/0x860
[41353.415308]  ? vfs_statx+0x63/0xb0
[41353.415309]  vfs_statx+0x63/0xb0
[41353.415312]  SYSC_newstat+0x26/0x40
[41353.415313]  ? __fput+0x174/0x210
[41353.415316]  ? task_work_run+0x7b/0x90
[41353.415319]  ? exit_to_usermode_loop+0xa6/0xc0
[41353.415320]  do_syscall_64+0x7b/0x150
[41353.415323]  entry_SYSCALL_64_after_hwframe+0x3d/0xa2
[41353.415324] RIP: 0033:0x7f130891c375
[41353.415325] RSP: 002b:00007f12d4d33278 EFLAGS: 00000246 ORIG_RAX: 0000000000000004
[41353.415327] RAX: ffffffffffffffda RBX: 00007f12bf6ffac0 RCX: 00007f130891c375
[41353.415327] RDX: 00007f12bf6ffad8 RSI: 00007f12bf6ffad8 RDI: 00007f12b4f4f70c
[41353.415328] RBP: 00007f12d4d332a0 R08: 0000000000000000 R09: 00007f130928cea5
[41353.415329] R10: 000000000000008f R11: 0000000000000246 R12: 0000000000000001
[41353.415330] R13: 00007f12bf6ffad8 R14: 00007f12b4b59b90 R15: 00007f12d4d332f0
[41353.415344] OOM killer enabled.
[41353.415344] Restarting tasks ... done.

Yes, that is significant. I’ve seen references to ‘QuotaManager’ with ‘Mozilla Firefox’. For test purposes, can you try suspending without any apps running? Some further research probably needed…