* SUCH DAMAGE.
*
* $FreeBSD: src/sys/boot/i386/libi386/biosdisk.c,v 1.45 2004/09/21 06:46:44 wes Exp $
- * $DragonFly: src/sys/boot/pc32/libi386/biosdisk.c,v 1.12 2007/06/18 05:13:42 dillon Exp $
*/
/*
if ((dptr->dp_typ == DOSPTYP_386BSD) && (dev->d_kind.biosdisk.partition < 0))
dev->d_kind.biosdisk.partition = 0;
- unsliced:
+unsliced:
/*
* Now we have the slice offset, look for the partition in the disklabel if we have
* a partition to start with.
ksnprintf(tmpstr2, sizeof(tmpstr2),
"bit %d",
sense->sense_key_spec[0] & 0x7);
- sbuf_printf(sb,
- ": %s byte %d %s is invalid",
- bad_command ?
- "Command" : "Data",
- scsi_2btoul(
- &sense->sense_key_spec[1]),
- tmpstr2);
+ sbuf_printf(sb, ": %s byte %d %s is invalid",
+ bad_command ? "Command" : "Data",
+ scsi_2btoul(&sense->sense_key_spec[1]),
+ tmpstr2);
break;
}
case SSD_KEY_RECOVERED_ERROR:
* SUCH DAMAGE.
*
* $FreeBSD: src/sys/dev/ppbus/ppb_base.c,v 1.10.2.1 2000/08/01 23:26:26 n_hibma Exp $
- * $DragonFly: src/sys/bus/ppbus/ppb_base.c,v 1.5 2003/08/07 21:16:47 dillon Exp $
- *
*/
+
#include <sys/param.h>
#include <sys/systm.h>
#include <sys/kernel.h>
if (PPBUS_SETMODE(device_get_parent(bus), mode))
return -1;
- /* XXX yet device mode = ppbus mode = chipset mode */
- ppb->mode = (mode & PPB_MASK);
+ /* XXX yet device mode = ppbus mode = chipset mode */
+ ppb->mode = (mode & PPB_MASK);
return (old_mode);
}
err = usbd_get_device_desc(dev, &dev->ddesc);
if (!err)
break;
- usbd_delay_ms(dev, 200);
+ usbd_delay_ms(dev, 200);
}
if (err)
return (err);
dev_rl = BUS_GET_RESOURCE_LIST(bus, dev);
bus_rl = BUS_GET_RESOURCE_LIST(device_get_parent(bus), bus);
if(bus_rl)
- kprintf("busrl is not null!\n");
- SLIST_FOREACH(dev_rle, dev_rl, link) {
+ kprintf("busrl is not null!\n");
+ SLIST_FOREACH(dev_rle, dev_rl, link) {
if (dev_rle->type != SYS_RES_IOPORT && dev_rle->type != SYS_RES_MEMORY)
continue;
* $Id: //depot/aic7xxx/aic7xxx/aic7xxx.c#155 $
*
* $FreeBSD: src/sys/dev/aic7xxx/aic7xxx.c,v 1.111 2007/04/19 18:53:52 scottl Exp $
- * $DragonFly: src/sys/dev/disk/aic7xxx/aic7xxx.c,v 1.29 2008/05/18 20:30:21 pavalos Exp $
*/
#include "aic7xxx_osm.h"
* At some speeds, we only support
* ST transfers.
*/
- if ((syncrate->sxfr_u2 & ST_SXFR) != 0)
+ if ((syncrate->sxfr_u2 & ST_SXFR) != 0)
*ppr_options &= ~MSG_EXT_PPR_DT_REQ;
break;
}
iscsi_lock_ex(&sp->io_mtx);
sp->flags |= ISC_OQNOTEMPTY;
if(sp->flags & ISC_OWAITING)
- wakeup(&sp->flags);
+ wakeup(&sp->flags);
iscsi_unlock_ex(&sp->io_mtx);
return error;
/* $FreeBSD: src/sys/dev/stg/tmc18c30.c,v 1.1.2.5 2001/12/17 13:30:19 non Exp $ */
-/* $DragonFly: src/sys/dev/disk/stg/tmc18c30.c,v 1.14 2007/01/06 08:33:34 dillon Exp $ */
/* $NecBSD: tmc18c30.c,v 1.28.12.3 2001/06/19 04:35:48 honda Exp $ */
/* $NetBSD$ */
if ((msg & SCSI_LOW_MSG_SYNCH) == 0)
return 0;
- period = ti->ti_maxsynch.period;
+ period = ti->ti_maxsynch.period;
offset = ti->ti_maxsynch.offset;
period = period << 2;
if (period >= 200)
x++;
if(x < 6)
- TRC(kprintf("Descrp %p, data pt %x, data %x, ",
- rxd, rxda, rxbuf));
+ TRC(kprintf("Descrp %p, data pt %x, data %x, ",
+ rxd, rxda, rxbuf));
rxd->bp = (u_short)(rxbuf & 0xfffful);
rxd->bpb = (u_char)((rxbuf >> 16) & 0xff);
* SUCH DAMAGE.
*
* $FreeBSD: src/sys/dev/cs/if_cs.c,v 1.19.2.1 2001/01/25 20:13:48 imp Exp $
- * $DragonFly: src/sys/dev/netif/cs/if_cs.c,v 1.30 2008/08/17 04:32:33 sephe Exp $
*/
/*
* Ignore empty parts
*/
if (!len)
- continue;
+ continue;
/*
* Find actual data address
ep_isa_match_id(u_int32_t id, struct isa_ident *isa_devs)
{
struct isa_ident * i = isa_devs;
+
while(i->name != NULL) {
- if (id == i->id)
- return (i->name);
- i++;
+ if (id == i->id)
+ return (i->name);
+ i++;
}
/*
* If we see a card that is likely to be a 3c509
/* check to see if there is a ccb for us to work with */
if ((csio = (struct ccb_scsiio *)amr_dequeue_ccb(sc)) == NULL)
- goto out;
+ goto out;
/* get bus/target, XXX validate against protected devices? */
bus = csio->ccb_h.sim_priv.entries[0].field;
/* Initialize the outbound FIFO */
if (sc->ha_Msgs != (PI2O_SCSI_ERROR_REPLY_MESSAGE_FRAME)NULL)
- for (size = sc->ha_Msgs_Count, addr = sc->ha_Msgs_Phys;
- size; --size) {
- sc->ha_Virt->FromFIFO = addr;
- addr += sizeof(I2O_SCSI_ERROR_REPLY_MESSAGE_FRAME);
- }
+ for (size = sc->ha_Msgs_Count, addr = sc->ha_Msgs_Phys;
+ size; --size) {
+ sc->ha_Virt->FromFIFO = addr;
+ addr +=
+ sizeof(I2O_SCSI_ERROR_REPLY_MESSAGE_FRAME);
+ }
return (*Reply_Ptr);
}
return (0);
if (mss->irq) {
if (mss->ih)
bus_teardown_intr(dev, mss->irq, mss->ih);
- bus_release_resource(dev, SYS_RES_IRQ, mss->irq_rid,
+ bus_release_resource(dev, SYS_RES_IRQ, mss->irq_rid,
mss->irq);
mss->irq = 0;
}
if (sb->irq) {
if (sb->ih)
bus_teardown_intr(dev, sb->irq, sb->ih);
- bus_release_resource(dev, SYS_RES_IRQ, 0, sb->irq);
+ bus_release_resource(dev, SYS_RES_IRQ, 0, sb->irq);
sb->irq = 0;
}
if (sb->drq2) {
if (sb->irq) {
if (sb->ih)
bus_teardown_intr(dev, sb->irq, sb->ih);
- bus_release_resource(dev, SYS_RES_IRQ, 0, sb->irq);
+ bus_release_resource(dev, SYS_RES_IRQ, 0, sb->irq);
sb->irq = 0;
}
if (sb->drq) {
/*
* Wait for a short while.
*/
- DELAY(25);
+ DELAY(25);
}
/*
#endif
envy24ht_wrcs(sc, ENVY24HT_CCS_GPIO_LDATA, data, 2);
if (sc->cfg->subdevice != 0x1150)
- envy24ht_wrcs(sc, ENVY24HT_CCS_GPIO_HDATA, data >> 16, 1);
+ envy24ht_wrcs(sc, ENVY24HT_CCS_GPIO_HDATA, data >> 16, 1);
return;
}
device_printf(sc->dev, "measured ac97 link rate at %d Hz", actual_48k_rate);
if (sc->ac97rate != actual_48k_rate)
kprintf(", will use %d Hz", sc->ac97rate);
- kprintf("\n");
+ kprintf("\n");
}
sc->flags |= ICH_CALIBRATE_DONE;
ICH_UNLOCK(sc);
if (bootverbose)
device_printf(sc->dev, "buftop is 0x%08x\n", sc->buftop);
- if ((nm_rdbuf(sc, ofs, 4) & NM_SIG_MASK) == NM_SIGNATURE) {
+ if ((nm_rdbuf(sc, ofs, 4) & NM_SIG_MASK) == NM_SIGNATURE) {
i = nm_rdbuf(sc, ofs + 4, 4);
if (i != 0 && i != 0xffffffff) {
if (bootverbose)
if (sc == NULL)
return (ENXIO);
- DPRINTFN(5, ("ugenopen: flag=%d, mode=%d, unit=%d endpt=%d\n",
+ DPRINTFN(5, ("ugenopen: flag=%d, mode=%d, unit=%d endpt=%d\n",
ap->a_oflags, ap->a_devtype, unit, endpt));
if (sc->sc_dying)
if (sc == NULL)
return (ENXIO);
- DPRINTFN(5, ("uscanneropen: flag=%d, mode=%d, unit=%d\n",
+ DPRINTFN(5, ("uscanneropen: flag=%d, mode=%d, unit=%d\n",
ap->a_oflags, ap->a_devtype, unit));
if (sc->sc_dying)
* decrement the link count on the parent
* of the target directory.
*/
- if (doingdirectory && !newparent) {
+ if (doingdirectory && !newparent) {
dp->i_nlink--;
dp->i_flag |= IN_CHANGE;
}
error = kern_sigtimedwait(set, &info, timeout);
if (error)
return (error);
- if (uap->info)
+ if (uap->info)
error = copyout(&info, uap->info, sizeof(info));
/* Repost if we got an error. */
/*
*
* @(#)kern_sysctl.c 8.4 (Berkeley) 4/14/94
* $FreeBSD: src/sys/kern/kern_sysctl.c,v 1.92.2.9 2003/05/01 22:48:09 trhodes Exp $
- * $DragonFly: src/sys/kern/kern_sysctl.c,v 1.30 2008/08/03 11:00:32 sephe Exp $
*/
#include <sys/param.h>
if (uap->namelen > CTL_MAXNAME || uap->namelen < 2)
return (EINVAL);
- error = copyin(uap->name, &name, uap->namelen * sizeof(int));
+ error = copyin(uap->name, &name, uap->namelen * sizeof(int));
if (error)
return (error);
*
* @(#)tty.c 8.8 (Berkeley) 1/21/94
* $FreeBSD: src/sys/kern/tty.c,v 1.129.2.5 2002/03/11 01:32:31 dd Exp $
- * $DragonFly: src/sys/kern/tty.c,v 1.46 2008/09/10 09:50:09 y0netan1 Exp $
*/
/*
*/
if (error)
break;
- if (uio->uio_resid == 0)
+ if (uio->uio_resid == 0)
break;
first = 0;
}
/*
* Give user character.
*/
- error = ureadc(c, uio);
+ error = ureadc(c, uio);
if (error)
/* XXX should ungetc(c, qp). */
break;
- if (uio->uio_resid == 0)
+ if (uio->uio_resid == 0)
break;
/*
* In canonical mode check for a "break character"
_PROP_ASSERT(obj);
if (po->po_type->pot_lock != NULL)
- po->po_type->pot_lock();
+ po->po_type->pot_lock();
/* Save pointerto unlock function */
unlock = po->po_type->pot_unlock;
(rpool->opts & PF_POOL_TYPEMASK) !=
PF_POOL_ROUNDROBIN)
return (1);
- raddr = &rpool->cur->addr.p.dyn->pfid_addr4;
- rmask = &rpool->cur->addr.p.dyn->pfid_mask4;
+ raddr = &rpool->cur->addr.p.dyn->pfid_addr4;
+ rmask = &rpool->cur->addr.p.dyn->pfid_mask4;
break;
#endif /* INET */
#ifdef INET6
nk->addr[pd->didx].v4.s_addr,
0);
- break;
+ break;
#endif /* INET */
#ifdef INET6
case AF_INET6:
* From: Version 2.4, Thu Apr 30 17:17:21 MSD 1997
*
* $FreeBSD: src/sys/net/if_spppsubr.c,v 1.59.2.13 2002/07/03 15:44:41 joerg Exp $
- * $DragonFly: src/sys/net/sppp/if_spppsubr.c,v 1.35 2008/06/09 11:24:24 sephe Exp $
*/
#include <sys/param.h>
log(LOG_DEBUG,
SPP_FMT "input packet is too small, %d bytes\n",
SPP_ARGS(ifp), m->m_pkthdr.len);
- drop:
+drop:
m_freem (m);
- drop2:
+drop2:
++ifp->if_ierrors;
++ifp->if_iqdrops;
return;
struct tuninfo *tunp;
switch (ap->a_cmd) {
- case TUNSIFINFO:
- tunp = (struct tuninfo *)ap->a_data;
+ case TUNSIFINFO:
+ tunp = (struct tuninfo *)ap->a_data;
if (tunp->mtu < IF_MINMTU)
return (EINVAL);
- tp->tun_if.if_mtu = tunp->mtu;
- tp->tun_if.if_type = tunp->type;
- tp->tun_if.if_baudrate = tunp->baudrate;
- break;
- case TUNGIFINFO:
- tunp = (struct tuninfo *)ap->a_data;
- tunp->mtu = tp->tun_if.if_mtu;
- tunp->type = tp->tun_if.if_type;
- tunp->baudrate = tp->tun_if.if_baudrate;
- break;
+ tp->tun_if.if_mtu = tunp->mtu;
+ tp->tun_if.if_type = tunp->type;
+ tp->tun_if.if_baudrate = tunp->baudrate;
+ break;
+ case TUNGIFINFO:
+ tunp = (struct tuninfo *)ap->a_data;
+ tunp->mtu = tp->tun_if.if_mtu;
+ tunp->type = tp->tun_if.if_type;
+ tunp->baudrate = tp->tun_if.if_baudrate;
+ break;
case TUNSDEBUG:
tundebug = *(int *)ap->a_data;
break;
M_NOWAIT);
if (stcb->asoc.pending_reply == NULL)
return; /* XXX */
- memcpy(stcb->asoc.pending_reply, resp, param_length);
+ memcpy(stcb->asoc.pending_reply, resp, param_length);
}
} else {
if (it == inp->inp_starting_point_for_iterator)
/* skip this guy, he's special */
continue;
- if (it->inp == inp) {
+ if (it->inp == inp) {
/* This is tricky and we DON'T lock the iterator.
* Reason is he's running but waiting for me since
* inp->inp_starting_point_for_iterator has the lock
if (bscopecmp < 0)
goto replace; /* (9) */
- replace:
+replace:
ifa_best = (struct in6_ifaddr *)ifa;
blen = tlen >= 0 ? tlen :
in6_matchlen(IFA_IN6(ifa), dst);
if (inp->in6p_options)
m_freem(inp->in6p_options);
- ip6_freepcbopts(inp->in6p_outputopts);
- ip6_freemoptions(inp->in6p_moptions);
+ ip6_freepcbopts(inp->in6p_outputopts);
+ ip6_freemoptions(inp->in6p_moptions);
if (inp->in6p_route.ro_rt)
rtfree(inp->in6p_route.ro_rt);
/* Check and free IPv4 related resources in case of mapped addr */
if (cmd != PRC_MSGSIZE)
arg = inet6ctlerrmap[cmd];
crit_enter();
- for (inp = LIST_FIRST(head); inp != NULL; inp = ninp) {
- ninp = LIST_NEXT(inp, inp_list);
+ for (inp = LIST_FIRST(head); inp != NULL; inp = ninp) {
+ ninp = LIST_NEXT(inp, inp_list);
if (inp->inp_flags & INP_PLACEMARKER)
continue;
- if ((inp->inp_vflag & INP_IPV6) == 0)
+ if ((inp->inp_vflag & INP_IPV6) == 0)
continue;
/*
* If the error designates a new path MTU for a destination