From owner-p4-projects@FreeBSD.ORG Fri Mar 2 17:32:22 2007 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 3579D16A404; Fri, 2 Mar 2007 17:32:22 +0000 (UTC) X-Original-To: perforce@freebsd.org Delivered-To: perforce@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 0BFBD16A400 for ; Fri, 2 Mar 2007 17:32:22 +0000 (UTC) (envelope-from piso@freebsd.org) Received: from repoman.freebsd.org (repoman.freebsd.org [69.147.83.41]) by mx1.freebsd.org (Postfix) with ESMTP id F19FC13C481 for ; Fri, 2 Mar 2007 17:32:21 +0000 (UTC) (envelope-from piso@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id l22HWL5O080582 for ; Fri, 2 Mar 2007 17:32:21 GMT (envelope-from piso@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id l22HWL9A080578 for perforce@freebsd.org; Fri, 2 Mar 2007 17:32:21 GMT (envelope-from piso@freebsd.org) Date: Fri, 2 Mar 2007 17:32:21 GMT Message-Id: <200703021732.l22HWL9A080578@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to piso@freebsd.org using -f From: Paolo Pisati To: Perforce Change Reviews Cc: Subject: PERFORCE change 115256 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 02 Mar 2007 17:32:22 -0000 http://perforce.freebsd.org/chv.cgi?CH=115256 Change 115256 by piso@piso_newluxor on 2007/03/02 17:31:21 Restablish a filtered version of aac. Affected files ... .. //depot/projects/soc2006/intr_filter/dev/aac/aac.c#10 edit .. //depot/projects/soc2006/intr_filter/dev/aac/aacvar.h#5 edit Differences ... ==== //depot/projects/soc2006/intr_filter/dev/aac/aac.c#10 (text+ko) ==== @@ -307,18 +307,11 @@ } } else { if (bus_setup_intr(sc->aac_dev, sc->aac_irq, - INTR_TYPE_BIO, aac_fast_intr, NULL, + INTR_TYPE_BIO, aac_fast_intr, aac_complete, sc, &sc->aac_intr)) { device_printf(sc->aac_dev, - "can't set up FAST interrupt\n"); - if (bus_setup_intr(sc->aac_dev, sc->aac_irq, - INTR_MPSAFE|INTR_TYPE_BIO, - NULL, (driver_intr_t *)aac_fast_intr, - sc, &sc->aac_intr)) { - device_printf(sc->aac_dev, - "can't set up MPSAFE interrupt\n"); + "can't set up FILTERed interrupt\n"); return (EINVAL); - } } } @@ -820,53 +813,9 @@ */ wakeup(sc->aifthread); } - return((ret)?ret:FILTER_STRAY); + return(ret ? ret : FILTER_STRAY); } -int -aac_intr(void *arg) -{ - struct aac_softc *sc; - u_int16_t reason; - - debug_called(2); - - sc = (struct aac_softc *)arg; - - /* - * Read the status register directly. This is faster than taking the - * driver lock and reading the queues directly. It also saves having - * to turn parts of the driver lock into a spin mutex, which would be - * ugly. - */ - reason = AAC_GET_ISTATUS(sc); - AAC_CLEAR_ISTATUS(sc, reason); - - /* handle completion processing */ - if (reason & AAC_DB_RESPONSE_READY) - taskqueue_enqueue_fast(taskqueue_fast, &sc->aac_task_complete); - - /* controller wants to talk to us */ - if (reason & (AAC_DB_PRINTF | AAC_DB_COMMAND_READY)) { - /* - * XXX Make sure that we don't get fooled by strange messages - * that start with a NULL. - */ - if ((reason & AAC_DB_PRINTF) && - (sc->aac_common->ac_printf[0] == 0)) - sc->aac_common->ac_printf[0] = 32; - - /* - * This might miss doing the actual wakeup. However, the - * msleep that this is waking up has a timeout, so it will - * wake up eventually. AIFs and printfs are low enough - * priority that they can handle hanging out for a few seconds - * if needed. - */ - wakeup(sc->aifthread); - } - return (FILTER_HANDLED); -} /* * Command Processing ==== //depot/projects/soc2006/intr_filter/dev/aac/aacvar.h#5 (text+ko) ==== @@ -426,7 +426,6 @@ extern int aac_resume(device_t dev); extern void aac_new_intr(void *arg); extern int aac_fast_intr(void *arg); -extern void aac_intr(void *arg); extern void aac_submit_bio(struct bio *bp); extern void aac_biodone(struct bio *bp); extern void aac_startio(struct aac_softc *sc);