zfs icon indicating copy to clipboard operation
zfs copied to clipboard

[2.1.11 backport] Fix buffered/direct/mmap I/O race

Open robn opened this issue 2 years ago • 2 comments

Description

Backporting #14498 and #14534 to 2.1.

How Has This Been Tested?

Compiles OK. Test suite will do the rest.

Types of changes

  • [x] Bug fix (non-breaking change which fixes an issue)
  • [ ] New feature (non-breaking change which adds functionality)
  • [ ] Performance enhancement (non-breaking change which improves efficiency)
  • [ ] Code cleanup (non-breaking change which makes code smaller or more readable)
  • [ ] Breaking change (fix or feature that would cause existing functionality to change)
  • [ ] Library ABI change (libzfs, libzfs_core, libnvpair, libuutil and libzfsbootenv)
  • [ ] Documentation (a change to man pages or other documentation)

Checklist:

  • [x] My code follows the OpenZFS code style requirements.
  • [ ] I have updated the documentation accordingly.
  • [x] I have read the contributing document.
  • [x] I have added tests to cover my changes.
  • [ ] I have run the ZFS Test Suite with this change applied.
  • [x] All commit messages are properly formatted and contain Signed-off-by.

robn avatar Apr 15 '23 04:04 robn

We should also include dd108f5d73e241a7a3fa836e5c3322a10d135a5c, which fixes the static analyzer complaint about what should be a real bug that occurs after this is merged.

ryao avatar Apr 16 '23 03:04 ryao

We should also include dd108f5, which fixes the static analyzer complaint about what should be a real bug that occurs after this is merged.

Good call! I've picked that commit and pushed it here. Thanks!

robn avatar Apr 16 '23 03:04 robn

Can you rebase this on the new zfs-2.1.12-staging. branch.

behlendorf avatar Apr 20 '23 17:04 behlendorf

@behlendorf done, thanks.

robn avatar Apr 20 '23 21:04 robn