diff options
author | 2011-05-30 21:16:57 +0000 | |
---|---|---|
committer | 2011-05-30 21:16:57 +0000 | |
commit | ac50c516d8609120d9ead186d4f8745cdb2c62f7 (patch) | |
tree | 862e72b1ca642035bb23289f71ee622853f9fdd8 | |
parent | Remove vndshutdown. It is unused. (diff) | |
download | wireguard-openbsd-ac50c516d8609120d9ead186d4f8745cdb2c62f7.tar.xz wireguard-openbsd-ac50c516d8609120d9ead186d4f8745cdb2c62f7.zip |
Enable MSI on inteldrm.
Disable it explictly for i945g and i945gm because according to linux
(which is written by intel people) msi is buggy as hell on that chipset.
ok kettenis@
-rw-r--r-- | sys/dev/pci/drm/i915_drv.c | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/sys/dev/pci/drm/i915_drv.c b/sys/dev/pci/drm/i915_drv.c index bab8dcd0094..bd51b409064 100644 --- a/sys/dev/pci/drm/i915_drv.c +++ b/sys/dev/pci/drm/i915_drv.c @@ -359,7 +359,15 @@ inteldrm_attach(struct device *parent, struct device *self, void *aux) return; } - if (pci_intr_map(pa, &dev_priv->ih) != 0) { + /* + * i945G/GM report MSI capability despite not actually supporting it. + * so explicitly disable it. + */ + if (IS_I945G(dev_priv) || IS_I945GM(dev_priv)) + pa->pa_flags &= ~PCI_FLAGS_MSI_ENABLED; + + if (pci_intr_map_msi(pa, &dev_priv->ih) != 0 && + pci_intr_map(pa, &dev_priv->ih) != 0) { printf(": couldn't map interrupt\n"); return; } |