Date: Tue, 13 Jun 2006 22:19:23 GMT From: Paolo Pisati <piso@FreeBSD.org> To: Perforce Change Reviews <perforce@freebsd.org> Subject: PERFORCE change 99182 for review Message-ID: <200606132219.k5DMJNT7000861@repoman.freebsd.org>
next in thread | raw e-mail | index | archive | help
http://perforce.freebsd.org/chv.cgi?CH=99182 Change 99182 by piso@piso_newluxor on 2006/06/13 22:19:17 First step toward interrupt filtering: convert all the INTR_FAST interrupt handlers to behave like a driver_filter_t, in this phase they will just return FILTER_HANDLED. Mark all the converted drivers with FIX_INTR_FILTER so i can easily find them later. Affected files ... .. //depot/projects/soc2006/intr_filter/dev/fdc/fdc.c#2 edit Differences ... ==== //depot/projects/soc2006/intr_filter/dev/fdc/fdc.c#2 (text+ko) ==== @@ -259,6 +259,7 @@ #define FD_NOT_VALID -2 static driver_intr_t fdc_intr; +static driver_filter_t fdc_intr_fast; static void fdc_reset(struct fdc_data *); SYSCTL_NODE(_debug, OID_AUTO, fdc, CTLFLAG_RW, 0, "fdc driver"); @@ -672,6 +673,14 @@ wakeup(arg); } +static int +fdc_intr_fast(void *arg) +{ + + wakeup(arg); + return(FILTER_HANDLED); +} + /* * fdc_pio(): perform programmed IO read/write for YE PCMCIA floppy. */ @@ -1736,10 +1745,12 @@ device_printf(dev, "does not respond\n"); return (error); } + // XXX - FIX_INTR_FILTER error = bus_setup_intr(dev, fdc->res_irq, INTR_TYPE_BIO | INTR_ENTROPY | INTR_MPSAFE | - ((fdc->flags & FDC_NOFAST) ? 0 : INTR_FAST), - fdc_intr, fdc, &fdc->fdc_intr); + ((fdc->flags & FDC_NOFAST) ? 0 : INTR_FAST), + ((fdc->flags & FDC_NOFAST) ? fdc_intr : (driver_intr_t *)fdc_intr_fast), + fdc, &fdc->fdc_intr); if (error) { device_printf(dev, "cannot setup interrupt\n"); return (error);
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200606132219.k5DMJNT7000861>