Pcie: Inject pending HP interrupt when guest enable HP interrupt
Pcie: Inject pending HP interrupt when guest enable HP interrupt

When pcie port driver put device into suspended state, it will
disable hotplug interrupt. So in order to inject virtual hotplug
interrupt into guest, virtual pcie port injects a virtual PME into
guest to resume pcie port, then pcie port driver enable hotplug
interrupt, finally virtual hotplug interrupt is injected after
PME is handled by guest.

Previously pending HP interrupt is injected at guest clear root
port's PME status, this is work for pcie root port only. Pcie
downstream port doesn't have root port's PME status. This commit
changes the time for injecting pending HP interrupt when guest
enable HP interrupt in PME handler.

BUG=b:199986018
TEST=Check root/downstream port's hotplug function in guest

Change-Id: Iffaa1fc73f13e1b940a45459fbcdc51af11dcca8
Reviewed-on: https://chromium-review.googlesource.com/c/crosvm/crosvm/+/3824072
Commit-Queue: Daniel Verkamp <72bc170b46ec491f7bdd4359a1c0bfed274de40c@chromium.org>
Tested-by: Daniel Verkamp <72bc170b46ec491f7bdd4359a1c0bfed274de40c@chromium.org>
Reviewed-by: Daniel Verkamp <72bc170b46ec491f7bdd4359a1c0bfed274de40c@chromium.org>

google/crosvm,google/crosvm,google/crosvm,google/crosvm