1. 01 Apr, 2021 2 commits
    • Paolo Bonzini's avatar
      KVM: SVM: ensure that EFER.SVME is set when running nested guest or on nested vmexit · 3c346c0c
      Paolo Bonzini authored
      Fixing nested_vmcb_check_save to avoid all TOC/TOU races
      is a bit harder in released kernels, so do the bare minimum
      by avoiding that EFER.SVME is cleared.  This is problematic
      because svm_set_efer frees the data structures for nested
      virtualization if EFER.SVME is cleared.
      
      Also check that EFER.SVME remains set after a nested vmexit;
      clearing it could happen if the bit is zero in the save area
      that is passed to KVM_SET_NESTED_STATE (the save area of the
      nested state corresponds to the nested hypervisor's state
      and is restored on the next nested vmexit).
      
      Cc: stable@vger.kernel.org
      Fixes: 2fcf4876 ("KVM: nSVM: implement on demand allocation of the nested state")
      Signed-off-by: default avatarPaolo Bonzini <pbonzini@redhat.com>
      3c346c0c
    • Paolo Bonzini's avatar
      KVM: SVM: load control fields from VMCB12 before checking them · a58d9166
      Paolo Bonzini authored
      Avoid races between check and use of the nested VMCB controls.  This
      for example ensures that the VMRUN intercept is always reflected to the
      nested hypervisor, instead of being processed by the host.  Without this
      patch, it is possible to end up with svm->nested.hsave pointing to
      the MSR permission bitmap for nested guests.
      
      This bug is CVE-2021-29657.
      Reported-by: default avatarFelix Wilhelm <fwilhelm@google.com>
      Cc: stable@vger.kernel.org
      Fixes: 2fcf4876 ("KVM: nSVM: implement on demand allocation of the nested state")
      Signed-off-by: default avatarPaolo Bonzini <pbonzini@redhat.com>
      a58d9166
  2. 13 Dec, 2020 3 commits
    • Linus Torvalds's avatar
      Linux 5.10 · 2c85ebc5
      Linus Torvalds authored
      2c85ebc5
    • Linus Torvalds's avatar
      Merge tag 'x86-urgent-2020-12-13' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip · ec6f5e0e
      Linus Torvalds authored
      Pull x86 fixes from Thomas Gleixner:
       "A set of x86 and membarrier fixes:
      
         - Correct a few problems in the x86 and the generic membarrier
           implementation. Small corrections for assumptions about visibility
           which have turned out not to be true.
      
         - Make the PAT bits for memory encryption correct vs 4K and 2M/1G
           page table entries as they are at a different location.
      
         - Fix a concurrency issue in the the local bandwidth readout of
           resource control leading to incorrect values
      
         - Fix the ordering of allocating a vector for an interrupt. The order
           missed to respect the provided cpumask when the first attempt of
           allocating node local in the mask fails. It then tries the node
           instead of trying the full provided mask first. This leads to
           erroneous error messages and breaking the (user) supplied affinity
           request. Reorder it.
      
         - Make the INT3 padding detection in optprobe work correctly"
      
      * tag 'x86-urgent-2020-12-13' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip:
        x86/kprobes: Fix optprobe to detect INT3 padding correctly
        x86/apic/vector: Fix ordering in vector assignment
        x86/resctrl: Fix incorrect local bandwidth when mba_sc is enabled
        x86/mm/mem_encrypt: Fix definition of PMD_FLAGS_DEC_WP
        membarrier: Execute SYNC_CORE on the calling thread
        membarrier: Explicitly sync remote cores when SYNC_CORE is requested
        membarrier: Add an actual barrier before rseq_preempt()
        x86/membarrier: Get rid of a dubious optimization
      ec6f5e0e
    • Linus Torvalds's avatar
      Merge tag 'block-5.10-2020-12-12' of git://git.kernel.dk/linux-block · d2360a39
      Linus Torvalds authored
      Pull block fixes from Jens Axboe:
       "This should be it for 5.10.
      
        Mike and Song looked into the warning case, and thankfully it appears
        the fix was pretty trivial - we can just change the md device chunk
        type to unsigned int to get rid of it. They cannot currently be < 0,
        and nobody is checking for that either.
      
        We're reverting the discard changes as the corruption reports came in
        very late, and there's just no time to attempt to deal with it at this
        point. Reverting the changes in question is the right call for 5.10"
      
      * tag 'block-5.10-2020-12-12' of git://git.kernel.dk/linux-block:
        md: change mddev 'chunk_sectors' from int to unsigned
        Revert "md: add md_submit_discard_bio() for submitting discard bio"
        Revert "md/raid10: extend r10bio devs to raid disks"
        Revert "md/raid10: pull codes that wait for blocked dev into one function"
        Revert "md/raid10: improve raid10 discard request"
        Revert "md/raid10: improve discard request for far layout"
        Revert "dm raid: remove unnecessary discard limits for raid10"
      d2360a39
  3. 12 Dec, 2020 12 commits
  4. 11 Dec, 2020 23 commits