Remove some assigned-to but otherwise unused variables.

This commit is contained in:
simonb 2003-10-30 01:58:17 +00:00
parent a2facef339
commit b6abb6ab1d
39 changed files with 106 additions and 204 deletions

View File

@ -1,4 +1,4 @@
/* $NetBSD: ibcs2_syscall.c,v 1.23 2003/10/27 14:11:46 junyoung Exp $ */
/* $NetBSD: ibcs2_syscall.c,v 1.24 2003/10/30 02:07:37 simonb Exp $ */
/*-
* Copyright (c) 1998, 2000 The NetBSD Foundation, Inc.
@ -37,7 +37,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: ibcs2_syscall.c,v 1.23 2003/10/27 14:11:46 junyoung Exp $");
__KERNEL_RCSID(0, "$NetBSD: ibcs2_syscall.c,v 1.24 2003/10/30 02:07:37 simonb Exp $");
#if defined(_KERNEL_OPT)
#include "opt_syscall_debug.h"
@ -194,14 +194,12 @@ ibcs2_syscall_fancy(frame)
register caddr_t params;
register const struct sysent *callp;
struct lwp *l;
register struct proc *p;
int error;
size_t argsize;
register_t code, args[8], rval[2];
uvmexp.syscalls++;
l = curlwp;
p = l->l_proc;
code = frame->tf_eax;
if (IBCS2_HIGH_SYSCALL(code))

View File

@ -1,4 +1,4 @@
/* $NetBSD: identcpu.c,v 1.6 2003/10/27 14:11:46 junyoung Exp $ */
/* $NetBSD: identcpu.c,v 1.7 2003/10/30 02:07:37 simonb Exp $ */
/*-
* Copyright (c) 1999, 2000, 2001 The NetBSD Foundation, Inc.
@ -37,7 +37,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: identcpu.c,v 1.6 2003/10/27 14:11:46 junyoung Exp $");
__KERNEL_RCSID(0, "$NetBSD: identcpu.c,v 1.7 2003/10/30 02:07:37 simonb Exp $");
#include "opt_cputype.h"
@ -1044,7 +1044,7 @@ identifycpu(struct cpu_info *ci)
{
const char *name, *modifier, *vendorname, *brand = "";
int class = CPUCLASS_386, vendor, i, max;
int modif, family, model, step;
int modif, family, model;
const struct cpu_cpuid_nameclass *cpup = NULL;
const struct cpu_cpuid_family *cpufam;
char *cpuname = ci->ci_dev->dv_xname;
@ -1071,7 +1071,6 @@ identifycpu(struct cpu_info *ci)
if (family < CPU_MINFAMILY)
panic("identifycpu: strange family value");
model = CPUID2MODEL(ci->ci_signature);
step = CPUID2STEPPING(ci->ci_signature);
for (i = 0; i < max; i++) {
if (!strncmp((char *)ci->ci_vendor,

View File

@ -1,4 +1,4 @@
/* $NetBSD: linux_syscall.c,v 1.26 2003/10/27 14:11:46 junyoung Exp $ */
/* $NetBSD: linux_syscall.c,v 1.27 2003/10/30 02:07:37 simonb Exp $ */
/*-
* Copyright (c) 1998, 2000 The NetBSD Foundation, Inc.
@ -37,7 +37,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: linux_syscall.c,v 1.26 2003/10/27 14:11:46 junyoung Exp $");
__KERNEL_RCSID(0, "$NetBSD: linux_syscall.c,v 1.27 2003/10/30 02:07:37 simonb Exp $");
#if defined(_KERNEL_OPT)
#include "opt_syscall_debug.h"
@ -194,14 +194,12 @@ linux_syscall_fancy(frame)
{
register const struct sysent *callp;
struct lwp *l;
register struct proc *p;
int error;
size_t argsize;
register_t code, args[8], rval[2];
uvmexp.syscalls++;
l = curlwp;
p = l->l_proc;
code = frame->tf_eax;
callp = linux_sysent;

View File

@ -1,4 +1,4 @@
/* $NetBSD: svr4_syscall.c,v 1.22 2003/10/27 14:11:47 junyoung Exp $ */
/* $NetBSD: svr4_syscall.c,v 1.23 2003/10/30 02:07:37 simonb Exp $ */
/*-
* Copyright (c) 1998, 2000 The NetBSD Foundation, Inc.
@ -37,7 +37,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: svr4_syscall.c,v 1.22 2003/10/27 14:11:47 junyoung Exp $");
__KERNEL_RCSID(0, "$NetBSD: svr4_syscall.c,v 1.23 2003/10/30 02:07:37 simonb Exp $");
#if defined(_KERNEL_OPT)
#include "opt_syscall_debug.h"
@ -191,14 +191,12 @@ svr4_syscall_fancy(frame)
register caddr_t params;
register const struct sysent *callp;
register struct lwp *l;
struct proc *p;
int error;
size_t argsize;
register_t code, args[8], rval[2];
uvmexp.syscalls++;
l = curlwp;
p = l->l_proc;
code = frame->tf_eax;
callp = svr4_sysent;

View File

@ -1,4 +1,4 @@
/* $NetBSD: coda_vfsops.c,v 1.29 2003/08/27 17:49:49 drochner Exp $ */
/* $NetBSD: coda_vfsops.c,v 1.30 2003/10/30 02:07:38 simonb Exp $ */
/*
*
@ -45,7 +45,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: coda_vfsops.c,v 1.29 2003/08/27 17:49:49 drochner Exp $");
__KERNEL_RCSID(0, "$NetBSD: coda_vfsops.c,v 1.30 2003/10/30 02:07:38 simonb Exp $");
#ifdef _LKM
#define NVCODA 4
@ -338,7 +338,6 @@ coda_root(vfsp, vpp)
struct vnode **vpp;
{
struct coda_mntinfo *mi = vftomi(vfsp);
struct vnode **result;
int error;
struct proc *p = curproc; /* XXX - bnoble */
CodaFid VFid;
@ -346,7 +345,6 @@ coda_root(vfsp, vpp)
ENTRY;
MARK_ENTRY(CODA_ROOT_STATS);
result = NULL;
if (vfsp == mi->mi_vfsp) {
if (memcmp(&VTOC(mi->mi_rootvp)->c_fid, &invalfid, sizeof(CodaFid)))

View File

@ -6,7 +6,7 @@ mkdir
rmdir
symlink
*/
/* $NetBSD: coda_vnops.c,v 1.37 2003/08/27 17:49:49 drochner Exp $ */
/* $NetBSD: coda_vnops.c,v 1.38 2003/10/30 02:07:38 simonb Exp $ */
/*
*
@ -54,7 +54,7 @@ symlink
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: coda_vnops.c,v 1.37 2003/08/27 17:49:49 drochner Exp $");
__KERNEL_RCSID(0, "$NetBSD: coda_vnops.c,v 1.38 2003/10/30 02:07:38 simonb Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@ -395,7 +395,6 @@ coda_rdwr(vp, uiop, rw, ioflag, cred, p)
/* locals */
struct cnode *cp = VTOC(vp);
struct vnode *cfvp = cp->c_ovp;
int igot_internally = 0;
int opened_internally = 0;
int error = 0;
@ -428,7 +427,6 @@ coda_rdwr(vp, uiop, rw, ioflag, cred, p)
* it's completely written.
*/
if (cp->c_inode != 0 && !(p && (p->p_acflag & ACORE))) {
igot_internally = 1;
error = coda_grab_vnode(cp->c_device, cp->c_inode, &cfvp);
if (error) {
MARK_INT_FAIL(CODA_RDWR_STATS);

View File

@ -1,4 +1,4 @@
/* $NetBSD: acpi_madt.c,v 1.6 2003/07/14 15:47:00 lukem Exp $ */
/* $NetBSD: acpi_madt.c,v 1.7 2003/10/30 01:58:17 simonb Exp $ */
/*
* Copyright (c) 2003 Wasabi Systems, Inc.
@ -36,7 +36,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: acpi_madt.c,v 1.6 2003/07/14 15:47:00 lukem Exp $");
__KERNEL_RCSID(0, "$NetBSD: acpi_madt.c,v 1.7 2003/10/30 01:58:17 simonb Exp $");
#include <sys/param.h>
#include <sys/ioctl.h>
@ -192,9 +192,7 @@ acpi_madt_walk(ACPI_STATUS (*func)(APIC_HEADER *, void *), void *aux)
{
char *madtend, *where;
APIC_HEADER *hdrp;
APIC_TABLE *ap;
ap = (APIC_TABLE *)AcpiGbl_MADT;
madtend = (char *)AcpiGbl_MADT + AcpiGbl_MADT->Length;
where = (char *)AcpiGbl_MADT + sizeof (APIC_TABLE);
while (where < madtend) {

View File

@ -1,4 +1,4 @@
/* $NetBSD: dpti.c,v 1.15 2003/10/29 02:13:09 mycroft Exp $ */
/* $NetBSD: dpti.c,v 1.16 2003/10/30 01:58:17 simonb Exp $ */
/*-
* Copyright (c) 2001 The NetBSD Foundation, Inc.
@ -64,7 +64,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: dpti.c,v 1.15 2003/10/29 02:13:09 mycroft Exp $");
__KERNEL_RCSID(0, "$NetBSD: dpti.c,v 1.16 2003/10/30 01:58:17 simonb Exp $");
#include "opt_i2o.h"
@ -440,7 +440,7 @@ dpti_passthrough(struct dpti_softc *sc, caddr_t data, struct proc *proc)
u_int32_t mbtmp[IOP_MAX_MSG_SIZE / sizeof(u_int32_t)];
u_int32_t rbtmp[IOP_MAX_MSG_SIZE / sizeof(u_int32_t)];
int rv, msgsize, repsize, sgoff, i, mapped, nbuf, nfrag, j, sz;
u_int32_t *p, *pmax, *pstart;
u_int32_t *p, *pmax;
iop = (struct iop_softc *)sc->sc_dv.dv_parent;
im = NULL;
@ -583,7 +583,7 @@ dpti_passthrough(struct dpti_softc *sc, caddr_t data, struct proc *proc)
*/
nfrag = 0;
sz = 0;
for (pstart = p; p <= pmax; p += 2) {
for (; p <= pmax; p += 2) {
if (nfrag == DPTI_MAX_SEGS) {
DPRINTF(("%s: too many segments\n",
sc->sc_dv.dv_xname));

View File

@ -1,4 +1,4 @@
/* $NetBSD: iop.c,v 1.40 2003/10/25 20:26:25 mycroft Exp $ */
/* $NetBSD: iop.c,v 1.41 2003/10/30 01:58:17 simonb Exp $ */
/*-
* Copyright (c) 2000, 2001, 2002 The NetBSD Foundation, Inc.
@ -41,7 +41,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: iop.c,v 1.40 2003/10/25 20:26:25 mycroft Exp $");
__KERNEL_RCSID(0, "$NetBSD: iop.c,v 1.41 2003/10/30 01:58:17 simonb Exp $");
#include "opt_i2o.h"
#include "iop.h"
@ -1798,10 +1798,8 @@ static void
iop_intr_event(struct device *dv, struct iop_msg *im, void *reply)
{
struct i2o_util_event_register_reply *rb;
struct iop_softc *sc;
u_int event;
sc = (struct iop_softc *)dv;
rb = reply;
if ((rb->msgflags & I2O_MSGFLAGS_FAIL) != 0)

View File

@ -1,4 +1,4 @@
/* $NetBSD: adwlib.c,v 1.29 2003/10/29 02:31:55 mycroft Exp $ */
/* $NetBSD: adwlib.c,v 1.30 2003/10/30 01:58:17 simonb Exp $ */
/*
* Low level routines for the Advanced Systems Inc. SCSI controllers chips
@ -52,7 +52,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: adwlib.c,v 1.29 2003/10/29 02:31:55 mycroft Exp $");
__KERNEL_RCSID(0, "$NetBSD: adwlib.c,v 1.30 2003/10/30 01:58:17 simonb Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@ -1728,7 +1728,6 @@ ADW_SCSI_REQ_Q *scsiq;
bus_space_tag_t iot = sc->sc_iot;
bus_space_handle_t ioh = sc->sc_ioh;
ADW_CCB *ccb;
long req_size;
u_int32_t req_paddr;
ADW_CARRIER *new_carrp;
@ -1764,7 +1763,6 @@ ADW_SCSI_REQ_Q *scsiq;
*/
new_carrp->next_ba = htole32(ASC_CQ_STOPPER);
req_size = sizeof(ADW_SCSI_REQ_Q);
req_paddr = sc->sc_dmamap_control->dm_segs[0].ds_addr +
ADW_CCB_OFF(ccb) + offsetof(struct adw_ccb, scsiq);
@ -2010,7 +2008,6 @@ ADW_SOFTC *sc;
bus_space_tag_t iot = sc->sc_iot;
bus_space_handle_t ioh = sc->sc_ioh;
u_int8_t int_stat;
u_int16_t target_bit;
ADW_CARRIER *free_carrp/*, *ccb_carr*/;
u_int32_t irq_next_pa;
ADW_SCSI_REQ_Q *scsiq;
@ -2107,9 +2104,6 @@ ADW_SOFTC *sc;
sc->carr_freelist = free_carrp;
sc->carr_pending_cnt--;
target_bit = ADW_TID_TO_TIDMASK(scsiq->target_id);
/*
* Clear request microcode control flag.
*/

View File

@ -1,4 +1,4 @@
/* $NetBSD: aic79xx_osm.c,v 1.6 2003/09/02 21:02:57 fvdl Exp $ */
/* $NetBSD: aic79xx_osm.c,v 1.7 2003/10/30 01:58:17 simonb Exp $ */
/*
* Bus independent NetBSD shim for the aic7xxx based adaptec SCSI controllers
@ -41,7 +41,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: aic79xx_osm.c,v 1.6 2003/09/02 21:02:57 fvdl Exp $");
__KERNEL_RCSID(0, "$NetBSD: aic79xx_osm.c,v 1.7 2003/10/30 01:58:17 simonb Exp $");
#include <dev/ic/aic79xx_osm.h>
#include <dev/ic/aic7xxx_cam.h>
@ -153,7 +153,6 @@ ahd_done(struct ahd_softc *ahd, struct scb *scb)
{
struct scsipi_xfer *xs;
struct scsipi_periph *periph;
int target;
int s;
LIST_REMOVE(scb, pending_links);
@ -163,8 +162,6 @@ ahd_done(struct ahd_softc *ahd, struct scb *scb)
callout_stop(&scb->xs->xs_callout);
target = periph->periph_target;
if (xs->datalen) {
int op;
@ -690,9 +687,6 @@ ahd_timeout(void *arg)
struct ahd_softc *ahd;
ahd_mode_state saved_modes;
int s;
int target;
int lun;
char channel;
scb = (struct scb *)arg;
ahd = (struct ahd_softc *)scb->ahd_softc;
@ -720,10 +714,6 @@ ahd_timeout(void *arg)
return;
}
target = SCB_GET_TARGET(ahd, scb);
channel = SCB_GET_CHANNEL(ahd, scb);
lun = SCB_GET_LUN(scb);
ahd_print_path(ahd, scb);
printf("SCB 0x%x - timed out\n", SCB_GET_TAG(scb));
ahd_dump_card_state(ahd);
@ -780,11 +770,10 @@ void
ahd_platform_set_tags(struct ahd_softc *ahd,
struct ahd_devinfo *devinfo, ahd_queue_alg alg)
{
struct ahd_initiator_tinfo *tinfo;
struct ahd_tmode_tstate *tstate;
tinfo = ahd_fetch_transinfo(ahd, devinfo->channel, devinfo->our_scsiid,
devinfo->target, &tstate);
ahd_fetch_transinfo(ahd, devinfo->channel, devinfo->our_scsiid,
devinfo->target, &tstate);
if (alg != AHD_QUEUE_NONE)
tstate->tagenable |= devinfo->target_mask;

View File

@ -1,4 +1,4 @@
/* $NetBSD: aic7xxx_osm.c,v 1.12 2003/10/01 18:01:06 fvdl Exp $ */
/* $NetBSD: aic7xxx_osm.c,v 1.13 2003/10/30 01:58:17 simonb Exp $ */
/*
* Bus independent FreeBSD shim for the aic7xxx based adaptec SCSI controllers
@ -39,7 +39,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: aic7xxx_osm.c,v 1.12 2003/10/01 18:01:06 fvdl Exp $");
__KERNEL_RCSID(0, "$NetBSD: aic7xxx_osm.c,v 1.13 2003/10/30 01:58:17 simonb Exp $");
#include <dev/ic/aic7xxx_osm.h>
#include <dev/ic/aic7xxx_inline.h>
@ -994,11 +994,10 @@ void
ahc_platform_set_tags(struct ahc_softc *ahc,
struct ahc_devinfo *devinfo, int enable)
{
struct ahc_initiator_tinfo *tinfo;
struct ahc_tmode_tstate *tstate;
tinfo = ahc_fetch_transinfo(ahc, devinfo->channel, devinfo->our_scsiid,
devinfo->target, &tstate);
ahc_fetch_transinfo(ahc, devinfo->channel, devinfo->our_scsiid,
devinfo->target, &tstate);
if (enable)
tstate->tagenable |= devinfo->target_mask;

View File

@ -1,4 +1,4 @@
/* $NetBSD: awi.c,v 1.55 2003/10/15 07:18:17 simonb Exp $ */
/* $NetBSD: awi.c,v 1.56 2003/10/30 01:58:17 simonb Exp $ */
/*-
* Copyright (c) 1999,2000,2001 The NetBSD Foundation, Inc.
@ -85,7 +85,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: awi.c,v 1.55 2003/10/15 07:18:17 simonb Exp $");
__KERNEL_RCSID(0, "$NetBSD: awi.c,v 1.56 2003/10/30 01:58:17 simonb Exp $");
#include "opt_inet.h"
#include "bpfilter.h"
@ -397,7 +397,7 @@ awi_intr(void *arg)
{
struct awi_softc *sc = arg;
u_int16_t status;
int error, handled = 0, ocansleep;
int handled = 0, ocansleep;
#ifdef AWI_DEBUG
static const char *intname[] = {
"CMD", "RX", "TX", "SCAN_CMPLT",
@ -417,7 +417,7 @@ awi_intr(void *arg)
sc->sc_cansleep = 0;
for (;;) {
if ((error = awi_intr_lock(sc)) != 0)
if (awi_intr_lock(sc) != 0)
break;
status = awi_read_1(sc, AWI_INTSTAT);
awi_write_1(sc, AWI_INTSTAT, 0);

View File

@ -1,4 +1,4 @@
/* $NetBSD: cs89x0.c,v 1.10 2003/10/25 18:35:42 christos Exp $ */
/* $NetBSD: cs89x0.c,v 1.11 2003/10/30 01:58:17 simonb Exp $ */
/*
* Copyright 1997
@ -186,7 +186,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: cs89x0.c,v 1.10 2003/10/25 18:35:42 christos Exp $");
__KERNEL_RCSID(0, "$NetBSD: cs89x0.c,v 1.11 2003/10/30 01:58:17 simonb Exp $");
#include "opt_inet.h"
@ -1286,9 +1286,6 @@ cs_counter_event(struct cs_softc *sc, u_int16_t cntEvent)
void
cs_buffer_event(struct cs_softc *sc, u_int16_t bufEvent)
{
struct ifnet *ifp;
ifp = &sc->sc_ethercom.ec_if;
/*
* multiple events can be in the buffer event register at one time so

View File

@ -1,4 +1,4 @@
/* $NetBSD: hd64570.c,v 1.23 2003/05/03 18:11:17 wiz Exp $ */
/* $NetBSD: hd64570.c,v 1.24 2003/10/30 01:58:17 simonb Exp $ */
/*
* Copyright (c) 1999 Christian E. Hopps
@ -65,7 +65,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: hd64570.c,v 1.23 2003/05/03 18:11:17 wiz Exp $");
__KERNEL_RCSID(0, "$NetBSD: hd64570.c,v 1.24 2003/10/30 01:58:17 simonb Exp $");
#include "bpfilter.h"
#include "opt_inet.h"
@ -1469,7 +1469,6 @@ sca_get_packets(sca_port_t *scp)
static int
sca_frame_avail(sca_port_t *scp)
{
struct sca_softc *sc;
u_int16_t cda;
u_int32_t desc_p; /* physical address (lower 16 bits) */
sca_desc_t *desc;
@ -1479,7 +1478,6 @@ sca_frame_avail(sca_port_t *scp)
/*
* Read the current descriptor from the SCA.
*/
sc = scp->sca;
cda = dmac_read_2(scp, SCA_CDAL0);
/*
@ -1970,12 +1968,9 @@ sca_shutdown(struct sca_softc *sca)
static void
sca_port_starttx(sca_port_t *scp)
{
struct sca_softc *sc;
u_int32_t startdesc_p, enddesc_p;
int enddesc;
sc = scp->sca;
SCA_DPRINTF(SCA_DEBUG_TX, ("TX: starttx\n"));
if (((scp->sp_if.if_flags & IFF_OACTIVE) == IFF_OACTIVE)

View File

@ -1,4 +1,4 @@
/* $NetBSD: interwave.c,v 1.18 2003/05/03 18:11:19 wiz Exp $ */
/* $NetBSD: interwave.c,v 1.19 2003/10/30 01:58:17 simonb Exp $ */
/*
* Copyright (c) 1997, 1999 The NetBSD Foundation, Inc.
@ -36,7 +36,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: interwave.c,v 1.18 2003/05/03 18:11:19 wiz Exp $");
__KERNEL_RCSID(0, "$NetBSD: interwave.c,v 1.19 2003/10/30 01:58:17 simonb Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@ -1047,7 +1047,6 @@ iw_start_output(addr, p, cc, intr, arg)
void *arg;
{
struct iw_softc *sc = addr;
int counter;
#ifdef AUDIO_DEBUG
if (sc->sc_playlocked) {
@ -1069,8 +1068,6 @@ iw_start_output(addr, p, cc, intr, arg)
sc->sc_dma_flags |= DMAMODE_WRITE;
sc->sc_playdma_bp = p;
counter = 0;
isa_dmastart(sc->sc_ic, sc->sc_playdrq, sc->sc_playdma_bp,
cc, NULL, DMAMODE_WRITE, BUS_DMA_NOWAIT);
@ -1112,7 +1109,6 @@ iw_start_input(addr, p, cc, intr, arg)
void *arg;
{
struct iw_softc *sc = addr;
int counter;
#if AUDIO_DEBUG
if (sc->sc_reclocked) {
@ -1135,8 +1131,6 @@ iw_start_input(addr, p, cc, intr, arg)
sc->sc_dma_flags |= DMAMODE_READ;
sc->sc_recdma_bp = p;
counter = 0;
isa_dmastart(sc->sc_ic, sc->sc_recdrq, sc->sc_recdma_bp,
cc, NULL, DMAMODE_READ, BUS_DMA_NOWAIT);

View File

@ -1,4 +1,4 @@
/* $NetBSD: midway.c,v 1.61 2003/06/23 11:01:58 martin Exp $ */
/* $NetBSD: midway.c,v 1.62 2003/10/30 01:58:17 simonb Exp $ */
/* (sync'd to midway.c 1.68) */
/*
@ -68,7 +68,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: midway.c,v 1.61 2003/06/23 11:01:58 martin Exp $");
__KERNEL_RCSID(0, "$NetBSD: midway.c,v 1.62 2003/10/30 01:58:17 simonb Exp $");
#include "opt_natm.h"
@ -2983,7 +2983,7 @@ struct en_softc *sc;
struct mbuf *m, *tmp;
u_int32_t cur, dstart, rbd, pdu, *sav, dma, bcode, count, *data, *datastop;
u_int32_t start, stop, cnt, needalign;
int slot, raw, aal5, llc, vci, fill, mlen, tlen, drqneed, need, needfill, end;
int slot, raw, aal5, vci, fill, mlen, tlen, drqneed, need, needfill, end;
aal5 = 0; /* Silence gcc */
next_vci:
@ -3057,7 +3057,6 @@ defer: /* defer processing */
/* normal mode */
aal5 = (sc->rxslot[slot].atm_flags & ATM_PH_AAL5);
llc = (aal5 && (sc->rxslot[slot].atm_flags & ATM_PH_LLCSNAP)) ? 1 : 0;
rbd = EN_READ(sc, cur);
if (MID_RBD_ID(rbd) != MID_RBD_STDID)
panic("en_service: id mismatch");

View File

@ -1,4 +1,4 @@
/* $NetBSD: rrunner.c,v 1.41 2003/10/19 01:49:03 simonb Exp $ */
/* $NetBSD: rrunner.c,v 1.42 2003/10/30 01:58:17 simonb Exp $ */
/*
* Copyright (c) 1997, 1998 The NetBSD Foundation, Inc.
@ -42,7 +42,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: rrunner.c,v 1.41 2003/10/19 01:49:03 simonb Exp $");
__KERNEL_RCSID(0, "$NetBSD: rrunner.c,v 1.42 2003/10/30 01:58:17 simonb Exp $");
#include "opt_inet.h"
#include "opt_ns.h"
@ -3335,7 +3335,6 @@ eshstop(sc)
struct ifnet *ifp = &sc->sc_if;
bus_space_tag_t iot = sc->sc_iot;
bus_space_handle_t ioh = sc->sc_ioh;
struct rr_ring_ctl *ring;
u_int32_t misc_host_ctl;
int i;
@ -3353,7 +3352,6 @@ eshstop(sc)
sc->sc_flags = 0;
ifp->if_timer = 0; /* turn off watchdog timer */
ring = sc->sc_recv_ring_table + HIPPI_ULP_802;
while (sc->sc_snap_recv.ec_consumer
!= sc->sc_snap_recv.ec_producer) {
struct mbuf *m0;
@ -3406,7 +3404,6 @@ eshstop(sc)
/* XXX: doesn't clear bufs being sent */
ring = &sc->sc_gen_info->ri_send_ring_ctl;
bus_dmamap_unload(sc->sc_dmat, sc->sc_send.ec_dma);
if (sc->sc_send.ec_cur_mbuf) {
m_freem(sc->sc_send.ec_cur_mbuf);

View File

@ -1,4 +1,4 @@
/* $NetBSD: tropic.c,v 1.20 2003/01/06 13:05:13 wiz Exp $ */
/* $NetBSD: tropic.c,v 1.21 2003/10/30 01:58:17 simonb Exp $ */
/*
* Ported to NetBSD by Onno van der Linden
@ -34,7 +34,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: tropic.c,v 1.20 2003/01/06 13:05:13 wiz Exp $");
__KERNEL_RCSID(0, "$NetBSD: tropic.c,v 1.21 2003/10/30 01:58:17 simonb Exp $");
#include "opt_inet.h"
#include "opt_ns.h"
@ -243,11 +243,8 @@ tr_attach(sc)
struct ifnet *ifp = &sc->sc_ethercom.ec_if;
if (sc->sc_init_status & FAST_PATH_TRANSMIT) {
bus_size_t srb;
int nbuf = 0;
srb = sc->sc_srb;
switch (sc->sc_memsize) {
case 65536:
nbuf = 58;

View File

@ -1,4 +1,4 @@
/* $NetBSD: uha.c,v 1.31 2001/11/15 09:48:08 lukem Exp $ */
/* $NetBSD: uha.c,v 1.32 2003/10/30 01:58:17 simonb Exp $ */
/*-
* Copyright (c) 1997, 1998 The NetBSD Foundation, Inc.
@ -60,7 +60,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: uha.c,v 1.31 2001/11/15 09:48:08 lukem Exp $");
__KERNEL_RCSID(0, "$NetBSD: uha.c,v 1.32 2003/10/30 01:58:17 simonb Exp $");
#undef UHADEBUG
#ifdef DDB
@ -434,7 +434,6 @@ uha_scsipi_request(chan, req, arg)
struct uha_softc *sc = (void *)chan->chan_adapter->adapt_dev;
bus_dma_tag_t dmat = sc->sc_dmat;
struct uha_mscp *mscp;
struct uha_dma_seg *sg;
int error, seg, flags, s;
@ -488,7 +487,6 @@ uha_scsipi_request(chan, req, arg)
mscp->target_stat = 0x00;
if (xs->datalen) {
sg = mscp->uha_dma;
seg = 0;
#ifdef TFS
if (flags & SCSI_DATA_UIO) {

View File

@ -1,4 +1,4 @@
/* $NetBSD: wdc.c,v 1.149 2003/10/29 22:09:41 bouyer Exp $ */
/* $NetBSD: wdc.c,v 1.150 2003/10/30 01:58:17 simonb Exp $ */
/*
* Copyright (c) 1998, 2001, 2003 Manuel Bouyer. All rights reserved.
@ -70,7 +70,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: wdc.c,v 1.149 2003/10/29 22:09:41 bouyer Exp $");
__KERNEL_RCSID(0, "$NetBSD: wdc.c,v 1.150 2003/10/30 01:58:17 simonb Exp $");
#ifndef WDCDEBUG
#define WDCDEBUG
@ -317,7 +317,7 @@ atabusconfig(atabus_sc)
struct atabus_softc *atabus_sc;
{
struct channel_softc *chp = atabus_sc->sc_chan;
int ctrl_flags, i, error, need_delref = 0;
int i, error, need_delref = 0;
struct ataparams params;
struct atabus_initq *atabus_initq = NULL;
u_int8_t st0 = 0, st1 = 0;
@ -458,7 +458,6 @@ atabusconfig(atabus_sc)
}
}
}
ctrl_flags = chp->wdc->sc_dev.dv_cfdata->cf_flags;
WDCDEBUG_PRINT(("atabusattach: ch_drive_flags 0x%x 0x%x\n",
chp->ch_drive[0].drive_flags, chp->ch_drive[1].drive_flags),

View File

@ -1,4 +1,4 @@
/* $NetBSD: if_eg.c,v 1.61 2003/01/15 22:00:43 bouyer Exp $ */
/* $NetBSD: if_eg.c,v 1.62 2003/10/30 01:58:17 simonb Exp $ */
/*
* Copyright (c) 1993 Dean Huxley <dean@fsa.ca>
@ -40,7 +40,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: if_eg.c,v 1.61 2003/01/15 22:00:43 bouyer Exp $");
__KERNEL_RCSID(0, "$NetBSD: if_eg.c,v 1.62 2003/10/30 01:58:17 simonb Exp $");
#include "opt_inet.h"
#include "opt_ns.h"
@ -273,7 +273,6 @@ egreadPCB(iot, ioh, pcb)
u_int8_t *pcb;
{
int i;
u_int8_t b;
bus_space_write_1(iot, ioh, EG_CONTROL,
(bus_space_read_1(iot, ioh, EG_CONTROL) & ~EG_PCB_STAT) | EG_PCB_NULL);
@ -304,7 +303,7 @@ egreadPCB(iot, ioh, pcb)
return 1;
if (egreadPCBstat(iot, ioh, EG_PCB_DONE))
return 1;
if ((b = bus_space_read_1(iot, ioh, EG_COMMAND)) != pcb[1] + 2) {
if (bus_space_read_1(iot, ioh, EG_COMMAND) != pcb[1] + 2) {
DPRINTF(("%d != %d\n", b, pcb[1] + 2));
return 1;
}

View File

@ -1,4 +1,4 @@
/* $NetBSD: if_iy.c,v 1.62 2003/01/06 13:05:14 wiz Exp $ */
/* $NetBSD: if_iy.c,v 1.63 2003/10/30 01:58:17 simonb Exp $ */
/* #define IYDEBUG */
/* #define IYMEMDEBUG */
@ -46,7 +46,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: if_iy.c,v 1.62 2003/01/06 13:05:14 wiz Exp $");
__KERNEL_RCSID(0, "$NetBSD: if_iy.c,v 1.63 2003/10/30 01:58:17 simonb Exp $");
#include "opt_inet.h"
#include "opt_ns.h"
@ -1093,7 +1093,6 @@ void
iy_intr_rx(sc)
struct iy_softc *sc;
{
struct ifnet *ifp;
bus_space_tag_t iot;
bus_space_handle_t ioh;
@ -1101,7 +1100,6 @@ struct iy_softc *sc;
iot = sc->sc_iot;
ioh = sc->sc_ioh;
ifp = &sc->sc_ethercom.ec_if;
rxadrs = sc->rx_start;
bus_space_write_2(iot, ioh, HOST_ADDR_REG, rxadrs);

View File

@ -1,4 +1,4 @@
/* $NetBSD: auvia.c,v 1.32 2003/09/14 14:48:17 jmmv Exp $ */
/* $NetBSD: auvia.c,v 1.33 2003/10/30 01:58:17 simonb Exp $ */
/*-
* Copyright (c) 2000 The NetBSD Foundation, Inc.
@ -47,7 +47,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: auvia.c,v 1.32 2003/09/14 14:48:17 jmmv Exp $");
__KERNEL_RCSID(0, "$NetBSD: auvia.c,v 1.33 2003/10/30 01:58:17 simonb Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@ -941,13 +941,12 @@ auvia_build_dma_ops(struct auvia_softc *sc, struct auvia_softc_chan *ch,
{
struct auvia_dma_op *op;
struct auvia_dma *dp;
bus_addr_t s, e;
bus_addr_t s;
size_t l;
int segs;
s = p->map->dm_segs[0].ds_addr;
l = ((char *)end - (char *)start);
e = s + l;
segs = (l + blksize - 1) / blksize;
if (segs > (ch->sc_dma_op_count)) {

View File

@ -1,6 +1,6 @@
/* $SourceForge: bktr_card.c,v 1.3 2003/03/11 23:11:21 thomasklausner Exp $ */
/* $NetBSD: bktr_card.c,v 1.15 2003/03/12 00:14:40 wiz Exp $ */
/* $NetBSD: bktr_card.c,v 1.16 2003/10/30 01:58:17 simonb Exp $ */
/* $FreeBSD: src/sys/dev/bktr/bktr_card.c,v 1.16 2000/10/31 13:09:56 roger Exp$ */
/*
@ -51,7 +51,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: bktr_card.c,v 1.15 2003/03/12 00:14:40 wiz Exp $");
__KERNEL_RCSID(0, "$NetBSD: bktr_card.c,v 1.16 2003/10/30 01:58:17 simonb Exp $");
#include "opt_bktr.h" /* Include any kernel config options */
@ -919,10 +919,9 @@ checkTuner:
/* Determine the model number from the eeprom */
if (bktr->card.eepromAddr != 0) {
/* eeprom data block structure */
unsigned char *block_1, *block_2, *block_3, *block_4;
unsigned char *block_1, *block_2, *block_3;
int block_1_data_size, block_2_data_size, block_3_data_size;
int block_1_total_size, block_2_total_size, block_3_total_size;
int block_4_header_size;
unsigned int model,revision;
unsigned char tuner_code;
@ -943,9 +942,6 @@ checkTuner:
block_3_data_size = (block_3[0] &0x07);
block_3_total_size = block_3_data_size + 1; /* Header size */
block_4 = &eeprom[block_1_total_size +block_2_total_size +block_3_total_size];
block_4_header_size = 1;
model = (block_1[12] << 8 | block_1[11]);
revision = (block_1[15] << 16 | block_1[14] << 8 | block_1[13]);

View File

@ -1,4 +1,4 @@
/* $NetBSD: cmdide.c,v 1.3 2003/10/24 00:24:15 mycroft Exp $ */
/* $NetBSD: cmdide.c,v 1.4 2003/10/30 01:58:17 simonb Exp $ */
/*
* Copyright (c) 1999, 2000, 2001 Manuel Bouyer.
@ -272,7 +272,6 @@ cmd_chip_map(struct pciide_softc *sc, struct pci_attach_args *pa)
static void
cmd0643_9_chip_map(struct pciide_softc *sc, struct pci_attach_args *pa)
{
struct pciide_channel *cp;
int channel;
pcireg_t rev = PCI_REVISION(pa->pa_class);
@ -348,10 +347,9 @@ cmd0643_9_chip_map(struct pciide_softc *sc, struct pci_attach_args *pa)
pci_conf_read(sc->sc_pc, sc->sc_tag, 0x58)),
DEBUG_PROBE);
for (channel = 0; channel < sc->sc_wdcdev.nchannels; channel++) {
cp = &sc->pciide_channels[channel];
for (channel = 0; channel < sc->sc_wdcdev.nchannels; channel++)
cmd_channel_map(pa, sc, channel);
}
/*
* note - this also makes sure we clear the irq disable and reset
* bits
@ -462,7 +460,6 @@ cmd646_9_irqack(struct channel_softc *chp)
static void
cmd680_chip_map(struct pciide_softc *sc, struct pci_attach_args *pa)
{
struct pciide_channel *cp;
int channel;
if (pciide_chipen(sc, pa) == 0)
@ -491,10 +488,8 @@ cmd680_chip_map(struct pciide_softc *sc, struct pci_attach_args *pa)
pciide_pci_write(sc->sc_pc, sc->sc_tag, 0x84, 0x00);
pciide_pci_write(sc->sc_pc, sc->sc_tag, 0x8a,
pciide_pci_read(sc->sc_pc, sc->sc_tag, 0x8a) | 0x01);
for (channel = 0; channel < sc->sc_wdcdev.nchannels; channel++) {
cp = &sc->pciide_channels[channel];
for (channel = 0; channel < sc->sc_wdcdev.nchannels; channel++)
cmd680_channel_map(pa, sc, channel);
}
}
static void

View File

@ -1,4 +1,4 @@
/* $NetBSD: emuxki.c,v 1.28 2003/10/25 21:31:43 christos Exp $ */
/* $NetBSD: emuxki.c,v 1.29 2003/10/30 01:58:17 simonb Exp $ */
/*-
* Copyright (c) 2001 The NetBSD Foundation, Inc.
@ -56,7 +56,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: emuxki.c,v 1.28 2003/10/25 21:31:43 christos Exp $");
__KERNEL_RCSID(0, "$NetBSD: emuxki.c,v 1.29 2003/10/30 01:58:17 simonb Exp $");
#include <sys/param.h>
#include <sys/device.h>
@ -437,10 +437,9 @@ static int
emuxki_detach(struct device *self, int flags)
{
struct emuxki_softc *sc = (struct emuxki_softc *) self;
int err = 0;
if (sc->sc_audev != NULL) /* Test in case audio didn't attach */
err = config_detach(sc->sc_audev, 0);
config_detach(sc->sc_audev, 0);
/* All voices should be stopped now but add some code here if not */
@ -1021,10 +1020,8 @@ static void
emuxki_channel_set_bufparms(struct emuxki_channel *chan,
u_int32_t start, u_int32_t end)
{
u_int8_t shift;
struct emuxki_voice *voice = chan->voice;
shift = voice->stereo + voice->b16;
chan->loop.start = start & EMU_CHAN_PSST_LOOPSTARTADDR_MASK;
chan->loop.end = end & EMU_CHAN_DSL_LOOPENDADDR_MASK;
}
@ -2130,9 +2127,7 @@ emuxki_mappage(void *addr, void *ptr, off_t off, int prot)
{
struct emuxki_softc *sc = addr;
struct emuxki_mem *mem;
u_int32_t *ptb;
ptb = KERNADDR(sc->ptb);
LIST_FOREACH(mem, &sc->mem, next) {
if (KERNADDR(mem->dmamem) == ptr) {
struct dmamem *dm = mem->dmamem;

View File

@ -1,4 +1,4 @@
/* $NetBSD: if_bge.c,v 1.52 2003/10/23 20:36:36 fvdl Exp $ */
/* $NetBSD: if_bge.c,v 1.53 2003/10/30 01:58:17 simonb Exp $ */
/*
* Copyright (c) 2001 Wind River Systems
@ -79,7 +79,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: if_bge.c,v 1.52 2003/10/23 20:36:36 fvdl Exp $");
__KERNEL_RCSID(0, "$NetBSD: if_bge.c,v 1.53 2003/10/30 01:58:17 simonb Exp $");
#include "bpfilter.h"
#include "vlan.h"
@ -435,13 +435,10 @@ bge_miibus_readreg(dev, phy, reg)
int phy, reg;
{
struct bge_softc *sc = (struct bge_softc *)dev;
struct ifnet *ifp;
u_int32_t val;
u_int32_t saved_autopoll;
int i;
ifp = &sc->ethercom.ec_if;
/*
* Several chips with builtin PHYs will incorrectly answer to
* other PHY instances than the builtin PHY at id 1.

View File

@ -1,4 +1,4 @@
/* $NetBSD: if_en_pci.c,v 1.19 2003/01/31 00:07:42 thorpej Exp $ */
/* $NetBSD: if_en_pci.c,v 1.20 2003/10/30 01:58:17 simonb Exp $ */
/*
*
@ -43,7 +43,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: if_en_pci.c,v 1.19 2003/01/31 00:07:42 thorpej Exp $");
__KERNEL_RCSID(0, "$NetBSD: if_en_pci.c,v 1.20 2003/10/30 01:58:17 simonb Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@ -334,7 +334,7 @@ eni_get_macaddr(scp, pa)
struct en_softc *sc = (struct en_softc *)scp;
pci_chipset_tag_t id = scp->en_pc;
pcitag_t tag = pa->pa_tag;
int i, j, address, status;
int i, j, address;
u_int32_t data, t_data;
u_int8_t tmp;
@ -370,7 +370,6 @@ eni_get_macaddr(scp, pa)
data |= EN_PROM_CLK ;
pci_conf_write(id, tag, EN_TONGA, data);
data = pci_conf_read(id, tag, EN_TONGA);
status = data & EN_PROM_DATA;
data &= ~EN_PROM_CLK ;
pci_conf_write(id, tag, EN_TONGA, data);
data |= EN_PROM_DATA ;
@ -397,7 +396,6 @@ eni_get_macaddr(scp, pa)
data |= EN_PROM_CLK ;
pci_conf_write(id, tag, EN_TONGA, data);
data = pci_conf_read(id, tag, EN_TONGA);
status = data & EN_PROM_DATA;
data &= ~EN_PROM_CLK ;
pci_conf_write(id, tag, EN_TONGA, data);
data |= EN_PROM_DATA ;

View File

@ -1,4 +1,4 @@
/* $NetBSD: neo.c,v 1.19 2003/05/03 18:11:36 wiz Exp $ */
/* $NetBSD: neo.c,v 1.20 2003/10/30 01:58:17 simonb Exp $ */
/*
* Copyright (c) 1999 Cameron Grant <gandalf@vilnya.demon.co.uk>
@ -32,7 +32,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: neo.c,v 1.19 2003/05/03 18:11:36 wiz Exp $");
__KERNEL_RCSID(0, "$NetBSD: neo.c,v 1.20 2003/10/30 01:58:17 simonb Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@ -350,10 +350,9 @@ int
neo_intr(void *p)
{
struct neo_softc *sc = (struct neo_softc *)p;
int status, x, active;
int status, x;
int rv = 0;
active = (sc->pintr || sc->rintr);
status = (sc->irsz == 2) ?
nm_rd_2(sc, NM_INT_REG) :
nm_rd_4(sc, NM_INT_REG);
@ -555,7 +554,6 @@ neo_attach(struct device *parent, struct device *self, void *aux)
char const *intrstr;
pci_intr_handle_t ih;
pcireg_t csr;
int error;
sc->type = PCI_PRODUCT(pa->pa_id);
@ -594,7 +592,7 @@ neo_attach(struct device *parent, struct device *self, void *aux)
}
printf("%s: interruping at %s\n", sc->dev.dv_xname, intrstr);
if ((error = nm_init(sc)) != 0)
if (nm_init(sc) != 0)
return;
/* Enable the device. */
@ -610,7 +608,7 @@ neo_attach(struct device *parent, struct device *self, void *aux)
sc->host_if.reset = neo_reset_codec;
sc->host_if.flags = neo_flags_codec;
if ((error = ac97_attach(&sc->host_if)) != 0)
if (ac97_attach(&sc->host_if) != 0)
return;
sc->powerhook = powerhook_establish(neo_power, sc);

View File

@ -1,4 +1,4 @@
/* $NetBSD: trm.c,v 1.13 2002/10/02 16:51:56 thorpej Exp $ */
/* $NetBSD: trm.c,v 1.14 2003/10/30 01:58:17 simonb Exp $ */
/*
* Device Driver for Tekram DC395U/UW/F, DC315/U
* PCI SCSI Bus Master Host Adapter
@ -42,7 +42,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: trm.c,v 1.13 2002/10/02 16:51:56 thorpej Exp $");
__KERNEL_RCSID(0, "$NetBSD: trm.c,v 1.14 2003/10/30 01:58:17 simonb Exp $");
/* #define TRM_DEBUG */
#ifdef TRM_DEBUG
@ -1116,7 +1116,6 @@ trm_intr(arg)
bus_space_tag_t iot;
bus_space_handle_t ioh;
struct trm_softc *sc;
struct trm_srb *srb;
int intstat, stat;
DPRINTF(("trm_intr......\n"));
@ -1151,7 +1150,6 @@ trm_intr(arg)
return (1);
}
if (intstat & (INT_BUSSERVICE | INT_CMDDONE)) {
srb = sc->sc_actsrb;
DPRINTF(("sc->sc_phase = %2d, sc->sc_state = %2d\n",
sc->sc_phase, sc->sc_state));
/*

View File

@ -1,4 +1,4 @@
/* $NetBSD: twe.c,v 1.51 2003/09/25 22:26:40 thorpej Exp $ */
/* $NetBSD: twe.c,v 1.52 2003/10/30 01:58:17 simonb Exp $ */
/*-
* Copyright (c) 2000, 2001, 2002, 2003 The NetBSD Foundation, Inc.
@ -70,7 +70,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: twe.c,v 1.51 2003/09/25 22:26:40 thorpej Exp $");
__KERNEL_RCSID(0, "$NetBSD: twe.c,v 1.52 2003/10/30 01:58:17 simonb Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@ -1647,7 +1647,6 @@ tweioctl(dev_t dev, u_long cmd, caddr_t data, int flag, struct proc *p)
struct twe_usercommand *tu;
struct twe_paramcommand *tp;
struct twe_drivecommand *td;
union twe_statrequest *ts;
void *pdata = NULL;
int s, error = 0;
u_int8_t cmdid;
@ -1659,7 +1658,6 @@ tweioctl(dev_t dev, u_long cmd, caddr_t data, int flag, struct proc *p)
tu = (struct twe_usercommand *)data;
tp = (struct twe_paramcommand *)data;
td = (struct twe_drivecommand *)data;
ts = (union twe_statrequest *)data;
/* This is intended to be compatible with the FreeBSD interface. */
switch (cmd) {

View File

@ -1,4 +1,4 @@
/* $NetBSD: rf_netbsdkintf.c,v 1.164 2003/10/25 18:34:14 christos Exp $ */
/* $NetBSD: rf_netbsdkintf.c,v 1.165 2003/10/30 01:58:17 simonb Exp $ */
/*-
* Copyright (c) 1996, 1997, 1998 The NetBSD Foundation, Inc.
* All rights reserved.
@ -146,7 +146,7 @@
***********************************************************/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: rf_netbsdkintf.c,v 1.164 2003/10/25 18:34:14 christos Exp $");
__KERNEL_RCSID(0, "$NetBSD: rf_netbsdkintf.c,v 1.165 2003/10/30 01:58:17 simonb Exp $");
#include <sys/param.h>
#include <sys/errno.h>
@ -702,7 +702,6 @@ raidstrategy(bp)
unsigned int raidID = raidunit(bp->b_dev);
RF_Raid_t *raidPtr;
struct raid_softc *rs = &raid_softc[raidID];
struct disklabel *lp;
int wlabel;
if ((rs->sc_flags & RAIDF_INITED) ==0) {
@ -732,7 +731,6 @@ raidstrategy(bp)
biodone(bp);
return;
}
lp = rs->sc_dkdev.dk_label;
/*
* Do bounds checking and adjust transfer. If there's an
@ -767,7 +765,6 @@ raidread(dev, uio, flags)
{
int unit = raidunit(dev);
struct raid_softc *rs;
int part;
if (unit >= numraid)
return (ENXIO);
@ -775,7 +772,6 @@ raidread(dev, uio, flags)
if ((rs->sc_flags & RAIDF_INITED) == 0)
return (ENXIO);
part = DISKPART(dev);
return (physio(raidstrategy, NULL, dev, B_READ, minphys, uio));

View File

@ -1,4 +1,4 @@
/* $NetBSD: sysmon_wdog.c,v 1.8 2003/06/29 22:30:51 fvdl Exp $ */
/* $NetBSD: sysmon_wdog.c,v 1.9 2003/10/30 01:58:18 simonb Exp $ */
/*-
* Copyright (c) 2000 Zembu Labs, Inc.
@ -41,7 +41,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: sysmon_wdog.c,v 1.8 2003/06/29 22:30:51 fvdl Exp $");
__KERNEL_RCSID(0, "$NetBSD: sysmon_wdog.c,v 1.9 2003/10/30 01:58:18 simonb Exp $");
#include <sys/param.h>
#include <sys/conf.h>
@ -114,7 +114,7 @@ int
sysmonclose_wdog(dev_t dev, int flag, int mode, struct proc *p)
{
struct sysmon_wdog *smw;
int omode, s, error = 0;
int s, error = 0;
/*
* If this is the last close, and there is a watchdog
@ -125,7 +125,7 @@ sysmonclose_wdog(dev_t dev, int flag, int mode, struct proc *p)
*/
SYSMON_WDOG_LOCK(s);
if ((smw = sysmon_armed_wdog) != NULL) {
if ((omode = smw->smw_mode) == WDOG_MODE_UTICKLE) {
if (smw->smw_mode == WDOG_MODE_UTICKLE) {
error = sysmon_wdog_setmode(smw,
WDOG_MODE_DISARMED, smw->smw_period);
if (error) {

View File

@ -1,4 +1,4 @@
/* $NetBSD: smbfs_node.c,v 1.18 2003/06/29 22:31:13 fvdl Exp $ */
/* $NetBSD: smbfs_node.c,v 1.19 2003/10/30 01:58:18 simonb Exp $ */
/*
* Copyright (c) 2000-2001 Boris Popov
@ -35,7 +35,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: smbfs_node.c,v 1.18 2003/06/29 22:31:13 fvdl Exp $");
__KERNEL_RCSID(0, "$NetBSD: smbfs_node.c,v 1.19 2003/10/30 01:58:18 simonb Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@ -273,13 +273,12 @@ smbfs_inactive(v)
struct vnode *vp = ap->a_vp;
struct smbnode *np = VTOSMB(vp);
struct smb_cred scred;
int error;
SMBVDEBUG("%.*s: %d\n", (int) np->n_nmlen, np->n_name, vp->v_usecount);
if (np->n_opencount) {
error = smbfs_vinvalbuf(vp, V_SAVE, cred, p, 1);
smbfs_vinvalbuf(vp, V_SAVE, cred, p, 1);
smb_makescred(&scred, p, cred);
error = smbfs_smb_close(np->n_mount->sm_share, np->n_fid,
smbfs_smb_close(np->n_mount->sm_share, np->n_fid,
&np->n_mtime, &scred);
np->n_opencount = 0;
}

View File

@ -1,4 +1,4 @@
/* $NetBSD: kern_malloc.c,v 1.88 2003/09/27 23:10:47 mycroft Exp $ */
/* $NetBSD: kern_malloc.c,v 1.89 2003/10/30 01:58:18 simonb Exp $ */
/*
* Copyright (c) 1987, 1991, 1993
@ -66,7 +66,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: kern_malloc.c,v 1.88 2003/09/27 23:10:47 mycroft Exp $");
__KERNEL_RCSID(0, "$NetBSD: kern_malloc.c,v 1.89 2003/10/30 01:58:18 simonb Exp $");
#include "opt_lockdebug.h"
@ -267,7 +267,6 @@ malloc(unsigned long size, struct malloc_type *ksp, int flags)
#ifdef DIAGNOSTIC
uint32_t *end, *lp;
int copysize;
const char *savedtype;
#endif
#ifdef LOCKDEBUG
@ -377,7 +376,6 @@ malloc(unsigned long size, struct malloc_type *ksp, int flags)
#ifdef DIAGNOSTIC
freep = (struct freelist *)va;
/* XXX potential to get garbage pointer here. */
savedtype = freep->type->ks_shortdesc;
if (kbp->kb_next) {
int rv;
vaddr_t addr = (vaddr_t)kbp->kb_next;

View File

@ -1,4 +1,4 @@
/* $NetBSD: kern_sa.c,v 1.29 2003/10/25 12:08:45 yamt Exp $ */
/* $NetBSD: kern_sa.c,v 1.30 2003/10/30 01:58:18 simonb Exp $ */
/*-
* Copyright (c) 2001 The NetBSD Foundation, Inc.
@ -37,7 +37,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: kern_sa.c,v 1.29 2003/10/25 12:08:45 yamt Exp $");
__KERNEL_RCSID(0, "$NetBSD: kern_sa.c,v 1.30 2003/10/30 01:58:18 simonb Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@ -1554,9 +1554,7 @@ debug_print_sa(struct proc *p)
int
debug_print_lwp(struct lwp *l)
{
struct proc *p;
p = l->l_proc;
printf("LWP %d address %p ", l->l_lid, l);
printf("state %d flags %x ", l->l_stat, l->l_flag);
if (l->l_wchan)

View File

@ -1,4 +1,4 @@
/* $NetBSD: kern_systrace.c,v 1.32 2003/09/13 08:32:14 jdolecek Exp $ */
/* $NetBSD: kern_systrace.c,v 1.33 2003/10/30 01:58:18 simonb Exp $ */
/*
* Copyright 2002, 2003 Niels Provos <provos@citi.umich.edu>
@ -31,7 +31,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: kern_systrace.c,v 1.32 2003/09/13 08:32:14 jdolecek Exp $");
__KERNEL_RCSID(0, "$NetBSD: kern_systrace.c,v 1.33 2003/10/30 01:58:18 simonb Exp $");
#include "opt_systrace.h"
@ -695,7 +695,7 @@ systrace_enter(struct proc *p, register_t code, void *v, register_t retval[])
struct str_policy *strpolicy;
struct fsystrace *fst;
struct pcred *pc;
int policy, error = 0, report = 0, maycontrol = 0, issuser = 0;
int policy, error = 0, maycontrol = 0, issuser = 0;
systrace_lock();
strp = p->p_systrace;
@ -772,7 +772,6 @@ systrace_enter(struct proc *p, register_t code, void *v, register_t retval[])
#ifndef __NetBSD__
CLR(strp->flags, STR_PROC_SYSCALLRES);
#endif
report = 1;
}
/* Replace the arguments if necessary */
if (strp->replace != NULL) {

View File

@ -1,4 +1,4 @@
/* $NetBSD: procfs_vnops.c,v 1.109 2003/09/27 13:29:02 darcy Exp $ */
/* $NetBSD: procfs_vnops.c,v 1.110 2003/10/30 01:58:18 simonb Exp $ */
/*
* Copyright (c) 1993, 1995
@ -76,7 +76,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: procfs_vnops.c,v 1.109 2003/09/27 13:29:02 darcy Exp $");
__KERNEL_RCSID(0, "$NetBSD: procfs_vnops.c,v 1.110 2003/10/30 01:58:18 simonb Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@ -1091,8 +1091,7 @@ procfs_readdir(v)
case PFSfd: {
struct proc *p;
struct filedesc *fdp;
struct file *fp;
int lim, last, nc = 0;
int lim, nc = 0;
p = PFIND(pfs->pfs_pid);
if (p == NULL)
@ -1101,7 +1100,6 @@ procfs_readdir(v)
fdp = p->p_fd;
lim = min((int)p->p_rlimit[RLIMIT_NOFILE].rlim_cur, maxfiles);
last = min(fdp->fd_nfiles, lim);
if (i >= lim)
return 0;
@ -1130,7 +1128,7 @@ procfs_readdir(v)
break;
}
for (; uio->uio_resid >= UIO_MX && i < fdp->fd_nfiles; i++) {
if ((fp = fd_getfile(fdp, i - 2)) == NULL)
if (fd_getfile(fdp, i - 2) == NULL)
continue;
d.d_fileno = PROCFS_FILENO(pfs->pfs_pid, PFSfd, i - 2);
d.d_namlen = snprintf(d.d_name, sizeof(d.d_name),