From owner-p4-projects@FreeBSD.ORG Mon Mar 13 02:45:05 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 94B9216A423; Mon, 13 Mar 2006 02:45:05 +0000 (UTC) X-Original-To: perforce@freebsd.org Delivered-To: perforce@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 4E0E516A401 for ; Mon, 13 Mar 2006 02:45:05 +0000 (UTC) (envelope-from marcel@freebsd.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 00F4243D45 for ; Mon, 13 Mar 2006 02:45:05 +0000 (GMT) (envelope-from marcel@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.1/8.13.1) with ESMTP id k2D2j4et068452 for ; Mon, 13 Mar 2006 02:45:04 GMT (envelope-from marcel@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.1/8.13.1/Submit) id k2D2j4pS068445 for perforce@freebsd.org; Mon, 13 Mar 2006 02:45:04 GMT (envelope-from marcel@freebsd.org) Date: Mon, 13 Mar 2006 02:45:04 GMT Message-Id: <200603130245.k2D2j4pS068445@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to marcel@freebsd.org using -f From: Marcel Moolenaar To: Perforce Change Reviews Cc: Subject: PERFORCE change 93224 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: Mon, 13 Mar 2006 02:45:05 -0000 http://perforce.freebsd.org/chv.cgi?CH=93224 Change 93224 by marcel@marcel_nfs on 2006/03/13 02:44:56 The source specific interrupt handlers return whether the interrupt condition is cleared or not. Affected files ... .. //depot/projects/uart/dev/uart/uart_bus.h#40 edit .. //depot/projects/uart/dev/uart/uart_core.c#46 edit Differences ... ==== //depot/projects/uart/dev/uart/uart_bus.h#40 (text+ko) ==== @@ -140,7 +140,7 @@ int uart_bus_attach(device_t dev); int uart_bus_detach(device_t dev); -driver_intr_t *uart_bus_ihand(device_t dev, int ipend); +serdev_intr_t *uart_bus_ihand(device_t dev, int ipend); int uart_bus_probe(device_t dev, int regshft, int rclk, int rid, int chan); int uart_bus_reset(device_t dev); ==== //depot/projects/uart/dev/uart/uart_core.c#46 (text+ko) ==== @@ -93,7 +93,7 @@ * the exceptional nature of the break condition, so we permit ourselves * to be sloppy. */ -static __inline void +static __inline int uart_intr_break(void *arg) { struct uart_softc *sc = arg; @@ -101,11 +101,12 @@ #if defined(KDB) && defined(BREAK_TO_DEBUGGER) if (sc->sc_sysdev != NULL && sc->sc_sysdev->type == UART_DEV_CONSOLE) { kdb_enter("Line break on console"); - return; + return (0); } #endif if (sc->sc_opened) uart_sched_softih(sc, SER_INT_BREAK); + return (0); } /* @@ -123,7 +124,7 @@ * token represents the loss of at least one, but possible more bytes in * the input stream. */ -static __inline void +static __inline int uart_intr_overrun(void *arg) { struct uart_softc *sc = arg; @@ -135,12 +136,13 @@ uart_sched_softih(sc, SER_INT_RXREADY); } UART_FLUSH(sc, UART_FLUSH_RECEIVER); + return (0); } /* * Received data ready. */ -static __inline void +static __inline int uart_intr_rxready(void *arg) { struct uart_softc *sc = arg; @@ -162,6 +164,7 @@ uart_sched_softih(sc, SER_INT_RXREADY); else sc->sc_rxput = sc->sc_rxget; /* Ignore received data. */ + return (1); } /* @@ -171,7 +174,7 @@ * bits. This is to avoid loosing state transitions due to having more * than 1 hardware interrupt between software interrupts. */ -static __inline void +static __inline int uart_intr_sigchg(void *arg) { struct uart_softc *sc = arg; @@ -202,12 +205,13 @@ if (sc->sc_opened) uart_sched_softih(sc, SER_INT_SIGCHG); + return (0); } /* * The transmitter can accept more data. */ -static __inline void +static __inline int uart_intr_txidle(void *arg) { struct uart_softc *sc = arg; @@ -216,6 +220,7 @@ sc->sc_txbusy = 0; uart_sched_softih(sc, SER_INT_TXIDLE); } + return (0); } static void @@ -238,7 +243,7 @@ } } -driver_intr_t * +serdev_intr_t * uart_bus_ihand(device_t dev, int ipend) {