summaryrefslogtreecommitdiff
path: root/sys/dev/pci/drm
diff options
context:
space:
mode:
authorOwain Ainsworth <oga@cvs.openbsd.org>2008-12-08 19:16:01 +0000
committerOwain Ainsworth <oga@cvs.openbsd.org>2008-12-08 19:16:01 +0000
commite635ed2fe5cf33d147a802ab7ca27cbe5c73d1a5 (patch)
treeb96018034772dda671bff8dfff19c57146196022 /sys/dev/pci/drm
parent9ef2a3fe2bed096bb54e91ec21a79c6b58c8239b (diff)
Don't forget to map the pci interrupt.
Noticed by kettenis@.
Diffstat (limited to 'sys/dev/pci/drm')
-rw-r--r--sys/dev/pci/drm/mga_drv.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/sys/dev/pci/drm/mga_drv.c b/sys/dev/pci/drm/mga_drv.c
index ae790759e68..278249746d7 100644
--- a/sys/dev/pci/drm/mga_drv.c
+++ b/sys/dev/pci/drm/mga_drv.c
@@ -167,8 +167,12 @@ mgadrm_attach(struct device *parent, struct device *self, void *aux)
printf(": can't map mmio space\n");
return;
}
- /* XXX map interrupt */
- printf("\n");
+
+ if (pci_intr_map(pa, &dev_priv->ih) != 0) {
+ printf(": couldn't map interrupt\n");
+ return;
+ }
+ printf(": %s\n", pci_intr_string(pa->pa_pc, dev_priv->ih));
/* XXX pcie */
is_agp = pci_get_capability(pa->pa_pc, pa->pa_tag, PCI_CAP_AGP,