NetBSD/sys
oster 0ff2145648 For each RAID set, pre-allocate a number of "emergency buffers" to be
used in the event that we can't malloc a buffer of the appropriate
size in the traditional way.  rf_AllocIOBuffer() and rf_FreeIOBuffer()
deal with allocating/freeing these structures.  These buffers are
stored in a list on the 'iobuf' list.  iobuf_count keeps track of how
many buffers are available, and numEmergencyBuffers is the effective
"high-water" mark for the freelist.  The buffers allocated by
rf_AllocIOBuffer() are stripe-unit sized, which is the maximum
size requested by any of the callers.

Add an iobufs entry to RF_DagHeader_s.  Use it for keeping track of
buffers that get allocated from the free-list.

Add a "generic list" pool (VoidPointerListElement Pool) for elements
used to maintain a list of allocated memory.  [It is somewhat less
than ideal to add another little pool to handle this...]

Teach rf_AllocBuffer() to use the new rf_AllocIOBuffer().  Modify
other Mallocs to use rf_AllocIOBuffer(), and to update dag_h->iobufs as
appropriate.

Update rf_FreeDAG() to handle cleanup of dag_h->iobufs.

While here, add some missing pool_destroy() calls for a number of pools.

With these changes, it should (in theory) be possible to swap on
RAID 5 sets again.  That said, I've not had any success there yet --
but the last issue I saw at least wasn't in RAIDframe. :-}

[There is room for this code to become a bit more consise, but I
wanted to do a checkpoint here with something known to work :) ]
2004-03-20 04:22:05 +00:00
..
altq parameter with two es. From Peter Postma. 2004-02-24 15:22:01 +00:00
arch Add gt_dma_bus_mem_to_phys and gt_dma_phys_to_bus_mem. 2004-03-20 01:55:00 +00:00
coda Fix spelling of "orphan" and placement of */ 2004-03-09 03:14:09 +00:00
compat Remove local declaration of 'sg', since it is no longer used. 2004-03-11 10:14:10 +00:00
conf Pull in sys/kern_kcont. Size is 1.4k, hardly worth making an option 2004-03-20 03:12:47 +00:00
crypto s/netbsd.org/NetBSD.org/g 2003-11-28 08:56:48 +00:00
ddb Uppercase CPU, plural is CPUs. 2004-02-13 11:36:08 +00:00
dev For each RAID set, pre-allocate a number of "emergency buffers" to be 2004-03-20 04:22:05 +00:00
fs add comment to smbfs_remove() regarding the limitation to only remove 2004-02-29 12:19:15 +00:00
gdbscripts
ipkdb
kern Fix typos. 2004-03-20 02:57:34 +00:00
lib netbsd.org -> NetBSD.org 2003-12-04 13:57:30 +00:00
lkm Alphabetize... 2004-01-20 04:55:46 +00:00
miscfs Remove pointless comment about layerfs_sysctl() 2004-03-09 03:16:08 +00:00
net Add 10GBASE-LR to IFM_10G_LR. 2004-03-10 14:42:10 +00:00
net80211 In wi(4), wi_choose_rate used to contain device-independent code. 2004-03-17 17:00:34 +00:00
netatalk
netccitt
netinet fix tcp/udp checksum test in the M_CSUM_NO_PSEUDOHDR case 2004-03-10 18:50:45 +00:00
netinet6 constify AH algorithm function table. suggested by robert watson 2004-03-10 03:45:04 +00:00
netipsec Delint for compiling with INET6: 2004-03-20 03:08:55 +00:00
netisdn Spell length with h after t. Inspired by a commit by brad@openbsd. 2004-02-13 18:02:05 +00:00
netiso Spell the plural of suffix "suffixes", not "suffices". 2004-02-13 17:56:17 +00:00
netkey occured -> occurred. From Peter Postma. 2004-02-24 15:12:51 +00:00
netnatm
netns parameter with two es. From Peter Postma. 2004-02-24 15:22:01 +00:00
netsmb parameter with two es. From Peter Postma. 2004-02-24 15:22:01 +00:00
nfs nfs_getattrcache: deal with timer wraparound. 2004-03-19 13:53:28 +00:00
opencrypto Split opencrypto configuration into an attribute, usable by inkernel 2003-12-31 16:44:26 +00:00
stand
sys Fix typos in comments. 2004-03-20 02:58:47 +00:00
ufs reserve a MAXBSIZE-sized buffer for inodedeps for pagedaemon. 2004-03-11 11:50:43 +00:00
uvm Something I posted to tech-kern a long time ago... 2004-03-17 23:58:12 +00:00
Makefile