开发者

Flushing the page cache associated with an inode

I modified the block mapping in an inode and want to flush the page cache associated with the inode so that the new inode with new mapping will be loaded from disk. I tried below functions but it works some time and fails some other time.

invalidate_mapping_pages() - for flushing non-dirty pages truncate_inode_pa开发者_运维问答ges() - for flushing dirty pages

Is there something I am missing in addition to this.

Thank you.

-- Bala


I found that filemap_datawrite_wait function can be used to write a dirty page to disk and read the updated page into memory.

-- Bala

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜