mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2024-08-26 10:49:33 +00: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
1 changed files with 1 additions and 1 deletions
|
@ -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 a new issue