1. 11 8月, 2021 6 次提交
  2. 03 8月, 2021 1 次提交
  3. 29 6月, 2021 1 次提交
  4. 26 6月, 2021 2 次提交
  5. 22 6月, 2021 1 次提交
  6. 17 6月, 2021 1 次提交
  7. 16 6月, 2021 1 次提交
  8. 14 6月, 2021 3 次提交
  9. 05 6月, 2021 2 次提交
  10. 27 3月, 2021 1 次提交
  11. 11 3月, 2021 1 次提交
  12. 10 2月, 2021 2 次提交
  13. 09 2月, 2021 1 次提交
  14. 03 2月, 2021 2 次提交
  15. 02 12月, 2020 1 次提交
  16. 17 11月, 2020 2 次提交
  17. 06 10月, 2020 1 次提交
    • D
      x86, powerpc: Rename memcpy_mcsafe() to copy_mc_to_{user, kernel}() · ec6347bb
      Dan Williams 提交于
      In reaction to a proposal to introduce a memcpy_mcsafe_fast()
      implementation Linus points out that memcpy_mcsafe() is poorly named
      relative to communicating the scope of the interface. Specifically what
      addresses are valid to pass as source, destination, and what faults /
      exceptions are handled.
      
      Of particular concern is that even though x86 might be able to handle
      the semantics of copy_mc_to_user() with its common copy_user_generic()
      implementation other archs likely need / want an explicit path for this
      case:
      
        On Fri, May 1, 2020 at 11:28 AM Linus Torvalds <torvalds@linux-foundation.org> wrote:
        >
        > On Thu, Apr 30, 2020 at 6:21 PM Dan Williams <dan.j.williams@intel.com> wrote:
        > >
        > > However now I see that copy_user_generic() works for the wrong reason.
        > > It works because the exception on the source address due to poison
        > > looks no different than a write fault on the user address to the
        > > caller, it's still just a short copy. So it makes copy_to_user() work
        > > for the wrong reason relative to the name.
        >
        > Right.
        >
        > And it won't work that way on other architectures. On x86, we have a
        > generic function that can take faults on either side, and we use it
        > for both cases (and for the "in_user" case too), but that's an
        > artifact of the architecture oddity.
        >
        > In fact, it's probably wrong even on x86 - because it can hide bugs -
        > but writing those things is painful enough that everybody prefers
        > having just one function.
      
      Replace a single top-level memcpy_mcsafe() with either
      copy_mc_to_user(), or copy_mc_to_kernel().
      
      Introduce an x86 copy_mc_fragile() name as the rename for the
      low-level x86 implementation formerly named memcpy_mcsafe(). It is used
      as the slow / careful backend that is supplanted by a fast
      copy_mc_generic() in a follow-on patch.
      
      One side-effect of this reorganization is that separating copy_mc_64.S
      to its own file means that perf no longer needs to track dependencies
      for its memcpy_64.S benchmarks.
      
       [ bp: Massage a bit. ]
      Signed-off-by: NDan Williams <dan.j.williams@intel.com>
      Signed-off-by: NBorislav Petkov <bp@suse.de>
      Reviewed-by: NTony Luck <tony.luck@intel.com>
      Acked-by: NMichael Ellerman <mpe@ellerman.id.au>
      Cc: <stable@vger.kernel.org>
      Link: http://lore.kernel.org/r/CAHk-=wjSqtXAqfUJxFtWNwmguFASTgB0dz1dT3V-78Quiezqbg@mail.gmail.com
      Link: https://lkml.kernel.org/r/160195561680.2163339.11574962055305783722.stgit@dwillia2-desk3.amr.corp.intel.com
      ec6347bb
  18. 02 9月, 2020 1 次提交
  19. 17 7月, 2020 1 次提交
  20. 16 7月, 2020 1 次提交
  21. 08 7月, 2020 1 次提交
  22. 01 7月, 2020 1 次提交
  23. 20 6月, 2020 1 次提交
  24. 18 6月, 2020 2 次提交
  25. 15 5月, 2020 2 次提交
  26. 17 4月, 2020 1 次提交
    • M
      dm writecache: fix data corruption when reloading the target · 31b22120
      Mikulas Patocka 提交于
      The dm-writecache reads metadata in the target constructor. However, when
      we reload the target, there could be another active instance running on
      the same device. This is the sequence of operations when doing a reload:
      
      1. construct new target
      2. suspend old target
      3. resume new target
      4. destroy old target
      
      Metadata that were written by the old target between steps 1 and 2 would
      not be visible by the new target.
      
      Fix the data corruption by loading the metadata in the resume handler.
      
      Also, validate block_size is at least as large as both the devices'
      logical block size and only read 1 block from the metadata during
      target constructor -- no need to read entirety of metadata now that it
      is done during resume.
      
      Fixes: 48debafe ("dm: add writecache target")
      Cc: stable@vger.kernel.org # v4.18+
      Signed-off-by: NMikulas Patocka <mpatocka@redhat.com>
      Signed-off-by: NMike Snitzer <snitzer@redhat.com>
      31b22120