Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 347609
b: refs/heads/master
c: 8884d53
h: refs/heads/master
i:
  347607: da012cf
v: v3
  • Loading branch information
David Zafman authored and Alex Elder committed Dec 13, 2012
1 parent f6a98d8 commit 71bf44f
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 1 deletion.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 0e5e1774a92e6fe9c511585de8f078b4c4c68dbb
refs/heads/master: 8884d53dd63b1d9315b343564fcbe1ede004a99e
9 changes: 9 additions & 0 deletions trunk/fs/ceph/addr.c
Original file line number Diff line number Diff line change
Expand Up @@ -267,6 +267,14 @@ static void finish_read(struct ceph_osd_request *req, struct ceph_msg *msg)
kfree(req->r_pages);
}

static void ceph_unlock_page_vector(struct page **pages, int num_pages)
{
int i;

for (i = 0; i < num_pages; i++)
unlock_page(pages[i]);
}

/*
* start an async read(ahead) operation. return nr_pages we submitted
* a read for on success, or negative error code.
Expand Down Expand Up @@ -347,6 +355,7 @@ static int start_read(struct inode *inode, struct list_head *page_list, int max)
return nr_pages;

out_pages:
ceph_unlock_page_vector(pages, nr_pages);
ceph_release_page_vector(pages, nr_pages);
out:
ceph_osdc_put_request(req);
Expand Down

0 comments on commit 71bf44f

Please sign in to comment.