[PATCH] iommu/amd: flush IOTLB for specific domains only
Jan Ziak
0xe2.0x9a.0x9b at gmail.com
Sat Jun 3 20:54:50 UTC 2017
Hi
I am getting "AMD-Vi: Completion-Wait loop timed out" error
approximately once per several days with R9 390.
Is there a reason why this patch isn't in the mainstream linux-git yet?
-Jan
-------------- next part --------------
[18107.021297] AMD-Vi: Completion-Wait loop timed out
[18107.168770] AMD-Vi: Completion-Wait loop timed out
[18107.444225] AMD-Vi: Completion-Wait loop timed out
[18107.714855] AMD-Vi: Completion-Wait loop timed out
[18107.846366] AMD-Vi: Completion-Wait loop timed out
[18108.047749] AMD-Vi: Event logged [
[18108.047752] IOTLB_INV_TIMEOUT device=23:00.0 address=0x000000042bb129e0]
[18108.179774] AMD-Vi: Completion-Wait loop timed out
[18108.580262] AMD-Vi: Completion-Wait loop timed out
[18108.710005] AMD-Vi: Completion-Wait loop timed out
[18108.911565] AMD-Vi: Event logged [
[18108.911567] IOTLB_INV_TIMEOUT device=23:00.0 address=0x000000042bb12a80]
[18109.041945] AMD-Vi: Completion-Wait loop timed out
[18109.243115] AMD-Vi: Completion-Wait loop timed out
[18109.646030] AMD-Vi: Completion-Wait loop timed out
[18109.847087] AMD-Vi: Completion-Wait loop timed out
[18109.918406] clocksource: timekeeping watchdog on CPU5: Marking clocksource 'tsc' as unstable because the skew is too large:
[18109.918408] clocksource: 'hpet' wd_now: 5f6204a6 wd_last: 5e860c6b mask: ffffffff
[18109.918408] clocksource: 'tsc' cs_now: 34ca9e6f0220 cs_last: 34c9ebff5f00 mask: ffffffffffffffff
[18109.918410] sched_clock: Marking unstable (18109972341058, -53936107)<-(18110036284612, -117879661)
[18109.918411] tsc: Marking TSC unstable due to clocksource watchdog
[18109.918421] AMD-Vi: Event logged [
[18109.918423] IOTLB_INV_TIMEOUT device=23:00.0 address=0x000000042bb12b20]
[18110.119761] sched: RT throttling activated
[18110.249804] AMD-Vi: Completion-Wait loop timed out
[18110.453355] AMD-Vi: Completion-Wait loop timed out
[18110.652707] AMD-Vi: Completion-Wait loop timed out
[18110.854045] AMD-Vi: Completion-Wait loop timed out
[18111.055387] AMD-Vi: Completion-Wait loop timed out
[18111.126714] AMD-Vi: Event logged [
[18111.126717] IOTLB_INV_TIMEOUT device=23:00.0 address=0x000000042bb12bc0]
[18111.127250] clocksource: Switched to clocksource hpet
[18111.144384] AMD-Vi: Completion-Wait loop timed out
[18111.274097] AMD-Vi: Completion-Wait loop timed out
[18111.427604] AMD-Vi: Completion-Wait loop timed out
[18111.533317] AMD-Vi: Completion-Wait loop timed out
[18111.663103] AMD-Vi: Completion-Wait loop timed out
[18111.891058] AMD-Vi: Event logged [
[18111.891061] IOTLB_INV_TIMEOUT device=23:00.0 address=0x000000042bb12c60]
[18111.894334] AMD-Vi: Completion-Wait loop timed out
[18112.024375] AMD-Vi: Completion-Wait loop timed out
[18112.167603] AMD-Vi: Completion-Wait loop timed out
[18112.297630] AMD-Vi: Completion-Wait loop timed out
[18112.427562] AMD-Vi: Completion-Wait loop timed out
[18112.557171] AMD-Vi: Completion-Wait loop timed out
[18112.689019] AMD-Vi: Completion-Wait loop timed out
[18112.891054] AMD-Vi: Event logged [
[18112.891056] IOTLB_INV_TIMEOUT device=23:00.0 address=0x000000042bb12d00]
[18112.927055] AMD-Vi: Completion-Wait loop timed out
[18113.039385] AMD-Vi: Completion-Wait loop timed out
[18113.187600] AMD-Vi: Completion-Wait loop timed out
[18113.315955] AMD-Vi: Completion-Wait loop timed out
[18113.445461] AMD-Vi: Completion-Wait loop timed out
[18113.600945] AMD-Vi: Completion-Wait loop timed out
[18113.724978] AMD-Vi: Completion-Wait loop timed out
[18113.891067] AMD-Vi: Event logged [
[18113.891069] IOTLB_INV_TIMEOUT device=23:00.0 address=0x000000042bb12da0]
[18113.854379] AMD-Vi: Completion-Wait loop timed out
[18114.024385] AMD-Vi: Completion-Wait loop timed out
[18114.173507] AMD-Vi: Completion-Wait loop timed out
[18114.310944] AMD-Vi: Completion-Wait loop timed out
[18114.573226] AMD-Vi: Completion-Wait loop timed out
[18114.621895] AMD-Vi: Completion-Wait loop timed out
[18114.734704] AMD-Vi: Completion-Wait loop timed out
[18114.891088] AMD-Vi: Event logged [
[18114.891090] IOTLB_INV_TIMEOUT device=23:00.0 address=0x000000042bb12e40]
[18114.910947] AMD-Vi: Completion-Wait loop timed out
[18115.039803] AMD-Vi: Completion-Wait loop timed out
[18115.184277] AMD-Vi: Completion-Wait loop timed out
[18115.324281] AMD-Vi: Completion-Wait loop timed out
[18115.464271] AMD-Vi: Completion-Wait loop timed out
[18115.677841] AMD-Vi: Completion-Wait loop timed out
[18115.747713] AMD-Vi: Completion-Wait loop timed out
[18115.891107] AMD-Vi: Event logged [
[18115.891109] IOTLB_INV_TIMEOUT device=23:00.0 address=0x000000042bb12ee0]
[18115.884118] AMD-Vi: Completion-Wait loop timed out
[18116.020404] AMD-Vi: Completion-Wait loop timed out
[18116.157621] AMD-Vi: Completion-Wait loop timed out
[18116.291560] AMD-Vi: Completion-Wait loop timed out
[18116.420952] AMD-Vi: Completion-Wait loop timed out
[18116.420952] ------------[ cut here ]------------
[18116.420952] WARNING: CPU: 4 PID: 0 at drivers/iommu/amd_iommu.c:1256 __domain_flush_pages+0x1d0/0x1f0
[18116.420952] Modules linked in: autofs4 dm_thin_pool dm_persistent_data dm_bufio dm_bio_prison nls_iso8859_1 nls_cp437 vfat fat xpad input_leds ff_memless led_class mxm_wmi kvm irqbypass efivars hwmon_vid nvidia_drm(PO) nvidia_modeset(PO) nvidia(PO) amdkfd i2c_piix4 amd_iommu_v2 amdgpu mfd_core i2c_algo_bit drm_kms_helper cfbfillrect syscopyarea cfbimgblt sysfillrect sysimgblt fb_sys_fops ttm cfbcopyarea drm r8169 mii wmi efivarfs
[18116.420952] CPU: 4 PID: 0 Comm: swapper/4 Tainted: P O 4.11.0+ #199
[18116.420952] Hardware name: MSI MS-7A33/X370 SLI PLUS (MS-7A33), BIOS 3.30 04/28/2017
[18116.420952] Call Trace:
[18116.420952] <IRQ>
[18116.420952] ? dump_stack+0x46/0x5a
[18116.420952] ? __warn+0xb9/0xe0
[18116.420952] ? __domain_flush_pages+0x1d0/0x1f0
[18116.420952] ? __queue_flush+0x41/0xc0
[18116.420952] ? __queue_flush+0x41/0xc0
[18116.420952] ? queue_flush_all+0x80/0x80
[18116.420952] ? queue_flush_all+0x6c/0x80
[18116.420952] ? queue_flush_all+0x80/0x80
[18116.420952] ? call_timer_fn+0x29/0x160
[18116.420952] ? queue_flush_all+0x80/0x80
[18116.420952] ? run_timer_softirq+0x1e5/0x450
[18116.420952] ? tick_sched_handle.isra.15+0x40/0x40
[18116.420952] ? tick_sched_handle.isra.15+0x29/0x40
[18116.420952] ? tick_sched_timer+0x33/0x60
[18116.420952] ? __do_softirq+0xfa/0x2e0
[18116.420952] ? irq_exit+0xa3/0xb0
[18116.420952] ? smp_apic_timer_interrupt+0x34/0x40
[18116.420952] ? apic_timer_interrupt+0x7f/0x90
[18116.420952] </IRQ>
[18116.420952] ? cpuidle_enter_state+0x113/0x2d0
[18116.420952] ? cpuidle_enter_state+0x102/0x2d0
[18116.420952] ? do_idle+0x16a/0x1d0
[18116.420952] ? cpu_startup_entry+0x14/0x20
[18116.420952] ? start_cpu+0x14/0x14
[18116.420952] ---[ end trace 8031b148282cc674 ]---
[18116.420952] AMD-Vi: Completion-Wait loop timed out
[18116.700947] AMD-Vi: Completion-Wait loop timed out
[18116.700947] ------------[ cut here ]------------
[18116.700947] WARNING: CPU: 4 PID: 0 at drivers/iommu/amd_iommu.c:1256 __domain_flush_pages+0x1d0/0x1f0
[18116.700947] Modules linked in: autofs4 dm_thin_pool dm_persistent_data dm_bufio dm_bio_prison nls_iso8859_1 nls_cp437 vfat fat xpad input_leds ff_memless led_class mxm_wmi kvm irqbypass efivars hwmon_vid nvidia_drm(PO) nvidia_modeset(PO) nvidia(PO) amdkfd i2c_piix4 amd_iommu_v2 amdgpu mfd_core i2c_algo_bit drm_kms_helper cfbfillrect syscopyarea cfbimgblt sysfillrect sysimgblt fb_sys_fops ttm cfbcopyarea drm r8169 mii wmi efivarfs
[18116.700947] CPU: 4 PID: 0 Comm: swapper/4 Tainted: P W O 4.11.0+ #199
[18116.700947] Hardware name: MSI MS-7A33/X370 SLI PLUS (MS-7A33), BIOS 3.30 04/28/2017
[18116.700947] Call Trace:
[18116.700947] <IRQ>
[18116.700947] ? dump_stack+0x46/0x5a
[18116.700947] ? __warn+0xb9/0xe0
[18116.700947] ? __domain_flush_pages+0x1d0/0x1f0
[18116.700947] ? __queue_flush+0x41/0xc0
[18116.700947] ? __queue_flush+0x41/0xc0
[18116.700947] ? queue_flush_all+0x80/0x80
[18116.700947] ? queue_flush_all+0x6c/0x80
[18116.700947] ? queue_flush_all+0x80/0x80
[18116.700947] ? call_timer_fn+0x29/0x160
[18116.700947] ? queue_flush_all+0x80/0x80
[18116.700947] ? run_timer_softirq+0x1e5/0x450
[18116.700947] ? tick_sched_handle.isra.15+0x40/0x40
[18116.700947] ? timerqueue_add+0x54/0xa0
[18116.700947] ? enqueue_hrtimer+0x33/0x90
[18116.700947] ? __do_softirq+0xfa/0x2e0
[18116.700947] ? irq_exit+0xa3/0xb0
[18116.700947] ? smp_apic_timer_interrupt+0x34/0x40
[18116.700947] ? apic_timer_interrupt+0x7f/0x90
[18116.700947] </IRQ>
[18116.700947] ? cpuidle_enter_state+0x113/0x2d0
[18116.700947] ? cpuidle_enter_state+0x102/0x2d0
[18116.700947] ? do_idle+0x16a/0x1d0
[18116.700947] ? cpu_startup_entry+0x14/0x20
[18116.700947] ? start_cpu+0x14/0x14
[18116.700947] ---[ end trace 8031b148282cc675 ]---
[18116.891112] AMD-Vi: Event logged [
[18116.891114] IOTLB_INV_TIMEOUT device=23:00.0 address=0x000000042bb12f80]
[18116.894435] AMD-Vi: Completion-Wait loop timed out
[18117.024351] AMD-Vi: Completion-Wait loop timed out
[18117.154682] AMD-Vi: Completion-Wait loop timed out
[18117.284702] AMD-Vi: Completion-Wait loop timed out
[18117.414678] AMD-Vi: Completion-Wait loop timed out
[18117.629124] AMD-Vi: Completion-Wait loop timed out
[18117.629124] AMD-Vi: Completion-Wait loop timed out
[18117.891190] AMD-Vi: Event logged [
[18117.891192] IOTLB_INV_TIMEOUT device=23:00.0 address=0x000000042bb13020]
[18117.894451] AMD-Vi: Completion-Wait loop timed out
[18118.024570] AMD-Vi: Completion-Wait loop timed out
[18118.154110] AMD-Vi: Completion-Wait loop timed out
[18118.320958] AMD-Vi: Completion-Wait loop timed out
[18118.423867] AMD-Vi: Completion-Wait loop timed out
[18118.553566] AMD-Vi: Completion-Wait loop timed out
[18118.683087] AMD-Vi: Completion-Wait loop timed out
[18118.891149] AMD-Vi: Event logged [
[18118.891151] IOTLB_INV_TIMEOUT device=23:00.0 address=0x000000042bb130a0]
[18118.947613] AMD-Vi: Completion-Wait loop timed out
[18119.024576] AMD-Vi: Completion-Wait loop timed out
[18119.249619] AMD-Vi: Completion-Wait loop timed out
[18119.314278] AMD-Vi: Completion-Wait loop timed out
[18119.456612] AMD-Vi: Completion-Wait loop timed out
[18119.602837] AMD-Vi: Completion-Wait loop timed out
[18119.734262] AMD-Vi: Completion-Wait loop timed out
[18119.891171] AMD-Vi: Event logged [
[18119.891173] IOTLB_INV_TIMEOUT device=23:00.0 address=0x000000042bb13140]
[18119.923845] AMD-Vi: Completion-Wait loop timed out
[18120.113568] AMD-Vi: Completion-Wait loop timed out
[18120.194383] AMD-Vi: Completion-Wait loop timed out
[18120.437792] AMD-Vi: Completion-Wait loop timed out
[18120.464487] AMD-Vi: Completion-Wait loop timed out
[18120.594263] AMD-Vi: Completion-Wait loop timed out
[18120.724266] AMD-Vi: Completion-Wait loop timed out
[18120.891190] AMD-Vi: Event logged [
[18120.891192] IOTLB_INV_TIMEOUT device=23:00.0 address=0x000000042bb131e0]
[18120.907716] AMD-Vi: Completion-Wait loop timed out
[18121.037845] AMD-Vi: Completion-Wait loop timed out
[18121.167698] AMD-Vi: Completion-Wait loop timed out
[18121.297737] AMD-Vi: Completion-Wait loop timed out
[18121.427691] AMD-Vi: Completion-Wait loop timed out
[18121.557819] AMD-Vi: Completion-Wait loop timed out
[18121.687864] AMD-Vi: Completion-Wait loop timed out
[18121.891226] AMD-Vi: Event logged [
[18121.891228] IOTLB_INV_TIMEOUT device=23:00.0 address=0x000000042bb13280]
[18121.894531] AMD-Vi: Completion-Wait loop timed out
[18122.024722] AMD-Vi: Completion-Wait loop timed out
[18122.154765] AMD-Vi: Completion-Wait loop timed out
[18122.284790] AMD-Vi: Completion-Wait loop timed out
[18122.414520] AMD-Vi: Completion-Wait loop timed out
[18122.544586] AMD-Vi: Completion-Wait loop timed out
[18122.694270] AMD-Vi: Completion-Wait loop timed out
[18122.891233] AMD-Vi: Event logged [
[18122.891235] IOTLB_INV_TIMEOUT device=23:00.0 address=0x000000042bb13320]
[18122.894553] AMD-Vi: Completion-Wait loop timed out
[18123.024665] AMD-Vi: Completion-Wait loop timed out
[18123.167594] AMD-Vi: Completion-Wait loop timed out
[18123.294126] AMD-Vi: Completion-Wait loop timed out
[18123.424127] AMD-Vi: Completion-Wait loop timed out
[18123.570945] AMD-Vi: Completion-Wait loop timed out
[18123.699899] AMD-Vi: Completion-Wait loop timed out
[18123.891252] AMD-Vi: Event logged [
[18123.891254] IOTLB_INV_TIMEOUT device=23:00.0 address=0x000000042bb133c0]
[18123.946365] AMD-Vi: Completion-Wait loop timed out
[18124.054278] AMD-Vi: Completion-Wait loop timed out
[18124.054278] ------------[ cut here ]------------
[18124.054278] WARNING: CPU: 3 PID: 0 at drivers/iommu/amd_iommu.c:1256 __domain_flush_pages+0x1d0/0x1f0
[18124.054278] Modules linked in: autofs4 dm_thin_pool dm_persistent_data dm_bufio dm_bio_prison nls_iso8859_1 nls_cp437 vfat fat xpad input_leds ff_memless led_class mxm_wmi kvm irqbypass efivars hwmon_vid nvidia_drm(PO) nvidia_modeset(PO) nvidia(PO) amdkfd i2c_piix4 amd_iommu_v2 amdgpu mfd_core i2c_algo_bit drm_kms_helper cfbfillrect syscopyarea cfbimgblt sysfillrect sysimgblt fb_sys_fops ttm cfbcopyarea drm r8169 mii wmi efivarfs
[18124.054278] CPU: 3 PID: 0 Comm: swapper/3 Tainted: P W O 4.11.0+ #199
[18124.054278] Hardware name: MSI MS-7A33/X370 SLI PLUS (MS-7A33), BIOS 3.30 04/28/2017
[18124.054278] Call Trace:
[18124.054278] <IRQ>
[18124.054278] ? dump_stack+0x46/0x5a
[18124.054278] ? __warn+0xb9/0xe0
[18124.054278] ? __domain_flush_pages+0x1d0/0x1f0
[18124.054278] ? __queue_flush+0x41/0xc0
[18124.054278] ? __queue_flush+0x41/0xc0
[18124.054278] ? queue_flush_all+0x80/0x80
[18124.054278] ? queue_flush_all+0x6c/0x80
[18124.054278] ? queue_flush_all+0x80/0x80
[18124.054278] ? call_timer_fn+0x29/0x160
[18124.054278] ? queue_flush_all+0x80/0x80
[18124.054278] ? run_timer_softirq+0x1e5/0x450
[18124.054278] ? tick_sched_handle.isra.15+0x40/0x40
[18124.054278] ? tick_sched_handle.isra.15+0x29/0x40
[18124.054278] ? tick_sched_timer+0x33/0x60
[18124.054278] ? __do_softirq+0xfa/0x2e0
[18124.054278] ? irq_exit+0xa3/0xb0
[18124.054278] ? smp_apic_timer_interrupt+0x34/0x40
[18124.054278] ? apic_timer_interrupt+0x7f/0x90
[18124.054278] </IRQ>
[18124.054278] ? cpuidle_enter_state+0x113/0x2d0
[18124.054278] ? cpuidle_enter_state+0x102/0x2d0
[18124.054278] ? do_idle+0x16a/0x1d0
[18124.054278] ? cpu_startup_entry+0x14/0x20
[18124.054278] ? start_cpu+0x14/0x14
[18124.054278] ---[ end trace 8031b148282cc676 ]---
[18124.054278] AMD-Vi: Completion-Wait loop timed out
[18124.292675] AMD-Vi: Completion-Wait loop timed out
[18124.292675] ------------[ cut here ]------------
[18124.292675] WARNING: CPU: 3 PID: 0 at drivers/iommu/amd_iommu.c:1256 __domain_flush_pages+0x1d0/0x1f0
[18124.292675] Modules linked in: autofs4 dm_thin_pool dm_persistent_data dm_bufio dm_bio_prison nls_iso8859_1 nls_cp437 vfat fat xpad input_leds ff_memless led_class mxm_wmi kvm irqbypass efivars hwmon_vid nvidia_drm(PO) nvidia_modeset(PO) nvidia(PO) amdkfd i2c_piix4 amd_iommu_v2 amdgpu mfd_core i2c_algo_bit drm_kms_helper cfbfillrect syscopyarea cfbimgblt sysfillrect sysimgblt fb_sys_fops ttm cfbcopyarea drm r8169 mii wmi efivarfs
[18124.292675] CPU: 3 PID: 0 Comm: swapper/3 Tainted: P W O 4.11.0+ #199
[18124.292675] Hardware name: MSI MS-7A33/X370 SLI PLUS (MS-7A33), BIOS 3.30 04/28/2017
[18124.292675] Call Trace:
[18124.292675] <IRQ>
[18124.292675] ? dump_stack+0x46/0x5a
[18124.292675] ? __warn+0xb9/0xe0
[18124.292675] ? __domain_flush_pages+0x1d0/0x1f0
[18124.292675] ? __queue_flush+0x41/0xc0
[18124.292675] ? __queue_flush+0x41/0xc0
[18124.292675] ? queue_flush_all+0x80/0x80
[18124.292675] ? queue_flush_all+0x6c/0x80
[18124.292675] ? queue_flush_all+0x80/0x80
[18124.292675] ? call_timer_fn+0x29/0x160
[18124.292675] ? queue_flush_all+0x80/0x80
[18124.292675] ? run_timer_softirq+0x1e5/0x450
[18124.292675] ? tick_sched_handle.isra.15+0x40/0x40
[18124.292675] ? tick_sched_handle.isra.15+0x29/0x40
[18124.292675] ? tick_sched_timer+0x33/0x60
[18124.292675] ? __do_softirq+0xfa/0x2e0
[18124.292675] ? irq_exit+0xa3/0xb0
[18124.292675] ? smp_apic_timer_interrupt+0x34/0x40
[18124.292675] ? apic_timer_interrupt+0x7f/0x90
[18124.292675] </IRQ>
[18124.292675] ? cpuidle_enter_state+0x113/0x2d0
[18124.292675] ? cpuidle_enter_state+0x102/0x2d0
[18124.292675] ? do_idle+0x16a/0x1d0
[18124.292675] ? cpu_startup_entry+0x14/0x20
[18124.292675] ? start_cpu+0x14/0x14
[18124.292675] ---[ end trace 8031b148282cc677 ]---
[18124.292675] AMD-Vi: Completion-Wait loop timed out
[18124.553754] AMD-Vi: Completion-Wait loop timed out
[18124.694048] AMD-Vi: Completion-Wait loop timed out
[18124.891268] AMD-Vi: Event logged [
[18124.891272] IOTLB_INV_TIMEOUT device=23:00.0 address=0x000000042bb13460]
[18124.946395] AMD-Vi: Completion-Wait loop timed out
[18125.040944] AMD-Vi: Completion-Wait loop timed out
[18125.170647] AMD-Vi: Completion-Wait loop timed out
[18125.300141] AMD-Vi: Completion-Wait loop timed out
[18125.429793] AMD-Vi: Completion-Wait loop timed out
[18125.574273] AMD-Vi: Completion-Wait loop timed out
[18125.703849] AMD-Vi: Completion-Wait loop timed out
[18125.891295] AMD-Vi: Event logged [
[18125.891297] IOTLB_INV_TIMEOUT device=23:00.0 address=0x000000042bb13500]
[18125.946133] AMD-Vi: Completion-Wait loop timed out
[18126.020951] AMD-Vi: Completion-Wait loop timed out
[18126.167769] AMD-Vi: Completion-Wait loop timed out
[18126.314274] AMD-Vi: Completion-Wait loop timed out
[18126.457592] AMD-Vi: Completion-Wait loop timed out
[18126.597591] AMD-Vi: Completion-Wait loop timed out
[18126.740942] AMD-Vi: Completion-Wait loop timed out
[18126.891474] AMD-Vi: Event logged [
[18126.891476] IOTLB_INV_TIMEOUT device=23:00.0 address=0x000000042bb13580]
[18126.894636] AMD-Vi: Completion-Wait loop timed out
[18127.037591] AMD-Vi: Completion-Wait loop timed out
[18127.167141] AMD-Vi: Completion-Wait loop timed out
[18127.296771] AMD-Vi: Completion-Wait loop timed out
[18127.426252] AMD-Vi: Completion-Wait loop timed out
More information about the amd-gfx
mailing list