Messages in this thread | | | Date | Thu, 1 Apr 2004 16:26:27 -0800 | From | Andrew Morton <> | Subject | Re: Possible error in fs/buffer.c |
| |
"Robert W. Maloy" <r.w.maloy@acm.org> wrote: > > While code surfing I found what appears to be a problem with the > following code in fs/buffer.c {function mark_buffer_inode_dirty}: > > if (list_empty(&bh->b_assoc_buffers)) > buffer_insert_list(&buffer_mapping->private_lock, > bh, &mapping->private_list);
This is saying "is the buffer is not on any list, then place it on the mapping's list now. If the buffer _is_ already on some list then we know it must already be on mapping->private_list, so we have nothing to do".
Re-dirtying an already-dirty buffer is an extremely common case, and here we look for an opportunity to avoid dirtying a cacheline or two.
- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
| |