From 16f8b30fa2f3d2f1ecd56d95b1a3e3bc1fe3a4a0 Mon Sep 17 00:00:00 2001 From: oster Date: Mon, 7 Oct 2002 04:05:55 +0000 Subject: [PATCH] Minor comment and 80-column fixes. No functional changes. --- sys/dev/raidframe/rf_reconutil.c | 32 ++++++++++++++++++++------------ 1 file changed, 20 insertions(+), 12 deletions(-) diff --git a/sys/dev/raidframe/rf_reconutil.c b/sys/dev/raidframe/rf_reconutil.c index 20160ef3601d..19c53b6a80ca 100644 --- a/sys/dev/raidframe/rf_reconutil.c +++ b/sys/dev/raidframe/rf_reconutil.c @@ -1,4 +1,4 @@ -/* $NetBSD: rf_reconutil.c,v 1.10 2002/09/17 03:21:41 oster Exp $ */ +/* $NetBSD: rf_reconutil.c,v 1.11 2002/10/07 04:05:55 oster Exp $ */ /* * Copyright (c) 1995 Carnegie-Mellon University. * All rights reserved. @@ -31,7 +31,7 @@ ********************************************/ #include -__KERNEL_RCSID(0, "$NetBSD: rf_reconutil.c,v 1.10 2002/09/17 03:21:41 oster Exp $"); +__KERNEL_RCSID(0, "$NetBSD: rf_reconutil.c,v 1.11 2002/10/07 04:05:55 oster Exp $"); #include @@ -71,7 +71,10 @@ rf_MakeReconControl(reconDesc, frow, fcol, srow, scol) /* make and zero the global reconstruction structure and the per-disk * structure */ RF_Calloc(reconCtrlPtr, 1, sizeof(RF_ReconCtrl_t), (RF_ReconCtrl_t *)); - RF_Calloc(reconCtrlPtr->perDiskInfo, raidPtr->numCol, sizeof(RF_PerDiskReconCtrl_t), (RF_PerDiskReconCtrl_t *)); /* this zeros it */ + + /* note: this zeros the perDiskInfo */ + RF_Calloc(reconCtrlPtr->perDiskInfo, raidPtr->numCol, + sizeof(RF_PerDiskReconCtrl_t), (RF_PerDiskReconCtrl_t *)); reconCtrlPtr->reconDesc = reconDesc; reconCtrlPtr->fcol = fcol; reconCtrlPtr->spareRow = srow; @@ -84,9 +87,8 @@ rf_MakeReconControl(reconDesc, frow, fcol, srow, scol) reconCtrlPtr->perDiskInfo[i].reconCtrl = reconCtrlPtr; reconCtrlPtr->perDiskInfo[i].row = frow; reconCtrlPtr->perDiskInfo[i].col = i; - reconCtrlPtr->perDiskInfo[i].curPSID = -1; /* make it appear as if - * we just finished an - * RU */ + /* make it appear as if we just finished an RU */ + reconCtrlPtr->perDiskInfo[i].curPSID = -1; reconCtrlPtr->perDiskInfo[i].ru_count = RUsPerPU - 1; } @@ -145,7 +147,8 @@ rf_MakeReconControl(reconDesc, frow, fcol, srow, scol) reconCtrlPtr->floatingRbufs = NULL; reconCtrlPtr->committedRbufs = NULL; for (i = 0; i < raidPtr->numFloatingReconBufs; i++) { - rbuf = rf_MakeReconBuffer(raidPtr, frow, fcol, RF_RBUF_TYPE_FLOATING); + rbuf = rf_MakeReconBuffer(raidPtr, frow, fcol, + RF_RBUF_TYPE_FLOATING); rbuf->next = reconCtrlPtr->floatingRbufs; reconCtrlPtr->floatingRbufs = rbuf; } @@ -183,7 +186,8 @@ rf_FreeReconControl(raidPtr, row) rf_cond_destroy(&reconCtrlPtr->eq_cond); rf_FreeReconMap(reconCtrlPtr->reconMap); rf_FreeParityStripeStatusTable(raidPtr, reconCtrlPtr->pssTable); - RF_Free(reconCtrlPtr->perDiskInfo, raidPtr->numCol * sizeof(RF_PerDiskReconCtrl_t)); + RF_Free(reconCtrlPtr->perDiskInfo, + raidPtr->numCol * sizeof(RF_PerDiskReconCtrl_t)); RF_Free(reconCtrlPtr, sizeof(*reconCtrlPtr)); } @@ -312,19 +316,23 @@ rf_CheckFloatingRbufCount(raidPtr, dolock) RF_UNLOCK_MUTEX(pssTable[i].mutex); } - for (rbuf = raidPtr->reconControl[frow]->floatingRbufs; rbuf; rbuf = rbuf->next) { + for (rbuf = raidPtr->reconControl[frow]->floatingRbufs; rbuf; + rbuf = rbuf->next) { if (rbuf->type == RF_RBUF_TYPE_FLOATING) sum++; } - for (rbuf = raidPtr->reconControl[frow]->committedRbufs; rbuf; rbuf = rbuf->next) { + for (rbuf = raidPtr->reconControl[frow]->committedRbufs; rbuf; + rbuf = rbuf->next) { if (rbuf->type == RF_RBUF_TYPE_FLOATING) sum++; } - for (rbuf = raidPtr->reconControl[frow]->fullBufferList; rbuf; rbuf = rbuf->next) { + for (rbuf = raidPtr->reconControl[frow]->fullBufferList; rbuf; + rbuf = rbuf->next) { if (rbuf->type == RF_RBUF_TYPE_FLOATING) sum++; } - for (rbuf = raidPtr->reconControl[frow]->priorityList; rbuf; rbuf = rbuf->next) { + for (rbuf = raidPtr->reconControl[frow]->priorityList; rbuf; + rbuf = rbuf->next) { if (rbuf->type == RF_RBUF_TYPE_FLOATING) sum++; }