PCI: don't allow "pci-phantom=" to mark real devices as phantom functions
authorJan Beulich <jbeulich@suse.com>
Tue, 7 Jun 2022 12:08:06 +0000 (14:08 +0200)
committerJan Beulich <jbeulich@suse.com>
Tue, 7 Jun 2022 12:08:06 +0000 (14:08 +0200)
commit8e11ec8fbf6f933f8854f4bc54226653316903f2
treef60de904c86c434ccdf6ec71f6c9ac1da987dd1a
parentf1be0b62a03b90a40a03e21f965e4cbb89809bb1
PCI: don't allow "pci-phantom=" to mark real devices as phantom functions

IOMMU code mapping / unmapping devices and interrupts will misbehave if
a wrong command line option declared a function "phantom" when there's a
real device at that position. Warn about this and adjust the specified
stride (in the worst case ignoring the option altogether).

Requested-by: Andrew Cooper <andrew.cooper3@citrix.com>
Signed-off-by: Jan Beulich <jbeulich@suse.com>
Reviewed-by: Roger Pau Monné <roger.pau@citrix.com>
master commit: 444b555dc9e09fa3ce90f066e0c88dec9b47f422
master date: 2022-05-20 12:20:35 +0200
xen/drivers/passthrough/pci.c