return rc;
}
-void ll_release_page(struct page *page, int remove)
+void ll_release_page(struct inode *inode, struct page *page, int remove)
{
kunmap(page);
if (remove) {
CDEBUG(D_VFSTRACE, "page %lu [%llu %llu], hash %llu\n",
offset, *start, *end, *hash);
if (*hash > *end) {
- ll_release_page(page, 0);
+ ll_release_page(dir, page, 0);
page = NULL;
} else if (*end != *start && *hash == *end) {
/*
* ll_get_dir_page() will issue RPC to fetch
* the page we want.
*/
- ll_release_page(page,
- le32_to_cpu(dp->ldp_flags) & LDF_COLLIDE);
+ ll_release_page(dir, page,
+ le32_to_cpu(dp->ldp_flags) &
+ LDF_COLLIDE);
page = NULL;
}
} else {
return page;
fail:
- ll_release_page(page, 1);
+ ll_release_page(dir, page, 1);
page = ERR_PTR(-EIO);
goto out_unlock;
}
if (done) {
pos = hash;
- ll_release_page(page, 0);
+ ll_release_page(inode, page, 0);
break;
}
* End of directory reached.
*/
done = 1;
- ll_release_page(page, 0);
+ ll_release_page(inode, page, 0);
} else {
/*
* Normal case: continue to the next
* page.
*/
- ll_release_page(page,
+ ll_release_page(inode, page,
le32_to_cpu(dp->ldp_flags) &
LDF_COLLIDE);
next = pos;
int ll_get_mdt_idx(struct inode *inode);
struct page *ll_get_dir_page(struct inode *dir, struct md_op_data *op_data,
__u64 hash, struct ll_dir_chain *chain);
-void ll_release_page(struct page *page, int remove);
+void ll_release_page(struct inode *inode, struct page *page, int remove);
/* llite/namei.c */
extern const struct inode_operations ll_special_inode_operations;
ll_post_statahead(sai);
if (unlikely(!thread_is_running(thread))) {
- ll_release_page(page, 0);
+ ll_release_page(dir, page, 0);
rc = 0;
goto out;
}
if (unlikely(
!thread_is_running(thread))) {
- ll_release_page(page, 0);
+ ll_release_page(dir, page, 0);
rc = 0;
goto out;
}
/*
* End of directory reached.
*/
- ll_release_page(page, 0);
+ ll_release_page(dir, page, 0);
while (1) {
l_wait_event(thread->t_ctl_waitq,
!list_empty(&sai->sai_entries_received) ||
* chain is exhausted.
* Normal case: continue to the next page.
*/
- ll_release_page(page, le32_to_cpu(dp->ldp_flags) &
- LDF_COLLIDE);
+ ll_release_page(dir, page,
+ le32_to_cpu(dp->ldp_flags) &
+ LDF_COLLIDE);
sai->sai_in_readpage = 1;
page = ll_get_dir_page(dir, op_data, pos, &chain);
sai->sai_in_readpage = 0;
else
rc = LS_FIRST_DOT_DE;
- ll_release_page(page, 0);
+ ll_release_page(dir, page, 0);
goto out;
}
pos = le64_to_cpu(dp->ldp_hash_end);
/*
* End of directory reached.
*/
- ll_release_page(page, 0);
+ ll_release_page(dir, page, 0);
goto out;
} else {
/*
* chain is exhausted
* Normal case: continue to the next page.
*/
- ll_release_page(page, le32_to_cpu(dp->ldp_flags) &
- LDF_COLLIDE);
+ ll_release_page(dir, page,
+ le32_to_cpu(dp->ldp_flags) &
+ LDF_COLLIDE);
page = ll_get_dir_page(dir, op_data, pos, &chain);
}
}