Messages in this thread | | | Date | Tue, 1 Jul 1997 21:54:33 +0200 (MET DST) | From | Gerard Roudier <> | Subject | Re: Bug in write request flushing !!! |
| |
On Tue, 1 Jul 1997, Dr. Werner Fink wrote:
Just my opinion on this change:
> - if (!grow_buffers(GFP_ATOMIC, size)) > + if (grow_buffers(GFP_ATOMIC, size)) > + needed -= PAGE_SIZE; > + else > wakeup_bdflush(1); > - needed -= PAGE_SIZE; > goto repeat;
If grow_buffers(GFP_ATOMIC, size) fails, that means that we have'nt been able to allocate a page and buffer headers, and sure that we are very low in memory. Since "bdflush" seems not to wait for IO completion, I'm not sure it is clever to try again to find some candidates if some buffer has been freed yet. I would prefer the following code.
else { wakeup_bdflush(1); if (free_list[size])/* Better to give up than to die stupidly */ return; }
Gerard.
| |