Subject: Re: CVS commit: src/sys/arch/xen/xen
To: None <source-changes@netbsd.org>
From: Jed Davis <jdev@panix.com>
List: source-changes
Date: 11/04/2006 01:09:29
Jed Davis <jld@netbsd.org> writes:

> Log Message:
> Recycle old buffers into new rx requests when their number reaches half of
> those not tied up in active mbufs, rather than half of the total number.
>
> (Or, to more literally translate the C, when there are at least as
> many buffers waiting to be reused as outstanding rx requests.)

Except that's not strictly true, because it'd also have to check that
condition in the event handler (i.e., when the number of active
requests decreases), not just when a buffer is freed.

Still, in the worst case it'll go off when the last rx request is
answered (and immediately freed for reuse), so it does kill the hang,
which was the point.  (But I already knew that it works, because it
was left to stew^W be tested for a week before committing.)

-- 
(let ((C call-with-current-continuation)) (apply (lambda (x y) (x y)) (map
((lambda (r) ((C C) (lambda (s) (r (lambda l (apply (s s) l))))))  (lambda
(f) (lambda (l) (if (null? l) C (lambda (k) (display (car l)) ((f (cdr l))
(C k)))))))    '((#\J #\d #\D #\v #\s) (#\e #\space #\a #\i #\newline)))))