From 9af3029471fac17983fbe3b1d3df020fcdc0e398 Mon Sep 17 00:00:00 2001 From: David Gwynne Date: Thu, 3 Jun 2010 01:03:56 +0000 Subject: get rid of the kthread. it is unused and just bloats the kernel. pointed out by brad. --- sys/dev/ic/ciss.c | 31 +------------------------------ sys/dev/ic/cissvar.h | 3 +-- 2 files changed, 2 insertions(+), 32 deletions(-) (limited to 'sys/dev/ic') diff --git a/sys/dev/ic/ciss.c b/sys/dev/ic/ciss.c index 8d247ad837c..b30d9e77035 100644 --- a/sys/dev/ic/ciss.c +++ b/sys/dev/ic/ciss.c @@ -1,4 +1,4 @@ -/* $OpenBSD: ciss.c,v 1.53 2010/06/03 01:02:13 dlg Exp $ */ +/* $OpenBSD: ciss.c,v 1.54 2010/06/03 01:03:55 dlg Exp $ */ /* * Copyright (c) 2005,2006 Michael Shalayeff @@ -29,7 +29,6 @@ #include #include #include -#include #include @@ -88,7 +87,6 @@ int ciss_ioctl(struct device *, u_long, caddr_t); int ciss_sync(struct ciss_softc *sc); void ciss_heartbeat(void *v); void ciss_shutdown(void *v); -void ciss_kthread(void *v); #ifndef SMALL_KERNEL void ciss_sensors(void *); #endif @@ -370,16 +368,6 @@ ciss_attach(struct ciss_softc *sc) return -1; } -#if 0 - if (kthread_create(ciss_kthread, sc, NULL, "%s", sc->sc_dev.dv_xname)) { - printf(": unable to create kernel thread\n"); - shutdownhook_disestablish(sc->sc_sh); - bus_dmamem_free(sc->dmat, sc->cmdseg, 1); - bus_dmamap_destroy(sc->dmat, sc->cmdmap); - return -1; - } -#endif - sc->sc_link.device = &ciss_dev; sc->sc_link.adapter_softc = sc; sc->sc_link.openings = sc->maxcmd / (sc->maxunits? sc->maxunits : 1); @@ -968,23 +956,6 @@ ciss_heartbeat(void *v) timeout_add_sec(&sc->sc_hb, 3); } -void -ciss_kthread(void *v) -{ - struct ciss_softc *sc = v; - ciss_lock_t lock; - - for (;;) { - tsleep(sc, PRIBIO, sc->sc_dev.dv_xname, 0); - - lock = CISS_LOCK(sc); - - - - CISS_UNLOCK(sc, lock); - } -} - int ciss_scsi_ioctl(struct scsi_link *link, u_long cmd, caddr_t addr, int flag, struct proc *p) diff --git a/sys/dev/ic/cissvar.h b/sys/dev/ic/cissvar.h index 97f245439ca..c6fba9d86aa 100644 --- a/sys/dev/ic/cissvar.h +++ b/sys/dev/ic/cissvar.h @@ -1,4 +1,4 @@ -/* $OpenBSD: cissvar.h,v 1.13 2010/06/03 00:56:42 dlg Exp $ */ +/* $OpenBSD: cissvar.h,v 1.14 2010/06/03 01:03:55 dlg Exp $ */ /* * Copyright (c) 2005,2006 Michael Shalayeff @@ -32,7 +32,6 @@ struct ciss_softc { struct timeout sc_hb; void *sc_ih; void *sc_sh; - struct proc *sc_thread; int sc_flush; struct ksensor *sensors; struct ksensordev sensordev; -- cgit v1.2.3