summaryrefslogtreecommitdiffstats
path: root/sys/dev/pci
diff options
context:
space:
mode:
authorse <se@FreeBSD.org>1996-01-23 21:48:28 +0000
committerse <se@FreeBSD.org>1996-01-23 21:48:28 +0000
commit9516aa2cafa23657dcba24410ae70f85a607f592 (patch)
tree0c05d619dce00b4358e22aba692e8f11615d00c7 /sys/dev/pci
parent1d9e7dac5c0c9137300b85bf72dbd842b1e65eaa (diff)
downloadFreeBSD-src-9516aa2cafa23657dcba24410ae70f85a607f592.zip
FreeBSD-src-9516aa2cafa23657dcba24410ae70f85a607f592.tar.gz
Make PCI interrupt handlers return void like everybody else does.
Reviewed by: davidg
Diffstat (limited to 'sys/dev/pci')
-rw-r--r--sys/dev/pci/pci.c35
-rw-r--r--sys/dev/pci/pcivar.h11
2 files changed, 12 insertions, 34 deletions
diff --git a/sys/dev/pci/pci.c b/sys/dev/pci/pci.c
index c1b6873..a73d9c5 100644
--- a/sys/dev/pci/pci.c
+++ b/sys/dev/pci/pci.c
@@ -1,6 +1,6 @@
/**************************************************************************
**
-** $Id: pci.c,v 1.39 1995/12/16 00:27:46 bde Exp $
+** $Id: pci.c,v 1.40 1996/01/19 19:01:19 se Exp $
**
** General subroutines for the PCI bus.
** pci_configure ()
@@ -1149,38 +1149,23 @@ static void
pci_int (int irq)
{
struct pci_int_desc * p;
- int c, s;
-#ifdef PCI_EDGE_INT
- int i, n;
-#endif
+ int s;
+
if (irq<0 || irq >= PCI_MAX_IRQ) {
printf ("pci_int: irq %d out of range, ignored\n", irq);
return;
};
-
-#ifdef PCI_EDGE_INT
- for (i=0; i<1000; i++) {
- n = 0;
-#endif
- for (p = pci_int_desc[irq]; p!=NULL; p=p->pcid_next) {
- s = splq (*p->pcid_maskptr);
- c= (*p->pcid_handler) (p->pcid_argument);
- p-> pcid_tally += c;
- splx (s);
-#ifdef PCI_EDGE_INT
- n += c;
-#endif
+ for (p = pci_int_desc[irq]; p!=NULL; p=p->pcid_next) {
+ s = splq (*p->pcid_maskptr);
+ (*p->pcid_handler) (p->pcid_argument);
+ p-> pcid_tally++;
+ splx (s);
#if 0
- if (c && p->pcid_tally<20)
+ if (p->pcid_tally<20)
printf ("PCI_INT: irq=%d h=%p cpl o=%x n=%x val=%d\n",
- irq, p->pcid_handler, s, cpl, c);
+ irq, p->pcid_handler, s, cpl, c);
#endif
- };
-#ifdef PCI_EDGE_INT
- if (!n) return;
};
- printf ("pci_int(%d): permanent interrupt request.\n", irq);
-#endif
}
#endif
diff --git a/sys/dev/pci/pcivar.h b/sys/dev/pci/pcivar.h
index c405771..50a037f 100644
--- a/sys/dev/pci/pcivar.h
+++ b/sys/dev/pci/pcivar.h
@@ -1,6 +1,6 @@
/**************************************************************************
**
-** $Id: pcivar.h,v 1.6 1995/05/30 08:13:12 rgrimes Exp $
+** $Id: pcivar.h,v 1.7 1995/11/21 12:54:55 bde Exp $
**
** Declarations for pci device drivers.
**
@@ -228,17 +228,10 @@ int pci_map_port (pcici_t tag, u_long entry, u_short * pa);
**
** Supports multiple handlers per irq (shared interrupts).
**
-** -----------------
-**
-** There is code to support shared edge triggered ints.
-** This relies on the cooperation of the interrupt handlers:
-** they have to return a value <>0 if and only if something
-** was done. Beware of the performance penalty.
-**
**-----------------------------------------------------------------
*/
-typedef int pci_inthand_t(void *arg);
+typedef void pci_inthand_t(void *arg);
struct pci_int_desc {
struct pci_int_desc * pcid_next;
OpenPOWER on IntegriCloud