diff options
author | 2008-10-22 19:53:31 +0000 | |
---|---|---|
committer | 2008-10-22 19:53:31 +0000 | |
commit | 590907c79030b1282c09bd651fe07db6ee05dabe (patch) | |
tree | 0eff6707a96213332bebff93d71eba235193c169 | |
parent | This isn't a real structure the firmware understands. (diff) | |
download | wireguard-openbsd-590907c79030b1282c09bd651fe07db6ee05dabe.tar.xz wireguard-openbsd-590907c79030b1282c09bd651fe07db6ee05dabe.zip |
Only call pic->pic_delroute() when disestablishing the last interrupt handler
for a pin. Resolves issues with azalia(4) devices that have no usable codecs
when they share an interrupt pin with other devices.
ok weingart@, krw@
-rw-r--r-- | sys/arch/amd64/amd64/intr.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/sys/arch/amd64/amd64/intr.c b/sys/arch/amd64/amd64/intr.c index 6756c90b6fe..04969b9043b 100644 --- a/sys/arch/amd64/amd64/intr.c +++ b/sys/arch/amd64/amd64/intr.c @@ -1,4 +1,4 @@ -/* $OpenBSD: intr.c,v 1.18 2008/10/09 18:35:38 chl Exp $ */ +/* $OpenBSD: intr.c,v 1.19 2008/10/22 19:53:31 kettenis Exp $ */ /* $NetBSD: intr.c,v 1.3 2003/03/03 22:16:20 fvdl Exp $ */ /* @@ -515,8 +515,10 @@ intr_disestablish(struct intrhand *ih) *p = q->ih_next; intr_calculatemasks(ci); - pic->pic_delroute(pic, ci, ih->ih_pin, idtvec, source->is_type); - pic->pic_hwunmask(pic, ih->ih_pin); + if (source->is_handlers == NULL) + pic->pic_delroute(pic, ci, ih->ih_pin, idtvec, source->is_type); + else + pic->pic_hwunmask(pic, ih->ih_pin); #ifdef INTRDEBUG printf("cpu%u: remove slot %d (pic %s pin %d vec %d)\n", |