fix empty if

This commit is contained in:
christos 2006-10-04 15:53:24 +00:00
parent 1f689bbab1
commit b64edcaded
9 changed files with 55 additions and 40 deletions

View File

@ -1,4 +1,4 @@
/* $NetBSD: mb89352.c,v 1.42 2006/09/02 09:26:47 xtraeme Exp $ */
/* $NetBSD: mb89352.c,v 1.43 2006/10/04 15:57:45 christos Exp $ */
/* NecBSD: mb89352.c,v 1.4 1998/03/14 07:31:20 kmatsuda Exp */
/*-
@ -70,7 +70,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: mb89352.c,v 1.42 2006/09/02 09:26:47 xtraeme Exp $");
__KERNEL_RCSID(0, "$NetBSD: mb89352.c,v 1.43 2006/10/04 15:57:45 christos Exp $");
#ifdef DDB
#define integrate
@ -812,10 +812,11 @@ spc_sched(struct spc_softc *sc)
sc->sc_nexus = acb;
spc_select(sc, acb);
return;
} else
} else {
SPC_MISC(("%d:%d busy\n",
periph->periph_target, periph->periph_lun));
}
}
SPC_MISC(("idle "));
/* Nothing to start; just enable reselections and wait. */
}

View File

@ -1,4 +1,4 @@
/* $NetBSD: ncr53c9x.c,v 1.120 2006/06/07 22:33:36 kardel Exp $ */
/* $NetBSD: ncr53c9x.c,v 1.121 2006/10/04 15:59:08 christos Exp $ */
/*-
* Copyright (c) 1998, 2002 The NetBSD Foundation, Inc.
@ -77,7 +77,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: ncr53c9x.c,v 1.120 2006/06/07 22:33:36 kardel Exp $");
__KERNEL_RCSID(0, "$NetBSD: ncr53c9x.c,v 1.121 2006/10/04 15:59:08 christos Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@ -1147,11 +1147,12 @@ ncr53c9x_sched(sc)
sc->sc_nexus = ecb;
ncr53c9x_select(sc, ecb);
break;
} else
} else {
NCR_TRACE(("%d:%d busy\n",
periph->periph_target,
periph->periph_lun));
}
}
}
void

View File

@ -1,4 +1,4 @@
/* $NetBSD: uaudio.c,v 1.104 2006/09/03 07:07:20 christos Exp $ */
/* $NetBSD: uaudio.c,v 1.105 2006/10/04 16:00:15 christos Exp $ */
/*
* Copyright (c) 1999 The NetBSD Foundation, Inc.
@ -44,7 +44,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: uaudio.c,v 1.104 2006/09/03 07:07:20 christos Exp $");
__KERNEL_RCSID(0, "$NetBSD: uaudio.c,v 1.105 2006/10/04 16:00:15 christos Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@ -2617,10 +2617,11 @@ uaudio_chan_open(struct uaudio_softc *sc, struct chan *ch)
*/
if (as->asf1desc->bSamFreqType != 1) {
err = uaudio_set_speed(sc, endpt, ch->sample_rate);
if (err)
if (err) {
DPRINTF(("uaudio_chan_open: set_speed failed err=%s\n",
usbd_errstr(err)));
}
}
ch->pipe = 0;
ch->sync_pipe = 0;

View File

@ -1,4 +1,4 @@
/* $NetBSD: ucycom.c,v 1.13 2006/10/01 20:31:51 elad Exp $ */
/* $NetBSD: ucycom.c,v 1.14 2006/10/04 16:01:23 christos Exp $ */
/*
* Copyright (c) 2005 The NetBSD Foundation, Inc.
@ -45,7 +45,7 @@
*/
#include <sys/cdefs.h>
__RCSID("$NetBSD: ucycom.c,v 1.13 2006/10/01 20:31:51 elad Exp $");
__RCSID("$NetBSD: ucycom.c,v 1.14 2006/10/04 16:01:23 christos Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@ -567,8 +567,9 @@ ucycomstart(struct tty *tp)
#endif
err = uhidev_write(sc->sc_hdev.sc_parent, sc->sc_obuf, sc->sc_olen);
if (err)
if (err) {
DPRINTF(("ucycomstart: error doing uhidev_write = %d\n", err));
}
#ifdef UCYCOM_DEBUG
ucycom_get_cfg(sc);
@ -1029,8 +1030,9 @@ ucycom_set_status(struct ucycom_softc *sc)
sc->sc_obuf[0] = sc->sc_mcr;
err = uhidev_write(sc->sc_hdev.sc_parent, sc->sc_obuf, sc->sc_olen);
if (err)
if (err) {
DPRINTF(("ucycom_set_status: err=%d\n", err));
}
}
#ifdef UCYCOM_DEBUG

View File

@ -1,4 +1,4 @@
/* $NetBSD: usb_subr.c,v 1.135 2006/06/11 16:00:08 christos Exp $ */
/* $NetBSD: usb_subr.c,v 1.136 2006/10/04 16:02:06 christos Exp $ */
/* $FreeBSD: src/sys/dev/usb/usb_subr.c,v 1.18 1999/11/17 22:33:47 n_hibma Exp $ */
/*
@ -39,7 +39,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: usb_subr.c,v 1.135 2006/06/11 16:00:08 christos Exp $");
__KERNEL_RCSID(0, "$NetBSD: usb_subr.c,v 1.136 2006/10/04 16:02:06 christos Exp $");
#include "opt_usbverbose.h"
@ -591,9 +591,10 @@ usbd_set_config_index(usbd_device_handle dev, int index, int msg)
/* We are unconfiguring the device, so leave unallocated. */
DPRINTF(("usbd_set_config_index: set config 0\n"));
err = usbd_set_config(dev, USB_UNCONFIG_NO);
if (err)
if (err) {
DPRINTF(("usbd_set_config_index: setting config=0 "
"failed, error=%s\n", usbd_errstr(err)));
}
return (err);
}

View File

@ -1,4 +1,4 @@
/* $NetBSD: lfs_bio.c,v 1.95 2006/09/15 15:51:12 yamt Exp $ */
/* $NetBSD: lfs_bio.c,v 1.96 2006/10/04 15:53:24 christos Exp $ */
/*-
* Copyright (c) 1999, 2000, 2001, 2002, 2003 The NetBSD Foundation, Inc.
@ -67,7 +67,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: lfs_bio.c,v 1.95 2006/09/15 15:51:12 yamt Exp $");
__KERNEL_RCSID(0, "$NetBSD: lfs_bio.c,v 1.96 2006/10/04 15:53:24 christos Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@ -832,12 +832,14 @@ lfs_countlocked(int *count, long *bytes, const char *msg)
* Theoretically this function never really does anything.
* Give a warning if we have to fix the accounting.
*/
if (n != *count)
if (n != *count) {
DLOG((DLOG_LLIST, "lfs_countlocked: %s: adjusted buf count"
" from %d to %d\n", msg, *count, n));
if (size != *bytes)
}
if (size != *bytes) {
DLOG((DLOG_LLIST, "lfs_countlocked: %s: adjusted byte count"
" from %ld to %ld\n", msg, *bytes, size));
}
*count = n;
*bytes = size;
simple_unlock(&bqueue_slock);

View File

@ -1,4 +1,4 @@
/* $NetBSD: lfs_segment.c,v 1.191 2006/09/28 23:08:23 perseant Exp $ */
/* $NetBSD: lfs_segment.c,v 1.192 2006/10/04 15:54:43 christos Exp $ */
/*-
* Copyright (c) 1999, 2000, 2001, 2002, 2003 The NetBSD Foundation, Inc.
@ -67,7 +67,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: lfs_segment.c,v 1.191 2006/09/28 23:08:23 perseant Exp $");
__KERNEL_RCSID(0, "$NetBSD: lfs_segment.c,v 1.192 2006/10/04 15:54:43 christos Exp $");
#ifdef DEBUG
# define vndebug(vp, str) do { \
@ -1243,10 +1243,11 @@ lfs_writeinode(struct lfs *fs, struct segment *sp, struct inode *ip)
IN_UPDATE | IN_MODIFY);
if (ip->i_lfs_effnblks == ip->i_ffs1_blocks)
LFS_CLR_UINO(ip, IN_MODIFIED);
else
DLOG((DLOG_VNODE, "lfs_writeinode: ino %d: real blks=%d, "
"eff=%d\n", ip->i_number, ip->i_ffs1_blocks,
ip->i_lfs_effnblks));
else {
DLOG((DLOG_VNODE, "lfs_writeinode: ino %d: real "
"blks=%d, eff=%d\n", ip->i_number,
ip->i_ffs1_blocks, ip->i_lfs_effnblks));
}
}
if (ip->i_number == LFS_IFILE_INUM) {

View File

@ -1,4 +1,4 @@
/* $NetBSD: lfs_subr.c,v 1.62 2006/09/15 18:50:49 perseant Exp $ */
/* $NetBSD: lfs_subr.c,v 1.63 2006/10/04 15:55:27 christos Exp $ */
/*-
* Copyright (c) 1999, 2000, 2001, 2002, 2003 The NetBSD Foundation, Inc.
@ -67,7 +67,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: lfs_subr.c,v 1.62 2006/09/15 18:50:49 perseant Exp $");
__KERNEL_RCSID(0, "$NetBSD: lfs_subr.c,v 1.63 2006/10/04 15:55:27 christos Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@ -495,8 +495,9 @@ lfs_segunlock(struct lfs *fs)
* sleep.
*/
simple_lock(&fs->lfs_interlock);
if (--fs->lfs_iocount == 0)
if (--fs->lfs_iocount == 0) {
LFS_DEBUG_COUNTLOCKED("lfs_segunlock");
}
if (fs->lfs_iocount <= 1)
wakeup(&fs->lfs_iocount);
simple_unlock(&fs->lfs_interlock);

View File

@ -1,4 +1,4 @@
/* $NetBSD: lfs_vfsops.c,v 1.221 2006/09/28 23:08:23 perseant Exp $ */
/* $NetBSD: lfs_vfsops.c,v 1.222 2006/10/04 15:56:46 christos Exp $ */
/*-
* Copyright (c) 1999, 2000, 2001, 2002, 2003 The NetBSD Foundation, Inc.
@ -67,7 +67,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: lfs_vfsops.c,v 1.221 2006/09/28 23:08:23 perseant Exp $");
__KERNEL_RCSID(0, "$NetBSD: lfs_vfsops.c,v 1.222 2006/10/04 15:56:46 christos Exp $");
#if defined(_KERNEL_OPT)
#include "opt_quota.h"
@ -254,17 +254,21 @@ lfs_writerd(void *arg)
locked_queue_bytes > LFS_MAX_BYTES ||
lfs_subsys_pages > LFS_MAX_PAGES) {
if (lfs_do_flush)
if (lfs_do_flush) {
DLOG((DLOG_FLUSH, "daemon: lfs_do_flush\n"));
if (locked_queue_count > LFS_MAX_BUFS)
}
if (locked_queue_count > LFS_MAX_BUFS) {
DLOG((DLOG_FLUSH, "daemon: lqc = %d, max %d\n",
locked_queue_count, LFS_MAX_BUFS));
if (locked_queue_bytes > LFS_MAX_BYTES)
}
if (locked_queue_bytes > LFS_MAX_BYTES) {
DLOG((DLOG_FLUSH, "daemon: lqb = %ld, max %ld\n",
locked_queue_bytes, LFS_MAX_BYTES));
if (lfs_subsys_pages > LFS_MAX_PAGES)
}
if (lfs_subsys_pages > LFS_MAX_PAGES) {
DLOG((DLOG_FLUSH, "daemon: lssp = %d, max %d\n",
lfs_subsys_pages, LFS_MAX_PAGES));
}
lfs_flush(NULL, SEGM_WRITERD, 0);
lfs_do_flush = 0;
@ -1754,18 +1758,19 @@ lfs_gop_write(struct vnode *vp, struct vm_page **pgs, int npages, int flags)
simple_lock(&vp->v_interlock);
/* Tell why we're here, if we know */
if (ip->i_lfs_iflags & LFSI_NO_GOP_WRITE)
if (ip->i_lfs_iflags & LFSI_NO_GOP_WRITE) {
DLOG((DLOG_PAGE, "lfs_gop_write: clean pages dirtied\n"));
else if ((pgs[0]->offset & fs->lfs_bmask) != 0)
} else if ((pgs[0]->offset & fs->lfs_bmask) != 0) {
DLOG((DLOG_PAGE, "lfs_gop_write: not on block boundary\n"));
else if (haveeof && startoffset >= eof)
} else if (haveeof && startoffset >= eof) {
DLOG((DLOG_PAGE, "lfs_gop_write: ino %d start 0x%" PRIx64
" eof 0x%" PRIx64 " npages=%d\n", VTOI(vp)->i_number,
pgs[0]->offset, eof, npages));
else if (LFS_STARVED_FOR_SEGS(fs))
} else if (LFS_STARVED_FOR_SEGS(fs)) {
DLOG((DLOG_PAGE, "lfs_gop_write: avail too low\n"));
else
} else {
DLOG((DLOG_PAGE, "lfs_gop_write: seglock not held\n"));
}
uvm_lock_pageq();
for (i = 0; i < npages; i++) {