[lkml]   [1999]   [Apr]   [27]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
SubjectRe: bforget and protected buffers
On Tue, 27 Apr 1999, Chuck Lever wrote:

>see the buffer_busy macro defined later in fs/buffer.c for use by
>try_to_free_buffers(). this will prevent protected ramdisk buffers from
>being reclaimed, although they can still appear on the free list if
>someone decides to add bforget() calls to the ramdisk logic... presumably
>if ramdisk decides to bforget a buffer, it doesn't care about it's
>now, if you add this to bforget():
> buf->b_state = 0;
>that defeats the buffer_busy check in try_to_free_buffers(), so maybe the
>check should be made explicitly in bforget() if you add this line.

Even if you don't add the buf->b_state = 0 by hand in bforgot, you'll get
b_state set to 0 by getblk a bit after.

Andrea Arcangeli

To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to
Please read the FAQ at

 \ /
  Last update: 2005-03-22 13:51    [W:0.071 / U:17.688 seconds]
©2003-2018 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site