Move a bunch of debugging stuff to be only used if DEBUG is turned on.
This commit is contained in:
parent
94f30b739f
commit
2ad74785a4
|
@ -1,4 +1,4 @@
|
|||
/* $NetBSD: rf_reconbuffer.c,v 1.6 2001/11/13 07:11:16 lukem Exp $ */
|
||||
/* $NetBSD: rf_reconbuffer.c,v 1.7 2002/01/09 03:10:20 oster 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.6 2001/11/13 07:11:16 lukem Exp $");
|
||||
__KERNEL_RCSID(0, "$NetBSD: rf_reconbuffer.c,v 1.7 2002/01/09 03:10:20 oster Exp $");
|
||||
|
||||
#include "rf_raid.h"
|
||||
#include "rf_reconbuffer.h"
|
||||
|
@ -45,12 +45,24 @@ __KERNEL_RCSID(0, "$NetBSD: rf_reconbuffer.c,v 1.6 2001/11/13 07:11:16 lukem Exp
|
|||
#include "rf_reconutil.h"
|
||||
#include "rf_nwayxor.h"
|
||||
|
||||
#ifdef DEBUG
|
||||
|
||||
#define Dprintf1(s,a) if (rf_reconbufferDebug) printf(s,a)
|
||||
#define Dprintf2(s,a,b) if (rf_reconbufferDebug) printf(s,a,b)
|
||||
#define Dprintf3(s,a,b,c) if (rf_reconbufferDebug) printf(s,a,b,c)
|
||||
#define Dprintf4(s,a,b,c,d) if (rf_reconbufferDebug) printf(s,a,b,c,d)
|
||||
#define Dprintf5(s,a,b,c,d,e) if (rf_reconbufferDebug) printf(s,a,b,c,d,e)
|
||||
|
||||
#else /* DEBUG */
|
||||
|
||||
#define Dprintf1(s,a) {}
|
||||
#define Dprintf2(s,a,b) {}
|
||||
#define Dprintf3(s,a,b,c) {}
|
||||
#define Dprintf4(s,a,b,c,d) {}
|
||||
#define Dprintf5(s,a,b,c,d,e) {}
|
||||
|
||||
#endif
|
||||
|
||||
/*****************************************************************************
|
||||
*
|
||||
* Submit a reconstruction buffer to the manager for XOR. We can only
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
/* $NetBSD: rf_reconstruct.c,v 1.32 2001/11/15 09:48:14 lukem Exp $ */
|
||||
/* $NetBSD: rf_reconstruct.c,v 1.33 2002/01/09 03:10:19 oster Exp $ */
|
||||
/*
|
||||
* Copyright (c) 1995 Carnegie-Mellon University.
|
||||
* All rights reserved.
|
||||
|
@ -33,7 +33,7 @@
|
|||
************************************************************/
|
||||
|
||||
#include <sys/cdefs.h>
|
||||
__KERNEL_RCSID(0, "$NetBSD: rf_reconstruct.c,v 1.32 2001/11/15 09:48:14 lukem Exp $");
|
||||
__KERNEL_RCSID(0, "$NetBSD: rf_reconstruct.c,v 1.33 2002/01/09 03:10:19 oster Exp $");
|
||||
|
||||
#include <sys/time.h>
|
||||
#include <sys/buf.h>
|
||||
|
@ -66,6 +66,7 @@ __KERNEL_RCSID(0, "$NetBSD: rf_reconstruct.c,v 1.32 2001/11/15 09:48:14 lukem Ex
|
|||
|
||||
/* setting these to -1 causes them to be set to their default values if not set by debug options */
|
||||
|
||||
#ifdef DEBUG
|
||||
#define Dprintf(s) if (rf_reconDebug) rf_debug_printf(s,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL)
|
||||
#define Dprintf1(s,a) if (rf_reconDebug) rf_debug_printf(s,(void *)((unsigned long)a),NULL,NULL,NULL,NULL,NULL,NULL,NULL)
|
||||
#define Dprintf2(s,a,b) if (rf_reconDebug) rf_debug_printf(s,(void *)((unsigned long)a),(void *)((unsigned long)b),NULL,NULL,NULL,NULL,NULL,NULL)
|
||||
|
@ -78,6 +79,23 @@ __KERNEL_RCSID(0, "$NetBSD: rf_reconstruct.c,v 1.32 2001/11/15 09:48:14 lukem Ex
|
|||
#define DDprintf1(s,a) if (rf_reconDebug) rf_debug_printf(s,(void *)((unsigned long)a),NULL,NULL,NULL,NULL,NULL,NULL,NULL)
|
||||
#define DDprintf2(s,a,b) if (rf_reconDebug) rf_debug_printf(s,(void *)((unsigned long)a),(void *)((unsigned long)b),NULL,NULL,NULL,NULL,NULL,NULL)
|
||||
|
||||
#else /* DEBUG */
|
||||
|
||||
#define Dprintf(s) {}
|
||||
#define Dprintf1(s,a) {}
|
||||
#define Dprintf2(s,a,b) {}
|
||||
#define Dprintf3(s,a,b,c) {}
|
||||
#define Dprintf4(s,a,b,c,d) {}
|
||||
#define Dprintf5(s,a,b,c,d,e) {}
|
||||
#define Dprintf6(s,a,b,c,d,e,f) {}
|
||||
#define Dprintf7(s,a,b,c,d,e,f,g) {}
|
||||
|
||||
#define DDprintf1(s,a) {}
|
||||
#define DDprintf2(s,a,b) {}
|
||||
|
||||
#endif /* DEBUG */
|
||||
|
||||
|
||||
static RF_FreeList_t *rf_recond_freelist;
|
||||
#define RF_MAX_FREE_RECOND 4
|
||||
#define RF_RECOND_INC 1
|
||||
|
|
Loading…
Reference in New Issue