Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys/dev remove CISS_NO_INTERRUPT_HACK, discussed with joerg@...
details: https://anonhg.NetBSD.org/src/rev/4451320fb7bc
branches: trunk
changeset: 935959:4451320fb7bc
user: jdolecek <jdolecek%NetBSD.org@localhost>
date: Tue Jul 14 12:04:46 2020 +0000
description:
remove CISS_NO_INTERRUPT_HACK, discussed with joerg@ and spz@
diffstat:
sys/dev/ic/ciss.c | 13 ++-----------
sys/dev/ic/cissvar.h | 5 +----
sys/dev/pci/ciss_pci.c | 28 ++--------------------------
3 files changed, 5 insertions(+), 41 deletions(-)
diffs (147 lines):
diff -r 12a198cf6d0f -r 4451320fb7bc sys/dev/ic/ciss.c
--- a/sys/dev/ic/ciss.c Tue Jul 14 11:44:52 2020 +0000
+++ b/sys/dev/ic/ciss.c Tue Jul 14 12:04:46 2020 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: ciss.c,v 1.48 2020/07/14 11:44:52 jdolecek Exp $ */
+/* $NetBSD: ciss.c,v 1.49 2020/07/14 12:04:46 jdolecek Exp $ */
/* $OpenBSD: ciss.c,v 1.68 2013/05/30 16:15:02 deraadt Exp $ */
/*
@@ -19,7 +19,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: ciss.c,v 1.48 2020/07/14 11:44:52 jdolecek Exp $");
+__KERNEL_RCSID(0, "$NetBSD: ciss.c,v 1.49 2020/07/14 12:04:46 jdolecek Exp $");
#include "bio.h"
@@ -74,11 +74,6 @@
void *addr, int flag, struct proc *p);
static void cissminphys(struct buf *bp);
-#if 0
-static void ciss_scsi_raw_cmd(struct scsipi_channel *chan,
- scsipi_adapter_req_t req, void *arg);
-#endif
-
static int ciss_sync(struct ciss_softc *sc);
static void ciss_heartbeat(void *v);
static void ciss_shutdown(void *v);
@@ -753,11 +748,9 @@
bus_dmamap_sync(sc->sc_dmat, sc->cmdmap, 0, sc->cmdmap->dm_mapsize,
BUS_DMASYNC_PREWRITE);
-#ifndef CISS_NO_INTERRUPT_HACK
if ((wait & (XS_CTL_POLL|XS_CTL_NOSLEEP)) == (XS_CTL_POLL|XS_CTL_NOSLEEP))
bus_space_write_4(sc->sc_iot, sc->sc_ioh, CISS_IMR,
bus_space_read_4(sc->sc_iot, sc->sc_ioh, CISS_IMR) | sc->iem);
-#endif
if (!pollsleep)
ccb->ccb_state = CISS_CCB_ONQ;
@@ -810,11 +803,9 @@
ccb->ccb_err.cmd_stat, ccb->ccb_err.scsi_stat));
}
-#ifndef CISS_NO_INTERRUPT_HACK
if ((wait & (XS_CTL_POLL|XS_CTL_NOSLEEP)) == (XS_CTL_POLL|XS_CTL_NOSLEEP))
bus_space_write_4(sc->sc_iot, sc->sc_ioh, CISS_IMR,
bus_space_read_4(sc->sc_iot, sc->sc_ioh, CISS_IMR) & ~sc->iem);
-#endif
return (error);
}
diff -r 12a198cf6d0f -r 4451320fb7bc sys/dev/ic/cissvar.h
--- a/sys/dev/ic/cissvar.h Tue Jul 14 11:44:52 2020 +0000
+++ b/sys/dev/ic/cissvar.h Tue Jul 14 12:04:46 2020 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: cissvar.h,v 1.9 2020/07/14 10:37:30 jdolecek Exp $ */
+/* $NetBSD: cissvar.h,v 1.10 2020/07/14 12:04:46 jdolecek Exp $ */
/* $OpenBSD: cissvar.h,v 1.15 2013/05/30 16:15:02 deraadt Exp $ */
/*
@@ -45,9 +45,6 @@
void *sc_sh; /* shutdown hook */
struct proc *sc_thread;
int sc_flush;
-#ifdef CISS_NO_INTERRUPT_HACK
- struct callout sc_interrupt_hack;
-#endif
struct scsipi_channel sc_channel;
struct scsipi_channel *sc_channel_raw;
diff -r 12a198cf6d0f -r 4451320fb7bc sys/dev/pci/ciss_pci.c
--- a/sys/dev/pci/ciss_pci.c Tue Jul 14 11:44:52 2020 +0000
+++ b/sys/dev/pci/ciss_pci.c Tue Jul 14 12:04:46 2020 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: ciss_pci.c,v 1.18 2020/07/14 10:37:30 jdolecek Exp $ */
+/* $NetBSD: ciss_pci.c,v 1.19 2020/07/14 12:04:46 jdolecek Exp $ */
/* $OpenBSD: ciss_pci.c,v 1.9 2005/12/13 15:56:01 brad Exp $ */
/*
@@ -19,7 +19,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: ciss_pci.c,v 1.18 2020/07/14 10:37:30 jdolecek Exp $");
+__KERNEL_RCSID(0, "$NetBSD: ciss_pci.c,v 1.19 2020/07/14 12:04:46 jdolecek Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@@ -243,20 +243,6 @@
return 0;
}
-#ifdef CISS_NO_INTERRUPT_HACK
-static void
-ciss_intr_wrapper(void *sc_)
-{
- struct ciss_softc *sc = sc_;
- int s;
-
- s = splbio();
- ciss_intr(sc);
- splx(s);
- callout_schedule(&sc->sc_interrupt_hack, 1);
-}
-#endif
-
void
ciss_pci_attach(device_t parent, device_t self, void *aux)
{
@@ -271,10 +257,6 @@
char intrbuf[PCI_INTRSTR_LEN];
int (*intr_handler)(void *);
-#ifdef CISS_NO_INTERRUPT_HACK
- callout_init(&sc->sc_interrupt_hack, 0);
- callout_setfunc(&sc->sc_interrupt_hack, ciss_intr_wrapper, sc);
-#endif
sc->sc_dev = self;
aprint_naive("\n");
@@ -339,11 +321,9 @@
(u_int32_t *)&sc->cfg, sizeof(sc->cfg) / 4);
/* disable interrupts until ready */
-#ifndef CISS_NO_INTERRUPT_HACK
bus_space_write_4(sc->sc_iot, sc->sc_ioh, CISS_IMR,
bus_space_read_4(sc->sc_iot, sc->sc_ioh, CISS_IMR) |
sc->iem | CISS_INTR_OPQ | CISS_INTR_MSI);
-#endif
int counts[PCI_INTR_TYPE_SIZE] = {
[PCI_INTR_TYPE_INTX] = 1,
@@ -409,11 +389,7 @@
return;
}
-#ifndef CISS_NO_INTERRUPT_HACK
/* enable interrupts now */
bus_space_write_4(sc->sc_iot, sc->sc_ioh, CISS_IMR,
bus_space_read_4(sc->sc_iot, sc->sc_ioh, CISS_IMR) & ~sc->iem);
-#else
- callout_schedule(&sc->sc_interrupt_hack, 1);
-#endif
}
Home |
Main Index |
Thread Index |
Old Index