acrn-kernel/drivers/xen
Jakub Kądziołka ff32baa1f3 xen: don't hang when resuming PCI device
If a xen domain with at least two VCPUs has a PCI device attached which
enters the D3hot state during suspend, the kernel may hang while
resuming, depending on the core on which an async resume task gets
scheduled.

The bug occurs because xen's do_suspend calls dpm_resume_start while
only the timer of the boot CPU has been resumed (when xen_suspend called
syscore_resume), before calling xen_arch_suspend to resume the timers of
the other CPUs. This breaks pci_dev_d3_sleep.

Thus this patch moves the call to xen_arch_resume before the call to
dpm_resume_start, eliminating the hangs and restoring the stack-like
structure of the suspend/restore procedure.

Signed-off-by: Jakub Kądziołka <niedzejkob@invisiblethingslab.com>
Reviewed-by: Juergen Gross <jgross@suse.com>
Link: https://lore.kernel.org/r/20220323012103.2537-1-niedzejkob@invisiblethingslab.com
Signed-off-by: Boris Ostrovsky <boris.ostrovsky@oracle.com>
2022-03-25 14:22:15 -05:00
..
events xen/console: harden hvc_xen against event channel storms 2021-12-16 08:24:08 +01:00
xen-pciback
xenbus xen/xenbus: don't let xenbus_grant_ring() remove grants in error case 2022-03-07 09:48:54 +01:00
xenfs
Kconfig arm/xen: Read extended regions from DT and init Xen resource 2022-01-06 09:53:41 +01:00
Makefile
acpi.c
arm-device.c
balloon.c xen: use time_is_before_eq_jiffies() instead of open coding it 2022-03-10 09:27:55 -06:00
biomerge.c
cpu_hotplug.c
dbgp.c
efi.c
evtchn.c
features.c
gntalloc.c xen/grant-table: remove readonly parameter from functions 2022-03-15 20:34:40 -05:00
gntdev-common.h
gntdev-dmabuf.c xen/grant-table: remove readonly parameter from functions 2022-03-15 20:34:40 -05:00
gntdev-dmabuf.h
gntdev.c xen/gntdev: fix unmap notification order 2022-01-06 08:52:22 +01:00
grant-table.c xen/grant-table: remove readonly parameter from functions 2022-03-15 20:34:40 -05:00
manage.c xen: don't hang when resuming PCI device 2022-03-25 14:22:15 -05:00
mcelog.c
mem-reservation.c
pci.c xen/pci: Make use of the helper macro LIST_HEAD() 2022-02-10 11:10:23 +01:00
pcpu.c
platform-pci.c
privcmd-buf.c
privcmd.c
privcmd.h
pvcalls-back.c
pvcalls-front.c xen/grant-table: remove readonly parameter from functions 2022-03-15 20:34:40 -05:00
pvcalls-front.h
swiotlb-xen.c
sys-hypervisor.c drivers/xen: use helper macro __ATTR_RW 2022-03-10 09:27:55 -06:00
time.c
unpopulated-alloc.c xen/unpopulated-alloc: Add mechanism to use Xen resource 2022-01-06 09:53:38 +01:00
xen-acpi-pad.c
xen-acpi-processor.c
xen-balloon.c
xen-front-pgdir-shbuf.c xen/grant-table: remove readonly parameter from functions 2022-03-15 20:34:40 -05:00
xen-scsiback.c
xlate_mmu.c