Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 37150
b: refs/heads/master
c: 948ecdb
h: refs/heads/master
v: v3
  • Loading branch information
Nathan Scott authored and Tim Shimmin committed Sep 28, 2006
1 parent 194dfc4 commit cb71335
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 4 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: efb8ad7e9431a430a75d44288614cf6047ff4baa
refs/heads/master: 948ecdb4c118293d2f3e267eec642c30c5d3a056
11 changes: 8 additions & 3 deletions trunk/fs/xfs/linux-2.6/xfs_buf.c
Original file line number Diff line number Diff line change
Expand Up @@ -318,8 +318,12 @@ xfs_buf_free(
if ((bp->b_flags & XBF_MAPPED) && (bp->b_page_count > 1))
free_address(bp->b_addr - bp->b_offset);

for (i = 0; i < bp->b_page_count; i++)
page_cache_release(bp->b_pages[i]);
for (i = 0; i < bp->b_page_count; i++) {
struct page *page = bp->b_pages[i];

ASSERT(!PagePrivate(page));
page_cache_release(page);
}
_xfs_buf_free_pages(bp);
} else if (bp->b_flags & _XBF_KMEM_ALLOC) {
/*
Expand Down Expand Up @@ -400,6 +404,7 @@ _xfs_buf_lookup_pages(
nbytes = min_t(size_t, size, PAGE_CACHE_SIZE - offset);
size -= nbytes;

ASSERT(!PagePrivate(page));
if (!PageUptodate(page)) {
page_count--;
if (blocksize >= PAGE_CACHE_SIZE) {
Expand Down Expand Up @@ -1117,10 +1122,10 @@ xfs_buf_bio_end_io(
do {
struct page *page = bvec->bv_page;

ASSERT(!PagePrivate(page));
if (unlikely(bp->b_error)) {
if (bp->b_flags & XBF_READ)
ClearPageUptodate(page);
SetPageError(page);
} else if (blocksize >= PAGE_CACHE_SIZE) {
SetPageUptodate(page);
} else if (!PagePrivate(page) &&
Expand Down

0 comments on commit cb71335

Please sign in to comment.