diff options
author | Darrick J. Wong <darrick.wong@oracle.com> | 2019-08-14 17:38:09 -0700 |
---|---|---|
committer | Darrick J. Wong <darrick.wong@oracle.com> | 2019-08-18 18:53:25 -0700 |
commit | 5d888b481e6abc726b36c86f0bf13af1583bb336 (patch) | |
tree | 902c57ac0fe14c9693ab36bd943de335eb23fc6d /arch/arm/mm/alignment.c | |
parent | edc58dd0123b552453a74369bd0c8d890b497b4b (diff) | |
download | linux-5d888b481e6abc726b36c86f0bf13af1583bb336.tar.bz2 |
xfs: fix reflink source file racing with directio writes
While trawling through the dedupe file comparison code trying to fix
page deadlocking problems, Dave Chinner noticed that the reflink code
only takes shared IOLOCK/MMAPLOCKs on the source file. Because
page_mkwrite and directio writes do not take the EXCL versions of those
locks, this means that reflink can race with writer processes.
For pure remapping this can lead to undefined behavior and file
corruption; for dedupe this means that we cannot be sure that the
contents are identical when we decide to go ahead with the remapping.
Signed-off-by: Darrick J. Wong <darrick.wong@oracle.com>
Reviewed-by: Christoph Hellwig <hch@lst.de>
Diffstat (limited to 'arch/arm/mm/alignment.c')
0 files changed, 0 insertions, 0 deletions