mirror of https://gitee.com/openkylin/linux.git
Merge branch 'remotes/lorenzo/pci/vmd'
- Fix vmd resource address calculation using Host Physical Address shadow register (Jon Derrick) * remotes/lorenzo/pci/vmd: PCI: vmd: Filter resource type bits from shadow register
This commit is contained in:
commit
2bd81cd04a
|
@ -445,9 +445,11 @@ static int vmd_enable_domain(struct vmd_dev *vmd, unsigned long features)
|
|||
if (!membar2)
|
||||
return -ENOMEM;
|
||||
offset[0] = vmd->dev->resource[VMD_MEMBAR1].start -
|
||||
readq(membar2 + MB2_SHADOW_OFFSET);
|
||||
(readq(membar2 + MB2_SHADOW_OFFSET) &
|
||||
PCI_BASE_ADDRESS_MEM_MASK);
|
||||
offset[1] = vmd->dev->resource[VMD_MEMBAR2].start -
|
||||
readq(membar2 + MB2_SHADOW_OFFSET + 8);
|
||||
(readq(membar2 + MB2_SHADOW_OFFSET + 8) &
|
||||
PCI_BASE_ADDRESS_MEM_MASK);
|
||||
pci_iounmap(vmd->dev, membar2);
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue