Page MenuHomeFreeBSD

D45905.diff
No OneTemporary

D45905.diff

diff --git a/sys/compat/linuxkpi/common/src/linux_pci.c b/sys/compat/linuxkpi/common/src/linux_pci.c
--- a/sys/compat/linuxkpi/common/src/linux_pci.c
+++ b/sys/compat/linuxkpi/common/src/linux_pci.c
@@ -780,12 +780,18 @@
linuxkpi_pci_iounmap(struct pci_dev *pdev, void *res)
{
struct pci_mmio_region *mmio, *p;
+ bus_space_handle_t bh = (bus_space_handle_t)res;
TAILQ_FOREACH_SAFE(mmio, &pdev->mmio, next, p) {
- if ((bus_space_handle_t)res < rman_get_bushandle(mmio->res) ||
- (bus_space_handle_t)res >= rman_get_bushandle(mmio->res) +
- rman_get_size(mmio->res))
- continue;
+ if (pdev->want_iomap_res) {
+ if (res != mmio->res)
+ continue;
+ } else {
+ if (bh < rman_get_bushandle(mmio->res) ||
+ bh >= rman_get_bushandle(mmio->res) +
+ rman_get_size(mmio->res))
+ continue;
+ }
bus_release_resource(pdev->dev.bsddev,
mmio->type, mmio->rid, mmio->res);
TAILQ_REMOVE(&pdev->mmio, mmio, next);

File Metadata

Mime Type
text/plain
Expires
Fri, Jan 10, 9:12 PM (15 h, 40 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
15746690
Default Alt Text
D45905.diff (961 B)

Event Timeline