diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2012-01-31 12:23:59 -0500 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2012-01-31 12:23:59 -0500 |
commit | d3712b9dfcf44ca145cf87e7f4096fa2d923471a (patch) | |
tree | d72aaaa845fb81c669093363a0a1cc6d9e96baf2 /fs/logfs/logfs.h | |
parent | c5d2bc11030568966f04a2af35bacf33d3e37af7 (diff) | |
parent | f2933e86ad93a8d1287079d59e67afd6f4166a9d (diff) |
Merge tag 'for-linus' of git://github.com/prasad-joshi/logfs_upstream
There are few important bug fixes for LogFS
* tag 'for-linus' of git://github.com/prasad-joshi/logfs_upstream:
Logfs: Allow NULL block_isbad() methods
logfs: Grow inode in delete path
logfs: Free areas before calling generic_shutdown_super()
logfs: remove useless BUG_ON
MAINTAINERS: Add Prasad Joshi in LogFS maintiners
logfs: Propagate page parameter to __logfs_write_inode
logfs: set superblock shutdown flag after generic sb shutdown
logfs: take write mutex lock during fsync and sync
logfs: Prevent memory corruption
logfs: update page reference count for pined pages
Fix up conflict in fs/logfs/dev_mtd.c due to semantic change in what
"mtd->block_isbad" means in commit f2933e86ad93: "Logfs: Allow NULL
block_isbad() methods" clashing with the abstraction changes in the
commits 7086c19d0742: "mtd: introduce mtd_block_isbad interface" and
d58b27ed58a3: "logfs: do not use 'mtd->block_isbad' directly".
This resolution takes the semantics from commit f2933e86ad93, and just
makes mtd_block_isbad() return zero (false) if the 'block_isbad'
function is NULL. But that also means that now "mtd_can_have_bb()"
always returns 0.
Now, "mtd_block_markbad()" will obviously return an error if the
low-level driver doesn't support bad blocks, so this is somewhat
non-symmetric, but it actually makes sense if a NULL "block_isbad"
function is considered to mean "I assume that all my blocks are always
good".
Diffstat (limited to 'fs/logfs/logfs.h')
-rw-r--r-- | fs/logfs/logfs.h | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/fs/logfs/logfs.h b/fs/logfs/logfs.h index 926373866a55..5f0937609465 100644 --- a/fs/logfs/logfs.h +++ b/fs/logfs/logfs.h | |||
@@ -528,7 +528,7 @@ void logfs_destroy_inode_cache(void); | |||
528 | void logfs_set_blocks(struct inode *inode, u64 no); | 528 | void logfs_set_blocks(struct inode *inode, u64 no); |
529 | /* these logically belong into inode.c but actually reside in readwrite.c */ | 529 | /* these logically belong into inode.c but actually reside in readwrite.c */ |
530 | int logfs_read_inode(struct inode *inode); | 530 | int logfs_read_inode(struct inode *inode); |
531 | int __logfs_write_inode(struct inode *inode, long flags); | 531 | int __logfs_write_inode(struct inode *inode, struct page *, long flags); |
532 | void logfs_evict_inode(struct inode *inode); | 532 | void logfs_evict_inode(struct inode *inode); |
533 | 533 | ||
534 | /* journal.c */ | 534 | /* journal.c */ |
@@ -577,6 +577,8 @@ void initialize_block_counters(struct page *page, struct logfs_block *block, | |||
577 | __be64 *array, int page_is_empty); | 577 | __be64 *array, int page_is_empty); |
578 | int logfs_exist_block(struct inode *inode, u64 bix); | 578 | int logfs_exist_block(struct inode *inode, u64 bix); |
579 | int get_page_reserve(struct inode *inode, struct page *page); | 579 | int get_page_reserve(struct inode *inode, struct page *page); |
580 | void logfs_get_wblocks(struct super_block *sb, struct page *page, int lock); | ||
581 | void logfs_put_wblocks(struct super_block *sb, struct page *page, int lock); | ||
580 | extern struct logfs_block_ops indirect_block_ops; | 582 | extern struct logfs_block_ops indirect_block_ops; |
581 | 583 | ||
582 | /* segment.c */ | 584 | /* segment.c */ |
@@ -594,6 +596,7 @@ int logfs_init_mapping(struct super_block *sb); | |||
594 | void logfs_sync_area(struct logfs_area *area); | 596 | void logfs_sync_area(struct logfs_area *area); |
595 | void logfs_sync_segments(struct super_block *sb); | 597 | void logfs_sync_segments(struct super_block *sb); |
596 | void freeseg(struct super_block *sb, u32 segno); | 598 | void freeseg(struct super_block *sb, u32 segno); |
599 | void free_areas(struct super_block *sb); | ||
597 | 600 | ||
598 | /* area handling */ | 601 | /* area handling */ |
599 | int logfs_init_areas(struct super_block *sb); | 602 | int logfs_init_areas(struct super_block *sb); |