LinuxQuestions.org
Review your favorite Linux distribution.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Password
Slackware This Forum is for the discussion of Slackware Linux.

Notices


Reply
  Search this Thread
Old 01-12-2016, 07:25 AM   #1
orbea
Senior Member
 
Registered: Feb 2015
Distribution: Slackware64-current
Posts: 1,950

Rep: Reputation: Disabled
Unable to suspend or hibernate with a 4.4.0 kernel.


I compiled a 4.4.0 kernel using the oldconfig from the generic 4.1.5 kernel using largely default options and then removing some hardware specific stuff I don't need. However now I can't use pm-suspend or pm-hibernate, it tries to suspend/hibernate and then resumes when its not able to. Any pointers on how to debug this? I have attached my kernel config at a .txt file in case this is my own doing.

This was not present on the 4.3.3 kernel release.

syslog
Code:
Jan 12 05:01:36 Linux kernel: [  646.351808] Freezing of tasks failed after 20.008
 seconds (3 tasks refusing to freeze, wq_busy=0):
Jan 12 05:01:36 Linux kernel: [  646.351837]  ffff8800ce53be08 ffffffff819af4c0 ff
ff8800ca490c40 0000000000000000
Jan 12 05:01:36 Linux kernel: [  646.351842]  ffff8800ca490c40 ffff8800ce53c000 ff
ff8800ca490c40 ffffffff81350990
Jan 12 05:01:36 Linux kernel: [  646.351847]  ffff8802224d5c80 0000000000000000 ff
ff8800ce53be20 ffffffff8174752c
Jan 12 05:01:36 Linux kernel: [  646.351852] Call Trace:
Jan 12 05:01:36 Linux kernel: [  646.351863]  [<ffffffff81350990>] ? xfs_trans_ail
_cursor_first+0x90/0x90
Jan 12 05:01:36 Linux kernel: [  646.351869]  [<ffffffff8174752c>] schedule+0x3c/0
x90
Jan 12 05:01:36 Linux kernel: [  646.351873]  [<ffffffff81350fe0>] xfsaild+0x650/0
x680
Jan 12 05:01:36 Linux kernel: [  646.351878]  [<ffffffff81746d17>] ? __schedule+0x
327/0xb00
Jan 12 05:01:36 Linux kernel: [  646.351882]  [<ffffffff81350990>] ? xfs_trans_ail
_cursor_first+0x90/0x90
Jan 12 05:01:36 Linux kernel: [  646.351886]  [<ffffffff81350990>] ? xfs_trans_ail
_cursor_first+0x90/0x90
Jan 12 05:01:36 Linux kernel: [  646.351892]  [<ffffffff810a3a39>] kthread+0xc9/0x
e0
Jan 12 05:01:36 Linux kernel: [  646.351896]  [<ffffffff810a3970>] ? kthread_worke
r_fn+0x170/0x170
Jan 12 05:01:36 Linux kernel: [  646.351901]  [<ffffffff8174b76f>] ret_from_fork+0x3f/0x70
Jan 12 05:01:36 Linux kernel: [  646.351905]  [<ffffffff810a3970>] ? kthread_worker_fn+0x170/0x170
Jan 12 05:01:36 Linux kernel: [  646.351915]  ffff8800c8c13e08 ffff8802259f9880 ffff8802241b3100 ffff8800cd988990
Jan 12 05:01:36 Linux kernel: [  646.351920]  0000000000000000 ffff8800c8c14000 ffff8802241b3100 ffffffff81350990
Jan 12 05:01:36 Linux kernel: [  646.351931]  ffff8800cd988980 0000000000000000 ffff8800c8c13e20 ffffffff8174752c
Jan 12 05:01:36 Linux kernel: [  646.351936] Call Trace:
Jan 12 05:01:36 Linux kernel: [  646.351940]  [<ffffffff81350990>] ? xfs_trans_ail_cursor_first+0x90/0x90
Jan 12 05:01:36 Linux kernel: [  646.351944]  [<ffffffff8174752c>] schedule+0x3c/0x90
Jan 12 05:01:36 Linux kernel: [  646.351948]  [<ffffffff81350fe0>] xfsaild+0x650/0x680
Jan 12 05:01:36 Linux kernel: [  646.351952]  [<ffffffff81746d17>] ? __schedule+0x327/0xb00
Jan 12 05:01:36 Linux kernel: [  646.351956]  [<ffffffff81350990>] ? xfs_trans_ail_cursor_first+0x90/0x90
Jan 12 05:01:36 Linux kernel: [  646.351960]  [<ffffffff81350990>] ? xfs_trans_ail_cursor_first+0x90/0x90
Jan 12 05:01:36 Linux kernel: [  646.351964]  [<ffffffff810a3a39>] kthread+0xc9/0xe0
Jan 12 05:01:36 Linux kernel: [  646.351968]  [<ffffffff810a3970>] ? kthread_worker_fn+0x170/0x170
Jan 12 05:01:36 Linux kernel: [  646.351973]  [<ffffffff8174b76f>] ret_from_fork+0x3f/0x70
Jan 12 05:01:36 Linux kernel: [  646.351977]  [<ffffffff810a3970>] ? kthread_worker_fn+0x170/0x170
Jan 12 05:01:36 Linux kernel: [  646.351986]  ffff8800c8c37e08 ffff8802259f8000 ffff8802241b4980 ffff8800c8c34000
Jan 12 05:01:36 Linux kernel: [  646.351990]  ffff8802241b4980 ffff8800c8c38000 ffff8802241b4980 0000000000000000
Jan 12 05:01:36 Linux kernel: [  646.351995]  ffff8802224d5880 ffff8800ca5d6800 ffff8800c8c37e20 ffffffff8174752c
Jan 12 05:01:36 Linux kernel: [  646.351999] Call Trace:
Jan 12 05:01:36 Linux kernel: [  646.352003]  [<ffffffff8174752c>] schedule+0x3c/0x90
Jan 12 05:01:36 Linux kernel: [  646.352007]  [<ffffffff81350fe0>] xfsaild+0x650/0x680
Jan 12 05:01:36 Linux kernel: [  646.352011]  [<ffffffff81350990>] ? xfs_trans_ail_cursor_first+0x90/0x90
Jan 12 05:01:36 Linux kernel: [  646.352015]  [<ffffffff81350990>] ? xfs_trans_ail_cursor_first+0x90/0x90
Jan 12 05:01:36 Linux kernel: [  646.352025]  [<ffffffff810a3a39>] kthread+0xc9/0xe0
Jan 12 05:01:36 Linux kernel: [  646.352027]  [<ffffffff810a3970>] ? kthread_worker_fn+0x170/0x170
Jan 12 05:01:36 Linux kernel: [  646.352028]  [<ffffffff8174b76f>] ret_from_fork+0x3f/0x70
Jan 12 05:01:36 Linux kernel: [  646.352030]  [<ffffffff810a3970>] ? kthread_worker_fn+0x170/0x170
Jan 12 05:01:36 Linux kernel: [  646.352041]
Code:
$ lspci 
00:00.0 Host bridge: Advanced Micro Devices, Inc. [AMD/ATI] RD890 PCI to PCI bridge (external gfx0 port B) (rev 02)
00:02.0 PCI bridge: Advanced Micro Devices, Inc. [AMD/ATI] RD890 PCI to PCI bridge (PCI express gpp port B)
00:09.0 PCI bridge: Advanced Micro Devices, Inc. [AMD/ATI] RD890 PCI to PCI bridge (PCI express gpp port H)
00:0a.0 PCI bridge: Advanced Micro Devices, Inc. [AMD/ATI] RD890 PCI to PCI bridge (external gfx1 port A)
00:11.0 SATA controller: Advanced Micro Devices, Inc. [AMD/ATI] SB7x0/SB8x0/SB9x0 SATA Controller [AHCI mode] (rev 40)
00:12.0 USB controller: Advanced Micro Devices, Inc. [AMD/ATI] SB7x0/SB8x0/SB9x0 USB OHCI0 Controller
00:12.2 USB controller: Advanced Micro Devices, Inc. [AMD/ATI] SB7x0/SB8x0/SB9x0 USB EHCI Controller
00:13.0 USB controller: Advanced Micro Devices, Inc. [AMD/ATI] SB7x0/SB8x0/SB9x0 USB OHCI0 Controller
00:13.2 USB controller: Advanced Micro Devices, Inc. [AMD/ATI] SB7x0/SB8x0/SB9x0 USB EHCI Controller
00:14.0 SMBus: Advanced Micro Devices, Inc. [AMD/ATI] SBx00 SMBus Controller (rev 42)
00:14.2 Audio device: Advanced Micro Devices, Inc. [AMD/ATI] SBx00 Azalia (Intel HDA) (rev 40)
00:14.3 ISA bridge: Advanced Micro Devices, Inc. [AMD/ATI] SB7x0/SB8x0/SB9x0 LPC host controller (rev 40)
00:14.4 PCI bridge: Advanced Micro Devices, Inc. [AMD/ATI] SBx00 PCI to PCI Bridge (rev 40)
00:14.5 USB controller: Advanced Micro Devices, Inc. [AMD/ATI] SB7x0/SB8x0/SB9x0 USB OHCI2 Controller
00:15.0 PCI bridge: Advanced Micro Devices, Inc. [AMD/ATI] SB700/SB800/SB900 PCI to PCI bridge (PCIE port 0)
00:15.2 PCI bridge: Advanced Micro Devices, Inc. [AMD/ATI] SB900 PCI to PCI bridge (PCIE port 2)
00:16.0 USB controller: Advanced Micro Devices, Inc. [AMD/ATI] SB7x0/SB8x0/SB9x0 USB OHCI0 Controller
00:16.2 USB controller: Advanced Micro Devices, Inc. [AMD/ATI] SB7x0/SB8x0/SB9x0 USB EHCI Controller
00:18.0 Host bridge: Advanced Micro Devices, Inc. [AMD] Family 15h Processor Function 0
00:18.1 Host bridge: Advanced Micro Devices, Inc. [AMD] Family 15h Processor Function 1
00:18.2 Host bridge: Advanced Micro Devices, Inc. [AMD] Family 15h Processor Function 2
00:18.3 Host bridge: Advanced Micro Devices, Inc. [AMD] Family 15h Processor Function 3
00:18.4 Host bridge: Advanced Micro Devices, Inc. [AMD] Family 15h Processor Function 4
00:18.5 Host bridge: Advanced Micro Devices, Inc. [AMD] Family 15h Processor Function 5
01:00.0 VGA compatible controller: NVIDIA Corporation GK110B [GeForce GTX 780 Ti] (rev a1)
01:00.1 Audio device: NVIDIA Corporation GK110 HDMI Audio (rev a1)
02:00.0 USB controller: VIA Technologies, Inc. VL805 USB 3.0 Host Controller (rev 01)
03:00.0 SATA controller: Marvell Technology Group Ltd. 88SE9172 SATA 6Gb/s Controller (rev 12)
05:00.0 Ethernet controller: Realtek Semiconductor Co., Ltd. RTL8111/8168/8411 PCI Express Gigabit Ethernet Controller (rev 0c)
06:00.0 SATA controller: Marvell Technology Group Ltd. 88SE9172 SATA 6Gb/s Controller (rev 12)
Edit:

dmesg
Code:
[  626.285757] PM: Syncing filesystems ... done.
[  626.342811] Freezing user space processes ... (elapsed 0.001 seconds) done.
[  626.344187] Freezing remaining freezable tasks ... 
[  646.351808] Freezing of tasks failed after 20.008 seconds (3 tasks refusing to freeze, wq_busy=0):
[  646.351830] xfsaild/sda10   S ffff8800ce53be08     0   900      2 0x00000000
[  646.351837]  ffff8800ce53be08 ffffffff819af4c0 ffff8800ca490c40 0000000000000000
[  646.351842]  ffff8800ca490c40 ffff8800ce53c000 ffff8800ca490c40 ffffffff81350990
[  646.351847]  ffff8802224d5c80 0000000000000000 ffff8800ce53be20 ffffffff8174752c
[  646.351852] Call Trace:
[  646.351863]  [<ffffffff81350990>] ? xfs_trans_ail_cursor_first+0x90/0x90
[  646.351869]  [<ffffffff8174752c>] schedule+0x3c/0x90
[  646.351873]  [<ffffffff81350fe0>] xfsaild+0x650/0x680
[  646.351878]  [<ffffffff81746d17>] ? __schedule+0x327/0xb00
[  646.351882]  [<ffffffff81350990>] ? xfs_trans_ail_cursor_first+0x90/0x90
[  646.351886]  [<ffffffff81350990>] ? xfs_trans_ail_cursor_first+0x90/0x90
[  646.351892]  [<ffffffff810a3a39>] kthread+0xc9/0xe0
[  646.351896]  [<ffffffff810a3970>] ? kthread_worker_fn+0x170/0x170
[  646.351901]  [<ffffffff8174b76f>] ret_from_fork+0x3f/0x70
[  646.351905]  [<ffffffff810a3970>] ? kthread_worker_fn+0x170/0x170
[  646.351910] xfsaild/sda11   S ffff8800c8c13e08     0   908      2 0x00000000
[  646.351915]  ffff8800c8c13e08 ffff8802259f9880 ffff8802241b3100 ffff8800cd988990
[  646.351920]  0000000000000000 ffff8800c8c14000 ffff8802241b3100 ffffffff81350990
[  646.351931]  ffff8800cd988980 0000000000000000 ffff8800c8c13e20 ffffffff8174752c
[  646.351936] Call Trace:
[  646.351940]  [<ffffffff81350990>] ? xfs_trans_ail_cursor_first+0x90/0x90
[  646.351944]  [<ffffffff8174752c>] schedule+0x3c/0x90
[  646.351948]  [<ffffffff81350fe0>] xfsaild+0x650/0x680
[  646.351952]  [<ffffffff81746d17>] ? __schedule+0x327/0xb00
[  646.351956]  [<ffffffff81350990>] ? xfs_trans_ail_cursor_first+0x90/0x90
[  646.351960]  [<ffffffff81350990>] ? xfs_trans_ail_cursor_first+0x90/0x90
[  646.351964]  [<ffffffff810a3a39>] kthread+0xc9/0xe0
[  646.351968]  [<ffffffff810a3970>] ? kthread_worker_fn+0x170/0x170
[  646.351973]  [<ffffffff8174b76f>] ret_from_fork+0x3f/0x70
[  646.351977]  [<ffffffff810a3970>] ? kthread_worker_fn+0x170/0x170
[  646.351981] xfsaild/sda14   S ffff8800c8c37e08     0   916      2 0x00000000
[  646.351986]  ffff8800c8c37e08 ffff8802259f8000 ffff8802241b4980 ffff8800c8c34000
[  646.351990]  ffff8802241b4980 ffff8800c8c38000 ffff8802241b4980 0000000000000000
[  646.351995]  ffff8802224d5880 ffff8800ca5d6800 ffff8800c8c37e20 ffffffff8174752c
[  646.351999] Call Trace:
[  646.352003]  [<ffffffff8174752c>] schedule+0x3c/0x90
[  646.352007]  [<ffffffff81350fe0>] xfsaild+0x650/0x680
[  646.352011]  [<ffffffff81350990>] ? xfs_trans_ail_cursor_first+0x90/0x90
[  646.352015]  [<ffffffff81350990>] ? xfs_trans_ail_cursor_first+0x90/0x90
[  646.352025]  [<ffffffff810a3a39>] kthread+0xc9/0xe0
[  646.352027]  [<ffffffff810a3970>] ? kthread_worker_fn+0x170/0x170
[  646.352028]  [<ffffffff8174b76f>] ret_from_fork+0x3f/0x70
[  646.352030]  [<ffffffff810a3970>] ? kthread_worker_fn+0x170/0x170

[  646.352042] Restarting kernel threads ... done.
[  646.352271] Restarting tasks ... done.
pm-suspend.log
Code:
Initial commandline parameters: 
Tue Jan 12 05:01:15 PST 2016: Running hooks for suspend.
Running hook /usr/lib64/pm-utils/sleep.d/00logging suspend suspend:
Linux Akita 4.4.0 #1 SMP PREEMPT Mon Jan 11 08:57:44 PST 2016 x86_64 AMD FX(tm)-6350 Six-Core Processor AuthenticAMD GNU/Linux
Module                  Size  Used by
cfg80211              446974  0
rfkill                 15562  1 cfg80211
fuse                   80238  1
joydev                 10151  0
nouveau              1401973  2
video                  24840  1 nouveau
ttm                    71260  1 nouveau
drm_kms_helper         96426  1 nouveau
drm                   271956  5 ttm,drm_kms_helper,nouveau
agpgart                26356  3 drm,ttm,nouveau
kvm_amd                53779  0
mxm_wmi                 1699  1 nouveau
i2c_dev                 5819  0
evdev                  13034  21
i2c_algo_bit            5456  1 nouveau
kvm                   444180  1 kvm_amd
fb_sys_fops             1506  1 drm_kms_helper
snd_hda_codec_realtek    55526  1
snd_hda_codec_hdmi     38014  1
snd_hda_codec_generic    56790  1 snd_hda_codec_realtek
k10temp                 3188  0
fam15h_power            3070  0
syscopyarea             3326  1 drm_kms_helper
sysfillrect             3818  1 drm_kms_helper
sysimgblt               2367  1 drm_kms_helper
snd_hda_intel          24429  0
snd_hda_codec          89273  4 snd_hda_codec_realtek,snd_hda_codec_hdmi,snd_hda_codec_generic,snd_hda_intel
snd_hda_core           39474  5 snd_hda_codec_realtek,snd_hda_codec_hdmi,snd_hda_codec_generic,snd_hda_codec,snd_hda_intel
irqbypass               2872  1 kvm
hwmon                   3250  3 fam15h_power,k10temp,nouveau
snd_hwdep               6250  1 snd_hda_codec
snd_pcm                79560  4 snd_hda_codec_hdmi,snd_hda_codec,snd_hda_intel,snd_hda_core
crct10dif_pclmul        4580  0
xhci_pci                4458  0
psmouse               104073  0
serio_raw               4785  0
crc32_pclmul            3059  0
snd_timer              18977  1 snd_pcm
xhci_hcd              111580  1 xhci_pci
crc32c_intel           13318  0
ohci_pci                3336  0
wmi                     7778  2 mxm_wmi,nouveau
r8168                 475441  0
ehci_pci                3999  0
snd                    58733  7 snd_hwdep,snd_timer,snd_hda_codec_hdmi,snd_pcm,snd_hda_codec_generic,snd_hda_codec,snd_hda_intel
8250_fintek             2957  0
shpchp                 24466  0
ohci_hcd               28028  1 ohci_pci
i2c_piix4               8793  0
i2c_core               38903  6 drm,i2c_dev,i2c_piix4,drm_kms_helper,i2c_algo_bit,nouveau
soundcore               5475  1 snd
tpm_infineon            7782  0
ehci_hcd               42560  1 ehci_pci
button                  4948  1 nouveau
acpi_cpufreq            7202  0
tpm_tis                10525  0
tpm                    30897  2 tpm_tis,tpm_infineon
processor              24183  7 acpi_cpufreq
loop                   19834  0
hid_generic             1385  0
usbhid                 36651  0
hid                   101351  2 hid_generic,usbhid
              total        used        free      shared  buff/cache   available
Mem:        8198208      664544       66316        4612     7467348     7463948
Swap:       8388604      121160     8267444
/usr/lib64/pm-utils/sleep.d/00logging suspend suspend: success.

Running hook /usr/lib64/pm-utils/sleep.d/00powersave suspend suspend:
/usr/lib64/pm-utils/sleep.d/00powersave suspend suspend: success.

Running hook /usr/lib64/pm-utils/sleep.d/01grub suspend suspend:
/usr/lib64/pm-utils/sleep.d/01grub suspend suspend: not applicable.

Running hook /usr/lib64/pm-utils/sleep.d/49bluetooth-generic suspend suspend:
/usr/lib64/pm-utils/sleep.d/49bluetooth-generic suspend suspend: success.

Running hook /usr/lib64/pm-utils/sleep.d/49bluetooth-ibm suspend suspend:
/usr/lib64/pm-utils/sleep.d/49bluetooth-ibm suspend suspend: not applicable.

Running hook /etc/pm/sleep.d/66screenlock suspend suspend:
/etc/pm/sleep.d/66screenlock suspend suspend: success.

Running hook /usr/lib64/pm-utils/sleep.d/75modules suspend suspend:
/usr/lib64/pm-utils/sleep.d/75modules suspend suspend: not applicable.

Running hook /usr/lib64/pm-utils/sleep.d/90clock suspend suspend:
/usr/lib64/pm-utils/sleep.d/90clock suspend suspend: not applicable.

Running hook /usr/lib64/pm-utils/sleep.d/94cpufreq suspend suspend:
/usr/lib64/pm-utils/sleep.d/94cpufreq suspend suspend: success.

Running hook /usr/lib64/pm-utils/sleep.d/95led suspend suspend:
/usr/lib64/pm-utils/sleep.d/95led suspend suspend: not applicable.

Running hook /usr/lib64/pm-utils/sleep.d/98video-quirk-db-handler suspend suspend:
xscreensaver-command: activating and locking.

Kernel modesetting video driver detected, not using quirks.
/usr/lib64/pm-utils/sleep.d/98video-quirk-db-handler suspend suspend: success.

Running hook /usr/lib64/pm-utils/sleep.d/99video suspend suspend:
kernel.acpi_video_flags = 0
/usr/lib64/pm-utils/sleep.d/99video suspend suspend: success.

Tue Jan 12 05:01:16 PST 2016: performing suspend
/usr/lib64/pm-utils/pm-functions: line 301: echo: write error: Device or resource busy
Tue Jan 12 05:01:36 PST 2016: Awake.
Tue Jan 12 05:01:36 PST 2016: Running hooks for resume
Running hook /usr/lib64/pm-utils/sleep.d/99video resume suspend:
/usr/lib64/pm-utils/sleep.d/99video resume suspend: success.

Running hook /usr/lib64/pm-utils/sleep.d/98video-quirk-db-handler resume suspend:
/usr/lib64/pm-utils/sleep.d/98video-quirk-db-handler resume suspend: success.

Running hook /usr/lib64/pm-utils/sleep.d/95led resume suspend:
/usr/lib64/pm-utils/sleep.d/95led resume suspend: not applicable.

Running hook /usr/lib64/pm-utils/sleep.d/94cpufreq resume suspend:
/usr/lib64/pm-utils/sleep.d/94cpufreq resume suspend: success.

Running hook /usr/lib64/pm-utils/sleep.d/90clock resume suspend:
/usr/lib64/pm-utils/sleep.d/90clock resume suspend: not applicable.

Running hook /usr/lib64/pm-utils/sleep.d/75modules resume suspend:
Reloaded unloaded modules.
/usr/lib64/pm-utils/sleep.d/75modules resume suspend: success.

Running hook /etc/pm/sleep.d/66screenlock resume suspend:
/etc/pm/sleep.d/66screenlock resume suspend: success.

Running hook /usr/lib64/pm-utils/sleep.d/49bluetooth-ibm resume suspend:
/usr/lib64/pm-utils/sleep.d/49bluetooth-ibm resume suspend: not applicable.

Running hook /usr/lib64/pm-utils/sleep.d/49bluetooth-generic resume suspend:
/usr/lib64/pm-utils/sleep.d/49bluetooth-generic resume suspend: success.

Running hook /usr/lib64/pm-utils/sleep.d/01grub resume suspend:
/usr/lib64/pm-utils/sleep.d/01grub resume suspend: not applicable.

Running hook /usr/lib64/pm-utils/sleep.d/00powersave resume suspend:
/usr/lib64/pm-utils/sleep.d/00powersave resume suspend: success.

Running hook /usr/lib64/pm-utils/sleep.d/00logging resume suspend:
/usr/lib64/pm-utils/sleep.d/00logging resume suspend: success.

Tue Jan 12 05:01:36 PST 2016: Finished.
/usr/lib64/pm-utils/pm-functions
Code:
        
check_suspend() { [ -n "$SUSPEND_MODULE" ]; }
check_hibernate() { [ -n "$HIBERNATE_MODULE" ]; }
check_suspend_hybrid() { [ -n "$SUSPEND_HYBRID_MODULE" ]; }

# allow autodetection of sleep methods
if [ "$SLEEP_MODULE" = "auto" ]; then
    SLEEP_MODULE="tuxonice uswsusp"
fi

for mod in $SLEEP_MODULE; do
    mod="${PM_UTILS_LIBDIR}/module.d/${mod}"
    [ -f "$mod" ] || continue
    . "$mod"
done

# always fall back to kernel methods if nothing else was declared

if [ -z "$SUSPEND_MODULE" ]; then
        if grep -q mem /sys/power/state; then
                SUSPEND_MODULE="kernel"
                do_suspend() { echo -n "mem" >/sys/power/state; }      ####### Line 301
        elif [ -c /dev/pmu ] && pm-pmu --check; then
                SUSPEND_MODULE="kernel"
                do_suspend() { pm-pmu --suspend; }
        elif grep -q standby /sys/power/state; then
                SUSPEND_MODULE="kernel"
                do_suspend() { echo -n "standby" >/sys/power/state; }
        fi
fi

if [ -z "$HIBERNATE_MODULE" ] && \n        [ -f /sys/power/disk ] && \n        grep -q disk /sys/power/state; then
        HIBERNATE_MODULE="kernel"
        do_hibernate()
        {
                [ -n "${HIBERNATE_MODE}" ] && \n                grep -qw "${HIBERNATE_MODE}" /sys/power/disk && \n                HIBERNATE_MODE_SAVE=$(cat /sys/power/disk) && \n                HIBERNATE_MODE_SAVE="${HIBERNATE_MODE_SAVE##*[}" && \n                HIBERNATE_MODE_SAVE="${HIBERNATE_MODE_SAVE%%]*}" && \n                echo -n "${HIBERNATE_MODE}" > /sys/power/disk
                echo -n "disk" > /sys/power/state
                RET=$?
                echo -n "$HIBERNATE_MODE_SAVE" > /sys/power/disk
                return "$RET"
        }
fi

# for kernels that support suspend to both (i.e. hybrid suspend)
# since kernel 3.6
if [ -z "$SUSPEND_HYBRID_MODULE" ] && \n        [ -f /sys/power/disk ] && \n        grep -q disk /sys/power/state && \n        grep -q suspend /sys/power/disk; then
        SUSPEND_HYBRID_MODULE="kernel"
        do_suspend_hybrid()
        {
                HIBERNATE_MODE="suspend"
                do_hibernate
        }
fi

# since the kernel does not directly support hybrid sleep, we do
# something else -- suspend and schedule an alarm to go into
# hibernate if we have slept long enough.
# Only do this if we do not need to do any special video hackery on resume
# from hibernate, though.
if [ -z "$SUSPEND_HYBRID_MODULE" -a -w "$PM_RTC/wakealarm" ] && \n    check_suspend && check_hibernate && ! is_set $HIBERNATE_RESUME_POST_VIDEO; \n    then
    SUSPEND_HYBRID_MODULE="kernel"
    do_suspend_hybrid() {
        WAKETIME=$(( $(cat "$PM_RTC/since_epoch") + PM_HIBERNATE_DELAY))
        echo >"$PM_RTC/wakealarm"
        echo $WAKETIME > "$PM_RTC/wakealarm"
        if do_suspend; then
            NOW=$(cat "$PM_RTC/since_epoch")
            if [ "$NOW" -ge "$WAKETIME" -a "$NOW" -lt $((WAKETIME + 30)) ]; then
                log "Woken by RTC alarm, hibernating."
                # if hibernate fails for any reason, go back to suspend.
                do_hibernate || do_suspend
            else
                echo > "$PM_RTC/wakealarm"
            fi
        else
            # if we cannot suspend, just try to hibernate.
            do_hibernate
        fi
    }
fi
/sys/power/state
Code:
freeze mem disk
Attached Files
File Type: txt config-4.4.0.txt (150.4 KB, 27 views)

Last edited by orbea; 01-12-2016 at 02:17 PM.
 
Old 01-12-2016, 07:25 PM   #2
MarcT
Member
 
Registered: Jan 2009
Location: UK
Distribution: Slackware 14.2
Posts: 125

Rep: Reputation: 51
When I've had similar, it was because I'd left a VirtualBox VM guest running, which veto'd the suspend.

Assuming it's not that - looks like a possible XFS filesystem issue:

Code:
3 tasks refusing to freeze:

xfsaild/sda10
xfsaild/sda11
xfsaild/sda14
I have no XFS experience, so can't help further with that. Perhaps see if there's an XFS dev list to post a bug report to?

Edit:
A quick Google shows this might be a known issue:
http://comments.gmane.org/gmane.comp....general/72096

Last edited by MarcT; 01-12-2016 at 07:32 PM.
 
1 members found this post helpful.
Old 01-12-2016, 07:31 PM   #3
orbea
Senior Member
 
Registered: Feb 2015
Distribution: Slackware64-current
Posts: 1,950

Original Poster
Rep: Reputation: Disabled
Well here are those three partitions. I'll see if I can find someone with xfs experience to ask since I'm not really sure either. I haven't had much luck with a search engine.

Code:
/dev/sda10       /gnu             xfs         defaults,relatime        0   2
/dev/sda11       /opt             xfs         defaults,relatime        0   2 
/dev/sda14       /usr/local/src   xfs         defaults,relatime        0   2
sda10 is connected to guix which hasn't caused any issues previously.

Edit: Here is similar if not the same issue reported here, without any solutions yet.

http://permalink.gmane.org/gmane.com....general/72096

Last edited by orbea; 01-12-2016 at 07:39 PM.
 
Old 01-12-2016, 09:49 PM   #4
orbea
Senior Member
 
Registered: Feb 2015
Distribution: Slackware64-current
Posts: 1,950

Original Poster
Rep: Reputation: Disabled
Okay, this is now solved for me.

I found the patch associated with the commit (24ba16b) that seems responsible according to the xfs list, reversed it and then rebuilt the kernel. Suspend now works again so I will mark this thread as solved.

Code:
patch -p1 -R < path/xfs_trans_ail.c.diff
Code:
diff --git a/fs/xfs/xfs_trans_ail.c b/fs/xfs/xfs_trans_ail.c
index 1098cf4..06d1a29 100644
--- a/fs/xfs/xfs_trans_ail.c
+++ b/fs/xfs/xfs_trans_ail.c
@@ -497,6 +497,7 @@ xfsaild(
 	long		tout = 0;	/* milliseconds */
 
 	current->flags |= PF_MEMALLOC;
+	set_freezable();
 
 	while (!kthread_should_stop()) {
 		if (tout && tout <= 20)
http://oss.sgi.com/archives/xfs/2015-10/msg00639.html
 
Old 01-13-2016, 01:21 AM   #5
rworkman
Slackware Contributor
 
Registered: Oct 2004
Location: Tuscaloosa, Alabama (USA)
Distribution: Slackware
Posts: 2,559

Rep: Reputation: 1351Reputation: 1351Reputation: 1351Reputation: 1351Reputation: 1351Reputation: 1351Reputation: 1351Reputation: 1351Reputation: 1351Reputation: 1351
Better link to the xfs mail list thread (with links to navigate the thread instead of gmane's terrible interface): http://oss.sgi.com/pipermail/xfs/201...ry/045864.html
I'll try to keep an eye on it, and we'll just hope that 4.4.1 will have a fix.
 
Old 02-05-2016, 08:58 AM   #6
slacksam
Member
 
Registered: Oct 2012
Location: Germany
Distribution: Slackware, Salix, slarm64
Posts: 210

Rep: Reputation: 37
Quote:
Originally Posted by rworkman
I'll try to keep an eye on it, and we'll just hope that 4.4.1 will have a fix.
No fix so far.
Now the Slackware-current kernel 4.4.1 has that bug too.
I have to use the patch Jiri Kosina suggested here: http://permalink.gmane.org/gmane.com....general/72268
 
Old 02-05-2016, 09:23 AM   #7
orbea
Senior Member
 
Registered: Feb 2015
Distribution: Slackware64-current
Posts: 1,950

Original Poster
Rep: Reputation: Disabled
According to the xfs devs that patch should not work and I wouldn't trust any code from Jiri at all at this point given how he is entirely non-responsive for issues he introduced himself.

Does reversing the initial broken patch still fix it?

Edit:

Code:
> Well, clearly the thread is sleeping in schedule() during the freezing 
> operation and it's supposed to be doing so; therefore it doesn't need 
> explicit freezing point, right?

No.

It's sleeping in schedule because it's got nothing more to do - it's
issued all it's IO and is idle. It is not going to run again until
filesystem modification activity is restarted.

But if the AIL still has objects in it (like it will after a sync),
then it will continue to run and issue IO until it returns to the
empty, idle state.  In this active state, we need to freeze the
thread on suspend so that it doesn't keep issuing IO all through the
suspend process...

> So the proper fix would rather be something like
> 
> 
> 
> From: Jiri Kosina <jkosina at suse.cz>
> Subject: [PATCH] xfs: xfsaild doesn't need to be freezable

No, that just means we guarantee that there will be suspend image
coherency problems when suspend is run on a busy filesystem...

This process is not going to enter a runable state, so is never
going to enter the freezer.  But we can't be certain of that,
because we haven't frozen the filesystem and hence it can still be
modified and this thread could be woken and do stuff when it
shouldn't.

Cheers,

Dave.
-- 
Dave Chinner
david at fromorbit.com
http://oss.sgi.com/pipermail/xfs/201...ry/046054.html

Last edited by orbea; 02-05-2016 at 09:28 AM.
 
Old 02-05-2016, 10:02 AM   #8
orbea
Senior Member
 
Registered: Feb 2015
Distribution: Slackware64-current
Posts: 1,950

Original Poster
Rep: Reputation: Disabled
I asked in #xfs @ freenode and reverting the patch is in xfs tree for-next so it should be fixed in the kernel. It should have the same effect as manually reversing the patch as explained above.

Code:
cc: <stable@vger.kernel.org> # 4.4
Signed-off-by: Dave Chinner <david@fromorbit.com>
Acked-by: Jiri Kosina <jkosina@suse.cz>
Reviewed-by: Brian Foster <bfoster@redhat.com>
Signed-off-by: Dave Chinner <david@fromorbit.com>
---
 fs/xfs/xfs_trans_ail.c | 1 -
 1 file changed, 1 deletion(-)

diff --git a/fs/xfs/xfs_trans_ail.c b/fs/xfs/xfs_trans_ail.c
index aa67339..4f18fd9 100644
--- a/fs/xfs/xfs_trans_ail.c
+++ b/fs/xfs/xfs_trans_ail.c
@@ -497,7 +497,6 @@ xfsaild(
 	long		tout = 0;	/* milliseconds */
 
 	current->flags |= PF_MEMALLOC;
-	set_freezable();
 
 	while (!kthread_should_stop()) {
 		if (tout && tout <= 20)
-- 
cgit v0.12
https://git.kernel.org/cgit/linux/ke...78c8327742634e

There is also supposedly a proper fix from a different suse dev, however its not in the xfs tree and I'm not sure why yet, I have not personally tested it.
Code:
Reported-by: Hendrik Woltersdorf <hendrikw@xxxxxxxx>
Signed-off-by: Michal Hocko <mhocko@xxxxxxxx>
---
 fs/xfs/xfs_trans_ail.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/fs/xfs/xfs_trans_ail.c b/fs/xfs/xfs_trans_ail.c
index aa67339b9537..d6c9c3e9e02b 100644
--- a/fs/xfs/xfs_trans_ail.c
+++ b/fs/xfs/xfs_trans_ail.c
@@ -520,14 +520,14 @@ xfsaild(
 		if (!xfs_ail_min(ailp) &&
 		    ailp->xa_target == ailp->xa_target_prev) {
 			spin_unlock(&ailp->xa_lock);
-			schedule();
+			freezable_schedule();
 			tout = 0;
 			continue;
 		}
 		spin_unlock(&ailp->xa_lock);
 
 		if (tout)
-			schedule_timeout(msecs_to_jiffies(tout));
+			freezable_schedule_timeout(msecs_to_jiffies(tout));
 
 		__set_current_state(TASK_RUNNING);
 
-- 
2.7.0.rc3

-- 
Michal Hocko
SUSE Labs
http://www.spinics.net/lists/xfs/msg37273.html

Last edited by orbea; 02-05-2016 at 10:04 AM.
 
1 members found this post helpful.
Old 02-05-2016, 06:01 PM   #9
slacksam
Member
 
Registered: Oct 2012
Location: Germany
Distribution: Slackware, Salix, slarm64
Posts: 210

Rep: Reputation: 37
The patch Hendrik Woltersdorf suggested works.
So I hope it will soon be applied to the next kernel release.

Thanks
 
Old 02-26-2016, 09:26 AM   #10
orbea
Senior Member
 
Registered: Feb 2015
Distribution: Slackware64-current
Posts: 1,950

Original Poster
Rep: Reputation: Disabled
Just a heads up that the original suse commit has been reversed in the upstream 4.4.3 kernel.

https://git.kernel.org/cgit/linux/ke...4.3&id2=v4.4.2
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] Suspend and hibernate linuxbird Slackware 6 12-19-2012 06:53 AM
Need to suspend or hibernate fletcher08 Linux - Newbie 1 04-18-2010 10:24 AM
[SOLVED] Unable to suspend my laptop after kernel upgrade! adityavpratap Slackware 13 06-30-2009 10:06 AM
Help need kernel 2.6.x with suspend already compiled for hibernate tetsuo83 Slackware 1 03-25-2006 08:37 PM
suspend a.k.a hibernate on kernel 2.6, how to use it? demmylls Linux - General 1 03-06-2004 12:06 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware

All times are GMT -5. The time now is 10:58 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration