Commit 6dda569f authored by Chris Wilson's avatar Chris Wilson

drm/i915: Switch to using pci_iounmap in conjunction with pci_iomap

After switching the MMIO registers to use pci_iomap, remember to dispose
of the mapping with pci_iounmap (for symmetry).
Signed-off-by: default avatarChris Wilson <chris@chris-wilson.co.uk>
parent 4066c0ae
...@@ -2082,7 +2082,7 @@ int i915_driver_load(struct drm_device *dev, unsigned long flags) ...@@ -2082,7 +2082,7 @@ int i915_driver_load(struct drm_device *dev, unsigned long flags)
out_iomapfree: out_iomapfree:
io_mapping_free(dev_priv->mm.gtt_mapping); io_mapping_free(dev_priv->mm.gtt_mapping);
out_rmmap: out_rmmap:
iounmap(dev_priv->regs); pci_iounmap(dev->pdev, dev_priv->regs);
put_bridge: put_bridge:
pci_dev_put(dev_priv->bridge_dev); pci_dev_put(dev_priv->bridge_dev);
free_priv: free_priv:
...@@ -2168,7 +2168,7 @@ int i915_driver_unload(struct drm_device *dev) ...@@ -2168,7 +2168,7 @@ int i915_driver_unload(struct drm_device *dev)
} }
if (dev_priv->regs != NULL) if (dev_priv->regs != NULL)
iounmap(dev_priv->regs); pci_iounmap(dev->pdev, dev_priv->regs);
intel_teardown_gmbus(dev); intel_teardown_gmbus(dev);
intel_teardown_mchbar(dev); intel_teardown_mchbar(dev);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment