]> git.baikalelectronics.ru Git - kernel.git/commit
PCI: hv: Do not wait forever on a device that has disappeared
authorDexuan Cui <decui@microsoft.com>
Wed, 23 May 2018 21:12:01 +0000 (21:12 +0000)
committerLorenzo Pieralisi <lorenzo.pieralisi@arm.com>
Fri, 25 May 2018 12:27:50 +0000 (13:27 +0100)
commit1afd531399864601c7fca2123835d87721aecf6b
tree48392fc384fd10c9ea18c5e24ad711581a1a99f1
parent2698539ba24f95e0ee71f9cfc1978818e0be2fb6
PCI: hv: Do not wait forever on a device that has disappeared

Before the guest finishes the device initialization, the device can be
removed anytime by the host, and after that the host won't respond to
the guest's request, so the guest should be prepared to handle this
case.

Add a polling mechanism to detect device presence.

Signed-off-by: Dexuan Cui <decui@microsoft.com>
[lorenzo.pieralisi@arm.com: edited commit log]
Signed-off-by: Lorenzo Pieralisi <lorenzo.pieralisi@arm.com>
Reviewed-by: Haiyang Zhang <haiyangz@microsoft.com>
Cc: Stephen Hemminger <sthemmin@microsoft.com>
Cc: K. Y. Srinivasan <kys@microsoft.com>
drivers/pci/host/pci-hyperv.c