summaryrefslogtreecommitdiff
path: root/sys/dev/raidframe
diff options
context:
space:
mode:
Diffstat (limited to 'sys/dev/raidframe')
-rw-r--r--sys/dev/raidframe/rf_aselect.c8
-rw-r--r--sys/dev/raidframe/rf_dagfuncs.c12
-rw-r--r--sys/dev/raidframe/rf_dagutils.c6
-rw-r--r--sys/dev/raidframe/rf_decluster.c6
-rw-r--r--sys/dev/raidframe/rf_desc.h4
-rw-r--r--sys/dev/raidframe/rf_diskqueue.c6
-rw-r--r--sys/dev/raidframe/rf_diskqueue.h6
-rw-r--r--sys/dev/raidframe/rf_driver.c12
-rw-r--r--sys/dev/raidframe/rf_driver.h6
-rw-r--r--sys/dev/raidframe/rf_evenodd_dagfuncs.c16
-rw-r--r--sys/dev/raidframe/rf_layout.h4
-rw-r--r--sys/dev/raidframe/rf_map.c8
-rw-r--r--sys/dev/raidframe/rf_map.h4
-rw-r--r--sys/dev/raidframe/rf_netbsdkintf.c12
-rw-r--r--sys/dev/raidframe/rf_paritylog.c8
-rw-r--r--sys/dev/raidframe/rf_paritylog.h10
-rw-r--r--sys/dev/raidframe/rf_paritylogDiskMgr.c20
-rw-r--r--sys/dev/raidframe/rf_paritylogging.c32
-rw-r--r--sys/dev/raidframe/rf_raid.h4
-rw-r--r--sys/dev/raidframe/rf_raid1.c11
-rw-r--r--sys/dev/raidframe/rf_reconbuffer.c6
-rw-r--r--sys/dev/raidframe/rf_reconstruct.h6
-rw-r--r--sys/dev/raidframe/rf_reconutil.c6
23 files changed, 106 insertions, 107 deletions
diff --git a/sys/dev/raidframe/rf_aselect.c b/sys/dev/raidframe/rf_aselect.c
index 4c796feefa3..4bb55c813b1 100644
--- a/sys/dev/raidframe/rf_aselect.c
+++ b/sys/dev/raidframe/rf_aselect.c
@@ -1,4 +1,4 @@
-/* $NetBSD: rf_aselect.c,v 1.24 2006/03/23 03:43:54 oster Exp $ */
+/* $NetBSD: rf_aselect.c,v 1.25 2007/03/04 06:02:36 christos Exp $ */
/*
* Copyright (c) 1995 Carnegie-Mellon University.
* All rights reserved.
@@ -33,7 +33,7 @@
*****************************************************************************/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: rf_aselect.c,v 1.24 2006/03/23 03:43:54 oster Exp $");
+__KERNEL_RCSID(0, "$NetBSD: rf_aselect.c,v 1.25 2007/03/04 06:02:36 christos Exp $");
#include <dev/raidframe/raidframevar.h>
@@ -137,7 +137,7 @@ rf_SelectAlgorithm(RF_RaidAccessDesc_t *desc, RF_RaidAccessFlags_t flags)
RF_RaidAddr_t address;
int length;
RF_PhysDiskAddr_t *physPtr;
- caddr_t buffer;
+ void *buffer;
lastdag_h = NULL;
asmh_u = asmh_b = NULL;
@@ -240,7 +240,7 @@ rf_SelectAlgorithm(RF_RaidAccessDesc_t *desc, RF_RaidAccessFlags_t flags)
* stripe-unit accesses */
address = physPtr->raidAddress + k;
length = 1;
- buffer = physPtr->bufPtr + (k * (1 << raidPtr->logBytesPerSector));
+ buffer = (char *)physPtr->bufPtr + (k * (1 << raidPtr->logBytesPerSector));
asmhle = rf_AllocASMHeaderListElem();
if (failed_stripe->asmh_b == NULL) {
diff --git a/sys/dev/raidframe/rf_dagfuncs.c b/sys/dev/raidframe/rf_dagfuncs.c
index 932de74fc24..bcc4831564a 100644
--- a/sys/dev/raidframe/rf_dagfuncs.c
+++ b/sys/dev/raidframe/rf_dagfuncs.c
@@ -1,4 +1,4 @@
-/* $NetBSD: rf_dagfuncs.c,v 1.28 2006/11/16 01:33:23 christos Exp $ */
+/* $NetBSD: rf_dagfuncs.c,v 1.29 2007/03/04 06:02:36 christos Exp $ */
/*
* Copyright (c) 1995 Carnegie-Mellon University.
* All rights reserved.
@@ -48,7 +48,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: rf_dagfuncs.c,v 1.28 2006/11/16 01:33:23 christos Exp $");
+__KERNEL_RCSID(0, "$NetBSD: rf_dagfuncs.c,v 1.29 2007/03/04 06:02:36 christos Exp $");
#include <sys/param.h>
#include <sys/ioctl.h>
@@ -168,7 +168,7 @@ int
rf_ParityLogUpdateFunc(RF_DagNode_t *node)
{
RF_PhysDiskAddr_t *pda = (RF_PhysDiskAddr_t *) node->params[0].p;
- caddr_t bf = (caddr_t) node->params[1].p;
+ void *bf = (void *) node->params[1].p;
RF_ParityLogData_t *logData;
#if RF_ACC_TRACE > 0
RF_AccTraceEntry_t *tracerec = node->dagHdr->tracerec;
@@ -205,7 +205,7 @@ int
rf_ParityLogOverwriteFunc(RF_DagNode_t *node)
{
RF_PhysDiskAddr_t *pda = (RF_PhysDiskAddr_t *) node->params[0].p;
- caddr_t bf = (caddr_t) node->params[1].p;
+ void *bf = (void *) node->params[1].p;
RF_ParityLogData_t *logData;
#if RF_ACC_TRACE > 0
RF_AccTraceEntry_t *tracerec = node->dagHdr->tracerec;
@@ -272,7 +272,7 @@ rf_DiskReadFuncForThreads(RF_DagNode_t *node)
{
RF_DiskQueueData_t *req;
RF_PhysDiskAddr_t *pda = (RF_PhysDiskAddr_t *) node->params[0].p;
- caddr_t bf = (caddr_t) node->params[1].p;
+ void *bf = (void *) node->params[1].p;
RF_StripeNum_t parityStripeID = (RF_StripeNum_t) node->params[2].v;
unsigned priority = RF_EXTRACT_PRIORITY(node->params[3].v);
unsigned which_ru = RF_EXTRACT_RU(node->params[3].v);
@@ -311,7 +311,7 @@ rf_DiskWriteFuncForThreads(RF_DagNode_t *node)
{
RF_DiskQueueData_t *req;
RF_PhysDiskAddr_t *pda = (RF_PhysDiskAddr_t *) node->params[0].p;
- caddr_t bf = (caddr_t) node->params[1].p;
+ void *bf = (void *) node->params[1].p;
RF_StripeNum_t parityStripeID = (RF_StripeNum_t) node->params[2].v;
unsigned priority = RF_EXTRACT_PRIORITY(node->params[3].v);
unsigned which_ru = RF_EXTRACT_RU(node->params[3].v);
diff --git a/sys/dev/raidframe/rf_dagutils.c b/sys/dev/raidframe/rf_dagutils.c
index dfc3ca27567..63ea955f207 100644
--- a/sys/dev/raidframe/rf_dagutils.c
+++ b/sys/dev/raidframe/rf_dagutils.c
@@ -1,4 +1,4 @@
-/* $NetBSD: rf_dagutils.c,v 1.50 2006/11/16 01:33:23 christos Exp $ */
+/* $NetBSD: rf_dagutils.c,v 1.51 2007/03/04 06:02:36 christos Exp $ */
/*
* Copyright (c) 1995 Carnegie-Mellon University.
* All rights reserved.
@@ -33,7 +33,7 @@
*****************************************************************************/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: rf_dagutils.c,v 1.50 2006/11/16 01:33:23 christos Exp $");
+__KERNEL_RCSID(0, "$NetBSD: rf_dagutils.c,v 1.51 2007/03/04 06:02:36 christos Exp $");
#include <dev/raidframe/raidframevar.h>
@@ -1214,7 +1214,7 @@ rf_RangeRestrictPDA(RF_Raid_t *raidPtr, RF_PhysDiskAddr_t *src,
dest->numSector = subAddr + RF_MIN(send, dend) + 1 - dest->startSector;
if (dobuffer)
- dest->bufPtr += (soffs > doffs) ? rf_RaidAddressToByte(raidPtr, soffs - doffs) : 0;
+ dest->bufPtr = (char *)(dest->bufPtr) + ((soffs > doffs) ? rf_RaidAddressToByte(raidPtr, soffs - doffs) : 0);
if (doraidaddr) {
dest->raidAddress = rf_RaidAddressOfPrevStripeUnitBoundary(layoutPtr, dest->raidAddress) +
rf_StripeUnitOffset(layoutPtr, dest->startSector);
diff --git a/sys/dev/raidframe/rf_decluster.c b/sys/dev/raidframe/rf_decluster.c
index 4117736b8b8..761b595baa7 100644
--- a/sys/dev/raidframe/rf_decluster.c
+++ b/sys/dev/raidframe/rf_decluster.c
@@ -1,4 +1,4 @@
-/* $NetBSD: rf_decluster.c,v 1.21 2006/11/16 01:33:23 christos Exp $ */
+/* $NetBSD: rf_decluster.c,v 1.22 2007/03/04 06:02:36 christos Exp $ */
/*
* Copyright (c) 1995 Carnegie-Mellon University.
* All rights reserved.
@@ -48,7 +48,7 @@
*--------------------------------------------------------------------*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: rf_decluster.c,v 1.21 2006/11/16 01:33:23 christos Exp $");
+__KERNEL_RCSID(0, "$NetBSD: rf_decluster.c,v 1.22 2007/03/04 06:02:36 christos Exp $");
#include <dev/raidframe/raidframevar.h>
@@ -649,7 +649,7 @@ rf_SetSpareTable(RF_Raid_t *raidPtr, void *data)
/* what we need to copyin is a 2-d array, so first copyin the user
* pointers to the rows in the table */
RF_Malloc(ptrs, info->TablesPerSpareRegion * sizeof(RF_SpareTableEntry_t *), (RF_SpareTableEntry_t **));
- retcode = copyin((caddr_t) data, (caddr_t) ptrs, info->TablesPerSpareRegion * sizeof(RF_SpareTableEntry_t *));
+ retcode = copyin((void *) data, (void *) ptrs, info->TablesPerSpareRegion * sizeof(RF_SpareTableEntry_t *));
if (retcode)
return (retcode);
diff --git a/sys/dev/raidframe/rf_desc.h b/sys/dev/raidframe/rf_desc.h
index c2c35e9d644..141a09305a7 100644
--- a/sys/dev/raidframe/rf_desc.h
+++ b/sys/dev/raidframe/rf_desc.h
@@ -1,4 +1,4 @@
-/* $NetBSD: rf_desc.h,v 1.19 2005/12/11 12:23:37 christos Exp $ */
+/* $NetBSD: rf_desc.h,v 1.20 2007/03/04 06:02:36 christos Exp $ */
/*
* Copyright (c) 1995 Carnegie-Mellon University.
* All rights reserved.
@@ -70,7 +70,7 @@ struct RF_RaidAccessDesc_s {
* transfer */
RF_StripeCount_t numStripes; /* number of stripes involved in
* access */
- caddr_t bufPtr; /* pointer to data buffer */
+ void *bufPtr; /* pointer to data buffer */
RF_RaidAccessFlags_t flags; /* flags controlling operation */
int state; /* index into states telling how far along the
* RAID operation has gotten */
diff --git a/sys/dev/raidframe/rf_diskqueue.c b/sys/dev/raidframe/rf_diskqueue.c
index f779fa45d0b..3a7a7cb16f2 100644
--- a/sys/dev/raidframe/rf_diskqueue.c
+++ b/sys/dev/raidframe/rf_diskqueue.c
@@ -1,4 +1,4 @@
-/* $NetBSD: rf_diskqueue.c,v 1.48 2006/11/16 01:33:23 christos Exp $ */
+/* $NetBSD: rf_diskqueue.c,v 1.49 2007/03/04 06:02:37 christos Exp $ */
/*
* Copyright (c) 1995 Carnegie-Mellon University.
* All rights reserved.
@@ -66,7 +66,7 @@
****************************************************************************/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: rf_diskqueue.c,v 1.48 2006/11/16 01:33:23 christos Exp $");
+__KERNEL_RCSID(0, "$NetBSD: rf_diskqueue.c,v 1.49 2007/03/04 06:02:37 christos Exp $");
#include <dev/raidframe/raidframevar.h>
@@ -440,7 +440,7 @@ rf_DiskIOPromote(RF_DiskQueue_t *queue, RF_StripeNum_t parityStripeID,
RF_DiskQueueData_t *
rf_CreateDiskQueueData(RF_IoType_t typ, RF_SectorNum_t ssect,
- RF_SectorCount_t nsect, caddr_t bf,
+ RF_SectorCount_t nsect, void *bf,
RF_StripeNum_t parityStripeID,
RF_ReconUnitNum_t which_ru,
int (*wakeF) (void *, int), void *arg,
diff --git a/sys/dev/raidframe/rf_diskqueue.h b/sys/dev/raidframe/rf_diskqueue.h
index cef1e8ef889..5e6c95ec7e8 100644
--- a/sys/dev/raidframe/rf_diskqueue.h
+++ b/sys/dev/raidframe/rf_diskqueue.h
@@ -1,4 +1,4 @@
-/* $NetBSD: rf_diskqueue.h,v 1.21 2005/12/11 12:23:37 christos Exp $ */
+/* $NetBSD: rf_diskqueue.h,v 1.22 2007/03/04 06:02:37 christos Exp $ */
/*
* Copyright (c) 1995 Carnegie-Mellon University.
* All rights reserved.
@@ -57,7 +57,7 @@ struct RF_DiskQueueData_s {
RF_SectorNum_t sectorOffset; /* sector offset into the disk */
RF_SectorCount_t numSector; /* number of sectors to read/write */
RF_IoType_t type; /* read/write/nop */
- caddr_t buf; /* buffer pointer */
+ void *buf; /* buffer pointer */
RF_StripeNum_t parityStripeID; /* the RAID parity stripe ID this
* access is for */
RF_ReconUnitNum_t which_ru; /* which RU within this parity stripe */
@@ -154,7 +154,7 @@ void rf_DiskIOEnqueue(RF_DiskQueue_t *, RF_DiskQueueData_t *, int);
void rf_DiskIOComplete(RF_DiskQueue_t *, RF_DiskQueueData_t *, int);
int rf_DiskIOPromote(RF_DiskQueue_t *, RF_StripeNum_t, RF_ReconUnitNum_t);
RF_DiskQueueData_t *rf_CreateDiskQueueData(RF_IoType_t, RF_SectorNum_t,
- RF_SectorCount_t , caddr_t,
+ RF_SectorCount_t , void *,
RF_StripeNum_t, RF_ReconUnitNum_t,
int (*wakeF) (void *, int),
void *,
diff --git a/sys/dev/raidframe/rf_driver.c b/sys/dev/raidframe/rf_driver.c
index b89569b741e..5706530d4ab 100644
--- a/sys/dev/raidframe/rf_driver.c
+++ b/sys/dev/raidframe/rf_driver.c
@@ -1,4 +1,4 @@
-/* $NetBSD: rf_driver.c,v 1.113 2006/11/16 01:33:23 christos Exp $ */
+/* $NetBSD: rf_driver.c,v 1.114 2007/03/04 06:02:37 christos Exp $ */
/*-
* Copyright (c) 1999 The NetBSD Foundation, Inc.
* All rights reserved.
@@ -73,7 +73,7 @@
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: rf_driver.c,v 1.113 2006/11/16 01:33:23 christos Exp $");
+__KERNEL_RCSID(0, "$NetBSD: rf_driver.c,v 1.114 2007/03/04 06:02:37 christos Exp $");
#include "opt_raid_diagnostic.h"
@@ -541,7 +541,7 @@ rf_ConfigureRDFreeList(RF_ShutdownList_t **listp)
RF_RaidAccessDesc_t *
rf_AllocRaidAccDesc(RF_Raid_t *raidPtr, RF_IoType_t type,
RF_RaidAddr_t raidAddress, RF_SectorCount_t numBlocks,
- caddr_t bufPtr, void *bp, RF_RaidAccessFlags_t flags,
+ void *bufPtr, void *bp, RF_RaidAccessFlags_t flags,
const RF_AccessState_t *states)
{
RF_RaidAccessDesc_t *desc;
@@ -632,16 +632,16 @@ rf_FreeRaidAccDesc(RF_RaidAccessDesc_t *desc)
* failures in a parity group.
*
* type should be read or write async_flag should be RF_TRUE or
- * RF_FALSE bp_in is a buf pointer. void * to facilitate ignoring it
+ * RF_FALSE bp_in is a buf pointer. void *to facilitate ignoring it
* outside the kernel
********************************************************************/
int
rf_DoAccess(RF_Raid_t * raidPtr, RF_IoType_t type, int async_flag,
RF_RaidAddr_t raidAddress, RF_SectorCount_t numBlocks,
- caddr_t bufPtr, struct buf *bp, RF_RaidAccessFlags_t flags)
+ void *bufPtr, struct buf *bp, RF_RaidAccessFlags_t flags)
{
RF_RaidAccessDesc_t *desc;
- caddr_t lbufPtr = bufPtr;
+ void *lbufPtr = bufPtr;
raidAddress += rf_raidSectorOffset;
diff --git a/sys/dev/raidframe/rf_driver.h b/sys/dev/raidframe/rf_driver.h
index 1b0580d5ab3..d3aed547809 100644
--- a/sys/dev/raidframe/rf_driver.h
+++ b/sys/dev/raidframe/rf_driver.h
@@ -1,4 +1,4 @@
-/* $NetBSD: rf_driver.h,v 1.16 2005/12/11 12:23:37 christos Exp $ */
+/* $NetBSD: rf_driver.h,v 1.17 2007/03/04 06:02:38 christos Exp $ */
/*
* rf_driver.h
*/
@@ -48,12 +48,12 @@ int rf_Shutdown(RF_Raid_t *);
int rf_Configure(RF_Raid_t *, RF_Config_t *, RF_AutoConfig_t *);
RF_RaidAccessDesc_t *rf_AllocRaidAccDesc(RF_Raid_t *, RF_IoType_t,
RF_RaidAddr_t, RF_SectorCount_t,
- caddr_t, void *,
+ void *, void *,
RF_RaidAccessFlags_t,
const RF_AccessState_t *);
void rf_FreeRaidAccDesc(RF_RaidAccessDesc_t *);
int rf_DoAccess(RF_Raid_t *, RF_IoType_t, int, RF_RaidAddr_t,
- RF_SectorCount_t, caddr_t, struct buf *,
+ RF_SectorCount_t, void *, struct buf *,
RF_RaidAccessFlags_t);
#if 0
int rf_SetReconfiguredMode(RF_Raid_t *, RF_RowCol_t, RF_RowCol_t);
diff --git a/sys/dev/raidframe/rf_evenodd_dagfuncs.c b/sys/dev/raidframe/rf_evenodd_dagfuncs.c
index 03dc01d1e1a..1eebddb2b84 100644
--- a/sys/dev/raidframe/rf_evenodd_dagfuncs.c
+++ b/sys/dev/raidframe/rf_evenodd_dagfuncs.c
@@ -1,4 +1,4 @@
-/* $NetBSD: rf_evenodd_dagfuncs.c,v 1.17 2006/08/28 02:58:16 christos Exp $ */
+/* $NetBSD: rf_evenodd_dagfuncs.c,v 1.18 2007/03/04 06:02:38 christos Exp $ */
/*
* Copyright (c) 1995 Carnegie-Mellon University.
* All rights reserved.
@@ -31,7 +31,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: rf_evenodd_dagfuncs.c,v 1.17 2006/08/28 02:58:16 christos Exp $");
+__KERNEL_RCSID(0, "$NetBSD: rf_evenodd_dagfuncs.c,v 1.18 2007/03/04 06:02:38 christos Exp $");
#include "rf_archs.h"
#include "opt_raid_diagnostic.h"
@@ -786,7 +786,7 @@ rf_EvenOddDoubleRecoveryFunc(node)
continue;
for (prm = 0; prm < ndataParam; prm++)
if (suoff[prm] <= sector && sector < suend[prm])
- buf[(prmToCol[prm])] = ((RF_PhysDiskAddr_t *) node->params[prm].p)->bufPtr +
+ buf[(prmToCol[prm])] = (char *)((RF_PhysDiskAddr_t *) node->params[prm].p)->bufPtr +
rf_RaidAddressToByte(raidPtr, sector - suoff[prm]);
/* find out if sector is in the shadow of any accessed failed
* SU. If yes, assign dest[0], dest[1] to point at suitable
@@ -795,21 +795,21 @@ rf_EvenOddDoubleRecoveryFunc(node)
* destination of decoding. */
RF_ASSERT(nresults == 1 || nresults == 2);
if (nresults == 1) {
- dest[0] = ((RF_PhysDiskAddr_t *) node->results[0])->bufPtr + rf_RaidAddressToByte(raidPtr, sector - fsuoff[0]);
+ dest[0] = (char *)((RF_PhysDiskAddr_t *) node->results[0])->bufPtr + rf_RaidAddressToByte(raidPtr, sector - fsuoff[0]);
/* Always malloc temp buffer to dest[1] */
RF_Malloc(dest[1], bytesPerSector, (char *));
memset(dest[1], 0, bytesPerSector);
mallc_two = 1;
} else {
if (fsuoff[0] <= sector && sector < fsuend[0])
- dest[0] = ((RF_PhysDiskAddr_t *) node->results[0])->bufPtr + rf_RaidAddressToByte(raidPtr, sector - fsuoff[0]);
+ dest[0] = (char *)((RF_PhysDiskAddr_t *) node->results[0])->bufPtr + rf_RaidAddressToByte(raidPtr, sector - fsuoff[0]);
else {
RF_Malloc(dest[0], bytesPerSector, (char *));
memset(dest[0], 0, bytesPerSector);
mallc_one = 1;
}
if (fsuoff[1] <= sector && sector < fsuend[1])
- dest[1] = ((RF_PhysDiskAddr_t *) node->results[1])->bufPtr + rf_RaidAddressToByte(raidPtr, sector - fsuoff[1]);
+ dest[1] = (char *)((RF_PhysDiskAddr_t *) node->results[1])->bufPtr + rf_RaidAddressToByte(raidPtr, sector - fsuoff[1]);
else {
RF_Malloc(dest[1], bytesPerSector, (char *));
memset(dest[1], 0, bytesPerSector);
@@ -817,8 +817,8 @@ rf_EvenOddDoubleRecoveryFunc(node)
}
RF_ASSERT(mallc_one == 0 || mallc_two == 0);
}
- pbuf = ppda->bufPtr + rf_RaidAddressToByte(raidPtr, sector - psuoff);
- ebuf = epda->bufPtr + rf_RaidAddressToByte(raidPtr, sector - esuoff);
+ pbuf = (char *)ppda->bufPtr + rf_RaidAddressToByte(raidPtr, sector - psuoff);
+ ebuf = (char *)epda->bufPtr + rf_RaidAddressToByte(raidPtr, sector - esuoff);
/*
* After finish finding all needed sectors, call doubleEOdecode function for decoding
* one sector to destination.
diff --git a/sys/dev/raidframe/rf_layout.h b/sys/dev/raidframe/rf_layout.h
index 5901f3a35f2..d6815a58bfb 100644
--- a/sys/dev/raidframe/rf_layout.h
+++ b/sys/dev/raidframe/rf_layout.h
@@ -1,4 +1,4 @@
-/* $NetBSD: rf_layout.h,v 1.16 2005/12/11 12:23:37 christos Exp $ */
+/* $NetBSD: rf_layout.h,v 1.17 2007/03/04 06:02:38 christos Exp $ */
/*
* Copyright (c) 1995 Carnegie-Mellon University.
* All rights reserved.
@@ -104,7 +104,7 @@ struct RF_PhysDiskAddr_s {
RF_SectorCount_t numSector; /* number of sectors accessed */
int type; /* used by higher levels: currently, data,
* parity, or q */
- caddr_t bufPtr; /* pointer to buffer supplying/receiving data */
+ void *bufPtr; /* pointer to buffer supplying/receiving data */
RF_RaidAddr_t raidAddress; /* raid address corresponding to this
* physical disk address */
RF_PhysDiskAddr_t *next;
diff --git a/sys/dev/raidframe/rf_map.c b/sys/dev/raidframe/rf_map.c
index 94764bd78f0..10f672c6a0b 100644
--- a/sys/dev/raidframe/rf_map.c
+++ b/sys/dev/raidframe/rf_map.c
@@ -1,4 +1,4 @@
-/* $NetBSD: rf_map.c,v 1.42 2006/11/16 01:33:23 christos Exp $ */
+/* $NetBSD: rf_map.c,v 1.43 2007/03/04 06:02:38 christos Exp $ */
/*
* Copyright (c) 1995 Carnegie-Mellon University.
* All rights reserved.
@@ -33,7 +33,7 @@
**************************************************************************/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: rf_map.c,v 1.42 2006/11/16 01:33:23 christos Exp $");
+__KERNEL_RCSID(0, "$NetBSD: rf_map.c,v 1.43 2007/03/04 06:02:38 christos Exp $");
#include <dev/raidframe/raidframevar.h>
@@ -77,7 +77,7 @@ static void rf_FreeASMList(RF_AccessStripeMap_t *asm_list);
RF_AccessStripeMapHeader_t *
rf_MapAccess(RF_Raid_t *raidPtr, RF_RaidAddr_t raidAddress,
- RF_SectorCount_t numBlocks, caddr_t buffer, int remap)
+ RF_SectorCount_t numBlocks, void *buffer, int remap)
{
RF_RaidLayout_t *layoutPtr = &(raidPtr->Layout);
RF_AccessStripeMapHeader_t *asm_hdr = NULL;
@@ -182,7 +182,7 @@ rf_MapAccess(RF_Raid_t *raidPtr, RF_RaidAddr_t raidAddress,
pda_p->numSector = RF_MIN(endAddress, nextStripeUnitAddress) - raidAddress;
RF_ASSERT(pda_p->numSector != 0);
rf_ASMCheckStatus(raidPtr, pda_p, asm_p, disks, 0);
- pda_p->bufPtr = buffer + rf_RaidAddressToByte(raidPtr, (raidAddress - startAddress));
+ pda_p->bufPtr = (char *)buffer + rf_RaidAddressToByte(raidPtr, (raidAddress - startAddress));
asm_p->totalSectorsAccessed += pda_p->numSector;
asm_p->numStripeUnitsAccessed++;
diff --git a/sys/dev/raidframe/rf_map.h b/sys/dev/raidframe/rf_map.h
index 2ff35b3e046..88a872f1289 100644
--- a/sys/dev/raidframe/rf_map.h
+++ b/sys/dev/raidframe/rf_map.h
@@ -1,4 +1,4 @@
-/* $NetBSD: rf_map.h,v 1.12 2005/12/11 12:23:37 christos Exp $ */
+/* $NetBSD: rf_map.h,v 1.13 2007/03/04 06:02:38 christos Exp $ */
/*
* Copyright (c) 1995 Carnegie-Mellon University.
* All rights reserved.
@@ -38,7 +38,7 @@
/* mapping structure allocation and free routines */
RF_AccessStripeMapHeader_t *rf_MapAccess(RF_Raid_t *, RF_RaidAddr_t,
- RF_SectorCount_t, caddr_t, int);
+ RF_SectorCount_t, void *, int);
void rf_MarkFailuresInASMList(RF_Raid_t *, RF_AccessStripeMapHeader_t *);
int rf_ConfigureMapModule(RF_ShutdownList_t **);
RF_AccessStripeMapHeader_t *rf_AllocAccessStripeMapHeader(void);
diff --git a/sys/dev/raidframe/rf_netbsdkintf.c b/sys/dev/raidframe/rf_netbsdkintf.c
index 4371be97d25..2da9ba2844c 100644
--- a/sys/dev/raidframe/rf_netbsdkintf.c
+++ b/sys/dev/raidframe/rf_netbsdkintf.c
@@ -1,4 +1,4 @@
-/* $NetBSD: rf_netbsdkintf.c,v 1.224 2006/11/30 23:01:50 oster Exp $ */
+/* $NetBSD: rf_netbsdkintf.c,v 1.225 2007/03/04 06:02:38 christos 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.224 2006/11/30 23:01:50 oster Exp $");
+__KERNEL_RCSID(0, "$NetBSD: rf_netbsdkintf.c,v 1.225 2007/03/04 06:02:38 christos Exp $");
#include <sys/param.h>
#include <sys/errno.h>
@@ -209,7 +209,7 @@ MALLOC_DEFINE(M_RAIDFRAME, "RAIDframe", "RAIDframe structures");
/* prototypes */
static void KernelWakeupFunc(struct buf *);
static void InitBP(struct buf *, struct vnode *, unsigned,
- dev_t, RF_SectorNum_t, RF_SectorCount_t, caddr_t, void (*) (struct buf *),
+ dev_t, RF_SectorNum_t, RF_SectorCount_t, void *, void (*) (struct buf *),
void *, int, struct proc *);
static void raidinit(RF_Raid_t *);
@@ -542,7 +542,7 @@ raidsize(dev_t dev)
}
int
-raiddump(dev_t dev, daddr_t blkno, caddr_t va,
+raiddump(dev_t dev, daddr_t blkno, void *va,
size_t size)
{
/* Not implemented. */
@@ -803,7 +803,7 @@ raidwrite(dev_t dev, struct uio *uio, int flags)
}
int
-raidioctl(dev_t dev, u_long cmd, caddr_t data, int flag, struct lwp *l)
+raidioctl(dev_t dev, u_long cmd, void *data, int flag, struct lwp *l)
{
int unit = raidunit(dev);
int error = 0;
@@ -2035,7 +2035,7 @@ KernelWakeupFunc(struct buf *bp)
*/
static void
InitBP(struct buf *bp, struct vnode *b_vp, unsigned rw_flag, dev_t dev,
- RF_SectorNum_t startSect, RF_SectorCount_t numSect, caddr_t bf,
+ RF_SectorNum_t startSect, RF_SectorCount_t numSect, void *bf,
void (*cbFunc) (struct buf *), void *cbArg, int logBytesPerSector,
struct proc *b_proc)
{
diff --git a/sys/dev/raidframe/rf_paritylog.c b/sys/dev/raidframe/rf_paritylog.c
index 1f1315e3f76..7edaca55b9a 100644
--- a/sys/dev/raidframe/rf_paritylog.c
+++ b/sys/dev/raidframe/rf_paritylog.c
@@ -1,4 +1,4 @@
-/* $NetBSD: rf_paritylog.c,v 1.12 2006/04/26 17:08:48 oster Exp $ */
+/* $NetBSD: rf_paritylog.c,v 1.13 2007/03/04 06:02:38 christos Exp $ */
/*
* Copyright (c) 1995 Carnegie-Mellon University.
* All rights reserved.
@@ -31,7 +31,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: rf_paritylog.c,v 1.12 2006/04/26 17:08:48 oster Exp $");
+__KERNEL_RCSID(0, "$NetBSD: rf_paritylog.c,v 1.13 2007/03/04 06:02:38 christos Exp $");
#include "rf_archs.h"
@@ -259,7 +259,7 @@ RF_ParityLogData_t *
rf_CreateParityLogData(
RF_ParityRecordType_t operation,
RF_PhysDiskAddr_t * pda,
- caddr_t bufPtr,
+ void *bufPtr,
RF_Raid_t * raidPtr,
int (*wakeFunc) (RF_DagNode_t * node, int status),
void *wakeArg,
@@ -803,7 +803,7 @@ rf_ParityLogAppend(
RF_ASSERT(log->records[logItem].parityAddr.startSector < raidPtr->regionInfo[regionID].parityStartAddr + raidPtr->regionInfo[regionID].numSectorsParity);
log->records[logItem].parityAddr.numSector = 1;
log->records[logItem].operation = item->common->operation;
- memcpy(log->bufPtr + (logItem * (1 << item->common->raidPtr->logBytesPerSector)), (item->common->bufPtr + (item->bufOffset++ * (1 << item->common->raidPtr->logBytesPerSector))), (1 << item->common->raidPtr->logBytesPerSector));
+ memcpy((char *)log->bufPtr + (logItem * (1 << item->common->raidPtr->logBytesPerSector)), ((char *)item->common->bufPtr + (item->bufOffset++ * (1 << item->common->raidPtr->logBytesPerSector))), (1 << item->common->raidPtr->logBytesPerSector));
item->diskAddress.numSector--;
item->diskAddress.startSector++;
if (item->diskAddress.numSector == 0)
diff --git a/sys/dev/raidframe/rf_paritylog.h b/sys/dev/raidframe/rf_paritylog.h
index c57fe2d71e8..67861c30f65 100644
--- a/sys/dev/raidframe/rf_paritylog.h
+++ b/sys/dev/raidframe/rf_paritylog.h
@@ -1,4 +1,4 @@
-/* $NetBSD: rf_paritylog.h,v 1.4 2001/10/04 15:58:55 oster Exp $ */
+/* $NetBSD: rf_paritylog.h,v 1.5 2007/03/04 06:02:38 christos Exp $ */
/*
* Copyright (c) 1995 Carnegie-Mellon University.
* All rights reserved.
@@ -54,7 +54,7 @@ struct RF_CommonLogData_s {
void *wakeArg;
RF_AccTraceEntry_t *tracerec;
RF_Etimer_t startTime;
- caddr_t bufPtr;
+ void *bufPtr;
RF_ParityRecordType_t operation;
RF_CommonLogData_t *next;
};
@@ -84,7 +84,7 @@ struct RF_ParityLog_s {
int numRecords;
int diskOffset;
RF_ParityLogRecord_t *records;
- caddr_t bufPtr;
+ void *bufPtr;
RF_ParityLog_t *next;
};
@@ -101,7 +101,7 @@ struct RF_RegionBufferQueue_s {
int availableBuffers; /* num available 'buffers' */
int emptyBuffersIndex; /* stick next freed buffer here */
int availBuffersIndex; /* grab next buffer from here */
- caddr_t *buffers; /* array buffers used to hold parity */
+ void **buffers; /* array buffers used to hold parity */
};
#define RF_PLOG_CREATED (1<<0)/* thread is created */
#define RF_PLOG_RUNNING (1<<1)/* thread is running */
@@ -165,7 +165,7 @@ struct RF_RegionInfo_s {
RF_ParityLogData_t *
rf_CreateParityLogData(RF_ParityRecordType_t operation,
- RF_PhysDiskAddr_t * pda, caddr_t bufPtr, RF_Raid_t * raidPtr,
+ RF_PhysDiskAddr_t * pda, void *bufPtr, RF_Raid_t * raidPtr,
int (*wakeFunc) (RF_DagNode_t * node, int status),
void *wakeArg, RF_AccTraceEntry_t * tracerec,
RF_Etimer_t startTime);
diff --git a/sys/dev/raidframe/rf_paritylogDiskMgr.c b/sys/dev/raidframe/rf_paritylogDiskMgr.c
index e58b2a47956..1cafdc3d36c 100644
--- a/sys/dev/raidframe/rf_paritylogDiskMgr.c
+++ b/sys/dev/raidframe/rf_paritylogDiskMgr.c
@@ -1,4 +1,4 @@
-/* $NetBSD: rf_paritylogDiskMgr.c,v 1.21 2006/11/16 01:33:23 christos Exp $ */
+/* $NetBSD: rf_paritylogDiskMgr.c,v 1.22 2007/03/04 06:02:38 christos Exp $ */
/*
* Copyright (c) 1995 Carnegie-Mellon University.
* All rights reserved.
@@ -30,7 +30,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: rf_paritylogDiskMgr.c,v 1.21 2006/11/16 01:33:23 christos Exp $");
+__KERNEL_RCSID(0, "$NetBSD: rf_paritylogDiskMgr.c,v 1.22 2007/03/04 06:02:38 christos Exp $");
#include "rf_archs.h"
@@ -57,13 +57,13 @@ __KERNEL_RCSID(0, "$NetBSD: rf_paritylogDiskMgr.c,v 1.21 2006/11/16 01:33:23 chr
#include "rf_paritylogDiskMgr.h"
-static caddr_t AcquireReintBuffer(RF_RegionBufferQueue_t *);
+static void *AcquireReintBuffer(RF_RegionBufferQueue_t *);
-static caddr_t
+static void *
AcquireReintBuffer(pool)
RF_RegionBufferQueue_t *pool;
{
- caddr_t bufPtr = NULL;
+ void *bufPtr = NULL;
/* Return a region buffer from the free list (pool). If the free list
* is empty, WAIT. BLOCKING */
@@ -87,7 +87,7 @@ AcquireReintBuffer(pool)
static void
ReleaseReintBuffer(
RF_RegionBufferQueue_t * pool,
- caddr_t bufPtr)
+ void *bufPtr)
{
/* Insert a region buffer (bufPtr) into the free list (pool).
* NON-BLOCKING */
@@ -109,7 +109,7 @@ static void
ReadRegionLog(
RF_RegionId_t regionID,
RF_MCPair_t * rrd_mcpair,
- caddr_t regionBuffer,
+ void *regionBuffer,
RF_Raid_t * raidPtr,
RF_DagHeader_t ** rrd_dag_h,
RF_AllocListElem_t ** rrd_alloclist,
@@ -215,7 +215,7 @@ static void
ReadRegionParity(
RF_RegionId_t regionID,
RF_MCPair_t * prd_mcpair,
- caddr_t parityBuffer,
+ void *parityBuffer,
RF_Raid_t * raidPtr,
RF_DagHeader_t ** prd_dag_h,
RF_AllocListElem_t ** prd_alloclist,
@@ -272,7 +272,7 @@ static void
WriteRegionParity(
RF_RegionId_t regionID,
RF_MCPair_t * pwr_mcpair,
- caddr_t parityBuffer,
+ void *parityBuffer,
RF_Raid_t * raidPtr,
RF_DagHeader_t ** pwr_dag_h,
RF_AllocListElem_t ** pwr_alloclist,
@@ -382,7 +382,7 @@ ReintegrateRegion(
RF_DagHeader_t *rrd_dag_h = NULL, *prd_dag_h, *pwr_dag_h;
RF_AllocListElem_t *rrd_alloclist = NULL, *prd_alloclist, *pwr_alloclist;
RF_PhysDiskAddr_t *rrd_pda = NULL, *prd_pda, *pwr_pda;
- caddr_t parityBuffer, regionBuffer = NULL;
+ void *parityBuffer, *regionBuffer = NULL;
/* Reintegrate a region (regionID).
*
diff --git a/sys/dev/raidframe/rf_paritylogging.c b/sys/dev/raidframe/rf_paritylogging.c
index 26c16573c06..c51f9f38152 100644
--- a/sys/dev/raidframe/rf_paritylogging.c
+++ b/sys/dev/raidframe/rf_paritylogging.c
@@ -1,4 +1,4 @@
-/* $NetBSD: rf_paritylogging.c,v 1.27 2006/11/16 01:33:23 christos Exp $ */
+/* $NetBSD: rf_paritylogging.c,v 1.28 2007/03/04 06:02:39 christos Exp $ */
/*
* Copyright (c) 1995 Carnegie-Mellon University.
* All rights reserved.
@@ -32,7 +32,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: rf_paritylogging.c,v 1.27 2006/11/16 01:33:23 christos Exp $");
+__KERNEL_RCSID(0, "$NetBSD: rf_paritylogging.c,v 1.28 2007/03/04 06:02:39 christos Exp $");
#include "rf_archs.h"
@@ -82,7 +82,7 @@ rf_ConfigureParityLogging(
RF_RaidLayout_t *layoutPtr = &raidPtr->Layout;
RF_ParityLoggingConfigInfo_t *info;
RF_ParityLog_t *l = NULL, *next;
- caddr_t lHeapPtr;
+ void *lHeapPtr;
if (rf_numParityRegions <= 0)
return(EINVAL);
@@ -230,7 +230,7 @@ rf_ConfigureParityLogging(
raidPtr->numParityLogs);
RF_Malloc(raidPtr->parityLogBufferHeap, raidPtr->numParityLogs *
raidPtr->numSectorsPerLog * raidPtr->bytesPerSector,
- (caddr_t));
+ (void *));
if (raidPtr->parityLogBufferHeap == NULL)
return (ENOMEM);
lHeapPtr = raidPtr->parityLogBufferHeap;
@@ -268,7 +268,7 @@ rf_ConfigureParityLogging(
l = l->next;
}
l->bufPtr = lHeapPtr;
- lHeapPtr += raidPtr->numSectorsPerLog *
+ lHeapPtr = (char *)lHeapPtr + raidPtr->numSectorsPerLog *
raidPtr->bytesPerSector;
RF_Malloc(l->records, (raidPtr->numSectorsPerLog *
sizeof(RF_ParityLogRecord_t)),
@@ -309,10 +309,10 @@ rf_ConfigureParityLogging(
raidPtr->regionBufferPool.emptyBuffersIndex = 0;
printf("Allocating %d bytes for regionBufferPool\n",
(int) (raidPtr->regionBufferPool.totalBuffers *
- sizeof(caddr_t)));
+ sizeof(void *)));
RF_Malloc(raidPtr->regionBufferPool.buffers,
- raidPtr->regionBufferPool.totalBuffers * sizeof(caddr_t),
- (caddr_t *));
+ raidPtr->regionBufferPool.totalBuffers * sizeof(void *),
+ (void **));
if (raidPtr->regionBufferPool.buffers == NULL) {
return (ENOMEM);
}
@@ -322,7 +322,7 @@ rf_ConfigureParityLogging(
sizeof(char)), i);
RF_Malloc(raidPtr->regionBufferPool.buffers[i],
raidPtr->regionBufferPool.bufferSize * sizeof(char),
- (caddr_t));
+ (void *));
if (raidPtr->regionBufferPool.buffers[i] == NULL) {
for (j = 0; j < i; j++) {
RF_Free(raidPtr->regionBufferPool.buffers[i],
@@ -331,7 +331,7 @@ rf_ConfigureParityLogging(
}
RF_Free(raidPtr->regionBufferPool.buffers,
raidPtr->regionBufferPool.totalBuffers *
- sizeof(caddr_t));
+ sizeof(void *));
return (ENOMEM);
}
printf("raidPtr->regionBufferPool.buffers[%d] = %lx\n", i,
@@ -358,11 +358,11 @@ rf_ConfigureParityLogging(
raidPtr->parityBufferPool.emptyBuffersIndex = 0;
printf("Allocating %d bytes for parityBufferPool of %d units\n",
(int) (raidPtr->parityBufferPool.totalBuffers *
- sizeof(caddr_t)),
+ sizeof(void *)),
raidPtr->parityBufferPool.totalBuffers );
RF_Malloc(raidPtr->parityBufferPool.buffers,
- raidPtr->parityBufferPool.totalBuffers * sizeof(caddr_t),
- (caddr_t *));
+ raidPtr->parityBufferPool.totalBuffers * sizeof(void *),
+ (void **));
if (raidPtr->parityBufferPool.buffers == NULL) {
return (ENOMEM);
}
@@ -372,7 +372,7 @@ rf_ConfigureParityLogging(
sizeof(char)),i);
RF_Malloc(raidPtr->parityBufferPool.buffers[i],
raidPtr->parityBufferPool.bufferSize * sizeof(char),
- (caddr_t));
+ (void *));
if (raidPtr->parityBufferPool.buffers == NULL) {
for (j = 0; j < i; j++) {
RF_Free(raidPtr->parityBufferPool.buffers[i],
@@ -381,7 +381,7 @@ rf_ConfigureParityLogging(
}
RF_Free(raidPtr->parityBufferPool.buffers,
raidPtr->regionBufferPool.totalBuffers *
- sizeof(caddr_t));
+ sizeof(void *));
return (ENOMEM);
}
printf("parityBufferPool.buffers[%d] = %lx\n", i,
@@ -548,7 +548,7 @@ FreeRegionBufferQueue(RF_RegionBufferQueue_t * queue)
}
for (i = 0; i < queue->totalBuffers; i++)
RF_Free(queue->buffers[i], queue->bufferSize);
- RF_Free(queue->buffers, queue->totalBuffers * sizeof(caddr_t));
+ RF_Free(queue->buffers, queue->totalBuffers * sizeof(void *));
RF_UNLOCK_MUTEX(queue->mutex);
}
diff --git a/sys/dev/raidframe/rf_raid.h b/sys/dev/raidframe/rf_raid.h
index a10feb4511f..4ddb13be711 100644
--- a/sys/dev/raidframe/rf_raid.h
+++ b/sys/dev/raidframe/rf_raid.h
@@ -1,4 +1,4 @@
-/* $NetBSD: rf_raid.h,v 1.35 2005/12/11 12:23:37 christos Exp $ */
+/* $NetBSD: rf_raid.h,v 1.36 2007/03/04 06:02:39 christos Exp $ */
/*
* Copyright (c) 1995 Carnegie-Mellon University.
* All rights reserved.
@@ -292,7 +292,7 @@ struct RF_Raid_s {
* region log */
RF_RegionBufferQueue_t parityBufferPool; /* buffers for holding
* parity */
- caddr_t parityLogBufferHeap; /* pool of unused parity logs */
+ void *parityLogBufferHeap; /* pool of unused parity logs */
RF_Thread_t pLogDiskThreadHandle;
#endif /* RF_INCLUDE_PARITYLOGGING > 0 */
diff --git a/sys/dev/raidframe/rf_raid1.c b/sys/dev/raidframe/rf_raid1.c
index abe5aeed745..b6f67987278 100644
--- a/sys/dev/raidframe/rf_raid1.c
+++ b/sys/dev/raidframe/rf_raid1.c
@@ -1,4 +1,4 @@
-/* $NetBSD: rf_raid1.c,v 1.29 2006/11/16 01:33:23 christos Exp $ */
+/* $NetBSD: rf_raid1.c,v 1.30 2007/03/04 06:02:39 christos Exp $ */
/*
* Copyright (c) 1995 Carnegie-Mellon University.
* All rights reserved.
@@ -33,7 +33,7 @@
*****************************************************************************/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: rf_raid1.c,v 1.29 2006/11/16 01:33:23 christos Exp $");
+__KERNEL_RCSID(0, "$NetBSD: rf_raid1.c,v 1.30 2007/03/04 06:02:39 christos Exp $");
#include "rf_raid.h"
#include "rf_raid1.h"
@@ -554,7 +554,7 @@ rf_SubmitReconBufferRAID1(RF_ReconBuffer_t *rbuf, int keep_it,
RF_CallbackDesc_t *cb, *p;
RF_ReconBuffer_t *t;
RF_Raid_t *raidPtr;
- caddr_t ta;
+ void *ta;
retcode = 0;
@@ -573,12 +573,11 @@ rf_SubmitReconBufferRAID1(RF_ReconBuffer_t *rbuf, int keep_it,
}
#endif
if (rf_reconDebug) {
+ unsigned char *b = rbuf->buffer;
printf("RAID1 reconbuffer submit psid %ld buf %lx\n",
(long) rbuf->parityStripeID, (long) rbuf->buffer);
printf("RAID1 psid %ld %02x %02x %02x %02x %02x\n",
- (long) rbuf->parityStripeID,
- rbuf->buffer[0], rbuf->buffer[1], rbuf->buffer[2], rbuf->buffer[3],
- rbuf->buffer[4]);
+ (long)rbuf->parityStripeID, b[0], b[1], b[2], b[3], b[4]);
}
RF_LOCK_PSS_MUTEX(raidPtr, rbuf->parityStripeID);
diff --git a/sys/dev/raidframe/rf_reconbuffer.c b/sys/dev/raidframe/rf_reconbuffer.c
index b117c3ec9ed..b13afcb0b6d 100644
--- a/sys/dev/raidframe/rf_reconbuffer.c
+++ b/sys/dev/raidframe/rf_reconbuffer.c
@@ -1,4 +1,4 @@
-/* $NetBSD: rf_reconbuffer.c,v 1.23 2005/12/11 12:23:37 christos Exp $ */
+/* $NetBSD: rf_reconbuffer.c,v 1.24 2007/03/04 06:02:39 christos Exp $ */
/*
* Copyright (c) 1995 Carnegie-Mellon University.
* All rights reserved.
@@ -33,7 +33,7 @@
***************************************************/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: rf_reconbuffer.c,v 1.23 2005/12/11 12:23:37 christos Exp $");
+__KERNEL_RCSID(0, "$NetBSD: rf_reconbuffer.c,v 1.24 2007/03/04 06:02:39 christos Exp $");
#include "rf_raid.h"
#include "rf_reconbuffer.h"
@@ -125,7 +125,7 @@ rf_SubmitReconBufferBasic(RF_ReconBuffer_t *rbuf, int keep_it,
RF_ReconParityStripeStatus_t *pssPtr;
RF_ReconBuffer_t *targetRbuf, *t = NULL; /* temporary rbuf
* pointers */
- caddr_t ta; /* temporary data buffer pointer */
+ void *ta; /* temporary data buffer pointer */
RF_CallbackDesc_t *cb, *p;
int retcode = 0;
diff --git a/sys/dev/raidframe/rf_reconstruct.h b/sys/dev/raidframe/rf_reconstruct.h
index 1d941bbb984..9c32deebbed 100644
--- a/sys/dev/raidframe/rf_reconstruct.h
+++ b/sys/dev/raidframe/rf_reconstruct.h
@@ -1,4 +1,4 @@
-/* $NetBSD: rf_reconstruct.h,v 1.22 2005/12/11 12:23:37 christos Exp $ */
+/* $NetBSD: rf_reconstruct.h,v 1.23 2007/03/04 06:02:39 christos Exp $ */
/*
* Copyright (c) 1995 Carnegie-Mellon University.
* All rights reserved.
@@ -47,8 +47,8 @@ struct RF_ReconConfig_s {
};
/* a reconstruction buffer */
struct RF_ReconBuffer_s {
- RF_Raid_t *raidPtr; /* void * to avoid recursive includes */
- caddr_t buffer; /* points to the data */
+ RF_Raid_t *raidPtr; /* void *to avoid recursive includes */
+ void *buffer; /* points to the data */
RF_StripeNum_t parityStripeID; /* the parity stripe that this data
* relates to */
int which_ru; /* which reconstruction unit within the PSS */
diff --git a/sys/dev/raidframe/rf_reconutil.c b/sys/dev/raidframe/rf_reconutil.c
index 90878702231..6748e91d546 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.27 2006/04/26 17:08:48 oster Exp $ */
+/* $NetBSD: rf_reconutil.c,v 1.28 2007/03/04 06:02:39 christos Exp $ */
/*
* Copyright (c) 1995 Carnegie-Mellon University.
* All rights reserved.
@@ -31,7 +31,7 @@
********************************************/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: rf_reconutil.c,v 1.27 2006/04/26 17:08:48 oster Exp $");
+__KERNEL_RCSID(0, "$NetBSD: rf_reconutil.c,v 1.28 2007/03/04 06:02:39 christos Exp $");
#include <dev/raidframe/raidframevar.h>
@@ -224,7 +224,7 @@ rf_MakeReconBuffer(RF_Raid_t *raidPtr, RF_RowCol_t col, RF_RbufType_t type)
u_int recon_buffer_size = rf_RaidAddressToByte(raidPtr, layoutPtr->SUsPerRU * layoutPtr->sectorsPerStripeUnit);
t = pool_get(&rf_pools.reconbuffer, PR_WAITOK);
- RF_Malloc(t->buffer, recon_buffer_size, (caddr_t));
+ RF_Malloc(t->buffer, recon_buffer_size, (void *));
t->raidPtr = raidPtr;
t->col = col;
t->priority = RF_IO_RECON_PRIORITY;