mirror of
https://github.com/Fishwaldo/Star64_linux.git
synced 2025-07-22 23:04:43 +00:00
mm: cleancache: s/flush/invalidate/
Per akpm suggestions alter the use of the term flush to be invalidate. The next patch will do this across all MM. This change is completely cosmetic. [v9: akpm@linux-foundation.org: change "flush" to "invalidate", part 3] Signed-off-by: Dan Magenheimer <dan.magenheimer@oracle.com> Cc: Kamezawa Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com> Cc: Jan Beulich <JBeulich@novell.com> Reviewed-by: Seth Jennings <sjenning@linux.vnet.ibm.com> Cc: Jeremy Fitzhardinge <jeremy@goop.org> Cc: Hugh Dickins <hughd@google.com> Cc: Johannes Weiner <hannes@cmpxchg.org> Cc: Nitin Gupta <ngupta@vflare.org> Cc: Matthew Wilcox <matthew@wil.cx> Cc: Chris Mason <chris.mason@oracle.com> Cc: Rik Riel <riel@redhat.com> Cc: Andrew Morton <akpm@linux-foundation.org> [v10: Fixed fs: move code out of buffer.c conflict change] Signed-off-by: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>
This commit is contained in:
parent
972b2c7199
commit
3167760f83
7 changed files with 51 additions and 44 deletions
|
@ -28,6 +28,11 @@ struct cleancache_ops {
|
|||
pgoff_t, struct page *);
|
||||
void (*put_page)(int, struct cleancache_filekey,
|
||||
pgoff_t, struct page *);
|
||||
/*
|
||||
* NOTE: per akpm, flush_page, flush_inode and flush_fs will be
|
||||
* renamed to invalidate_* in a later commit in which all
|
||||
* dependencies (i.e Xen, zcache) will be renamed simultaneously
|
||||
*/
|
||||
void (*flush_page)(int, struct cleancache_filekey, pgoff_t);
|
||||
void (*flush_inode)(int, struct cleancache_filekey);
|
||||
void (*flush_fs)(int);
|
||||
|
@ -39,9 +44,9 @@ extern void __cleancache_init_fs(struct super_block *);
|
|||
extern void __cleancache_init_shared_fs(char *, struct super_block *);
|
||||
extern int __cleancache_get_page(struct page *);
|
||||
extern void __cleancache_put_page(struct page *);
|
||||
extern void __cleancache_flush_page(struct address_space *, struct page *);
|
||||
extern void __cleancache_flush_inode(struct address_space *);
|
||||
extern void __cleancache_flush_fs(struct super_block *);
|
||||
extern void __cleancache_invalidate_page(struct address_space *, struct page *);
|
||||
extern void __cleancache_invalidate_inode(struct address_space *);
|
||||
extern void __cleancache_invalidate_fs(struct super_block *);
|
||||
extern int cleancache_enabled;
|
||||
|
||||
#ifdef CONFIG_CLEANCACHE
|
||||
|
@ -99,24 +104,24 @@ static inline void cleancache_put_page(struct page *page)
|
|||
__cleancache_put_page(page);
|
||||
}
|
||||
|
||||
static inline void cleancache_flush_page(struct address_space *mapping,
|
||||
static inline void cleancache_invalidate_page(struct address_space *mapping,
|
||||
struct page *page)
|
||||
{
|
||||
/* careful... page->mapping is NULL sometimes when this is called */
|
||||
if (cleancache_enabled && cleancache_fs_enabled_mapping(mapping))
|
||||
__cleancache_flush_page(mapping, page);
|
||||
__cleancache_invalidate_page(mapping, page);
|
||||
}
|
||||
|
||||
static inline void cleancache_flush_inode(struct address_space *mapping)
|
||||
static inline void cleancache_invalidate_inode(struct address_space *mapping)
|
||||
{
|
||||
if (cleancache_enabled && cleancache_fs_enabled_mapping(mapping))
|
||||
__cleancache_flush_inode(mapping);
|
||||
__cleancache_invalidate_inode(mapping);
|
||||
}
|
||||
|
||||
static inline void cleancache_flush_fs(struct super_block *sb)
|
||||
static inline void cleancache_invalidate_fs(struct super_block *sb)
|
||||
{
|
||||
if (cleancache_enabled)
|
||||
__cleancache_flush_fs(sb);
|
||||
__cleancache_invalidate_fs(sb);
|
||||
}
|
||||
|
||||
#endif /* _LINUX_CLEANCACHE_H */
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue