mirror of
https://github.com/RGBCube/serenity
synced 2025-05-23 18:45:07 +00:00
Kernel: Invalidate file-backed VMO's when inodes are written.
The current strategy is simply to nuke all physical pages and force reload them from disk. This is obviously not optimal and should eventually be optimized. It should be fairly straightforward.
This commit is contained in:
parent
af21a45b1a
commit
ca16d9d98e
7 changed files with 117 additions and 11 deletions
|
@ -109,6 +109,18 @@ void Inode::will_be_destroyed()
|
|||
flush_metadata();
|
||||
}
|
||||
|
||||
void Inode::inode_contents_changed(off_t offset, size_t size, const byte* data)
|
||||
{
|
||||
if (m_vmo)
|
||||
m_vmo->inode_contents_changed(Badge<Inode>(), offset, size, data);
|
||||
}
|
||||
|
||||
void Inode::inode_size_changed(size_t old_size, size_t new_size)
|
||||
{
|
||||
if (m_vmo)
|
||||
m_vmo->inode_size_changed(Badge<Inode>(), old_size, new_size);
|
||||
}
|
||||
|
||||
int Inode::set_atime(time_t)
|
||||
{
|
||||
return -ENOTIMPL;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue