Go to file
oster 85611189b6 These changes complete the effective removal of malloc() from all
write paths within RAIDframe.  They also resolve the "panics with
RAID 5 sets with more than 3 components" issue which was present
(briefly) in the commits which were previously supposed to address
the malloc() issue.

With this new code the 5-component RAID 5 set panics are now gone.

It is also now also possible to swap to RAID 5.

The changes made are:

1) Introduce rf_AllocStripeBuffer() and rf_FreeStripeBuffer() to
allocate/free one stripe's worth of space.  rf_AllocStripeBuffer() is
used in rf_MapUnaccessedPortionOfStripe() where it is not sufficient to
allocate memory using just rf_AllocBuffer().  rf_FreeStripeBuffer() is
called from rf_FreeRaidAccDesc(), well after the DAG is finished.

2) Add a set of emergency "stripe buffers" to struct RF_Raid_s.
Arrange for their initialization in rf_Configure().  In low-memory
situations these buffers will be returned by rf_AllocStripeBuffer()
and re-populated by rf_FreeStripeBuffer().

3) Move	RF_VoidPointerListElem_t *iobufs from the dagHeader into
into struct RF_RaidAccessDesc_s.  This is more consistent with the
original code, and will not result in items being freed "too early".

4) Add a RF_RaidAccessDesc_t *desc to RF_DagHeader_s so that we have a
way to find desc->iobufs.

5) Arrange for desc in the DagHeader to be initialized in InitHdrNode().

6) Don't cleanup iobufs in rf_FreeDAG() -- the freeing is now delayed
until rf_FreeRaidAccDesc() (which is how the original code handled the
allocList, and for which there seem to be some subtle, undocumented
assumptions).

7) Rename rf_AllocBuffer2() to be rf_AllocBuffer() and remove the
former rf_AllocBuffer().  Fix all callers of rf_AllocBuffer().
(This was how it was *supposed* to be after the last time these
changes were made, before they were backed out).

8) Remove RF_IOBufHeader and all references to it.

9) Remove desc->cleanupList and all references to it.

Fixes PR#20191
2004-04-09 23:10:16 +00:00
bin Revert last, revision 1.46. 2004-04-02 12:53:05 +00:00
contrib/sys Convert athhal-elf.o to a .uue and add appropriate make hooks to use it 2004-03-25 23:32:10 +00:00
crypto From Heimdal, cast size_t to unsigned long for LP64 platforms. 2004-04-02 20:58:36 +00:00
dist Commit fix, from Darren Reed (darrenr@netbsd.org), for a functional regression 2004-04-09 20:39:22 +00:00
distrib Add mmapw - mmapr is already there. Discovered while trying to build 2.0. 2004-04-05 17:52:16 +00:00
doc note file(1) update to 4.09 2004-04-08 12:41:44 +00:00
etc Avoid the output "Running xxx.local" if the "xxx.local" script 2004-04-09 17:35:21 +00:00
games Rework to use curses.h only on the target, not on the host. 2004-04-07 17:46:47 +00:00
gnu apply the changes in PR#22489. 2004-04-05 14:32:56 +00:00
include Merge changes between heimdal-0.6 and heimdal-0.6.1 2004-04-02 14:59:46 +00:00
lib Weak aliases for sysctlfoobar() functions. 2004-04-08 05:45:26 +00:00
libexec Remove duplicated include of <sys/types.h> 2004-04-05 19:27:01 +00:00
regress The bug that this test was intended to check is rather volatile. In testing 2004-03-30 09:33:55 +00:00
rescue no need to list gnu/usr.bin any more. 2004-04-01 14:41:09 +00:00
sbin Don't copy the size that sysctl gave back directly, copy the size of 2004-04-08 06:49:03 +00:00
share The device is called /dev/dmoverio, not /dev/dmover. 2004-04-08 05:49:13 +00:00
sys These changes complete the effective removal of malloc() from all 2004-04-09 23:10:16 +00:00
tools Fix the processing of '-s .lo\ .ln' (etc). 2004-03-27 18:36:23 +00:00
usr.bin sysctl(3) no longer returns ENOPROTOOPT in this case, but ENOENT, 2004-04-09 18:48:05 +00:00
usr.sbin Wait for libpfkey to build before descending into racoon, as the 2004-04-09 22:23:14 +00:00
x11 mirror change in Imakefiles: provide DEFAULTVT=vt05 for amd64 as well. 2004-04-05 12:21:04 +00:00
build.sh Add 2004-02-06 23:19:30 +00:00
BUILDING Document MKTTINTERP. 2004-03-19 12:34:39 +00:00
Makefile Be more gcc like in the way we deal with libgcc so that sh3/hppa millicode 2004-02-15 19:52:27 +00:00
Makefile.inc don't set KERNSRCDIR here; pull in <bsd.kernobj.mk> if you need it 2002-04-10 14:53:43 +00:00
UPDATING Note need for latest bsd.files.mk now wrt athhal-elf.o 2004-03-26 17:48:13 +00:00