summaryrefslogtreecommitdiff
path: root/sys/dev/pci/drm
diff options
context:
space:
mode:
authorJonathan Gray <jsg@cvs.openbsd.org>2018-05-23 02:24:59 +0000
committerJonathan Gray <jsg@cvs.openbsd.org>2018-05-23 02:24:59 +0000
commit4a672f9a334219064052a885805ee3195ec70b71 (patch)
tree41865d256a7319ae7ec4e4cc744b5a444333bf4e /sys/dev/pci/drm
parent757c13b8c2b93f1fbf31dac57ef0bd26a4bb6ffc (diff)
Add back a local change to prevent interrupt handlers claiming an
interrupt when it is shared by other devices. Fixes a regression reported by nigel@ where USB stopped working after the radeondrm update on a machine where ohci shared an interrupt with radeondrm.
Diffstat (limited to 'sys/dev/pci/drm')
-rw-r--r--sys/dev/pci/drm/radeon/cik.c2
-rw-r--r--sys/dev/pci/drm/radeon/evergreen.c2
-rw-r--r--sys/dev/pci/drm/radeon/r600.c2
-rw-r--r--sys/dev/pci/drm/radeon/si.c2
4 files changed, 8 insertions, 0 deletions
diff --git a/sys/dev/pci/drm/radeon/cik.c b/sys/dev/pci/drm/radeon/cik.c
index 5ce8951c2bc..515a033f156 100644
--- a/sys/dev/pci/drm/radeon/cik.c
+++ b/sys/dev/pci/drm/radeon/cik.c
@@ -7901,6 +7901,8 @@ int cik_irq_process(struct radeon_device *rdev)
wptr = cik_get_ih_wptr(rdev);
+ if (wptr == rdev->ih.rptr)
+ return IRQ_NONE;
restart_ih:
/* is somebody else already processing irqs? */
if (atomic_xchg(&rdev->ih.lock, 1))
diff --git a/sys/dev/pci/drm/radeon/evergreen.c b/sys/dev/pci/drm/radeon/evergreen.c
index 255f6fe90e1..e10aca71c96 100644
--- a/sys/dev/pci/drm/radeon/evergreen.c
+++ b/sys/dev/pci/drm/radeon/evergreen.c
@@ -5072,6 +5072,8 @@ int evergreen_irq_process(struct radeon_device *rdev)
wptr = evergreen_get_ih_wptr(rdev);
+ if (wptr == rdev->ih.rptr)
+ return IRQ_NONE;
restart_ih:
/* is somebody else already processing irqs? */
if (atomic_xchg(&rdev->ih.lock, 1))
diff --git a/sys/dev/pci/drm/radeon/r600.c b/sys/dev/pci/drm/radeon/r600.c
index 05ca3ffbb65..ddfcbbd1e7a 100644
--- a/sys/dev/pci/drm/radeon/r600.c
+++ b/sys/dev/pci/drm/radeon/r600.c
@@ -4058,6 +4058,8 @@ int r600_irq_process(struct radeon_device *rdev)
wptr = r600_get_ih_wptr(rdev);
+ if (wptr == rdev->ih.rptr)
+ return IRQ_NONE;
restart_ih:
/* is somebody else already processing irqs? */
if (atomic_xchg(&rdev->ih.lock, 1))
diff --git a/sys/dev/pci/drm/radeon/si.c b/sys/dev/pci/drm/radeon/si.c
index 3d47942e94b..f7e77e824b5 100644
--- a/sys/dev/pci/drm/radeon/si.c
+++ b/sys/dev/pci/drm/radeon/si.c
@@ -6441,6 +6441,8 @@ int si_irq_process(struct radeon_device *rdev)
wptr = si_get_ih_wptr(rdev);
+ if (wptr == rdev->ih.rptr)
+ return IRQ_NONE;
restart_ih:
/* is somebody else already processing irqs? */
if (atomic_xchg(&rdev->ih.lock, 1))