Re: bio_chain: proposed solution for bio_alloc failure and large IO simplification

From: Adam J. Richter (
Date: Sat Jun 15 2002 - 03:52:59 EST

Jens Axboe wrote:
>The I/O path allocations all use GFP_NOIO (or GFP_NOFS), which all have
>__GFP_WAIT set. So the bio allocations will try normal allocation first,
>then fall back to the bio pool. If the bio pool is also empty, we will
>block waiting for entries to be freed there. So there never will be a

        I did not realize that allocation with __GFP_WAIT was guaranteed
to _never_ fail.

        Even so, if __GFP_WAIT never fails, then it can deadlock (for
example, some other device driver has a memory leak). Under a
scheme like bio_chain (provided that it is changed not to call a
memory allocator that can deadlock), the only way you deadlock is
if there really is deadlock bug in the lower layers that process
the underlying request.

Adam J. Richter __ ______________ 575 Oroville Road \ / Milpitas, California 95035
+1 408 309-6081 | g g d r a s i l United States of America
                         "Free Software For The Rest Of Us."
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to
More majordomo info at
Please read the FAQ at

This archive was generated by hypermail 2b29 : Sat Jun 15 2002 - 22:00:33 EST