Yan Zheng
2007-Oct-31 07:20 UTC
[Btrfs-devel][PATCH]small fix for find_lock_delalloc_range.
Hello, There is a 'finish_wait', but no 'prepare_to_wait' . So I think that the 'prepare_to_wait' is missing. The second change is according to the name of variable. Regards YZ --- diff -r bc6bfcf7a158 extent_map.c --- a/extent_map.c Tue Oct 30 16:56:53 2007 -0400 +++ b/extent_map.c Wed Oct 31 21:58:21 2007 +0800 @@ -1039,6 +1039,8 @@ search_again: if (state->state & EXTENT_LOCKED) { DEFINE_WAIT(wait); atomic_inc(&state->refs); + prepare_to_wait(&state->wq, &wait, + TASK_UNINTERRUPTIBLE); write_unlock_irq(&tree->lock); schedule(); write_lock_irq(&tree->lock); @@ -1054,7 +1056,7 @@ search_again: node = rb_next(node); if (!node) break; - total_bytes = state->end - state->start + 1; + total_bytes += state->end - state->start + 1; if (total_bytes >= max_bytes) break; }
Chris Mason
2007-Nov-01 09:14 UTC
[Btrfs-devel][PATCH]small fix for find_lock_delalloc_range.
On Wed, 31 Oct 2007 22:20:08 +0800 "Yan Zheng" <yanzheng@21cn.com> wrote:> Hello, > > There is a 'finish_wait', but no 'prepare_to_wait' . So I think that > the 'prepare_to_wait' is missing. The second change is according to > the name of variable.These are pretty big thanks ;) -chris