This function is called at the end of RMAP routine, i.e. filesystem
recovery function, to collect and kill processes using a shared page of
DAX file. The difference between mf_generic_kill_procs() is,
it accepts file's mapping,offset instead of struct page. Because
different file's mappings and o
The current dax_lock_page() locks dax entry by obtaining mapping and
index in page. To support 1-to-N RMAP in NVDIMM, we need a new function
to lock a specific dax entry corresponding to this file's mapping,index.
And BTW, output the page corresponding to the specific dax entry for
caller use.
Si
In order to introduce dax holder registration, we need a write lock for
dax. Because of the rarity of notification failures and the infrequency
of registration events, it would be better to be a global lock rather
than per-device. So, change the current lock to rwsem and introduce a
write lock fo
When memory-failure occurs, we call this function which is implemented
by each kind of devices. For the fsdax case, pmem device driver
implements it. Pmem device driver will find out the filesystem in which
the corrupted page located in.
With dax_holder notify support, we are able to notify the
To easily track filesystem from a pmem device, we introduce a holder for
dax_device structure, and also its operation. This holder is used to
remember who is using this dax_device:
- When it is the backend of a filesystem, the holder will be the
superblock of this filesystem.
- When this pmem
memory_failure_dev_pagemap code is a bit complex before introduce RMAP
feature for fsdax. So it is needed to factor some helper functions to
simplify these code.
Signed-off-by: Shiyang Ruan
---
mm/memory-failure.c | 140
1 file changed, 76 insertions
This patchset is aimed to support shared pages tracking for fsdax.
Changes from [V6 RESEND]:
- Move ->memory_failure() into the patch who implements it
- Change the parameter of ->memory_failure():
unsigned long nr_pfns -> size_t size
- Remove changes(2 patches) for mapped device
- A
This function is used to handle errors which may cause data lost in
filesystem. Such as memory failure in fsdax mode.
If the rmap feature of XFS enabled, we can query it to find files and
metadata which are associated with the corrupt data. For now all we do
is kill processes with that file mapp
For reflinked files, one dax page may be associated more than once with
different fime mapping and index. It will report warning. Now, since
we have introduced dax-RMAP for this case and also have to keep its
functionality for other filesystems who are not support rmap, I add this
exception here.
9 matches
Mail list logo