diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2010-05-24 10:57:41 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2010-05-24 10:57:41 -0400 |
commit | 0163916f1db7f345963dad1af78b7628c759c6ee (patch) | |
tree | c33e3551b7825e8700db65b8b27869f6f7d45c72 /fs | |
parent | a69eee4988752c7196677958b4ed8f4c2b28499a (diff) | |
parent | ddf08f4b90a413892bbb9bb2e8a57aed991cd47d (diff) |
Merge branch 'for-linus' of git://git.open-osd.org/linux-open-osd
* 'for-linus' of git://git.open-osd.org/linux-open-osd:
exofs: confusion between kmap() and kmap_atomic() api
exofs: Add default address_space_operations
Diffstat (limited to 'fs')
-rw-r--r-- | fs/exofs/dir.c | 2 | ||||
-rw-r--r-- | fs/exofs/inode.c | 30 |
2 files changed, 31 insertions, 1 deletions
diff --git a/fs/exofs/dir.c b/fs/exofs/dir.c index 4cfab1cc75c0..d91e9d829bc1 100644 --- a/fs/exofs/dir.c +++ b/fs/exofs/dir.c | |||
@@ -608,7 +608,7 @@ int exofs_make_empty(struct inode *inode, struct inode *parent) | |||
608 | de->inode_no = cpu_to_le64(parent->i_ino); | 608 | de->inode_no = cpu_to_le64(parent->i_ino); |
609 | memcpy(de->name, PARENT_DIR, sizeof(PARENT_DIR)); | 609 | memcpy(de->name, PARENT_DIR, sizeof(PARENT_DIR)); |
610 | exofs_set_de_type(de, inode); | 610 | exofs_set_de_type(de, inode); |
611 | kunmap_atomic(page, KM_USER0); | 611 | kunmap_atomic(kaddr, KM_USER0); |
612 | err = exofs_commit_chunk(page, 0, chunk_size); | 612 | err = exofs_commit_chunk(page, 0, chunk_size); |
613 | fail: | 613 | fail: |
614 | page_cache_release(page); | 614 | page_cache_release(page); |
diff --git a/fs/exofs/inode.c b/fs/exofs/inode.c index d7c6afa79754..4bb6ef822e46 100644 --- a/fs/exofs/inode.c +++ b/fs/exofs/inode.c | |||
@@ -755,6 +755,21 @@ static int exofs_write_end(struct file *file, struct address_space *mapping, | |||
755 | return ret; | 755 | return ret; |
756 | } | 756 | } |
757 | 757 | ||
758 | static int exofs_releasepage(struct page *page, gfp_t gfp) | ||
759 | { | ||
760 | EXOFS_DBGMSG("page 0x%lx\n", page->index); | ||
761 | WARN_ON(1); | ||
762 | return try_to_free_buffers(page); | ||
763 | } | ||
764 | |||
765 | static void exofs_invalidatepage(struct page *page, unsigned long offset) | ||
766 | { | ||
767 | EXOFS_DBGMSG("page_has_buffers=>%d\n", page_has_buffers(page)); | ||
768 | WARN_ON(1); | ||
769 | |||
770 | block_invalidatepage(page, offset); | ||
771 | } | ||
772 | |||
758 | const struct address_space_operations exofs_aops = { | 773 | const struct address_space_operations exofs_aops = { |
759 | .readpage = exofs_readpage, | 774 | .readpage = exofs_readpage, |
760 | .readpages = exofs_readpages, | 775 | .readpages = exofs_readpages, |
@@ -762,6 +777,21 @@ const struct address_space_operations exofs_aops = { | |||
762 | .writepages = exofs_writepages, | 777 | .writepages = exofs_writepages, |
763 | .write_begin = exofs_write_begin_export, | 778 | .write_begin = exofs_write_begin_export, |
764 | .write_end = exofs_write_end, | 779 | .write_end = exofs_write_end, |
780 | .releasepage = exofs_releasepage, | ||
781 | .set_page_dirty = __set_page_dirty_nobuffers, | ||
782 | .invalidatepage = exofs_invalidatepage, | ||
783 | |||
784 | /* Not implemented Yet */ | ||
785 | .bmap = NULL, /* TODO: use osd's OSD_ACT_READ_MAP */ | ||
786 | .direct_IO = NULL, /* TODO: Should be trivial to do */ | ||
787 | |||
788 | /* With these NULL has special meaning or default is not exported */ | ||
789 | .sync_page = NULL, | ||
790 | .get_xip_mem = NULL, | ||
791 | .migratepage = NULL, | ||
792 | .launder_page = NULL, | ||
793 | .is_partially_uptodate = NULL, | ||
794 | .error_remove_page = NULL, | ||
765 | }; | 795 | }; |
766 | 796 | ||
767 | /****************************************************************************** | 797 | /****************************************************************************** |