Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 243031
b: refs/heads/master
c: 272b62c
h: refs/heads/master
i:
  243029: e6bad32
  243027: 452a0cb
  243023: f842b95
v: v3
  • Loading branch information
Goldwyn Rodrigues authored and Joel Becker committed Mar 28, 2011
1 parent 580dff8 commit 3e37fc8
Show file tree
Hide file tree
Showing 2 changed files with 7 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: 99bdc3880c611c7f2061fbd5372ef81b40217e26
refs/heads/master: 272b62c1f0f6f742046e45b50b6fec98860208a0
6 changes: 6 additions & 0 deletions trunk/fs/ocfs2/aops.c
Original file line number Diff line number Diff line change
Expand Up @@ -1015,6 +1015,12 @@ static int ocfs2_prepare_page_for_write(struct inode *inode, u64 *p_blkno,
ocfs2_figure_cluster_boundaries(OCFS2_SB(inode->i_sb), cpos,
&cluster_start, &cluster_end);

/* treat the write as new if the a hole/lseek spanned across
* the page boundary.
*/
new = new | ((i_size_read(inode) <= page_offset(page)) &&
(page_offset(page) <= user_pos));

if (page == wc->w_target_page) {
map_from = user_pos & (PAGE_CACHE_SIZE - 1);
map_to = map_from + user_len;
Expand Down

0 comments on commit 3e37fc8

Please sign in to comment.