Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/sys/arch/amiga gcc-4.8.x unused variable fixes



details:   https://anonhg.NetBSD.org/src/rev/a37fe116c975
branches:  trunk
changeset: 326183:a37fe116c975
user:      christos <christos%NetBSD.org@localhost>
date:      Wed Jan 22 00:25:16 2014 +0000

description:
gcc-4.8.x unused variable fixes

diffstat:

 sys/arch/amiga/amiga/cc.c         |   7 +++----
 sys/arch/amiga/amiga/disksubr.c   |   7 +++----
 sys/arch/amiga/dev/empsc.c        |   5 +++--
 sys/arch/amiga/dev/fd.c           |  19 +++++++------------
 sys/arch/amiga/dev/gayle_pcmcia.c |   5 +++--
 sys/arch/amiga/dev/grf_cl.c       |  19 +++++--------------
 sys/arch/amiga/dev/grf_cv.c       |  25 ++++++++++---------------
 sys/arch/amiga/dev/grf_cv3d.c     |  20 ++++----------------
 sys/arch/amiga/dev/grf_cv3dreg.h  |   3 ++-
 sys/arch/amiga/dev/grf_cvreg.h    |   3 ++-
 sys/arch/amiga/dev/grf_et.c       |  11 +++--------
 sys/arch/amiga/dev/grf_rh.c       |  10 ++++------
 sys/arch/amiga/dev/grf_ul.c       |  10 ++--------
 sys/arch/amiga/dev/if_es.c        |   5 +++--
 sys/arch/amiga/dev/if_le.c        |   5 +++--
 sys/arch/amiga/dev/ite.c          |   9 +++------
 sys/arch/amiga/dev/ite_rt.c       |   6 ++----
 sys/arch/amiga/dev/ivsc.c         |   5 +++--
 sys/arch/amiga/dev/mlhsc.c        |   6 ++++--
 sys/arch/amiga/dev/otgsc.c        |   5 +++--
 sys/arch/amiga/dev/repulse.c      |   9 +++++----
 sys/arch/amiga/dev/sbic.c         |  15 ++++++++-------
 sys/arch/amiga/dev/sci.c          |  12 +++++++++---
 sys/arch/amiga/dev/ser.c          |   6 ++++--
 sys/arch/amiga/dev/siop.c         |   9 +++++++--
 sys/arch/amiga/dev/siop2.c        |  10 ++++++++--
 sys/arch/amiga/dev/toccata.c      |   8 ++------
 sys/arch/amiga/dev/wstsc.c        |   5 +++--
 28 files changed, 118 insertions(+), 141 deletions(-)

diffs (truncated from 1278 to 300 lines):

diff -r cc310fd1320d -r a37fe116c975 sys/arch/amiga/amiga/cc.c
--- a/sys/arch/amiga/amiga/cc.c Wed Jan 22 00:24:53 2014 +0000
+++ b/sys/arch/amiga/amiga/cc.c Wed Jan 22 00:25:16 2014 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: cc.c,v 1.25 2014/01/03 07:14:20 mlelstv Exp $  */
+/*     $NetBSD: cc.c,v 1.26 2014/01/22 00:25:16 christos Exp $ */
 
 /*
  * Copyright (c) 1994 Christian E. Hopps
@@ -31,7 +31,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: cc.c,v 1.25 2014/01/03 07:14:20 mlelstv Exp $");
+__KERNEL_RCSID(0, "$NetBSD: cc.c,v 1.26 2014/01/22 00:25:16 christos Exp $");
 
 #include <sys/types.h>
 #include <sys/param.h>
@@ -348,11 +348,10 @@
 void
 audio_handler(void)
 {
-       u_short audio_dma, disable_dma, flag, ir;
+       u_short audio_dma, flag, ir;
        int i;
 
        audio_dma = custom.dmaconr;
-       disable_dma = 0;
 
        /*
         * only check channels who have DMA enabled.
diff -r cc310fd1320d -r a37fe116c975 sys/arch/amiga/amiga/disksubr.c
--- a/sys/arch/amiga/amiga/disksubr.c   Wed Jan 22 00:24:53 2014 +0000
+++ b/sys/arch/amiga/amiga/disksubr.c   Wed Jan 22 00:25:16 2014 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: disksubr.c,v 1.60 2009/09/12 09:18:42 phx Exp $        */
+/*     $NetBSD: disksubr.c,v 1.61 2014/01/22 00:25:16 christos Exp $   */
 
 /*
  * Copyright (c) 1982, 1986, 1988 Regents of the University of California.
@@ -66,7 +66,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: disksubr.c,v 1.60 2009/09/12 09:18:42 phx Exp $");
+__KERNEL_RCSID(0, "$NetBSD: disksubr.c,v 1.61 2014/01/22 00:25:16 christos Exp $");
 
 #include <sys/param.h>
 #include <sys/systm.h>
@@ -536,7 +536,6 @@
 int
 writedisklabel(dev_t dev, void (*strat)(struct buf *), struct disklabel *lp, struct cpu_disklabel *clp)
 {
-       struct rdbmap *bmap;
        struct buf *bp;
        struct disklabel *dlp;
        int error = 0;
@@ -576,7 +575,7 @@
            (clp->rdblock <= 0 || clp->rdblock >= RDB_MAXBLOCKS))
                return(EINVAL);
 
-       bmap = getrdbmap(dev, strat, lp, clp);
+       (void)getrdbmap(dev, strat, lp, clp);
        return(EINVAL);
 }
 
diff -r cc310fd1320d -r a37fe116c975 sys/arch/amiga/dev/empsc.c
--- a/sys/arch/amiga/dev/empsc.c        Wed Jan 22 00:24:53 2014 +0000
+++ b/sys/arch/amiga/dev/empsc.c        Wed Jan 22 00:25:16 2014 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: empsc.c,v 1.27 2012/10/27 17:17:28 chs Exp $ */
+/*     $NetBSD: empsc.c,v 1.28 2014/01/22 00:25:16 christos Exp $ */
 
 /*
  * Copyright (c) 1982, 1990 The Regents of the University of California.
@@ -66,7 +66,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: empsc.c,v 1.27 2012/10/27 17:17:28 chs Exp $");
+__KERNEL_RCSID(0, "$NetBSD: empsc.c,v 1.28 2014/01/22 00:25:16 christos Exp $");
 
 #include <sys/param.h>
 #include <sys/systm.h>
@@ -187,6 +187,7 @@
        if ((*dev->sci_csr & SCI_CSR_INT) == 0)
                return(0);
        stat = *dev->sci_iack;
+       __USE(stat);
        /* XXXX is: something is missing here, at least a: */
        return(1);
 }
diff -r cc310fd1320d -r a37fe116c975 sys/arch/amiga/dev/fd.c
--- a/sys/arch/amiga/dev/fd.c   Wed Jan 22 00:24:53 2014 +0000
+++ b/sys/arch/amiga/dev/fd.c   Wed Jan 22 00:25:16 2014 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: fd.c,v 1.87 2012/10/27 17:17:28 chs Exp $ */
+/*     $NetBSD: fd.c,v 1.88 2014/01/22 00:25:16 christos Exp $ */
 
 /*
  * Copyright (c) 1994 Christian E. Hopps
@@ -33,7 +33,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: fd.c,v 1.87 2012/10/27 17:17:28 chs Exp $");
+__KERNEL_RCSID(0, "$NetBSD: fd.c,v 1.88 2014/01/22 00:25:16 christos Exp $");
 
 #include <sys/param.h>
 #include <sys/systm.h>
@@ -644,12 +644,10 @@
 void
 fdstrategy(struct buf *bp)
 {
-       struct disklabel *lp;
        struct fd_softc *sc;
-       int unit, part, s;
+       int unit, s;
 
        unit = FDUNIT(bp->b_dev);
-       part = FDPART(bp->b_dev);
        sc = getsoftc(fd_cd, unit);
 
 #ifdef FDDEBUG
@@ -658,7 +656,6 @@
        /*
         * check for valid partition and bounds
         */
-       lp = sc->dkdev.dk_label;
        if ((sc->flags & FDF_HAVELABEL) == 0) {
                bp->b_error = EIO;
                goto done;
@@ -1653,12 +1650,11 @@
 fdminphys(struct buf *bp)
 {
        struct fd_softc *sc;
-       int trk, sec, toff, tsz;
+       int sec, toff, tsz;
 
        if ((sc = getsoftc(fd_cd, FDUNIT(bp->b_dev))) == NULL)
                panic("fdminphys: couldn't get softc");
 
-       trk = bp->b_blkno / sc->nsectors;
        sec = bp->b_blkno % sc->nsectors;
 
        toff = sec * FDSECSIZE;
@@ -1705,7 +1701,7 @@
 amcachetoraw(struct fd_softc *sc)
 {
        static u_long mfmnull[4];
-       u_long *rp, *crp, *dp, hcksum, dcksum, info, zero;
+       u_long *rp, *crp, *dp, hcksum, dcksum, info;
        int sec, i;
 
        rp = fdc_dmap;
@@ -1720,7 +1716,6 @@
         * process sectors
         */
        dp = sc->cachep;
-       zero = 0;
        info = 0xff000000 | (sc->cachetrk << 16) | sc->nsectors;
        for (sec = 0; sec < sc->nsectors; sec++, info += (1 << 8) - 1) {
                hcksum = dcksum = 0;
@@ -1938,11 +1933,11 @@
 int
 msrawtocache(struct fd_softc *sc)
 {
-       u_short *rp, *srp, *erp;
+       u_short *rp, *erp;
        u_char tb[5], *cp;
        int ct, sec, retry;
 
-       srp = rp = (u_short *)fdc_dmap;
+       rp = (u_short *)fdc_dmap;
        erp = rp + sc->type->nreadw;
        cp = sc->cachep;
 
diff -r cc310fd1320d -r a37fe116c975 sys/arch/amiga/dev/gayle_pcmcia.c
--- a/sys/arch/amiga/dev/gayle_pcmcia.c Wed Jan 22 00:24:53 2014 +0000
+++ b/sys/arch/amiga/dev/gayle_pcmcia.c Wed Jan 22 00:25:16 2014 +0000
@@ -1,9 +1,9 @@
-/*     $NetBSD: gayle_pcmcia.c,v 1.28 2014/01/03 00:33:06 rkujawa Exp $ */
+/*     $NetBSD: gayle_pcmcia.c,v 1.29 2014/01/22 00:25:16 christos Exp $ */
 
 /* public domain */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: gayle_pcmcia.c,v 1.28 2014/01/03 00:33:06 rkujawa Exp $");
+__KERNEL_RCSID(0, "$NetBSD: gayle_pcmcia.c,v 1.29 2014/01/22 00:25:16 christos Exp $");
 
 /* PCMCIA front-end driver for A1200's and A600's. */
 
@@ -209,6 +209,7 @@
                *reset_card_reg = 0x0;
                delay(1000);
                x = *reset_card_reg;
+               __USE(x);
                gayle_pcmcia_status_write(GAYLE_CCMEM_WP | GAYLE_CCIO_SPKR);
        }
 
diff -r cc310fd1320d -r a37fe116c975 sys/arch/amiga/dev/grf_cl.c
--- a/sys/arch/amiga/dev/grf_cl.c       Wed Jan 22 00:24:53 2014 +0000
+++ b/sys/arch/amiga/dev/grf_cl.c       Wed Jan 22 00:25:16 2014 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: grf_cl.c,v 1.48 2012/11/08 18:04:56 rkujawa Exp $ */
+/*     $NetBSD: grf_cl.c,v 1.49 2014/01/22 00:25:16 christos Exp $ */
 
 /*
  * Copyright (c) 1997 Klaus Burkert
@@ -36,7 +36,7 @@
 #include "opt_amigacons.h"
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: grf_cl.c,v 1.48 2012/11/08 18:04:56 rkujawa Exp $");
+__KERNEL_RCSID(0, "$NetBSD: grf_cl.c,v 1.49 2014/01/22 00:25:16 christos Exp $");
 
 #include "grfcl.h"
 #include "ite.h"
@@ -198,10 +198,9 @@
 grfclmatch(device_t parent, cfdata_t cf, void *aux)
 {
        struct zbus_args *zap;
-       static int regprod, fbprod, fbprod2;
+       static int regprod, fbprod;
        int error;
 
-       fbprod2 = 0;
        zap = aux;
 
 #ifndef CL5426CONSOLE
@@ -223,7 +222,6 @@
                                error = 0;
                                break;
                            case 22:
-                               fbprod2 = 22;
                                error = 0;
                                break;
                            case 21:
@@ -829,7 +827,7 @@
 cl_setmousepos(struct grf_softc *gp, struct grf_position *data)
 {
        volatile char *ba = gp->g_regkva;
-        short rx, ry, prx, pry;
+        short rx, ry;
 #ifdef CL_SHIFTSPRITE
        volatile char *fb = gp->g_fbkva;
         volatile char *sprite = fb + (cl_fbsize - 1024);
@@ -842,8 +840,6 @@
         /* current and previous real coordinates */
        rx = data->x - cl_cursprite.hot.x;
        ry = data->y - cl_cursprite.hot.y;
-       prx = cl_cursprite.pos.x - cl_cursprite.hot.x;
-       pry = cl_cursprite.pos.y - cl_cursprite.hot.y;
 
         /*
         * if we are/were on an edge, create (un)shifted bitmap --
@@ -1339,7 +1335,7 @@
        unsigned char num0, denom0, clkdoub;
        unsigned short HT, HDE, HBS, HBE, HSS, HSE, VDE, VBS, VBE, VSS,
                VSE, VT;
-       int     clkmul, offsmul, clkmode;
+       int     clkmul, clkmode;
        int     vmul;
        int     sr15;
        unsigned char hvsync_pulse;
@@ -1403,13 +1399,11 @@
        switch (gv->depth) {
            case 8:
                clkmul = 1;
-               offsmul = 1;
                clkmode = 0x0;
                break;
            case 15:
            case 16:
                clkmul = 1;
-               offsmul = 2;
                clkmode = 0x6;
                break;
            case 24:
@@ -1417,17 +1411,14 @@
                        clkmul = 1;
                else
                        clkmul = 3;
-               offsmul = 3;
                clkmode = 0x4;
                break;
            case 32:
                clkmul = 1;
-               offsmul = 2;
                clkmode = 0x8;
                break;
            default:
                clkmul = 1;
-               offsmul = 1;
                clkmode = 0x0;
                break;
        }
diff -r cc310fd1320d -r a37fe116c975 sys/arch/amiga/dev/grf_cv.c
--- a/sys/arch/amiga/dev/grf_cv.c       Wed Jan 22 00:24:53 2014 +0000
+++ b/sys/arch/amiga/dev/grf_cv.c       Wed Jan 22 00:25:16 2014 +0000



Home | Main Index | Thread Index | Old Index