You are not logged in.

#1 2018-11-25 23:36:13

wellsaid
Member
Registered: 2016-04-13
Posts: 23

[SOLVED] intel_iommu=on causes suspend to fail on asus laptop

Hi,
I am trying to do VGA passtrough with my laptop:
https://www.asus.com/it/Laptops/VivoBoo … fications/

I have no problems so far with the VGA passtrough process, but when i enable the intel_iommu=on in the kernel it fails to suspend.

Here's the log form journalctl when i try to suspend:

nov 26 00:29:20 archlinux-N552V systemd[1]: Starting Suspend...
nov 26 00:29:21 archlinux-N552V systemd-sleep[4253]: Suspending system...
nov 26 00:29:21 archlinux-N552V kernel: PM: suspend entry (deep)
nov 26 00:29:21 archlinux-N552V kernel: PM: Syncing filesystems ... done.
nov 26 00:29:21 archlinux-N552V kernel: bbswitch: enabling discrete graphics
nov 26 00:29:24 archlinux-N552V kernel: Freezing user space processes ... (elapsed 0.002 seconds) done.
nov 26 00:29:24 archlinux-N552V kernel: OOM killer disabled.
nov 26 00:29:24 archlinux-N552V kernel: Freezing remaining freezable tasks ... (elapsed 0.001 seconds) done.
nov 26 00:29:24 archlinux-N552V kernel: Suspending console(s) (use no_console_suspend to debug)
nov 26 00:29:24 archlinux-N552V kernel: wlp2s0: deauthenticating from 10:be:f5:04:eb:11 by local choice (Reason: 3=DEAUTH_LEAVING)
nov 26 00:29:24 archlinux-N552V kernel: DMAR: DRHD: handling fault status reg 2
nov 26 00:29:24 archlinux-N552V kernel: DMAR: [DMA Read] Request device [04:00.0] fault addr 0 [fault reason 06] PTE Read access is not set
nov 26 00:29:24 archlinux-N552V kernel: pcieport 0000:00:1c.4: AER: Corrected error received: 0000:00:1c.4
nov 26 00:29:24 archlinux-N552V kernel: pcieport 0000:00:1c.4: PCIe Bus Error: severity=Corrected, type=Data Link Layer, (Transmitter ID)
nov 26 00:29:24 archlinux-N552V kernel: pcieport 0000:00:1c.4:   device [8086:a114] error status/mask=00001000/00002000
nov 26 00:29:24 archlinux-N552V kernel: pcieport 0000:00:1c.4:    [12] Timeout               
nov 26 00:29:24 archlinux-N552V kernel: xhci_hcd 0000:04:00.0: WARN: xHC save state timeout
nov 26 00:29:24 archlinux-N552V kernel: suspend_common(): xhci_pci_suspend+0x0/0x222 [xhci_pci] returns -110
nov 26 00:29:24 archlinux-N552V kernel: pci_pm_suspend(): hcd_pci_suspend+0x0/0x190 returns -110
nov 26 00:29:24 archlinux-N552V kernel: dpm_run_callback(): pci_pm_suspend+0x0/0x120 returns -110
nov 26 00:29:24 archlinux-N552V kernel: PM: Device 0000:04:00.0 failed to suspend async: error -110
nov 26 00:29:24 archlinux-N552V kernel: sd 3:0:0:0: [sda] Synchronizing SCSI cache
nov 26 00:29:24 archlinux-N552V kernel: sd 3:0:0:0: [sda] Stopping disk
nov 26 00:29:24 archlinux-N552V kernel: PM: Some devices failed to suspend, or early wake event detected
nov 26 00:29:24 archlinux-N552V kernel: ACPI: button: The lid device is not compliant to SW_LID.
nov 26 00:29:24 archlinux-N552V kernel: sd 3:0:0:0: [sda] Starting disk
nov 26 00:29:24 archlinux-N552V kernel: ata3: SATA link down (SStatus 4 SControl 300)
nov 26 00:29:24 archlinux-N552V kernel: OOM killer enabled.
nov 26 00:29:24 archlinux-N552V wpa_supplicant[3484]: wlp2s0: CTRL-EVENT-DISCONNECTED bssid=10:be:f5:04:eb:11 reason=3 locally_generated=1
nov 26 00:29:24 archlinux-N552V NetworkManager[3291]: <warn>  [1543188564.1851] sup-iface[0x55ff256b40d0,wlp2s0]: connection disconnected (reason -3)
nov 26 00:29:24 archlinux-N552V kernel: Restarting tasks ... done.
nov 26 00:29:24 archlinux-N552V NetworkManager[3291]: <info>  [1543188564.1920] device (wlp2s0): supplicant interface state: completed -> disconnected
nov 26 00:29:24 archlinux-N552V kernel: video LNXVIDEO:00: Restoring backlight state
nov 26 00:29:24 archlinux-N552V kernel: video LNXVIDEO:01: Restoring backlight state
nov 26 00:29:24 archlinux-N552V kernel: bbswitch: disabling discrete graphics
nov 26 00:29:24 archlinux-N552V kernel: PM: suspend exit
nov 26 00:29:24 archlinux-N552V kernel: PM: suspend entry (s2idle)
nov 26 00:29:24 archlinux-N552V NetworkManager[3291]: <info>  [1543188564.2896] device (wlp2s0): supplicant interface state: disconnected -> scanning
nov 26 00:29:24 archlinux-N552V kernel: PM: Syncing filesystems ... 
nov 26 00:29:24 archlinux-N552V kernel: r8169 0000:03:00.1 enp3s0f1: Link is Down
nov 26 00:29:24 archlinux-N552V kernel: done.
nov 26 00:29:24 archlinux-N552V kernel: bbswitch: enabling discrete graphics
nov 26 00:29:27 archlinux-N552V kernel: Freezing user space processes ... (elapsed 0.002 seconds) done.
nov 26 00:29:27 archlinux-N552V kernel: OOM killer disabled.
nov 26 00:29:27 archlinux-N552V kernel: Freezing remaining freezable tasks ... (elapsed 0.001 seconds) done.
nov 26 00:29:27 archlinux-N552V kernel: Suspending console(s) (use no_console_suspend to debug)
nov 26 00:29:27 archlinux-N552V kernel: pcieport 0000:00:1c.4: AER: Corrected error received: 0000:00:1c.4
nov 26 00:29:27 archlinux-N552V kernel: pcieport 0000:00:1c.4: PCIe Bus Error: severity=Corrected, type=Physical Layer, (Receiver ID)
nov 26 00:29:27 archlinux-N552V kernel: pcieport 0000:00:1c.4:   device [8086:a114] error status/mask=00000001/00002000
nov 26 00:29:27 archlinux-N552V kernel: pcieport 0000:00:1c.4:    [ 0] RxErr                  (First)
nov 26 00:29:27 archlinux-N552V kernel: xhci_hcd 0000:04:00.0: WARN: xHC save state timeout
nov 26 00:29:27 archlinux-N552V kernel: suspend_common(): xhci_pci_suspend+0x0/0x222 [xhci_pci] returns -110
nov 26 00:29:27 archlinux-N552V kernel: pci_pm_suspend(): hcd_pci_suspend+0x0/0x190 returns -110
nov 26 00:29:27 archlinux-N552V kernel: dpm_run_callback(): pci_pm_suspend+0x0/0x120 returns -110
nov 26 00:29:27 archlinux-N552V kernel: PM: Device 0000:04:00.0 failed to suspend async: error -110
nov 26 00:29:27 archlinux-N552V kernel: sd 3:0:0:0: [sda] Synchronizing SCSI cache
nov 26 00:29:27 archlinux-N552V kernel: sd 3:0:0:0: [sda] Stopping disk
nov 26 00:29:27 archlinux-N552V kernel: PM: Some devices failed to suspend, or early wake event detected
nov 26 00:29:27 archlinux-N552V kernel: sd 3:0:0:0: [sda] Starting disk
nov 26 00:29:27 archlinux-N552V kernel: ata3: SATA link down (SStatus 4 SControl 300)
nov 26 00:29:27 archlinux-N552V kernel: OOM killer enabled.
nov 26 00:29:27 archlinux-N552V kernel: Restarting tasks ... done.
nov 26 00:29:27 archlinux-N552V wpa_supplicant[3484]: wlp2s0: SME: Trying to authenticate with 10:be:f5:04:eb:11 (SSID='Infostrada-2.4GHz-04EB11' freq=2427 MHz)
nov 26 00:29:27 archlinux-N552V kernel: wlp2s0: authenticate with 10:be:f5:04:eb:11
nov 26 00:29:27 archlinux-N552V kernel: wlp2s0: send auth to 10:be:f5:04:eb:11 (try 1/3)
nov 26 00:29:27 archlinux-N552V kernel: video LNXVIDEO:00: Restoring backlight state
nov 26 00:29:27 archlinux-N552V NetworkManager[3291]: <info>  [1543188567.2928] device (wlp2s0): supplicant interface state: scanning -> authenticating
nov 26 00:29:27 archlinux-N552V wpa_supplicant[3484]: wlp2s0: Trying to associate with 10:be:f5:04:eb:11 (SSID='Infostrada-2.4GHz-04EB11' freq=2427 MHz)
nov 26 00:29:27 archlinux-N552V kernel: wlp2s0: authenticated
nov 26 00:29:27 archlinux-N552V kernel: wlp2s0: associating with AP with corrupt probe response
nov 26 00:29:27 archlinux-N552V kernel: video LNXVIDEO:01: Restoring backlight state
nov 26 00:29:27 archlinux-N552V kernel: bbswitch: disabling discrete graphics
nov 26 00:29:27 archlinux-N552V kernel: wlp2s0: associate with 10:be:f5:04:eb:11 (try 1/3)
nov 26 00:29:27 archlinux-N552V NetworkManager[3291]: <info>  [1543188567.2990] device (wlp2s0): supplicant interface state: authenticating -> associating
nov 26 00:29:27 archlinux-N552V kernel: wlp2s0: RX AssocResp from 10:be:f5:04:eb:11 (capab=0x411 status=0 aid=6)
nov 26 00:29:27 archlinux-N552V wpa_supplicant[3484]: wlp2s0: Associated with 10:be:f5:04:eb:11
nov 26 00:29:27 archlinux-N552V wpa_supplicant[3484]: wlp2s0: CTRL-EVENT-SUBNET-STATUS-UPDATE status=0
nov 26 00:29:27 archlinux-N552V kernel: wlp2s0: associated
nov 26 00:29:27 archlinux-N552V NetworkManager[3291]: <info>  [1543188567.3101] device (wlp2s0): supplicant interface state: associating -> associated
nov 26 00:29:27 archlinux-N552V systemd-sleep[4253]: Failed to suspend system. System resumed again: Connection timed out
nov 26 00:29:27 archlinux-N552V kernel: PM: suspend exit
nov 26 00:29:27 archlinux-N552V systemd[1]: systemd-suspend.service: Main process exited, code=exited, status=1/FAILURE
nov 26 00:29:27 archlinux-N552V systemd[1]: systemd-suspend.service: Failed with result 'exit-code'.
nov 26 00:29:27 archlinux-N552V systemd[1]: Failed to start Suspend.
nov 26 00:29:27 archlinux-N552V systemd[1]: Dependency failed for Suspend.
nov 26 00:29:27 archlinux-N552V kernel: audit: type=1130 audit(1543188567.335:140): pid=1 uid=0 auid=4294967295 ses=4294967295 subj==unconfined msg='unit=systemd-suspend comm="systemd" exe="/usr/lib/systemd/systemd" hostname=? addr=? terminal=? res=failed'
nov 26 00:29:27 archlinux-N552V audit[1]: SERVICE_START pid=1 uid=0 auid=4294967295 ses=4294967295 subj==unconfined msg='unit=systemd-suspend comm="systemd" exe="/usr/lib/systemd/systemd" hostname=? addr=? terminal=? res=failed'
nov 26 00:29:27 archlinux-N552V systemd[1]: suspend.target: Job suspend.target/start failed with result 'dependency'.
nov 26 00:29:27 archlinux-N552V systemd-logind[2671]: Operation 'sleep' finished.
nov 26 00:29:27 archlinux-N552V systemd[1]: Stopped target Sleep.

I have no idea how to find out exactly what is causing the fail, but i assume is the pci device: 0000:00:1c.4 or 0000:04:00.0.

lspci output:

00:00.0 Host bridge: Intel Corporation Xeon E3-1200 v5/E3-1500 v5/6th Gen Core Processor Host Bridge/DRAM Registers (rev 07)
00:01.0 PCI bridge: Intel Corporation Xeon E3-1200 v5/E3-1500 v5/6th Gen Core Processor PCIe Controller (x16) (rev 07)
00:02.0 VGA compatible controller: Intel Corporation HD Graphics 530 (rev 06)
00:04.0 Signal processing controller: Intel Corporation Xeon E3-1200 v5/E3-1500 v5/6th Gen Core Processor Thermal Subsystem (rev 07)
00:14.0 USB controller: Intel Corporation 100 Series/C230 Series Chipset Family USB 3.0 xHCI Controller (rev 31)
00:14.2 Signal processing controller: Intel Corporation 100 Series/C230 Series Chipset Family Thermal Subsystem (rev 31)
00:15.0 Signal processing controller: Intel Corporation 100 Series/C230 Series Chipset Family Serial IO I2C Controller #0 (rev 31)
00:15.1 Signal processing controller: Intel Corporation 100 Series/C230 Series Chipset Family Serial IO I2C Controller #1 (rev 31)
00:16.0 Communication controller: Intel Corporation 100 Series/C230 Series Chipset Family MEI Controller #1 (rev 31)
00:17.0 SATA controller: Intel Corporation HM170/QM170 Chipset SATA Controller [AHCI Mode] (rev 31)
00:1c.0 PCI bridge: Intel Corporation 100 Series/C230 Series Chipset Family PCI Express Root Port #3 (rev f1)
00:1c.3 PCI bridge: Intel Corporation 100 Series/C230 Series Chipset Family PCI Express Root Port #4 (rev f1)
00:1c.4 PCI bridge: Intel Corporation 100 Series/C230 Series Chipset Family PCI Express Root Port #5 (rev f1)
00:1f.0 ISA bridge: Intel Corporation HM170 Chipset LPC/eSPI Controller (rev 31)
00:1f.2 Memory controller: Intel Corporation 100 Series/C230 Series Chipset Family Power Management Controller (rev 31)
00:1f.3 Audio device: Intel Corporation 100 Series/C230 Series Chipset Family HD Audio Controller (rev 31)
00:1f.4 SMBus: Intel Corporation 100 Series/C230 Series Chipset Family SMBus (rev 31)
01:00.0 3D controller: NVIDIA Corporation GM107M [GeForce GTX 950M] (rev ff)
02:00.0 Network controller: Intel Corporation Wireless 7265 (rev 59)
03:00.0 Unassigned class [ff00]: Realtek Semiconductor Co., Ltd. RTL8411B PCI Express Card Reader (rev 01)
03:00.1 Ethernet controller: Realtek Semiconductor Co., Ltd. RTL8111/8168/8411 PCI Express Gigabit Ethernet Controller (rev 12)
04:00.0 USB controller: ASMedia Technology Inc. ASM1142 USB 3.1 Host Controller

Do you guys have any idea on how to investigate this?

Last edited by wellsaid (2018-11-26 08:46:03)

Offline

#2 2018-11-26 08:45:41

wellsaid
Member
Registered: 2016-04-13
Posts: 23

Re: [SOLVED] intel_iommu=on causes suspend to fail on asus laptop

UPDATE:
I was able to find a workaround based on this reddit post: https://www.reddit.com/r/linuxquestions … er/dd17ikb

1. Look the driver of your device:

$ lspci -nnk -s 0000:04:00.0
04:00.0 USB controller [0c03]: ASMedia Technology Inc. ASM1142 USB 3.1 Host Controller [1b21:1242]
	Subsystem: ASUSTeK Computer Inc. ASM1142 USB 3.1 Host Controller [1043:201f]
	Kernel driver in use: xhci_hcd
	Kernel modules: xhci_pci

2. Create (and enable) a service to unbind it from the driver before suspend

$ cat /etc/systemd/system/unbind-suspend-failing-device.service 
[Unit]
Description=Unbind device which causes suspend to fail
Before=sleep.target
[Service]
Type=simple
ExecStart=-/bin/sh -c '/bin/echo -n "0000:04:00.0" > /sys/bus/pci/drivers/xhci_hcd/unbind'
[Install]
WantedBy=sleep.target

2. Create (and enable) a service to re-bind it to the driver after suspend

$ cat /etc/systemd/system/rebind-suspend-failing-device.service
[Unit]
Description=Rebind device which causes suspend to fail
After=suspend.target
[Service]
Type=simple
ExecStart=-/bin/sh -c '/bin/echo -n "0000:04:00.0" > /sys/bus/pci/drivers/xhci_hcd/bind'
[Install]
WantedBy=suspend.target

And you are good to go.

Last edited by wellsaid (2018-11-26 08:47:15)

Offline

#3 2020-01-31 22:24:41

clydedroid
Member
Registered: 2020-01-22
Posts: 5

Re: [SOLVED] intel_iommu=on causes suspend to fail on asus laptop

Hey @wellsaid, just wanted to say thanks for posting this, my suspending broke and your solution fixed it! Cheers smile

Offline

Board footer

Powered by FluxBB