From owner-p4-projects@FreeBSD.ORG Fri Dec 15 23:06:31 2006 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 D9D7D16A415; Fri, 15 Dec 2006 23:06:30 +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 99E8E16A40F for ; Fri, 15 Dec 2006 23:06:30 +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 6E69143CAB for ; Fri, 15 Dec 2006 23:04:46 +0000 (GMT) (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 kBFN6UV7067239 for ; Fri, 15 Dec 2006 23:06:30 GMT (envelope-from piso@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id kBFN6Ux1067236 for perforce@freebsd.org; Fri, 15 Dec 2006 23:06:30 GMT (envelope-from piso@freebsd.org) Date: Fri, 15 Dec 2006 23:06:30 GMT Message-Id: <200612152306.kBFN6Ux1067236@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 111758 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, 15 Dec 2006 23:06:31 -0000 http://perforce.freebsd.org/chv.cgi?CH=111758 Change 111758 by piso@piso_newluxor on 2006/12/15 23:05:37 Teach msk about new bus_setup_intr() API. Affected files ... .. //depot/projects/soc2006/intr_filter/dev/msk/if_msk.c#2 edit Differences ... ==== //depot/projects/soc2006/intr_filter/dev/msk/if_msk.c#2 (text+ko) ==== @@ -228,7 +228,7 @@ static int msk_detach(device_t); static void msk_tick(void *); -static void msk_intr(void *); +static int msk_intr(void *); static void msk_int_task(void *, int); static void msk_intr_phy(struct msk_if_softc *); static void msk_intr_gmac(struct msk_if_softc *); @@ -1771,7 +1771,7 @@ device_get_nameunit(sc->msk_dev)); /* Hook interrupt last to avoid having to lock softc. */ error = bus_setup_intr(dev, sc->msk_res[1], INTR_TYPE_NET | - INTR_MPSAFE | INTR_FAST, msk_intr, sc, &sc->msk_intrhand); + INTR_MPSAFE, msk_intr, NULL, sc, &sc->msk_intrhand); if (error != 0) { device_printf(dev, "couldn't set up interrupt handler\n"); @@ -3465,7 +3465,7 @@ return (sc->msk_stat_cons != CSR_READ_2(sc, STAT_PUT_IDX)); } -static void +static int msk_intr(void *xsc) { struct msk_softc *sc; @@ -3476,10 +3476,11 @@ /* Reading B0_Y2_SP_ISRC2 masks further interrupts. */ if (status == 0 || status == 0xffffffff) { CSR_WRITE_4(sc, B0_Y2_SP_ICR, 2); - return; + return (FILTER_STRAY); } taskqueue_enqueue(sc->msk_tq, &sc->msk_int_task); + return (FILTER_HANDLED); } static void