Module Name: src Committed By: martin Date: Fri Oct 25 21:48:48 UTC 2013
Modified Files: src/sys/arch/mac68k/dev: mac68k5380.c ncr5380.c Log Message: Simplify To generate a diff of this commit: cvs rdiff -u -r1.48 -r1.49 src/sys/arch/mac68k/dev/mac68k5380.c cvs rdiff -u -r1.65 -r1.66 src/sys/arch/mac68k/dev/ncr5380.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
Modified files: Index: src/sys/arch/mac68k/dev/mac68k5380.c diff -u src/sys/arch/mac68k/dev/mac68k5380.c:1.48 src/sys/arch/mac68k/dev/mac68k5380.c:1.49 --- src/sys/arch/mac68k/dev/mac68k5380.c:1.48 Thu Dec 6 13:28:17 2012 +++ src/sys/arch/mac68k/dev/mac68k5380.c Fri Oct 25 21:48:48 2013 @@ -1,4 +1,4 @@ -/* $NetBSD: mac68k5380.c,v 1.48 2012/12/06 13:28:17 hauke Exp $ */ +/* $NetBSD: mac68k5380.c,v 1.49 2013/10/25 21:48:48 martin Exp $ */ /* * Copyright (c) 1995 Allen Briggs @@ -34,7 +34,7 @@ */ #include <sys/cdefs.h> -__KERNEL_RCSID(0, "$NetBSD: mac68k5380.c,v 1.48 2012/12/06 13:28:17 hauke Exp $"); +__KERNEL_RCSID(0, "$NetBSD: mac68k5380.c,v 1.49 2013/10/25 21:48:48 martin Exp $"); #include <sys/param.h> #include <sys/systm.h> @@ -147,9 +147,8 @@ static int transfer_pdma(u_char *, u_cha static void scsi_clr_ipend(void) { - int tmp; - tmp = GET_5380_REG(NCR5380_IRCV); + GET_5380_REG(NCR5380_IRCV); scsi_clear_irq(); } @@ -357,7 +356,7 @@ extern int *nofault, m68k_fault_addr; register int count; volatile u_int32_t *long_drq; u_int32_t *long_data; - volatile u_int8_t *drq, tmp_data; + volatile u_int8_t *drq; u_int8_t *data; #if DBG_PID @@ -499,8 +498,7 @@ extern int *nofault, m68k_fault_addr; PID("write complete"); - drq = (volatile u_int8_t *) ncr_5380_with_drq; - tmp_data = *drq; + (void)*((volatile u_int8_t *) ncr_5380_with_drq); PID("read a byte to force a phase change"); } Index: src/sys/arch/mac68k/dev/ncr5380.c diff -u src/sys/arch/mac68k/dev/ncr5380.c:1.65 src/sys/arch/mac68k/dev/ncr5380.c:1.66 --- src/sys/arch/mac68k/dev/ncr5380.c:1.65 Sat Oct 27 17:17:59 2012 +++ src/sys/arch/mac68k/dev/ncr5380.c Fri Oct 25 21:48:48 2013 @@ -1,4 +1,4 @@ -/* $NetBSD: ncr5380.c,v 1.65 2012/10/27 17:17:59 chs Exp $ */ +/* $NetBSD: ncr5380.c,v 1.66 2013/10/25 21:48:48 martin Exp $ */ /* * Copyright (c) 1995 Leo Weppelman. @@ -26,7 +26,7 @@ */ #include <sys/cdefs.h> -__KERNEL_RCSID(0, "$NetBSD: ncr5380.c,v 1.65 2012/10/27 17:17:59 chs Exp $"); +__KERNEL_RCSID(0, "$NetBSD: ncr5380.c,v 1.66 2013/10/25 21:48:48 martin Exp $"); /* * Bit mask of targets you want debugging to be shown @@ -262,7 +262,6 @@ ncr5380_scsi_request(struct scsipi_chann void *arg) { struct scsipi_xfer *xs; - struct scsipi_periph *periph; struct ncr_softc *sc = device_private(chan->chan_adapter->adapt_dev); int sps, flags; SC_REQ *reqp, *link, *tmp; @@ -271,7 +270,6 @@ ncr5380_scsi_request(struct scsipi_chann case ADAPTER_REQ_RUN_XFER: xs = arg; flags = xs->xs_control; - periph = xs->xs_periph; /* * We do not queue RESET commands @@ -1629,7 +1627,6 @@ static int reach_msg_out(struct ncr_softc *sc, u_long len) { u_char phase; - u_char data; u_long n = len; ncr_aprint(sc, "Trying to reach Message-out phase\n"); @@ -1648,7 +1645,7 @@ reach_msg_out(struct ncr_softc *sc, u_lo if (((GET_5380_REG(NCR5380_IDSTAT) >> 2) & 7) != phase) break; if (PH_IN(phase)) { - data = GET_5380_REG(NCR5380_DATA); + GET_5380_REG(NCR5380_DATA); SET_5380_REG(NCR5380_ICOM, SC_A_ACK | SC_A_ATN); } else {