Commit graph

1251184 commits

Author SHA1 Message Date
Paolo Bonzini
a81d95ae8c KVM async page fault changes for 6.9:
- Always flush the async page fault workqueue when a work item is being
    removed, especially during vCPU destruction, to ensure that there are no
    workers running in KVM code when all references to KVM-the-module are gone,
    i.e. to prevent a use-after-free if kvm.ko is unloaded.
 
  - Grab a reference to the VM's mm_struct in the async #PF worker itself instead
    of gifting the worker a reference, e.g. so that there's no need to remember
    to *conditionally* clean up after the worker.
 -----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCgAdFiEEKTobbabEP7vbhhN9OlYIJqCjN/0FAmXrhPAACgkQOlYIJqCj
 N/3gYQ/+KIMCqcckstiHOu8euOVBt8yZSeIb7vYuu8gpAH2Z1UsvIfF4O4d0uFzz
 9KCaMi+/F62CfT2FUHDjxI33FqN/mPIV+lP6LTeYEnmYtBWM7SmqNWpidKcbLxnp
 IJ6lSuxTEjkJSA0lDb7f49ctEFXr6VadklTQbGrTSeyWmhoipXWkPGjGj7R9gMPM
 dXaRWFTKm95bkrir656cZQngivzqzrFqI+fez9eK0dMDCmCSyTZ1YmqWc0w2KiiV
 oCjRWJqfCRd6+6reN/bYsMOFQ/BWnZlrTnWNOQMMdg9VHGaKvMjsHUcHfira04qU
 uZgHbSTLJLyOIhRSS0l+iIgBylWZMg7QUepcSQwbf2iAtK7W0NeXgWqArl01KZDg
 0eiHSSh4QKKjEgcw1MFRY/8WQtz2xPTCc1cnJ1m4Z2pm0+qscdQitdcSmkgClGMb
 sXbiNC0C8H6fJd0BfuwvtSAl5vT1C0qT8tL55Ca6zwMSZjmOiwcisWn1QAyFGuog
 n0k/7hF4LCJliK3uy+j7NAp0OGaV32ysSm5s1mzm/ezQVacjcntidp3cgN7UYmGn
 cwIhhAVEN7njK2V9dXz5/s7f7S6eE9O/oIeF9nWWyqb53b50122ZxXP23Q6dUTAT
 XpUbim6XgI6vdcwafgl89kFxho6ZYftoerfnwJUMHGuAsVN8omA=
 =J5Ug
 -----END PGP SIGNATURE-----

Merge tag 'kvm-x86-asyncpf-6.9' of https://github.com/kvm-x86/linux into HEAD

KVM async page fault changes for 6.9:

 - Always flush the async page fault workqueue when a work item is being
   removed, especially during vCPU destruction, to ensure that there are no
   workers running in KVM code when all references to KVM-the-module are gone,
   i.e. to prevent a use-after-free if kvm.ko is unloaded.

 - Grab a reference to the VM's mm_struct in the async #PF worker itself instead
   of gifting the worker a reference, e.g. so that there's no need to remember
   to *conditionally* clean up after the worker.
2024-03-11 10:22:41 -04:00
Paolo Bonzini
4d4c02852a KVM selftests changes for 6.9:
- Add macros to reduce the amount of boilerplate code needed to write "simple"
    selftests, and to utilize selftest TAP infrastructure, which is especially
    beneficial for KVM selftests with multiple testcases.
 
  - Add basic smoke tests for SEV and SEV-ES, along with a pile of library
    support for handling private/encrypted/protected memory.
 
  - Fix benign bugs where tests neglect to close() guest_memfd files.
 -----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCgAdFiEEKTobbabEP7vbhhN9OlYIJqCjN/0FAmXrUT8ACgkQOlYIJqCj
 N/0azBAAkjVan7STJkDkyoSJAfXbGLFtt1SrSi7886siW+IVIwINyHAdqFbJG8h/
 OXSfkQ6Mu4GY27qmuPqAbfVksb6ccAd0SdEDNixtErs2qU4BJvAiNfxxJlfx9b0f
 IGhN5mNNcxC4LosEIXZJRI9QPfXsxWkiXvShJ7qQmGXx1/oZGMCTyL6L6Bpqz4PV
 PDUAgeQDME1G0uw2AbN5pl9yS1Macl1R5Z0FjXs7pHu/Qy05fn3Afb1UsC4LfcW6
 BTUgD4NYamaBOjzgiOzjBZCAL6ee3ZUx+Wy0ohfM2Ewm/MSArPt3SRuIck07bmUu
 FRuAKvb0q4Mc6uL9mvxP5t5aowP/2IIb1qR1DakXbXqSIVS4+yQzRhJqaVKdIRuD
 KXnxUFXqZ0QOLTgoWRK8fRVwMJWT0kFskNaAmDhcIoWVPxlvGjlXLSYncLIYTeic
 qC4Da02p+DSatw+GeONh3Eh2LUfyHuET5Wjb6GVsPr12IAx4KREUWJLShjHtF4FZ
 cXncKS6DCT3X5EjoruXgxYYKNoYG0S4ied8G0xE8El/i/O8X8IyeJu6sisdYZF/G
 SYpdooF+jnJeMq5eivL+WlaThOVcMpPeNp9fmU3g/TUTn/fIGpBtMf+goZG5jFLz
 pzLucXYehpsx28duyEC5SckdVJQ36J5EwZ/ybB35hh6NadMm7LM=
 =x6+F
 -----END PGP SIGNATURE-----

Merge tag 'kvm-x86-selftests-6.9' of https://github.com/kvm-x86/linux into HEAD

KVM selftests changes for 6.9:

 - Add macros to reduce the amount of boilerplate code needed to write "simple"
   selftests, and to utilize selftest TAP infrastructure, which is especially
   beneficial for KVM selftests with multiple testcases.

 - Add basic smoke tests for SEV and SEV-ES, along with a pile of library
   support for handling private/encrypted/protected memory.

 - Fix benign bugs where tests neglect to close() guest_memfd files.
2024-03-11 10:20:35 -04:00
Paolo Bonzini
f074158a0d KVM/riscv changes for 6.9
- Exception and interrupt handling for selftests
 - Sstc (aka arch_timer) selftest
 - Forward seed CSR access to KVM userspace
 - Ztso extension support for Guest/VM
 - Zacas extension support for Guest/VM
 -----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCgAdFiEEZdn75s5e6LHDQ+f/rUjsVaLHLAcFAmXpXfMACgkQrUjsVaLH
 LAfZoRAAgIJqgL9jMQ2dliTq8sk24dQQUPo1V2yP7yEYLeUyp/9EAR31ZhBDP1EE
 yTT0yvEbyn21fxhdHagVnqJXOepHz1MPmGGxEFx96RVib/m80zDhyDKogW6IgP4c
 e9yXW1Wo6m0R+7aQhn8YA9+47xbmq/cNDCwjlkIp0oL/SyktJdTcPjZUTr524jde
 dYTGLqSyoQyZMm+wBrJYTiME6nFK3RhKf7V9Mn77VTTFnhIk4J2upl+1kE2pLTAQ
 Zp3EwXCK1B2D2J1bdOuqclCApglw3H0CM4c81knDaEyB4w/l/OwpuCA+u58tSU9g
 z6DTO+vYvwlROmfeFjjmHKx1pl9uSktYlFlVqinelW7IG7Y3qDD1zPnbT27OpkLP
 rFIsF4Dm42MnmcC0sTxaMgKQtMvb56lgpaoa9XHL/DD76pAUvgKoWUnWay+32j1e
 8Hhx/PEp16ALGvDfm+9Wo8AgbvrFGl37epe2LXFFr6+zOzmGN+6vATW2EqgJ3Ueo
 P5TNkcFSyKg61r0moEr/ZSKZNvv8MuVUKSe0EmPykIccqg6oYHAoAJ66FL5yaX1k
 n/aIVNnIavzwlN6DeaQyjAxZxfSg39Z7wOH5PyKmateYKg9yM8P3RY/DndiO6F3c
 me9Q0eshu+C7h4YBRXPVstdWkkhCSVa+TN1b/6hnlSP0HLtyHik=
 =cWpl
 -----END PGP SIGNATURE-----

Merge tag 'kvm-riscv-6.9-1' of https://github.com/kvm-riscv/linux into HEAD

KVM/riscv changes for 6.9

- Exception and interrupt handling for selftests
- Sstc (aka arch_timer) selftest
- Forward seed CSR access to KVM userspace
- Ztso extension support for Guest/VM
- Zacas extension support for Guest/VM
2024-03-11 10:10:48 -04:00
Paolo Bonzini
961e2bfcf3 KVM/arm64 updates for 6.9
- Infrastructure for building KVM's trap configuration based on the
    architectural features (or lack thereof) advertised in the VM's ID
    registers
 
  - Support for mapping vfio-pci BARs as Normal-NC (vaguely similar to
    x86's WC) at stage-2, improving the performance of interacting with
    assigned devices that can tolerate it
 
  - Conversion of KVM's representation of LPIs to an xarray, utilized to
    address serialization some of the serialization on the LPI injection
    path
 
  - Support for _architectural_ VHE-only systems, advertised through the
    absence of FEAT_E2H0 in the CPU's ID register
 
  - Miscellaneous cleanups, fixes, and spelling corrections to KVM and
    selftests
 -----BEGIN PGP SIGNATURE-----
 
 iHUEABYIAB0WIQSNXHjWXuzMZutrKNKivnWIJHzdFgUCZepBjgAKCRCivnWIJHzd
 FnngAP93VxjCkJ+5qSmYpFNG6r0ECVIbLHFQ59nKn0+GgvbPEgEAwt8svdLdW06h
 njFTpdzvl4Po+aD/V9xHgqVz3kVvZwE=
 =1FbW
 -----END PGP SIGNATURE-----

Merge tag 'kvmarm-6.9' of https://git.kernel.org/pub/scm/linux/kernel/git/kvmarm/kvmarm into HEAD

KVM/arm64 updates for 6.9

 - Infrastructure for building KVM's trap configuration based on the
   architectural features (or lack thereof) advertised in the VM's ID
   registers

 - Support for mapping vfio-pci BARs as Normal-NC (vaguely similar to
   x86's WC) at stage-2, improving the performance of interacting with
   assigned devices that can tolerate it

 - Conversion of KVM's representation of LPIs to an xarray, utilized to
   address serialization some of the serialization on the LPI injection
   path

 - Support for _architectural_ VHE-only systems, advertised through the
   absence of FEAT_E2H0 in the CPU's ID register

 - Miscellaneous cleanups, fixes, and spelling corrections to KVM and
   selftests
2024-03-11 10:02:32 -04:00
Paolo Bonzini
233d0bc4d8 LoongArch KVM changes for v6.9
1. Set reserved bits as zero in CPUCFG.
 2. Start SW timer only when vcpu is blocking.
 3. Do not restart SW timer when it is expired.
 4. Remove unnecessary CSR register saving during enter guest.
 -----BEGIN PGP SIGNATURE-----
 
 iQJKBAABCAA0FiEEzOlt8mkP+tbeiYy5AoYrw/LiJnoFAmXoeWIWHGNoZW5odWFj
 YWlAa2VybmVsLm9yZwAKCRAChivD8uImehb3D/9C5IrdyU/2f3fEUuuXO0a2ZS1p
 l2OT+yr7C6/jATokGcd+53CF8MzYawzuAT3tSXYyoqAxRu0HUkvuS1oA/eFM4EwV
 iIoUC3jnqcsQ5LCPt6yt+Tzgug64Xm5F4btYWIpmXgCJWx/VVG6+z3JarXAfA2it
 vgVMGgrrfHt68sEsenNFNgiJ5tCCubjR7XFwjM8rsL7AzUDdmXpF7gFyH2Ufgosi
 a5CxcPPauO1y5ZCGU4JU9QvxnVqW1kt/TRZIGqqGfULtlBSoZbD9zP3OcCQkL+ai
 SPNxvU5I+BeX6honpmO6aR/F1EphQhRji3ZKxI8UBo4aJD5+FtMG/YOEPI+ZAS0/
 JPuWpDqJH46SN3jfKTQay8jXc+mcnOYXJ9Yrixd4UCf66WJit/+BOma/wP638u2j
 RUzm1kqhNGad6QiDDtSjISM6sg6FozAGc/KhCkWAhV+lHLnfkXtaf3S+GIu5OiWz
 ETCKlmIGiy0y774+iftlD7RDRGmtrC4cx5ibl7cKKi62Y5vgujCdDofAyYC+D5cW
 puaIuHOx1hWtPRT9p1WfUL310ED+Qj3N2pDDcJcqdCIiRRZ5l/hxGS7V687a30WV
 GcegEqh19CjI9KDat4E1ld4jUHJxaFrw3pr2z3SP7cW3IgdngPJL57M0M2jSazaQ
 479xZPJ/i4xhJaKACg==
 =8HOW
 -----END PGP SIGNATURE-----

Merge tag 'loongarch-kvm-6.9' of git://git.kernel.org/pub/scm/linux/kernel/git/chenhuacai/linux-loongson into HEAD

LoongArch KVM changes for v6.9

* Set reserved bits as zero in CPUCFG.
* Start SW timer only when vcpu is blocking.
* Do not restart SW timer when it is expired.
* Remove unnecessary CSR register saving during enter guest.
2024-03-11 09:56:54 -04:00
Paolo Bonzini
7d8942d8e7 KVM GUEST_MEMFD fixes for 6.8:
- Make KVM_MEM_GUEST_MEMFD mutually exclusive with KVM_MEM_READONLY to
    avoid creating ABI that KVM can't sanely support.
 
  - Update documentation for KVM_SW_PROTECTED_VM to make it abundantly
    clear that such VMs are purely a development and testing vehicle, and
    come with zero guarantees.
 
  - Limit KVM_SW_PROTECTED_VM guests to the TDP MMU, as the long term plan
    is to support confidential VMs with deterministic private memory (SNP
    and TDX) only in the TDP MMU.
 
  - Fix a bug in a GUEST_MEMFD negative test that resulted in false passes
    when verifying that KVM_MEM_GUEST_MEMFD memslots can't be dirty logged.
 -----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCgAdFiEEKTobbabEP7vbhhN9OlYIJqCjN/0FAmXZB/8ACgkQOlYIJqCj
 N/3XlQ//RIsvqr38k7kELSKhCMyWgF4J57itABrHpMqAZu3gaAo5sETX8AGcHEe5
 mxmquxyNQSf4cthhWy1kzxjGCy6+fk+Z0Z7wzfz0Yd5D+FI6vpo3HhkjovLb2gpt
 kSrHuhJyuj2vkftNvdaz0nHX1QalVyIEnXnR3oqTmxUUsg6lp1x/zr5SP0KBXjo8
 ZzJtyFd0fkRXWpA792T7XPRBWrzPV31HYZBLX8sPlYmJATcbIx9rYSThgCN6XuVN
 bfE6wATsC+mwv5BpCoDFpCKmFcqSqamag9NGe5qE5mOby5DQGYTCRMCQB8YXXBR0
 97ppaY9ZJV4nOVjrYJn6IMOSMVNfoG7nTRFfcd0eFP4tlPEgHwGr5BGDaBtQPkrd
 KcgWJw8nS02eCA2iOE+FtCXvGJwKhTTjQ45w7rU4EcfUk603L5J4GO1ddmjMhPcP
 upGGcWDK9vCGrSUFTm8pyWp/NKRJPvAQEiQd/BweSk9+isQHTX2RYCQgPAQnwlTS
 wTg7ZPNSLoUkRYmd6r+TUT32ELJGNc8GLftMnxIwweq6V7AgNMi0HE60eMovuBNO
 7DAWWzfBEZmJv+0mNNZPGXczHVv4YvMWysRdKkhztBc3+sO7P3AL1zWIDlm5qwoG
 LpFeeI3qo3o5ZNaqGzkSop2pUUGNGpWCH46WmP0AG7RpzW/Natw=
 =M0td
 -----END PGP SIGNATURE-----

Merge tag 'kvm-x86-guest_memfd_fixes-6.8' of https://github.com/kvm-x86/linux into HEAD

KVM GUEST_MEMFD fixes for 6.8:

 - Make KVM_MEM_GUEST_MEMFD mutually exclusive with KVM_MEM_READONLY to
   avoid creating ABI that KVM can't sanely support.

 - Update documentation for KVM_SW_PROTECTED_VM to make it abundantly
   clear that such VMs are purely a development and testing vehicle, and
   come with zero guarantees.

 - Limit KVM_SW_PROTECTED_VM guests to the TDP MMU, as the long term plan
   is to support confidential VMs with deterministic private memory (SNP
   and TDX) only in the TDP MMU.

 - Fix a bug in a GUEST_MEMFD negative test that resulted in false passes
   when verifying that KVM_MEM_GUEST_MEMFD memslots can't be dirty logged.
2024-03-09 11:48:35 -05:00
Oliver Upton
4a09ddb833 Merge branch kvm-arm64/kerneldoc into kvmarm/next
* kvm-arm64/kerneldoc:
  : kerneldoc warning fixes, courtesy of Randy Dunlap
  :
  : Fixes addressing the widespread misuse of kerneldoc-style comments
  : throughout KVM/arm64.
  KVM: arm64: vgic: fix a kernel-doc warning
  KVM: arm64: vgic-its: fix kernel-doc warnings
  KVM: arm64: vgic-init: fix a kernel-doc warning
  KVM: arm64: sys_regs: fix kernel-doc warnings
  KVM: arm64: PMU: fix kernel-doc warnings
  KVM: arm64: mmu: fix a kernel-doc warning
  KVM: arm64: vhe: fix a kernel-doc warning
  KVM: arm64: hyp/aarch32: fix kernel-doc warnings
  KVM: arm64: guest: fix kernel-doc warnings
  KVM: arm64: debug: fix kernel-doc warnings

Signed-off-by: Oliver Upton <oliver.upton@linux.dev>
2024-03-07 00:56:16 +00:00
Oliver Upton
9bd8d7df19 Merge branch kvm-arm64/vfio-normal-nc into kvmarm/next
* kvm-arm64/vfio-normal-nc:
  : Normal-NC support for vfio-pci @ stage-2, courtesy of Ankit Agrawal
  :
  : KVM's policy to date has been that any and all MMIO mapping at stage-2
  : is treated as Device-nGnRE. This is primarily done due to concerns of
  : the guest triggering uncontainable failures in the system if they manage
  : to tickle the device / memory system the wrong way, though this is
  : unnecessarily restrictive for devices that can be reasoned as 'safe'.
  :
  : Unsurprisingly, the Device-* mapping can really hurt the performance of
  : assigned devices that can handle Gathering, and can be an outright
  : correctness issue if the guest driver does unaligned accesses.
  :
  : Rather than opening the floodgates to the full ecosystem of devices that
  : can be exposed to VMs, take the conservative approach and allow PCI
  : devices to be mapped as Normal-NC since it has been determined to be
  : 'safe'.
  vfio: Convey kvm that the vfio-pci device is wc safe
  KVM: arm64: Set io memory s2 pte as normalnc for vfio pci device
  mm: Introduce new flag to indicate wc safe
  KVM: arm64: Introduce new flag for non-cacheable IO memory

Signed-off-by: Oliver Upton <oliver.upton@linux.dev>
2024-03-07 00:56:01 +00:00
Oliver Upton
8dbc41105e Merge branch kvm-arm64/lpi-xarray into kvmarm/next
* kvm-arm64/lpi-xarray:
  : xarray-based representation of vgic LPIs
  :
  : KVM's linked-list of LPI state has proven to be a bottleneck in LPI
  : injection paths, due to lock serialization when acquiring / releasing a
  : reference on an IRQ.
  :
  : Start the tedious process of reworking KVM's LPI injection by replacing
  : the LPI linked-list with an xarray, leveraging this to allow RCU readers
  : to walk it outside of the spinlock.
  KVM: arm64: vgic: Don't acquire the lpi_list_lock in vgic_put_irq()
  KVM: arm64: vgic: Ensure the irq refcount is nonzero when taking a ref
  KVM: arm64: vgic: Rely on RCU protection in vgic_get_lpi()
  KVM: arm64: vgic: Free LPI vgic_irq structs in an RCU-safe manner
  KVM: arm64: vgic: Use atomics to count LPIs
  KVM: arm64: vgic: Get rid of the LPI linked-list
  KVM: arm64: vgic-its: Walk the LPI xarray in vgic_copy_lpi_list()
  KVM: arm64: vgic-v3: Iterate the xarray to find pending LPIs
  KVM: arm64: vgic: Use xarray to find LPI in vgic_get_lpi()
  KVM: arm64: vgic: Store LPIs in an xarray

Signed-off-by: Oliver Upton <oliver.upton@linux.dev>
2024-03-07 00:55:53 +00:00
Oliver Upton
0d874858c6 Merge branch kvm-arm64/vm-configuration into kvmarm/next
* kvm-arm64/vm-configuration: (29 commits)
  : VM configuration enforcement, courtesy of Marc Zyngier
  :
  : Userspace has gained the ability to control the features visible
  : through the ID registers, yet KVM didn't take this into account as the
  : effective feature set when determing trap / emulation behavior. This
  : series adds:
  :
  :  - Mechanism for testing the presence of a particular CPU feature in the
  :    guest's ID registers
  :
  :  - Infrastructure for computing the effective value of VNCR-backed
  :    registers, taking into account the RES0 / RES1 bits for a particular
  :    VM configuration
  :
  :  - Implementation of 'fine-grained UNDEF' controls that shadow the FGT
  :    register definitions.
  KVM: arm64: Don't initialize idreg debugfs w/ preemption disabled
  KVM: arm64: Fail the idreg iterator if idregs aren't initialized
  KVM: arm64: Make build-time check of RES0/RES1 bits optional
  KVM: arm64: Add debugfs file for guest's ID registers
  KVM: arm64: Snapshot all non-zero RES0/RES1 sysreg fields for later checking
  KVM: arm64: Make FEAT_MOPS UNDEF if not advertised to the guest
  KVM: arm64: Make AMU sysreg UNDEF if FEAT_AMU is not advertised to the guest
  KVM: arm64: Make PIR{,E0}_EL1 UNDEF if S1PIE is not advertised to the guest
  KVM: arm64: Make TLBI OS/Range UNDEF if not advertised to the guest
  KVM: arm64: Streamline save/restore of HFG[RW]TR_EL2
  KVM: arm64: Move existing feature disabling over to FGU infrastructure
  KVM: arm64: Propagate and handle Fine-Grained UNDEF bits
  KVM: arm64: Add Fine-Grained UNDEF tracking information
  KVM: arm64: Rename __check_nv_sr_forward() to triage_sysreg_trap()
  KVM: arm64: Use the xarray as the primary sysreg/sysinsn walker
  KVM: arm64: Register AArch64 system register entries with the sysreg xarray
  KVM: arm64: Always populate the trap configuration xarray
  KVM: arm64: nv: Move system instructions to their own sys_reg_desc array
  KVM: arm64: Drop the requirement for XARRAY_MULTI
  KVM: arm64: nv: Turn encoding ranges into discrete XArray stores
  ...

Signed-off-by: Oliver Upton <oliver.upton@linux.dev>
2024-03-07 00:51:31 +00:00
Oliver Upton
a040adfb7e Merge branch kvm-arm64/misc into kvmarm/next
* kvm-arm64/misc:
  : Miscellaneous updates
  :
  :  - Fix handling of features w/ nonzero safe values in set_id_regs
  :    selftest
  :
  :  - Cleanup the unused kern_hyp_va() asm macro
  :
  :  - Differentiate nVHE and hVHE in boot-time message
  :
  :  - Several selftests cleanups
  :
  :  - Drop bogus return value from kvm_arch_create_vm_debugfs()
  :
  :  - Make save/restore of SPE and TRBE control registers affect EL1 state
  :    in hVHE mode
  :
  :  - Typos
  KVM: arm64: Fix TRFCR_EL1/PMSCR_EL1 access in hVHE mode
  KVM: selftests: aarch64: Remove unused functions from vpmu test
  KVM: arm64: Fix typos
  KVM: Get rid of return value from kvm_arch_create_vm_debugfs()
  KVM: selftests: Print timer ctl register in ISTATUS assertion
  KVM: selftests: Fix GUEST_PRINTF() format warnings in ARM code
  KVM: arm64: removed unused kern_hyp_va asm macro
  KVM: arm64: add comments to __kern_hyp_va
  KVM: arm64: print Hyp mode
  KVM: arm64: selftests: Handle feature fields with nonzero minimum value correctly

Signed-off-by: Oliver Upton <oliver.upton@linux.dev>
2024-03-07 00:50:23 +00:00
Oliver Upton
262cd16e76 Merge branch kvm-arm64/feat_e2h0 into kvmarm/next
* kvm-arm64/feat_e2h0:
  : Support for FEAT_E2H0, courtesy of Marc Zyngier
  :
  : As described in the cover letter:
  :
  :   Since ARMv8.1, the architecture has grown the VHE feature, which makes
  :   EL2 a superset of EL1. With ARMv9.5 (and retroactively allowed from
  :   ARMv8.1), the architecture allows implementations to have VHE as the
  :   *only* implemented behaviour, meaning that HCR_EL2.E2H can be
  :   implemented as RES1. As a follow-up, HCR_EL2.NV1 can also be
  :   implemented as RES0, making the VHE-ness of the architecture
  :   recursive.
  :
  : This series adds support for detecting the architectural feature of E2H
  : being RES1, leveraging the existing infrastructure for handling
  : out-of-spec CPUs that are VHE-only. Additionally, the (incomplete) NV
  : infrastructure in KVM is updated to enforce E2H=1 for guest hypervisors
  : on implementations that do not support NV1.
  arm64: cpufeatures: Fix FEAT_NV check when checking for FEAT_NV1
  arm64: cpufeatures: Only check for NV1 if NV is present
  arm64: cpufeatures: Add missing ID_AA64MMFR4_EL1 to __read_sysreg_by_encoding()
  KVM: arm64: Handle Apple M2 as not having HCR_EL2.NV1 implemented
  KVM: arm64: Force guest's HCR_EL2.E2H RES1 when NV1 is not implemented
  KVM: arm64: Expose ID_AA64MMFR4_EL1 to guests
  arm64: Treat HCR_EL2.E2H as RES1 when ID_AA64MMFR4_EL1.E2H0 is negative
  arm64: cpufeature: Detect HCR_EL2.NV1 being RES0
  arm64: cpufeature: Add ID_AA64MMFR4_EL1 handling
  arm64: sysreg: Add layout for ID_AA64MMFR4_EL1
  arm64: cpufeature: Correctly display signed override values
  arm64: cpufeatures: Correctly handle signed values
  arm64: Add macro to compose a sysreg field value

Signed-off-by: Oliver Upton <oliver.upton@linux.dev>
2024-03-07 00:45:24 +00:00
Anup Patel
d8c0831348 KVM: riscv: selftests: Add Zacas extension to get-reg-list test
The KVM RISC-V allows Zacas extension for Guest/VM so add this
extension to get-reg-list test.

Signed-off-by: Anup Patel <apatel@ventanamicro.com>
Reviewed-by: Andrew Jones <ajones@ventanamicro.com>
Signed-off-by: Anup Patel <anup@brainfault.org>
2024-03-06 20:53:44 +05:30
Anup Patel
77fc0bfa43 RISC-V: KVM: Allow Zacas extension for Guest/VM
Extend the KVM ISA extension ONE_REG interface to allow KVM user space
to detect and enable Zacas extension for Guest/VM.

Signed-off-by: Anup Patel <apatel@ventanamicro.com>
Reviewed-by: Andrew Jones <ajones@ventanamicro.com>
Signed-off-by: Anup Patel <anup@brainfault.org>
2024-03-06 20:53:40 +05:30
Anup Patel
d9bb4eca32 KVM: riscv: selftests: Add Ztso extension to get-reg-list test
The KVM RISC-V allows Ztso extension for Guest/VM so add this
extension to get-reg-list test.

Signed-off-by: Anup Patel <apatel@ventanamicro.com>
Reviewed-by: Andrew Jones <ajones@ventanamicro.com>
Signed-off-by: Anup Patel <anup@brainfault.org>
2024-03-06 20:53:37 +05:30
Anup Patel
f943ebe2ec RISC-V: KVM: Allow Ztso extension for Guest/VM
Extend the KVM ISA extension ONE_REG interface to allow KVM user space
to detect and enable Ztso extension for Guest/VM.

Signed-off-by: Anup Patel <apatel@ventanamicro.com>
Reviewed-by: Andrew Jones <ajones@ventanamicro.com>
Signed-off-by: Anup Patel <anup@brainfault.org>
2024-03-06 20:53:34 +05:30
Anup Patel
d808f0b1be RISC-V: KVM: Forward SEED CSR access to user space
The SEED CSR access from VS/VU mode (guest) will always trap to
HS-mode (KVM) when Zkr extension is available to the Guest/VM.

Forward this CSR access to KVM user space so that it can be
emulated based on the method chosen by VMM.

Fixes: f370b4e668 ("RISC-V: KVM: Allow scalar crypto extensions for Guest/VM")
Signed-off-by: Anup Patel <apatel@ventanamicro.com>
Reviewed-by: Andrew Jones <ajones@ventanamicro.com>
Signed-off-by: Anup Patel <anup@brainfault.org>
2024-03-06 20:53:32 +05:30
Haibo Xu
d0b94bcbb0 KVM: riscv: selftests: Add sstc timer test
Add a KVM selftests to validate the Sstc timer functionality.
The test was ported from arm64 arch timer test.

Signed-off-by: Haibo Xu <haibo1.xu@intel.com>
Reviewed-by: Andrew Jones <ajones@ventanamicro.com>
Signed-off-by: Anup Patel <anup@brainfault.org>
2024-03-06 20:53:29 +05:30
Haibo Xu
812806bd1e KVM: riscv: selftests: Change vcpu_has_ext to a common function
Move vcpu_has_ext to the processor.c and rename it to __vcpu_has_ext
so that other test cases can use it for vCPU extension check.

Signed-off-by: Haibo Xu <haibo1.xu@intel.com>
Reviewed-by: Andrew Jones <ajones@ventanamicro.com>
Signed-off-by: Anup Patel <anup@brainfault.org>
2024-03-06 20:53:27 +05:30
Haibo Xu
1e979288c9 KVM: riscv: selftests: Add guest helper to get vcpu id
Add guest_get_vcpuid() helper to simplify accessing to per-cpu
private data. The sscratch CSR was used to store the vcpu id.

Signed-off-by: Haibo Xu <haibo1.xu@intel.com>
Reviewed-by: Andrew Jones <ajones@ventanamicro.com>
Signed-off-by: Anup Patel <anup@brainfault.org>
2024-03-06 20:53:23 +05:30
Haibo Xu
38f680c25e KVM: riscv: selftests: Add exception handling support
Add the infrastructure for guest exception handling in riscv selftests.
Customized handlers can be enabled by vm_install_exception_handler(vector)
or vm_install_interrupt_handler().

The code is inspired from that of x86/arm64.

Signed-off-by: Haibo Xu <haibo1.xu@intel.com>
Reviewed-by: Andrew Jones <ajones@ventanamicro.com>
Signed-off-by: Anup Patel <anup@brainfault.org>
2024-03-06 20:51:41 +05:30
Bibo Mao
b99f783106 LoongArch: KVM: Remove unnecessary CSR register saving during enter guest
Some CSR registers like CRMD/PRMD are saved during enter VM mode now.
However they are not restored for actual use, so saving for these CSR
registers can be removed.

Reviewed-by: Tianrui Zhao <zhaotianrui@loongson.cn>
Signed-off-by: Bibo Mao <maobibo@loongson.cn>
Signed-off-by: Huacai Chen <chenhuacai@loongson.cn>
2024-03-06 09:12:13 +08:00
Bibo Mao
f66228053e LoongArch: KVM: Do not restart SW timer when it is expired
LoongArch VCPUs have their own separate HW timers. SW timer is to wake
up blocked vcpu thread, rather than HW timer emulation. When blocking
vcpu scheduled out, SW timer is used to wakeup blocked vcpu thread and
injects timer interrupt. It does not care about whether guest timer is
in period mode or oneshot mode, and SW timer needs not to be restarted
since vcpu has been woken.

This patch does not restart SW timer when it is expired.

Signed-off-by: Bibo Mao <maobibo@loongson.cn>
Signed-off-by: Huacai Chen <chenhuacai@loongson.cn>
2024-03-06 09:12:13 +08:00
Bibo Mao
8bc15d02d5 LoongArch: KVM: Start SW timer only when vcpu is blocking
SW timer is enabled when vcpu thread is scheduled out, and it is to wake
up vcpu from blocked queue. If vcpu thread is scheduled out but is not
blocked, such as it is preempted by other threads, it is not necessary
to enable SW timer. Since vcpu thread is still on running queue if it is
preempted and SW timer is only to wake up vcpu on blocking queue, so SW
timer is not useful in this situation.

This patch enables SW timer only when vcpu is scheduled out and is
blocking.

Signed-off-by: Bibo Mao <maobibo@loongson.cn>
Signed-off-by: Huacai Chen <chenhuacai@loongson.cn>
2024-03-06 09:12:13 +08:00
Bibo Mao
aebd3bd586 LoongArch: KVM: Set reserved bits as zero in CPUCFG
Supported CPUCFG information comes from function _kvm_get_cpucfg_mask().
A bit should be zero if it is reserved by HW or if it is not supported
by KVM.

Also LoongArch software page table walk feature defined in CPUCFG2_LSPW
is supported by KVM, it should be enabled by default.

Signed-off-by: Bibo Mao <maobibo@loongson.cn>
Signed-off-by: Huacai Chen <chenhuacai@loongson.cn>
2024-03-06 09:12:13 +08:00
Dongli Zhang
e9da6f08ed KVM: selftests: Explicitly close guest_memfd files in some gmem tests
Explicitly close() guest_memfd files in various guest_memfd and
private_mem_conversions tests, there's no reason to keep the files open
until the test exits.

Fixes: 8a89efd434 ("KVM: selftests: Add basic selftest for guest_memfd()")
Fixes: 43f623f350 ("KVM: selftests: Add x86-only selftest for private memory conversions")
Signed-off-by: Dongli Zhang <dongli.zhang@oracle.com>
Link: https://lore.kernel.org/r/20240227015716.27284-1-dongli.zhang@oracle.com
[sean: massage changelog]
Signed-off-by: Sean Christopherson <seanjc@google.com>
2024-03-05 13:31:20 -08:00
Linus Torvalds
90d35da658 Linux 6.8-rc7 2024-03-03 13:02:52 -08:00
Linus Torvalds
58c806d867 phy second set of fixes for 6.8
- Driver fixes for
    - qcom: m31 pointer err fix, eusb2 fix redundant zero-out loop and v3
      offset fix on qmp-usb
    - freescale: fix for dphy alias
 -----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCAAdFiEE+vs47OPLdNbVcHzyfBQHDyUjg0cFAmXkq3wACgkQfBQHDyUj
 g0fl7g//ZtyACrr3ngykyKoLfSP31lnye6fDgoo5h80Qx37hTTtn7a5JepiSyFj1
 UzeCE11MI9kpDgYL5hF2agNipb7K04jOgH8RQsAcBuUNGNWSdLnSXMU3yC6amdQM
 XiPuM8IARrHaWMP2KLXo/CC/qLFquq6M9GBY11wFE9gg4rt/HDeiYAin9lv2REdy
 C3yAoXxPTOEv8B8MvbVrZTciybFSWFONpBR/qCnXFKC5f+ieXGjKcjiQXGaKQBZJ
 mqHpl5Qg2RbTBqCfRAS9S7ldONzp317K4Hm3ehdVMJnY+VoqoNKg0nS+35OU0I+P
 EO62h7JEIBzVUu2HUJ6UZsBpu7GD/kG5s32Tlig3/i3YaP7pGaBXp18//t6F6ViV
 d9rLLaCLdMrVVFHJwHVwLinT/y5kydIKdGUQSWf1gisa+69dto806OqSQvl0YgAk
 XuvKBti0mTSXK8GbQCqYQtvjPNPFZLpdDgST6L81CawmudD/KbLK3KMUJHYiRaBi
 i6qlCpSfKcjb531tdNSytmX0GARcwYeMkGTUxjI4CjB0B4fXrlfIjd+ruu9GyiZx
 AxyChrMGqx0GWKq4cmjZ5H53n7a6cN4bHIiaEAtTWXfxAWrqb5r2brePy75m9UUx
 xuRMdzEzph/6fyT1OygRWh4jNuIkc0pyT0DcQiEySjAzNfQC1VA=
 =jXqZ
 -----END PGP SIGNATURE-----

Merge tag 'phy-fixes2-6.8' of git://git.kernel.org/pub/scm/linux/kernel/git/phy/linux-phy

Pull phy fixes from Vinod Koul:

  - qcom: m31 pointer err fix, eusb2 fix redundant zero-out loop and v3
    offset fix on qmp-usb

  - freescale: fix for dphy alias

* tag 'phy-fixes2-6.8' of git://git.kernel.org/pub/scm/linux/kernel/git/phy/linux-phy:
  phy: qcom-qmp-usb: fix v3 offsets data
  phy: qualcomm: eusb2-repeater: Rework init to drop redundant zero-out loop
  phy: qcom: phy-qcom-m31: fix wrong pointer pass to PTR_ERR()
  phy: freescale: phy-fsl-imx8-mipi-dphy: Fix alias name to use dashes
2024-03-03 09:56:49 -08:00
Linus Torvalds
d57dd2d24d dmaengine second set of fixes for v6.8
Driver fixes for:
  - dw-edma fixes to improve driver and remote HDMA setup
  - fsl-edma fixes for SoC hange, irq init and byte calculations
    and sparse fixes
  - idxd: safe user copy of completion record fix
  - ptdma: consistent DMA mask fix
 -----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCAAdFiEE+vs47OPLdNbVcHzyfBQHDyUjg0cFAmXkqM4ACgkQfBQHDyUj
 g0flMg//bgnkYdt/Y4nDbJxPobQHSOLl86GbD9mIddeocwdsA/QQ4uz/WzN+rngY
 0M7/7Zfq+RMq6lfesLMJ5DXycYBGIMQYZ1ItpIL4Xw3sSo2i6qFn18dSqbesRpkB
 bsfdrbqCEHWwghkBszoTGXGx24XRdQzTUmMziL9jqdIvXXf5HCKeGSZnC5L6ssxs
 JfdCee7ZSPK6gOVlBlN8zjzG8ZI2bwH+B1okyZwWljorPInr8UQ3ysR3neEUab6O
 JMzVmp46LhTQmHEZxzBbfR18rbVhr0xRRs78UwJPhPrgp9PFOkxdLl9lGDh8Fa2x
 jApi9cl5rSrW2bEv5fe8k5EM64G9G5arJU9F6+Goqm39ftDTktKBPhwmIR/NqOZF
 AHmW2c+0trDMOg099oWd+ozgbMkdbrdjf6BA9vSLKsXLTFHDZEA1fEKifJP5NCSQ
 ZQJVpQn0wiBOQSJxpr4mbk/n5JeKzt/uyQSF8Qo8Kp9OWXiNrjWzJ0bZnVafkTlU
 E91WGiGjYQmh28DV432IM07IXVKLtIMa/BXuWMhOZY+/HUJK/AaRStxEB5kkLJDm
 EExDe23Rviu0lXDW4cH+R14d4L/9EJY87Ynm2p85rOj/rnwW9gWyu3BwD3aBXa2e
 yKlng355WCBISMl8wXpeMQe1/yaxf48YLdrmdLD95bT0w5Dc0gc=
 =mX0o
 -----END PGP SIGNATURE-----

Merge tag 'dmaengine-fix2-6.8' of git://git.kernel.org/pub/scm/linux/kernel/git/vkoul/dmaengine

Pull dmaengine fixes from Vinod Koul:

 - dw-edma fixes to improve driver and remote HDMA setup

 - fsl-edma fixes for SoC hange, irq init and byte calculations and
   sparse fixes

 - idxd: safe user copy of completion record fix

 - ptdma: consistent DMA mask fix

* tag 'dmaengine-fix2-6.8' of git://git.kernel.org/pub/scm/linux/kernel/git/vkoul/dmaengine:
  dmaengine: ptdma: use consistent DMA masks
  dmaengine: fsl-qdma: add __iomem and struct in union to fix sparse warning
  dmaengine: idxd: Ensure safe user copy of completion record
  dmaengine: fsl-edma: correct max_segment_size setting
  dmaengine: idxd: Remove shadow Event Log head stored in idxd
  dmaengine: fsl-edma: correct calculation of 'nbytes' in multi-fifo scenario
  dmaengine: fsl-qdma: init irq after reg initialization
  dmaengine: fsl-qdma: fix SoC may hang on 16 byte unaligned read
  dmaengine: dw-edma: eDMA: Add sync read before starting the DMA transfer in remote setup
  dmaengine: dw-edma: HDMA: Add sync read before starting the DMA transfer in remote setup
  dmaengine: dw-edma: Add HDMA remote interrupt configuration
  dmaengine: dw-edma: HDMA_V0_REMOTEL_STOP_INT_EN typo fix
  dmaengine: dw-edma: Fix wrong interrupt bit set for HDMA
  dmaengine: dw-edma: Fix the ch_count hdma callback
2024-03-03 09:54:03 -08:00
Linus Torvalds
e4f7900095 powerpc fixes for 6.8 #5
- Fix IOMMU table initialisation when doing kdump over SR-IOV.
 
  - Fix incorrect RTAS function name for resetting TCE tables.
 
  - Fix fpu_signal selftest failures since a recent change.
 
 Thanks to: Gaurav Batra, Nathan Lynch.
 -----BEGIN PGP SIGNATURE-----
 
 iQJHBAABCAAxFiEEJFGtCPCthwEv2Y/bUevqPMjhpYAFAmXkauwTHG1wZUBlbGxl
 cm1hbi5pZC5hdQAKCRBR6+o8yOGlgLTSD/4/boNe5MtrGgk6RtxnyWJv/p9KCMcC
 rRTa5pSR6HFVK3m89V17O0onL8aKyIljO5P3rDS8X4SUhr41Z9b9/FUoHv277E7a
 f7hgX4/901DYiMLJEt9jkfmM30IxTYkPmlft0Uus/NiesNdTcdQOO4UScSysnZac
 0HM1POp32KSC2HQRc/i+WIshRnaZcC+f0PPTU/qfS/u7/pwK4eekWdayLNvvvSvH
 TfjV5Hu4JVDF7hBLsoY4PdqVQGVD3t3d1D5+UrhHuYzPx+Afc8rIDfJx/+o339W6
 ZTXrRPOfiticfhHQvMX1AgsYr3/A0BbZj/wCvv+pPsCjZPfox9XsW6CgiMKUxVDf
 ifrBhvNx0fICMf+cEjH9q2dcGwMba7dZTX5HBlSXR4xLeNitUI8pt6bYCaqw7UjH
 ohwl9aAI7Rl1hcW6qBaviKaIDqhbmj3N4B4ZdgMAKj2gnovbF9gUSG3ARLwEjsqB
 qfd0c3x6UUThj4vYfGC/iI1z1LCXC8myqof6EGArLTc13R9vFv+ycx5FwERvAxtY
 ALNBh6LMIkKI5z8ZrGWULoXHoS2QrE1SXpQ5ooH2g9n+vLibd37JdJNcrEMf/TJZ
 PluhRCJcEWkw98aUSzIoRFIFpZ2wMg/uzg3KZePhRus3GhgttTqFTbrcKHhyONBO
 pq/EDB8FizZ9/A==
 =MSDF
 -----END PGP SIGNATURE-----

Merge tag 'powerpc-6.8-5' of git://git.kernel.org/pub/scm/linux/kernel/git/powerpc/linux

Pull powerpc fixes from Michael Ellerman:

 - Fix IOMMU table initialisation when doing kdump over SR-IOV

 - Fix incorrect RTAS function name for resetting TCE tables

 - Fix fpu_signal selftest failures since a recent change

Thanks to Gaurav Batra and Nathan Lynch.

* tag 'powerpc-6.8-5' of git://git.kernel.org/pub/scm/linux/kernel/git/powerpc/linux:
  selftests/powerpc: Fix fpu_signal failures
  powerpc/rtas: use correct function name for resetting TCE tables
  powerpc/pseries/iommu: IOMMU table is not initialized for kdump over SR-IOV
2024-03-03 09:47:19 -08:00
Linus Torvalds
73d35f8335 - Do not reserve SETUP_RNG_SEED setup data in the e820 map as it should
be used by kexec only
 
 - Make sure MKTME feature detection happens at an earlier time in the
   boot process so that the physical address size supported by the CPU is
   properly corrected and MTRR masks are programmed properly, leading to
   TDX systems booting without disable_mtrr_cleanup on the cmdline
 
 - Make sure the different address sizes supported by the CPU are read
   out as early as possible
 -----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCgAdFiEEzv7L6UO9uDPlPSfHEsHwGGHeVUoFAmXkVjkACgkQEsHwGGHe
 VUqSfg//XGV970NhxR3kLW7I+MvQsQDwWA61u+XpyCFdTZDOWKo17ZndR2/exHXI
 fjnpnS8SP3Dgib0wrWfqBAqmcDkN5laBIpvceH+l57NXi0Jep1leSunRBFS22jxT
 1/FqKFlOka9SG4aMJRD4xhG2Y9TO2uLqjPam7gZkdLbI7TIfIACEm4JPqWu4wLQo
 JKeoYmlSkSC5kbHMOXpIKBSzUCm4cKSU39uZRxIhpZf50nXiJf25IAlDFlVZ5uBw
 p5S2Rm4jF4eekRMArG76c61AMsdIg9kcp2OZ4Kop/t1Ouo96pap+h1G6c6Xi73zi
 WX99roTuS5FoBCguDmkxi2Hx8HU8PQGbzIAuwoTtPc6u9XHDdmXQZEvhZxIn/by8
 fjhZd4DCfmqBoasR+AaX8YzK0j5ypp8BKcFCKmvWzqVR+aMB16lxGj62xyUsvbry
 gvd6GezMn8WODXjUOa27gmh+YhOJboX2hozf6FhqItBGEnvGpsWDdMfViO5/AZnk
 T0KZxwH5OpD/CrPG1TYSWynz5vLSHSIaj2Y7iXFHfYu9s6yW3E/jZsWt33Qaag96
 sBt8/YlFR82gU8mbpmg0epJ7s6OLtGmfuoujFMfl0fK+OoLLtzOA+VZPX6Ud0Vrg
 9NMY6Q8szKqDDH68DZuj7OSbf6i9NlZI/AiHpGzH3bT77iHknnI=
 =fmsi
 -----END PGP SIGNATURE-----

Merge tag 'x86_urgent_for_v6.8_rc7' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip

Pull x86 fixes from Borislav Petkov:

 - Do not reserve SETUP_RNG_SEED setup data in the e820 map as it should
   be used by kexec only

 - Make sure MKTME feature detection happens at an earlier time in the
   boot process so that the physical address size supported by the CPU
   is properly corrected and MTRR masks are programmed properly, leading
   to TDX systems booting without disable_mtrr_cleanup on the cmdline

 - Make sure the different address sizes supported by the CPU are read
   out as early as possible

* tag 'x86_urgent_for_v6.8_rc7' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip:
  x86/e820: Don't reserve SETUP_RNG_SEED in e820
  x86/cpu/intel: Detect TME keyid bits before setting MTRR mask registers
  x86/cpu: Allow reducing x86_phys_bits during early_identify_cpu()
2024-03-03 09:43:03 -08:00
Linus Torvalds
04b8076df2 firewire-fixes-6.8-rc7
A workaround to suppress the continuous bus resets in the case that older
 devices are connected to the modern 1394 OHCI hardware and devices
 
 In IEEE 1394 Amendment (IEEE 1394a-2000), the short bus reset is added to
 resolve the shortcomings of the long bus reset in IEEE 1394-1995. However,
 it is well-known that the solution is not necessarily effective in the
 mixing environment that both IEEE 1394-1995 PHY and IEEE 1394a-2000 (or
 later) PHY exist, as described in section 8.4.6.2 of IEEE 1394a-2000.
 
 The current implementation of firewire stack schedules the short bus
 reset when attempting to resolve the mismatch of gap count in the certain
 generation of bus topology. It can cause the continuous bus reset in the
 issued environment.
 
 The workaround simply uses the long bus reset instead of the short bus
 reset. It is desirable to detect whether the issued environment or not.
 However, the way to access PHY registers from remote note is firstly
 defined in IEEE 1394a-2000, thus it is not available in the case.
 -----BEGIN PGP SIGNATURE-----
 
 iHUEABYKAB0WIQQE66IEYNDXNBPeGKSsLtaWM8LwEwUCZeOqLAAKCRCsLtaWM8Lw
 E2rLAQDJiYNXItCD0Q+RISEH7mtrfXmx/f4Tb1Uf9lBtKzOKIAD/Vn0H5WRrj5Qx
 fuTb70AD2zRb4zpTM65hOdYBEQ4TnAE=
 =T3IO
 -----END PGP SIGNATURE-----

Merge tag 'firewire-fixes-6.8-rc7' of git://git.kernel.org/pub/scm/linux/kernel/git/ieee1394/linux1394

Pull firewire fixes from Takashi Sakamoto:
 "A workaround to suppress the continuous bus resets in the case that
  older devices are connected to the modern 1394 OHCI hardware and
  devices

  In IEEE 1394 Amendment (IEEE 1394a-2000), the short bus reset is added
  to resolve the shortcomings of the long bus reset in IEEE 1394-1995.
  However, it is well-known that the solution is not necessarily
  effective in the mixing environment that both IEEE 1394-1995 PHY and
  IEEE 1394a-2000 (or later) PHY exist, as described in section 8.4.6.2
  of IEEE 1394a-2000.

  The current implementation of firewire stack schedules the short bus
  reset when attempting to resolve the mismatch of gap count in the
  certain generation of bus topology. It can cause the continuous bus
  reset in the issued environment.

  The workaround simply uses the long bus reset instead of the short bus
  reset. It is desirable to detect whether the issued environment or
  not. However, the way to access PHY registers from remote note is
  firstly defined in IEEE 1394a-2000, thus it is not available in the
  case"

* tag 'firewire-fixes-6.8-rc7' of git://git.kernel.org/pub/scm/linux/kernel/git/ieee1394/linux1394:
  firewire: core: use long bus reset on gap count error
2024-03-02 15:18:02 -08:00
Linus Torvalds
4640e2be39 Changes for 6.8-rc7:
* Drop experimental warning for FSDAX.
 
 Signed-off-by: Chandan Babu R <chandanbabu@kernel.org>
 -----BEGIN PGP SIGNATURE-----
 
 iHUEABYIAB0WIQQjMC4mbgVeU7MxEIYH7y4RirJu9AUCZd1uBAAKCRAH7y4RirJu
 9Io/AP9+wwQRMgBT4gmCtUytpYgjZaEs8D3pVN+B9cV2OGzBzwD+Oek5ax/rKFRr
 62gcdMwAIRX7AQMQTOdkcyp/q0UslgY=
 =6sb7
 -----END PGP SIGNATURE-----

Merge tag 'xfs-6.8-fixes-4' of git://git.kernel.org/pub/scm/fs/xfs/xfs-linux

Pull xfs fix from Chandan Babu:
 "Drop experimental warning message when mounting an xfs filesystem on
  an fsdax device. We now consider xfs on fsdax to be stable"

* tag 'xfs-6.8-fixes-4' of git://git.kernel.org/pub/scm/fs/xfs/xfs-linux:
  xfs: drop experimental warning for FSDAX
2024-03-02 09:38:03 -08:00
Linus Torvalds
705c72567b gpio fixes for v6.8-rc7
- fix resource freeing ordering in error path when adding a GPIO chip
 - only set pins to output after the reset is complete in gpio-74x164
 -----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCgAdFiEEFp3rbAvDxGAT0sefEacuoBRx13IFAmXjAFQACgkQEacuoBRx
 13JQDhAAiRnE6kYITVWr4O581UpyC9v9yp0Yo6mVeUCHIGKkmZnKrBqcDjORo4Qg
 zmpeot5W7zmYQfMy/cjzyo/rSi55mKb3wAyA4/BHScz4SwUyWJrNjkx5WIQgJssW
 85ZA7x5G6qptf+4oGqSTVG8G6Q/7uR3s+VKgVVWETT31DomPv6DUXFJj1Eu6HNyG
 M25hZvBu8tWMTc6p/rPYcASMYYNrmHDpoETQwrBeESS2kvDIyvoTaTYAFttOOYUN
 aB9UyoW1e4KFQ/tppQwdpBEpGWLLHzR/dMnyV20pUW3OIuToSwQ2HdDRGx4Wnco4
 fImfVqeg4n8DHay43mlr/eSO65CrrngJdhwrB5415wSU6mMkRvd6A12mEWXU0Mjh
 UGiqBI3jxQBPW2tQlQa0zsQpsUyQPZhXt0SD0/DP8FV8GbJFHt90jH4TZauJvsiC
 rX0P50tVOFySBYOCdouVpoc/MVDUCK6Shey/Q0GodaSeH7tw/w+isaR2ftvr/bH3
 c9PQ27b5/s1VM+FIHQxY4J9xiW49GhPZaG4eIB506XDU13q0aZ4bfg6PR1YId5sR
 MdX4gtkkvvZG2Ufa1QCYePY7P6sA+Zxjrg/TBXntgAv759bYds1pLv0SNehLP1F+
 3pKwrN9tuuy/yAIRA783Pp6/0oVaEajEeAA+7xNx0U3qC6E1MAY=
 =i27Z
 -----END PGP SIGNATURE-----

Merge tag 'gpio-fixes-for-v6.8-rc7' of git://git.kernel.org/pub/scm/linux/kernel/git/brgl/linux

Pull gpio fixes from Bartosz Golaszewski:

 - fix resource freeing ordering in error path when adding a GPIO chip

 - only set pins to output after the reset is complete in gpio-74x164

* tag 'gpio-fixes-for-v6.8-rc7' of git://git.kernel.org/pub/scm/linux/kernel/git/brgl/linux:
  gpio: fix resource unwinding order in error path
  gpiolib: Fix the error path order in gpiochip_add_data_with_key()
  gpio: 74x164: Enable output pins after registers are reset
2024-03-02 09:25:12 -08:00
Ming Lei
7838b46561 block: define bvec_iter as __packed __aligned(4)
In commit 19416123ab ("block: define 'struct bvec_iter' as packed"),
what we need is to save the 4byte padding, and avoid `bio` to spread on
one extra cache line.

It is enough to define it as '__packed __aligned(4)', as '__packed'
alone means byte aligned, and can cause compiler to generate horrible
code on architectures that don't support unaligned access in case that
bvec_iter is embedded in other structures.

Cc: Mikulas Patocka <mpatocka@redhat.com>
Suggested-by: Linus Torvalds <torvalds@linux-foundation.org>
Fixes: 19416123ab ("block: define 'struct bvec_iter' as packed")
Signed-off-by: Ming Lei <ming.lei@redhat.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2024-03-02 09:15:01 -08:00
Linus Torvalds
7fd664466a SCSI fixes on 20240302
Two small fixes, all in drivers (the more obsolete mpt3sas and the
 newer mpi3mr).
 
 Signed-off-by: James E.J. Bottomley <jejb@linux.ibm.com>
 -----BEGIN PGP SIGNATURE-----
 
 iJwEABMIAEQWIQTnYEDbdso9F2cI+arnQslM7pishQUCZeLhxiYcamFtZXMuYm90
 dG9tbGV5QGhhbnNlbnBhcnRuZXJzaGlwLmNvbQAKCRDnQslM7pishe4aAQCe0pM9
 Ssol+/GThNmtpEMBshFYFPJTEMJlJ3Sf6Jgm7AD/ZSikfS6wbyRw8xNKRBz7H/x/
 Cpi/IMaJbyJgLb9+YKE=
 =wUnX
 -----END PGP SIGNATURE-----

Merge tag 'scsi-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi

Pull SCSI fixes from James Bottomley:
 "Two small fixes, all in drivers (the more obsolete mpt3sas and the
  newer mpi3mr)"

* tag 'scsi-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi:
  scsi: mpt3sas: Prevent sending diag_reset when the controller is ready
  scsi: mpi3mr: Reduce stack usage in mpi3mr_refresh_sas_ports()
2024-03-02 09:10:00 -08:00
Linus Torvalds
5ad3cb0ed5 Power Supply Fixes for 6.8 cycle
* mm8013: select REGMAP_I2C
  * bq27xxx-i2c: do not free non-existing IRQ
 -----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCgAdFiEE72YNB0Y/i3JqeVQT2O7X88g7+poFAmXidvkACgkQ2O7X88g7
 +pprPQ//fz6hk3kjikeJ1bzoMea3RcCPoXbDAQRw6n9ni67dwWRy3YNUW1rntMS3
 wiE2Yj8kJZmPc6vqdxfLkjvSSPtr4VGs1uvLGg/7gaNY7wBH4d72aXDR4BDLo4RN
 rg7D7oa9nckUGWeNh29iOhoKGcpohsmOEQINU6rQcyuIHi4RfTL4SML3cDclGTRZ
 B3OLvpDUQRXfrkB6IS9XSrwGjAS76tVEI9V6ZqROj6Nn1E/deZi4iheXXRwjHJIW
 Gelj6yDpxpsaXqm8Pt4dShsMM8oOf4NHlwJWDePISfclUMUxz5glSC3zuvOtB5Qr
 1LxckGAKFSpRHbHM3vUqmR2Ec8sxLkWetHeHwhlL/NmFWnhVtyCZi3bsHgtIysXI
 HdRHKH5INoDV4LTWR7cP/1S1jBangG35G2LOSIqUfi73NO07Xu/Wc715CmFbKXBQ
 KEw67xFA/hrVpZMOJsdE7uV/nBOT+88jSwvrO8m6lJkrIY5HGZM0AhaZjbF5tiLX
 iLju7uGvAEzbbgFXgAF0lvepYRFJGrp4m2+TsplLyQ3zzYsLiNsJ8oTeoEvikkT5
 XeCj4F/uCEH/l4bmPffMS9wl3nHtOfCwVUk5vgrnX0TQPsvlMWzEoSBsKE7NRdqB
 ieFTXHnKQUIVYFx7vleoLCe40fc1zmYVmmOtVeKQ3az2nyi0ot4=
 =iWgO
 -----END PGP SIGNATURE-----

Merge tag 'for-v6.8-rc2' of git://git.kernel.org/pub/scm/linux/kernel/git/sre/linux-power-supply

Pull power supply fixes from Sebastian Reichel:

 - Kconfig dependency fix

 - bq27xxx-i2c: do not free non-existing IRQ

* tag 'for-v6.8-rc2' of git://git.kernel.org/pub/scm/linux/kernel/git/sre/linux-power-supply:
  power: supply: bq27xxx-i2c: Do not free non existing IRQ
  power: supply: mm8013: select REGMAP_I2C
2024-03-01 17:25:31 -08:00
Linus Torvalds
e613c90dda iommufd for 6.8 rc
Four syzkaller found bugs:
 
 - Corruption during error unwind in iommufd_access_change_ioas()
 
 - Overlapping IDs in the test suite due to out of order destruction
 
 - Missing locking for access->ioas in the test suite
 
 - False failures in the test suite validation logic with huge pages
 -----BEGIN PGP SIGNATURE-----
 
 iHUEABYIAB0WIQRRRCHOFoQz/8F5bUaFwuHvBreFYQUCZeH0gQAKCRCFwuHvBreF
 YcC5AP91VuNxoExC6Zx9c8i1U2SR5IbvVAHT572qgdhaKoVzugEAtfKJA2ELheL8
 s1F+TDOo8fR/aawIAPzK5GCuHc5oIwg=
 =S44j
 -----END PGP SIGNATURE-----

Merge tag 'for-linus-iommufd' of git://git.kernel.org/pub/scm/linux/kernel/git/jgg/iommufd

Pull iommufd fixes from Jason Gunthorpe:
 "Four syzkaller found bugs:

   - Corruption during error unwind in iommufd_access_change_ioas()

   - Overlapping IDs in the test suite due to out of order destruction

   - Missing locking for access->ioas in the test suite

   - False failures in the test suite validation logic with huge pages"

* tag 'for-linus-iommufd' of git://git.kernel.org/pub/scm/linux/kernel/git/jgg/iommufd:
  iommufd/selftest: Don't check map/unmap pairing with HUGE_PAGES
  iommufd: Fix protection fault in iommufd_test_syz_conv_iova
  iommufd/selftest: Fix mock_dev_num bug
  iommufd: Fix iopt_access_list_id overwrite bug
2024-03-01 17:22:46 -08:00
Linus Torvalds
fb54efc293 Devicetree fix for v6.8, part 2:
One fix for a bug in fw_devlink handling of OF graph. This doesn't
 completely fix the reported problems, but it's with users adding out of
 tree code.
 -----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCgAdFiEEktVUI4SxYhzZyEuo+vtdtY28YcMFAmXiViMACgkQ+vtdtY28
 YcN3yRAAixL7WT+8NDECMy+X25fNaSeUAWRdXRno0F8/EwyBPevXh3TkGEiz5RyT
 nCkwC3X3ykgVWWD9nPa214oay3Hg+NKrekBMD9GK9M4WnI/ZcsCqmcPKDB4OwNDL
 M/QBLY8o7juVh5RD7SAKKXmS9VRfrnzsdHMwKoyMC7uqSixq299kR85wc9KZW7co
 yh1MD+oY/5jymkN71ZZkyysBhybTHX2AlBAHKLD4biKU6J4JOpEju31Tlmw0xu4l
 xqNtfZalgfG9Rc6NUvBJQgIMD+he+fsowsxOShkd7/4JhgIiF5SqNl6IPEq6Uwhk
 9AHsa6KOal3aiLcbDMIum44P2Bvb1GYTPmGXfvqSZp4O1K8OXZ0EOxFlddwDtCqG
 MBnhdN7iTymNLS0ojwz6za4IS6VDfmjofB5uEjjHyTam/b/uLogPXrRWU68hYDAS
 DdujcZ0a7Fyw9Ltz6EzuYyNlcumLaNnF97RJG0+6FTn+NF2slUMjjeKE2yvAuFpy
 bAFs5iF1z5mXrJArZFf3ioRHSCJrVJ8lnKHmOwrAkdc23V9CYZjRywwokqH7xA2/
 Qudo0O3ZFp6M9hhGq+DruM2nNvrLVTRYKCD4Oxe6geIAMmPJaD+gaTDnZPTcY/0t
 VkQnu8aXGLH+5T2dGALhk3JzZQ7JYwkyXhKvO283IXhKY+XV0rg=
 =9QKD
 -----END PGP SIGNATURE-----

Merge tag 'devicetree-fixes-for-6.8-2' of git://git.kernel.org/pub/scm/linux/kernel/git/robh/linux

Pull devicetree fix from Rob Herring:
 "One fix for a bug in fw_devlink handling of OF graph. This doesn't
  completely fix the reported problems, but it's with users adding out
  of tree code"

* tag 'devicetree-fixes-for-6.8-2' of git://git.kernel.org/pub/scm/linux/kernel/git/robh/linux:
  of: property: fw_devlink: Fix stupid bug in remote-endpoint parsing
2024-03-01 17:18:35 -08:00
Saravana Kannan
7cb50f6c9f of: property: fw_devlink: Fix stupid bug in remote-endpoint parsing
Introduced a stupid bug in commit 782bfd03c3 ("of: property: Improve
finding the supplier of a remote-endpoint property") due to a last minute
incorrect edit of "index !=0" into "!index". This patch fixes it to be
"index > 0" to match the comment right next to it.

Reported-by: Luca Ceresoli <luca.ceresoli@bootlin.com>
Link: https://lore.kernel.org/lkml/20240223171849.10f9901d@booty/
Fixes: 782bfd03c3 ("of: property: Improve finding the supplier of a remote-endpoint property")
Signed-off-by: Saravana Kannan <saravanak@google.com>
Reviewed-by: Herve Codina <herve.codina@bootlin.com>
Reviewed-by: Luca Ceresoli <luca.ceresoli@bootlin.com>
Tested-by: Luca Ceresoli <luca.ceresoli@bootlin.com>
Link: https://lore.kernel.org/r/20240224052436.3552333-1-saravanak@google.com
Signed-off-by: Rob Herring <robh@kernel.org>
2024-03-01 15:28:17 -06:00
Linus Torvalds
d17468c6f1 RISC-V Fixes for 6.8-rc7
* A fix for detecting ".option arch" support on not-yet-released LLVM
   builds.
 * A fix for a missing TLB flush when modifying non-leaf PTEs.
 * A handufl of fixes for T-Head custom extensions.
 * A fix for systems with the legacy PMU, that manifests as a crash on
   kernels built without SBI PMU support.
 * A fix for systems that clear *envcfg on suspend, which manifests as
   cbo.zero trapping after resume.
 * A pair of fixes for Svnapot systems, including removing Svnapot
   support for huge vmalloc/vmap regions.
 -----BEGIN PGP SIGNATURE-----
 
 iQJHBAABCAAxFiEEKzw3R0RoQ7JKlDp6LhMZ81+7GIkFAmXh8A0THHBhbG1lckBk
 YWJiZWx0LmNvbQAKCRAuExnzX7sYif7tD/9mlPpK/OZs9U8DXVpZU91iEekVU7ss
 CWY+Y9+fx9hjOahqUgJ72aG6mj5p9DW9cqz+73Ktds4xGCrh3Sr734nAFTshpo2K
 IiKx+Ruq6YIURzXMcNuQ4JHAOMI4P4p34cha+fZ5ORPXRKLJQqBR3eNFBa5NHuR4
 md6TaU0gJAZE3yY2llLJOPlj9cT8swPV4gc8I0pUb4gKYj3sU/2HWVEYfiBoDnjo
 XUSNV2ts9mWv7OGgBqS1QqdZeFKizPp87PRfzNBye5Gx8mpUXS52Z+W7vr6f/EUf
 stWhDnR2XQ2HYSPoo5rQqIfZHH9dp+DUtqGjNo+jX54OoFAvHHtlhrEVC4q3uGkY
 Y3RoIe17s1EvozMKXCVQ+tCrhOh/jttye5Om5gb8yJ2clATL5dJM/jkoMKMdIh5n
 KLhZBYLrgN/Z0Mb0wePnlXhVnW2/N4ruIlP5Kd+wHRR+rUlQm6Xjccg4r5MgxMgK
 iaVbBZ/JTkJhP/II5ACr519Mz5Nh2N1QKTQkbHA5XWrn9+SDnF9Dio/EurPshvmm
 xJYcG42sxkI4V9UEmriyiAs6NqIDTKyNoA28WXYLVDCrFomtehmttS9RWE7FqPku
 mAUIUd3hbP4Qrt81Gus+CwCIZSuVhJin+3VUAI6Z6FpImDoamquJvIQ3aYtZ/nye
 pDSC3QhivYUA6A==
 =FpVN
 -----END PGP SIGNATURE-----

Merge tag 'riscv-for-linus-6.8-rc7' of git://git.kernel.org/pub/scm/linux/kernel/git/riscv/linux

Pull RISC-V fixes from Palmer Dabbelt:

 - detect ".option arch" support on not-yet-released LLVM builds

 - fix missing TLB flush when modifying non-leaf PTEs

 - fixes for T-Head custom extensions

 - fix for systems with the legacy PMU, that manifests as a crash on
   kernels built without SBI PMU support

 - fix for systems that clear *envcfg on suspend, which manifests as
   cbo.zero trapping after resume

 - fixes for Svnapot systems, including removing Svnapot support for
   huge vmalloc/vmap regions

* tag 'riscv-for-linus-6.8-rc7' of git://git.kernel.org/pub/scm/linux/kernel/git/riscv/linux:
  riscv: Sparse-Memory/vmemmap out-of-bounds fix
  riscv: Fix pte_leaf_size() for NAPOT
  Revert "riscv: mm: support Svnapot in huge vmap"
  riscv: Save/restore envcfg CSR during CPU suspend
  riscv: Add a custom ISA extension for the [ms]envcfg CSR
  riscv: Fix enabling cbo.zero when running in M-mode
  perf: RISCV: Fix panic on pmu overflow handler
  MAINTAINERS: Update SiFive driver maintainers
  drivers: perf: ctr_get_width function for legacy is not defined
  drivers: perf: added capabilities for legacy PMU
  RISC-V: Ignore V from the riscv,isa DT property on older T-Head CPUs
  riscv: Fix build error if !CONFIG_ARCH_ENABLE_HUGEPAGE_MIGRATION
  riscv: mm: fix NOCACHE_THEAD does not set bit[61] correctly
  riscv: add CALLER_ADDRx support
  RISC-V: Drop invalid test from CONFIG_AS_HAS_OPTION_ARCH
  kbuild: Add -Wa,--fatal-warnings to as-instr invocation
  riscv: tlb: fix __p*d_free_tlb()
2024-03-01 12:44:33 -08:00
Linus Torvalds
5870ba3dc6 A patch to catch up with mdsmap encoding rectification which ended up
being necessary after all to enable cluster upgrades from problematic
 v18.2.0 and v18.2.1 releases.
 -----BEGIN PGP SIGNATURE-----
 
 iQFHBAABCAAxFiEEydHwtzie9C7TfviiSn/eOAIR84sFAmXiERQTHGlkcnlvbW92
 QGdtYWlsLmNvbQAKCRBKf944AhHzixs3B/0a4oo8pguKFwv7nRoPhj8psutefUo4
 DAclob36DA+7BZEPEOfcRC++fwQpuX1Xjly5hTouIvX5kJ8MbZh0HIstS8zr73XF
 DJxK+WO+mMieR7k5Ig4zjUc6Vm5JOxl4DWMo/r/+v6/tVIsD1mvvXrrtQkr/HBXs
 8OXimd1XshI7Y7z2q/liT8K5ozf1Wa0adBOeOmke0TSfJm81uauao3ZHvNkO5yE+
 zAa7XRtczYPgn5sA9ydUY5PYUUPYEtkarn1s12W42fudM5VHI2Ui6tSTcCUr6lTU
 UQRElSXygvpptl4PuFlkLdUoiTItfiF1X6TqQ5zrUnjOBVBr9v4Xz8hL
 =YrOC
 -----END PGP SIGNATURE-----

Merge tag 'ceph-for-6.8-rc7' of https://github.com/ceph/ceph-client

Pull ceph fix from Ilya Dryomov:
 "Catch up with mdsmap encoding rectification which ended up being
  necessary after all to enable cluster upgrades from problematic
  v18.2.0 and v18.2.1 releases"

* tag 'ceph-for-6.8-rc7' of https://github.com/ceph/ceph-client:
  ceph: switch to corrected encoding of max_xattr_size in mdsmap
2024-03-01 12:34:23 -08:00
Linus Torvalds
7505aa147a for-6.8-rc6-tag
-----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCgAdFiEE8rQSAMVO+zA4DBdWxWXV+ddtWDsFAmXh1GgACgkQxWXV+ddt
 WDtnvA/7BN7BZ6QmwWv9UyxhgSBtzI19AXPi/kBsssnnjNuzXoHFaVHj68lQCCOB
 a4YjRxAg7nmwFGHdVDTdnwXgUECzqlVkeX9cXg1ZpJy0IfP9RriGedRlC/93z7aV
 pg6DnKMh2FlkibK7yO6kRBR8RYLc5aVIytqHXgUeqbaquuhj2Hh8EpqRo2X0RsoE
 wDXlK0qgrU8HyrA3fHdqKYPcm1+cYABGTCwGx65iRffy8vH+KFSAr71G8jOJVEUj
 DgNWJCpBjXJNs0dsKrik5oGmvLd3GDBKinNX7R2mAvMAMGWrL+fVVTVTfBS/clUT
 FBiVFNYCJuphMcO3Qjs6JIuEez0GuGEeh1m+tQ8W795At1FSiINtE5J7LjmJUl5X
 FuUwOUpxco1lTXBLX149Y9kk7AEOaqYxy0XbH4r5bbKyuzQegRGB9/qQX4sSaCt3
 3T+Td9PvS+6Jo+CDO0dsYhG/h3bsHeHtHGR6f2CiO/m1zHDnTX9aYVcLMM3hsrMI
 8OUEy1jkuKnDZQuZuIWES/3V9FlJL34dR3Cb236Pv/yIH1iujIc27g0qXrC1vzPg
 wnUL1wheLQ9IRLedXoiHtX2Y2ZfFQGQDrIKNCJFD+WNPkZYffih5QNTV/mPZmL80
 9EbjoVTu+6rygzdD43R1RWvK0kFsY44RKhHreI8SItO+e3/0TAs=
 =hMf8
 -----END PGP SIGNATURE-----

Merge tag 'for-6.8-rc6-tag' of git://git.kernel.org/pub/scm/linux/kernel/git/kdave/linux

Pull btrfs fixes from David Sterba:

 - fix freeing allocated id for anon dev when snapshot creation fails

 - fiemap fixes:
     - followup for a recent deadlock fix, ranges that fiemap can access
       can still race with ordered extent completion
     - make sure fiemap with SYNC flag does not race with writes

* tag 'for-6.8-rc6-tag' of git://git.kernel.org/pub/scm/linux/kernel/git/kdave/linux:
  btrfs: fix double free of anonymous device after snapshot creation failure
  btrfs: ensure fiemap doesn't race with writes when FIEMAP_FLAG_SYNC is given
  btrfs: fix race between ordered extent completion and fiemap
2024-03-01 12:29:20 -08:00
Linus Torvalds
3aec97e0c7 Description for this pull request:
- Fix ftruncate failure when allocating non-contiguous clusters.
 -----BEGIN PGP SIGNATURE-----
 
 iQJKBAABCgA0FiEE6NzKS6Uv/XAAGHgyZwv7A1FEIQgFAmXhiBkWHGxpbmtpbmpl
 b25Aa2VybmVsLm9yZwAKCRBnC/sDUUQhCFRdD/47DYPGhZPWt4+JamGs3ZR0WX8l
 555GnbSjzLmmGUYjEyDsMmJllL7I0gX3Hm2QNOJIce1ETh3a2oSQlp+O+uIJM7zW
 rQjV8l6u+JZXEvpZwbfIfpyQ2+p6wFgueFC8+HX+VwfiJXw0hKNfqIwugjyRiWUF
 P1pptVZvsne2d7dUM8nmwedFZClP2GhyFxPqOiAvPd6Yw5s6b2yOj534eU9JSWfp
 ph/ZVnZOZNwaKUPD57OWYFKb4hLHEDTpjWjpU1jXkdeKCAB9WuJyegJMtznJIaBW
 DtkDmaUeQLPccWFWlZXOPvZfueJuWU1rxzGCqYBOvP77SPDATxqgFh5yhRj5wqnx
 Cs//VqFY6fZC6HfXAURvbM6l+NblaH1m6Bm7o7PkbBScju9tyKByqMNGLtHHnH2V
 y8jD8mFj2wjvwD+6EBdIVD7ddr1M8uyPUpk++gYxklpSDwwzngkqpUItYCv1sKhD
 tlwyPY5efDXC1e38KWTmbhGh0UACz8pVNPbFZsQ7jVlvKlAoT+/T4SGz4t+4qXpA
 IEo36PYEznxNZllf5/kTQ/yzVjPuX2K0CVTvNb01nTdGfHE1p8Uvt1nWJr2nRall
 vSsOswEbJ78O+313+HCWL2WreqlN4yCVhh+cpyinGLZgrQwBMl4uJrgBb0XxwTD6
 0PjItbRcF4C+Bo4tGw==
 =LfJg
 -----END PGP SIGNATURE-----

Merge tag 'exfat-for-6.8-rc7' of git://git.kernel.org/pub/scm/linux/kernel/git/linkinjeon/exfat

Pull exfat fix from Namjae Jeon:

 - Fix ftruncate failure when allocating non-contiguous clusters

* tag 'exfat-for-6.8-rc7' of git://git.kernel.org/pub/scm/linux/kernel/git/linkinjeon/exfat:
  exfat: fix appending discontinuous clusters to empty file
2024-03-01 12:22:30 -08:00
Linus Torvalds
1678f8d85d vfs-6.8-rc7.fixes
-----BEGIN PGP SIGNATURE-----
 
 iHUEABYKAB0WIQRAhzRXHqcMeLMyaSiRxhvAZXjcogUCZeHE0QAKCRCRxhvAZXjc
 ojUoAQDaH72HFy7vw9/5x9IN1LfbwWLNmFpF2eFVWIB/xnJaMAD/aPOxqBSHfC7W
 kam84prsnQcOh3wNF5j23HSR9HS79gw=
 =5YAw
 -----END PGP SIGNATURE-----

Merge tag 'vfs-6.8-rc7.fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/vfs/vfs

Pull vfs fixes from Christian Brauner:
 "Two small fixes:

   - Fix an endless loop during afs directory iteration caused by not
     skipping silly-rename files correctly.

   - Fix reporting of completion events for aio causing leaks in
     userspace. This is based on the fix last week as it's now possible
     to recognize aio events submitted through the old aio interface"

* tag 'vfs-6.8-rc7.fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/vfs/vfs:
  fs/aio: Make io_cancel() generate completions again
  afs: Fix endless loop in directory parsing
2024-03-01 12:17:02 -08:00
Linus Torvalds
17ba56605b IOMMU fix for Linux v6.8-rc6:
- Fix SVA handle sharing in multi device case
 -----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCAAdFiEEr9jSbILcajRFYWYyK/BELZcBGuMFAmXh7h8ACgkQK/BELZcB
 GuOcaA//QlD6S6U1mQ3Su/Nisfw/5GQK80wRpE9w3VmdyXvRXqrzecxQYAcBKbRY
 3if2nsWIexB2RRPkmRIGe4NT5MrIPRZuzjLBu+IPvuZGEiEDX8GNw5LafJ8otogH
 GPlOpEVzdx5EGQsqPR7iPzTDuHWjcPl6Fclfc9g17F0MgOHQiRmdcJo41azCJnj7
 qabBnu5uItva1/kN9ipgliRCmtU/DcHWVPnOhDVvmKK4lvsaKSn2kpWAVmuNU/ht
 6DIKsZiowjXAVdKz0WBpfL9bmllVQsvtYUG0YJu3oQikH2UoASDn2i6+GJUr1OB9
 7N6C9+YCtl5Tm7GV+91JnbNJ9Q2juSD9hRo22GauNmjS6Go5zW14T88NiF1p14pu
 Whn2C1jybGTYOAa/6Mn7D6wSDDrJ7jz79Vd4Q+ehXAD0WWeDmiat6T1Hxkrb23nE
 jfvlDUHF7oNEA6pjRNoouyUvcmT5MMBPmgayRlBDpSxHhO32O9mU0cLW7b4lt+px
 l+JQKgLADbi3W7qE19VkH/9qhCt3TGFaSwWdu+dB0b/IxeW0zqxl+BjOcBG3F0HD
 ocU63Zxm+u4VYZm9tsHhpql90914Iyr2kn8MJg0XXtwpzh9ErNcYG6wHVyh+Mh2J
 Za8tizN1KmSxd4RL9J+xlU8neY9y5y1D4OCS/hXjR5hqvaRe6XM=
 =VVrn
 -----END PGP SIGNATURE-----

Merge tag 'iommu-fix-v6.8-rc6' of git://git.kernel.org/pub/scm/linux/kernel/git/joro/iommu

Pull iommu fix from Joerg Roedel:

 - Fix SVA handle sharing in multi device case

* tag 'iommu-fix-v6.8-rc6' of git://git.kernel.org/pub/scm/linux/kernel/git/joro/iommu:
  iommu/sva: Fix SVA handle sharing in multi device case
2024-03-01 12:01:43 -08:00
Linus Torvalds
371e4a1f91 MMC core:
- Fix eMMC initialization with 1-bit bus connection
 
 MMC host:
  - mmci: Fix DMA API overlapping mappings for the stm32 variant
  - sdhci-xenon: Fix PHY stability issues
 -----BEGIN PGP SIGNATURE-----
 
 iQJLBAABCgA1FiEEugLDXPmKSktSkQsV/iaEJXNYjCkFAmXhqHMXHHVsZi5oYW5z
 c29uQGxpbmFyby5vcmcACgkQ/iaEJXNYjClzsA//QxUuGQKkjYZIRt0KKYfXA8v/
 bHW1cAK+xMmklm2XLHCE2U7ckZGdWFRCNiotXQa4iYyVFAUpx5zFYdszXZbaJkqy
 1Q4Zbl014NoxAijuJoMWPZPNThMwWtl11ZEw3hEO8d5it3g+kH7GafrdRINRDUeK
 VLhRpaUdMdjXLdEfrM9vv9slE4wA3qwGKRLm1D4H0YpDL/hPHa/tJRmcw3hCxEYO
 wzjza+tGKDi9oZdg/7H0HVZW2Yf0jImAAIvwXgLhF1Zm7LVzQxG5fW9VV5tc/Yi5
 XDi/UtjJhqoEudLCd+tK59uJa8PE0x//Uo3wNJ1nujy/5Av6J9+RV0Dk/oamF/O2
 o7wrWsdtZF/MoDQ3Fp7jjy3uqUFFMQreDM4TEEFr7+ZF0fT7mKPNB7YKms40+dI5
 mzhDdIWKedJffmj8zRipqkGfp6oIX5bj3h8AwSjLmu7N1lRyJu0TuBLzVCwASdQj
 +dc/xS7k9/MjDPXj2vppiS2ALygMArMEFTk9rdJj4HMDsMAgjDcBkeGH7tn6Bs6S
 ntTdY8DH5E+N9n2IZezsUbm81gI84r/jfZ30Iol2rkfCAuryVVdmbTVGsKgCrCX0
 M1oT7oPjMPfEjeXSw8qO0crZbBRugPANDxhTxahaGJ3jbJkY+aXjYBJuROYk+myR
 Px30aQTBJpDZM921Alw=
 =PO2r
 -----END PGP SIGNATURE-----

Merge tag 'mmc-v6.8-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/ulfh/mmc

Pull MMC fixes from Ulf Hansson:
 "MMC core:
   - Fix eMMC initialization with 1-bit bus connection

  MMC host:
   - mmci: Fix DMA API overlapping mappings for the stm32 variant
   - sdhci-xenon: Fix PHY stability issues"

* tag 'mmc-v6.8-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/ulfh/mmc:
  mmc: sdhci-xenon: add timeout for PHY init complete
  mmc: sdhci-xenon: fix PHY init clock stability
  mmc: mmci: stm32: fix DMA API overlapping mappings warning
  mmc: core: Fix eMMC initialization with 1-bit bus connection
2024-03-01 11:55:19 -08:00
Linus Torvalds
fafbad4a20 Providers:
- qcom: Fix enabled_corner aggregation for rpmhpd
  - arm: Fix NULL dereference on scmi_perf_domain removal
 -----BEGIN PGP SIGNATURE-----
 
 iQJLBAABCgA1FiEEugLDXPmKSktSkQsV/iaEJXNYjCkFAmXhpP8XHHVsZi5oYW5z
 c29uQGxpbmFyby5vcmcACgkQ/iaEJXNYjCnHZBAAynC53E42DsyteCF6uqhatamj
 06pNVGQe+7GqFQfpDgvwobM3mznAOIiEnh1omUqoA0eQH8ZM411fWDOflqpey+et
 sE2NLSPmTc7UJdCoAxXVspC+cVI0e+ZE8u2752FG1ARaEO7z+jlu/QPLkWQ5/kgh
 kuZVDtGQv6uQhG+ZsUqnaHfcrvZIB7Q+sD2YiGxTka3/c8HWbig0x2gQp/fwQO3G
 AAmS7HudBvctqWCDnjSTDv426d2rXdyDeUEDVWg/2NC8I64QRyIg4DZ/dI4oJvqa
 cJdHSfLZRhGFap0A4143cn7u054zZD430xWeMKheOwHjGrtmxhEcGHYGODCOjaVo
 R4vaeE35rnhqCLjiRHkOiuQQmysx/I/hlbu+DVkGJat9mKmwbrJvHKzO1AFD2kuX
 D9cRMTFn6T2vm44Av71l1Sm9fExYRsyHgdtatABPPd7ede+Y8rBs9AHtEU1Xd2Wb
 3moJsHinfZ//ffVsKsIe7EkUTp8Jk8OPZKkv+gbJczl4qvCt9Gu77U1cAygigBOF
 l4VyhWM7XAFU+aENZ9uob8S2NptXmYkZB1hv1ZKlnGt3+W88naY/BE533ifdGMXf
 DqYhjtWZG5LMVn0VkvJDxCJOM0MTE30yMCa8KeJSZfCgl+SbpsShwOFCzxuZlVHJ
 5lcuRv2v9ENh41khTi8=
 =e1Rr
 -----END PGP SIGNATURE-----

Merge tag 'pmdomain-v6.8-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/ulfh/linux-pm

Pull pmdomain fixes from Ulf Hansson:

 - qcom: Fix enabled_corner aggregation for rpmhpd

 - arm: Fix NULL dereference on scmi_perf_domain removal

* tag 'pmdomain-v6.8-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/ulfh/linux-pm:
  pmdomain: qcom: rpmhpd: Fix enabled_corner aggregation
  pmdomain: arm: Fix NULL dereference on scmi_perf_domain removal
2024-03-01 11:52:27 -08:00
Linus Torvalds
2bbb54ba1b EFI fixes for v6.8 #2
- Fix phys_addr_t size confusion in 32-bit capsule loader
 - Reduce maximum EFI variable name size to 512 to work around buggy
   firmware
 - Drop some redundant code from efivarfs while at it
 -----BEGIN PGP SIGNATURE-----
 
 iHUEABYIAB0WIQQQm/3uucuRGn1Dmh0wbglWLn0tXAUCZdr/HgAKCRAwbglWLn0t
 XGqrAP96SmiLbkEBzBAkjpIvQIwoiPUAQmfBXs4PuZ6MH/aq3wEA0VOxxH8CpVAu
 dpjd2HIjO59zMr4G7BvR/ezit3Gp2A0=
 =Bd3Z
 -----END PGP SIGNATURE-----

Merge tag 'efi-fixes-for-v6.8-2' of git://git.kernel.org/pub/scm/linux/kernel/git/efi/efi

Pull EFI fixes from Ard Biesheuvel:
 "Only the EFI variable name size change is significant, and will be
  backported once it lands. The others are cleanup.

   - Fix phys_addr_t size confusion in 32-bit capsule loader

   - Reduce maximum EFI variable name size to 512 to work around buggy
     firmware

   - Drop some redundant code from efivarfs while at it"

* tag 'efi-fixes-for-v6.8-2' of git://git.kernel.org/pub/scm/linux/kernel/git/efi/efi:
  efivarfs: Drop 'duplicates' bool parameter on efivar_init()
  efivarfs: Drop redundant cleanup on fill_super() failure
  efivarfs: Request at most 512 bytes for variable names
  efi/capsule-loader: fix incorrect allocation size
2024-03-01 11:40:29 -08:00
Linus Torvalds
fbf9e3b697 sound fixes for 6.8-rc7
The amount of changes wasn't as small as wished, but all reasonably
 small fixes.  There is a PCM core API change, which is for correcting
 the behavior change we took in 6.8.  The rest are device-specific
 fixes for ASoC AMD, Qualcomm, Cirrus codecs, HD-audio quirks & co.
 -----BEGIN PGP SIGNATURE-----
 
 iQJCBAABCAAsFiEEIXTw5fNLNI7mMiVaLtJE4w1nLE8FAmXgjKoOHHRpd2FpQHN1
 c2UuZGUACgkQLtJE4w1nLE82Wg/9Ht2/Po7+Vvl44hh3f5VtLjytZ0TAlxt/OQTM
 ZZVfZuBEUggps7EGXYemvPWHOw1ycTiw8+Me7Pk1RiG3Q567vvp25k9LL33I7Tio
 be4GobIn6wRdArIbvfZuhqdM8InbhQqz+cXFMW5rV0QbHL+IwNWlLVTym1NObRaF
 7aYI2dUAJ8YJUPRpbVjFEvk+vSo9cCYZulqYCzhLda2/G9nRraW+fynpqhJfiixA
 Lz9T8i+978nh81wR1DQtWCqkExW0ICIVFIM6wnr+eIyJEN1g/kxF6dBNfxzRdSKM
 pl64l8fWdOBXsOjCcu41eDDX4DputTt4p9z8KUmu0tOHfofVr4KLghOQk4SBirs2
 ipBJtCIyZvh26tdLwRgSviWiZrt2kbP5JwNaayYvj9v9GzBH4TJLhTGb/6xk8TT0
 XcRHjbozqckVChGNjKPsQ2rJ+AD8dEdAH7C4n0VAT9odLEv7ldQj8gdZbjfMVzgw
 gXIjhYpMtuk5eDxuvS3OHaKpDiyIopMIz/IWaH2kXxriI23ibBM1AoK65UHrhFVY
 ZL47jbSQ0d2XvSTigQ2/KqYzT48A9ozAI5bOfGsoqqMCxkYGACjQM8B9sAPQ9XbL
 3R2ry6ilCqJ90H0X5a0JvUxegGmbakaYxB059mmMHkMynZnNO+mRqZWi5W83yAaA
 6HaZWHk=
 =Zk6g
 -----END PGP SIGNATURE-----

Merge tag 'sound-6.8-rc7' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound

Pull sound fixes from Takashi Iwai:
 "The amount of changes wasn't as small as wished, but all reasonably
  small fixes. There is a PCM core API change, which is for correcting
  the behavior change we took in 6.8. The rest are device-specific fixes
  for ASoC AMD, Qualcomm, Cirrus codecs, HD-audio quirks & co"

* tag 'sound-6.8-rc7' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound:
  ASoC: amd: yc: Fix non-functional mic on Lenovo 21J2
  ASoC: amd: yc: add new YC platform variant (0x63) support
  ALSA: hda/realtek - ALC285 reduce pop noise from Headphone port
  ASoC: amd: yc: Add Lenovo ThinkBook 21J0 into DMI quirk table
  ALSA: hda/realtek: Add special fixup for Lenovo 14IRP8
  ASoC: soc-card: Fix missing locking in snd_soc_card_get_kcontrol()
  ALSA: hda/realtek: tas2781: enable subwoofer volume control
  ALSA: pcm: clarify and fix default msbits value for all formats
  ASoC: qcom: Fix uninitialized pointer dmactl
  ALSA: hda/realtek: fix mute/micmute LED For HP mt440
  ALSA: Drop leftover snd-rtctimer stuff from Makefile
  ALSA: ump: Fix the discard error code from snd_ump_legacy_open()
  ALSA: hda/realtek: Enable Mute LED on HP 840 G8 (MB 8AB8)
  ASoC: cs35l56: Must clear HALO_STATE before issuing SYSTEM_RESET
  ALSA: hda/realtek: Fix top speaker connection on Dell Inspiron 16 Plus 7630
  ALSA: firewire-lib: fix to check cycle continuity
2024-03-01 11:32:41 -08:00