1. 13 May, 2022 5 commits
    • Jason A. Donenfeld's avatar
      parisc: define get_cycles macro for arch-override · 8865bbe6
      Jason A. Donenfeld authored
      PA-RISC defines a get_cycles() function, but it does not do the usual
      `#define get_cycles get_cycles` dance, making it impossible for generic
      code to see if an arch-specific function was defined. While the
      get_cycles() ifdef is not currently used, the following timekeeping
      patch in this series will depend on the macro existing (or not existing)
      when defining random_get_entropy().
      
      Cc: Thomas Gleixner <tglx@linutronix.de>
      Cc: Arnd Bergmann <arnd@arndb.de>
      Acked-by: default avatarHelge Deller <deller@gmx.de>
      Signed-off-by: default avatarJason A. Donenfeld <Jason@zx2c4.com>
      8865bbe6
    • Jason A. Donenfeld's avatar
      s390: define get_cycles macro for arch-override · 2e3df523
      Jason A. Donenfeld authored
      S390x defines a get_cycles() function, but it does not do the usual
      `#define get_cycles get_cycles` dance, making it impossible for generic
      code to see if an arch-specific function was defined. While the
      get_cycles() ifdef is not currently used, the following timekeeping
      patch in this series will depend on the macro existing (or not existing)
      when defining random_get_entropy().
      
      Cc: Thomas Gleixner <tglx@linutronix.de>
      Cc: Arnd Bergmann <arnd@arndb.de>
      Cc: Vasily Gorbik <gor@linux.ibm.com>
      Cc: Alexander Gordeev <agordeev@linux.ibm.com>
      Cc: Christian Borntraeger <borntraeger@linux.ibm.com>
      Cc: Sven Schnelle <svens@linux.ibm.com>
      Acked-by: default avatarHeiko Carstens <hca@linux.ibm.com>
      Signed-off-by: default avatarJason A. Donenfeld <Jason@zx2c4.com>
      2e3df523
    • Jason A. Donenfeld's avatar
      ia64: define get_cycles macro for arch-override · 57c0900b
      Jason A. Donenfeld authored
      Itanium defines a get_cycles() function, but it does not do the usual
      `#define get_cycles get_cycles` dance, making it impossible for generic
      code to see if an arch-specific function was defined. While the
      get_cycles() ifdef is not currently used, the following timekeeping
      patch in this series will depend on the macro existing (or not existing)
      when defining random_get_entropy().
      
      Cc: Thomas Gleixner <tglx@linutronix.de>
      Cc: Arnd Bergmann <arnd@arndb.de>
      Signed-off-by: default avatarJason A. Donenfeld <Jason@zx2c4.com>
      57c0900b
    • Jason A. Donenfeld's avatar
      init: call time_init() before rand_initialize() · fe222a6c
      Jason A. Donenfeld authored
      Currently time_init() is called after rand_initialize(), but
      rand_initialize() makes use of the timer on various platforms, and
      sometimes this timer needs to be initialized by time_init() first. In
      order for random_get_entropy() to not return zero during early boot when
      it's potentially used as an entropy source, reverse the order of these
      two calls. The block doing random initialization was right before
      time_init() before, so changing the order shouldn't have any complicated
      effects.
      
      Cc: Andrew Morton <akpm@linux-foundation.org>
      Reviewed-by: default avatarStafford Horne <shorne@gmail.com>
      Signed-off-by: default avatarJason A. Donenfeld <Jason@zx2c4.com>
      fe222a6c
    • Jason A. Donenfeld's avatar
      random: fix sysctl documentation nits · 069c4ea6
      Jason A. Donenfeld authored
      A semicolon was missing, and the almost-alphabetical-but-not ordering
      was confusing, so regroup these by category instead.
      Signed-off-by: default avatarJason A. Donenfeld <Jason@zx2c4.com>
      069c4ea6
  2. 08 May, 2022 24 commits
  3. 07 May, 2022 3 commits
  4. 06 May, 2022 8 commits
    • Linus Torvalds's avatar
      Merge tag 'for-5.18-rc5-tag' of git://git.kernel.org/pub/scm/linux/kernel/git/kdave/linux · 4b97bac0
      Linus Torvalds authored
      Pull btrfs fixes from David Sterba:
       "Regression fixes in zone activation:
      
         - move a loop invariant out of the loop to avoid checking space
           status
      
         - properly handle unlimited activation
      
        Other fixes:
      
         - for subpage, force the free space v2 mount to avoid a warning and
           make it easy to switch a filesystem on different page size systems
      
         - export sysfs status of exclusive operation 'balance paused', so the
           user space tools can recognize it and allow adding a device with
           paused balance
      
         - fix assertion failure when logging directory key range item"
      
      * tag 'for-5.18-rc5-tag' of git://git.kernel.org/pub/scm/linux/kernel/git/kdave/linux:
        btrfs: sysfs: export the balance paused state of exclusive operation
        btrfs: fix assertion failure when logging directory key range item
        btrfs: zoned: activate block group properly on unlimited active zone device
        btrfs: zoned: move non-changing condition check out of the loop
        btrfs: force v2 space cache usage for subpage mount
      4b97bac0
    • Linus Torvalds's avatar
      Merge tag 'nfs-for-5.18-3' of git://git.linux-nfs.org/projects/trondmy/linux-nfs · adcffc17
      Linus Torvalds authored
      Pull NFS client fixes from Trond Myklebust:
       "Highlights include:
      
        Stable fixes:
      
         - Fix a socket leak when setting up an AF_LOCAL RPC client
      
         - Ensure that knfsd connects to the gss-proxy daemon on setup
      
        Bugfixes:
      
         - Fix a refcount leak when migrating a task off an offlined transport
      
         - Don't gratuitously invalidate inode attributes on delegation return
      
         - Don't leak sockets in xs_local_connect()
      
         - Ensure timely close of disconnected AF_LOCAL sockets"
      
      * tag 'nfs-for-5.18-3' of git://git.linux-nfs.org/projects/trondmy/linux-nfs:
        Revert "SUNRPC: attempt AF_LOCAL connect on setup"
        SUNRPC: Ensure gss-proxy connects on setup
        SUNRPC: Ensure timely close of disconnected AF_LOCAL sockets
        SUNRPC: Don't leak sockets in xs_local_connect()
        NFSv4: Don't invalidate inode attributes on delegation return
        SUNRPC release the transport of a relocated task with an assigned transport
      adcffc17
    • Linus Torvalds's avatar
      Merge tag 'for-linus' of git://git.kernel.org/pub/scm/virt/kvm/kvm · bce58da1
      Linus Torvalds authored
      Pull kvm fixes from Paolo Bonzini:
       "x86:
      
         - Account for family 17h event renumberings in AMD PMU emulation
      
         - Remove CPUID leaf 0xA on AMD processors
      
         - Fix lockdep issue with locking all vCPUs
      
         - Fix loss of A/D bits in SPTEs
      
         - Fix syzkaller issue with invalid guest state"
      
      * tag 'for-linus' of git://git.kernel.org/pub/scm/virt/kvm/kvm:
        KVM: VMX: Exit to userspace if vCPU has injected exception and invalid state
        KVM: SEV: Mark nested locking of vcpu->lock
        kvm: x86/cpuid: Only provide CPUID leaf 0xA if host has architectural PMU
        KVM: x86/svm: Account for family 17h event renumberings in amd_pmc_perf_hw_id
        KVM: x86/mmu: Use atomic XCHG to write TDP MMU SPTEs with volatile bits
        KVM: x86/mmu: Move shadow-present check out of spte_has_volatile_bits()
        KVM: x86/mmu: Don't treat fully writable SPTEs as volatile (modulo A/D)
      bce58da1
    • Linus Torvalds's avatar
      Merge tag 'riscv-for-linus-5.18-rc6' of git://git.kernel.org/pub/scm/linux/kernel/git/riscv/linux · 497fe3bb
      Linus Torvalds authored
      Pull RISC-V fix from Palmer Dabbelt:
      
       - A fix to relocate the DTB early in boot, in cases where the
         bootloader doesn't put the DTB in a region that will end up
         mapped by the kernel.
      
         This manifests as a crash early in boot on a handful of
         configurations.
      
      * tag 'riscv-for-linus-5.18-rc6' of git://git.kernel.org/pub/scm/linux/kernel/git/riscv/linux:
        RISC-V: relocate DTB if it's outside memory region
      497fe3bb
    • Sean Christopherson's avatar
      KVM: VMX: Exit to userspace if vCPU has injected exception and invalid state · 053d2290
      Sean Christopherson authored
      Exit to userspace with an emulation error if KVM encounters an injected
      exception with invalid guest state, in addition to the existing check of
      bailing if there's a pending exception (KVM doesn't support emulating
      exceptions except when emulating real mode via vm86).
      
      In theory, KVM should never get to such a situation as KVM is supposed to
      exit to userspace before injecting an exception with invalid guest state.
      But in practice, userspace can intervene and manually inject an exception
      and/or stuff registers to force invalid guest state while a previously
      injected exception is awaiting reinjection.
      
      Fixes: fc4fad79 ("KVM: VMX: Reject KVM_RUN if emulation is required with pending exception")
      Reported-by: syzbot+cfafed3bb76d3e37581b@syzkaller.appspotmail.com
      Signed-off-by: default avatarSean Christopherson <seanjc@google.com>
      Message-Id: <20220502221850.131873-1-seanjc@google.com>
      Signed-off-by: default avatarPaolo Bonzini <pbonzini@redhat.com>
      053d2290
    • Peter Gonda's avatar
      KVM: SEV: Mark nested locking of vcpu->lock · 0c2c7c06
      Peter Gonda authored
      svm_vm_migrate_from() uses sev_lock_vcpus_for_migration() to lock all
      source and target vcpu->locks. Unfortunately there is an 8 subclass
      limit, so a new subclass cannot be used for each vCPU. Instead maintain
      ownership of the first vcpu's mutex.dep_map using a role specific
      subclass: source vs target. Release the other vcpu's mutex.dep_maps.
      
      Fixes: b5663931 ("KVM: SEV: Add support for SEV intra host migration")
      Reported-by: John Sperbeck<jsperbeck@google.com>
      Suggested-by: default avatarDavid Rientjes <rientjes@google.com>
      Suggested-by: default avatarSean Christopherson <seanjc@google.com>
      Suggested-by: default avatarPaolo Bonzini <pbonzini@redhat.com>
      Cc: Hillf Danton <hdanton@sina.com>
      Cc: kvm@vger.kernel.org
      Cc: linux-kernel@vger.kernel.org
      Signed-off-by: default avatarPeter Gonda <pgonda@google.com>
      
      Message-Id: <20220502165807.529624-1-pgonda@google.com>
      Signed-off-by: default avatarPaolo Bonzini <pbonzini@redhat.com>
      0c2c7c06
    • Linus Torvalds's avatar
      Merge tag 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/rdma/rdma · 4df22ca8
      Linus Torvalds authored
      Pull rdma fixes from Jason Gunthorpe:
       "A few recent regressions in rxe's multicast code, and some old driver
        bugs:
      
         - Error case unwind bug in rxe for rkeys
      
         - Dot not call netdev functions under a spinlock in rxe multicast
           code
      
         - Use the proper BH lock type in rxe multicast code
      
         - Fix idrma deadlock and crash
      
         - Add a missing flush to drain irdma QPs when in error
      
         - Fix high userspace latency in irdma during destroy due to
           synchronize_rcu()
      
         - Rare race in siw MPA processing"
      
      * tag 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/rdma/rdma:
        RDMA/rxe: Change mcg_lock to a _bh lock
        RDMA/rxe: Do not call  dev_mc_add/del() under a spinlock
        RDMA/siw: Fix a condition race issue in MPA request processing
        RDMA/irdma: Fix possible crash due to NULL netdev in notifier
        RDMA/irdma: Reduce iWARP QP destroy time
        RDMA/irdma: Flush iWARP QP if modified to ERR from RTR state
        RDMA/rxe: Recheck the MR in when generating a READ reply
        RDMA/irdma: Fix deadlock in irdma_cleanup_cm_core()
        RDMA/rxe: Fix "Replace mr by rkey in responder resources"
      4df22ca8
    • Linus Torvalds's avatar
      Merge tag 'mmc-v5.18-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/ulfh/mmc · 64267926
      Linus Torvalds authored
      Pull mmc fixes from Ulf Hansson:
       "MMC core:
      
         - Fix initialization for eMMC's HS200/HS400 mode
      
        MMC host:
      
         - sdhci-msm: Reset GCC_SDCC_BCR register to prevent timeout issues
      
         - sunxi-mmc: Fix DMA descriptors allocated above 32 bits"
      
      * tag 'mmc-v5.18-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/ulfh/mmc:
        mmc: sdhci-msm: Reset GCC_SDCC_BCR register for SDHC
        mmc: sunxi-mmc: Fix DMA descriptors allocated above 32 bits
        mmc: core: Set HS clock speed before sending HS CMD13
      64267926