mirror of
https://github.com/edk2-porting/linux-next.git
synced 2024-12-26 14:14:01 +08:00
s390/pci: fix bar check
Fix the check which bar space we should map to allow available bars only. Signed-off-by: Sebastian Ott <sebott@linux.vnet.ibm.com> Reviewed-by: Gerald Schaefer <gerald.schaefer@de.ibm.com> Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
This commit is contained in:
parent
c506fff3d3
commit
c0cabaddee
@ -270,7 +270,7 @@ void __iomem *pci_iomap_range(struct pci_dev *pdev,
|
||||
struct zpci_dev *zdev = to_zpci(pdev);
|
||||
int idx;
|
||||
|
||||
if ((bar & 7) != bar)
|
||||
if (!pci_resource_len(pdev, bar))
|
||||
return NULL;
|
||||
|
||||
idx = zdev->bars[bar].map_idx;
|
||||
|
Loading…
Reference in New Issue
Block a user