Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 47416
b: refs/heads/master
c: 7671932
h: refs/heads/master
v: v3
  • Loading branch information
Ken Chen authored and Linus Torvalds committed Feb 11, 2007
1 parent a3b9c1d commit 8bd0ff5
Show file tree
Hide file tree
Showing 4 changed files with 13 additions and 2 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: bd8029b66069d29fd02c304599411ca9bb7fa38c
refs/heads/master: 767193253bbac889e176f90b6f17b7015f986551
1 change: 1 addition & 0 deletions trunk/include/linux/mm.h
Original file line number Diff line number Diff line change
Expand Up @@ -785,6 +785,7 @@ extern int try_to_release_page(struct page * page, gfp_t gfp_mask);
extern void do_invalidatepage(struct page *page, unsigned long offset);

int __set_page_dirty_nobuffers(struct page *page);
int __set_page_dirty_no_writeback(struct page *page);
int redirty_page_for_writepage(struct writeback_control *wbc,
struct page *page);
int FASTCALL(set_page_dirty(struct page *page));
Expand Down
10 changes: 10 additions & 0 deletions trunk/mm/page-writeback.c
Original file line number Diff line number Diff line change
Expand Up @@ -736,6 +736,16 @@ int write_one_page(struct page *page, int wait)
}
EXPORT_SYMBOL(write_one_page);

/*
* For address_spaces which do not use buffers nor write back.
*/
int __set_page_dirty_no_writeback(struct page *page)
{
if (!PageDirty(page))
SetPageDirty(page);
return 0;
}

/*
* For address_spaces which do not use buffers. Just tag the page as dirty in
* its radix tree.
Expand Down
2 changes: 1 addition & 1 deletion trunk/mm/shmem.c
Original file line number Diff line number Diff line change
Expand Up @@ -2316,7 +2316,7 @@ static void destroy_inodecache(void)

static const struct address_space_operations shmem_aops = {
.writepage = shmem_writepage,
.set_page_dirty = __set_page_dirty_nobuffers,
.set_page_dirty = __set_page_dirty_no_writeback,
#ifdef CONFIG_TMPFS
.prepare_write = shmem_prepare_write,
.commit_write = simple_commit_write,
Expand Down

0 comments on commit 8bd0ff5

Please sign in to comment.