diff options
author | Sebastian Ott | 2019-06-27 15:13:05 +0200 |
---|---|---|
committer | Vasily Gorbik | 2019-07-04 13:13:57 +0200 |
commit | c7ff0e918a7cb39f6bfb2a7bdc30199986ff1571 (patch) | |
tree | 072ed18459ad304b530f9a0af4442abd7e9943b1 /arch/s390/include | |
parent | 05f31e3bf6b34fe6e4922868d132f6455f81d5bf (diff) |
s390/pci: deal with devices that have no support for MIO instructions
Unfortunately we have to handle a class of devices that don't support the
new MIO instructions. Adjust resource assignment and mapping accordingly.
Signed-off-by: Sebastian Ott <sebott@linux.ibm.com>
Signed-off-by: Vasily Gorbik <gor@linux.ibm.com>
Diffstat (limited to 'arch/s390/include')
-rw-r--r-- | arch/s390/include/asm/pci.h | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/arch/s390/include/asm/pci.h b/arch/s390/include/asm/pci.h index 305befd55326..a2399eff84ca 100644 --- a/arch/s390/include/asm/pci.h +++ b/arch/s390/include/asm/pci.h @@ -194,6 +194,11 @@ int zpci_init_iommu(struct zpci_dev *zdev); void zpci_destroy_iommu(struct zpci_dev *zdev); #ifdef CONFIG_PCI +static inline bool zpci_use_mio(struct zpci_dev *zdev) +{ + return static_branch_likely(&have_mio) && zdev->mio_capable; +} + /* Error handling and recovery */ void zpci_event_error(void *); void zpci_event_availability(void *); |