Commit graph

1123689 commits

Author SHA1 Message Date
Zeng Heng
03764b30a4 Kconfig: remove unused function 'menu_get_root_menu'
There is nowhere calling `menu_get_root_menu` function,
so remove it.

Signed-off-by: Zeng Heng <zengheng4@huawei.com>
Signed-off-by: Masahiro Yamada <masahiroy@kernel.org>
2022-09-24 04:30:30 +09:00
yangxingwu
237fe72749 scripts/clang-tools: remove unused module
Remove unused imported 'os' module.

Signed-off-by: yangxingwu <xingwu.yang@gmail.com>
Reviewed-by: Nathan Chancellor <nathan@kernel.org>
Signed-off-by: Masahiro Yamada <masahiroy@kernel.org>
2022-09-24 04:30:06 +09:00
Ming Lei
df02452f3d cgroup: cgroup_get_from_id() must check the looked-up kn is a directory
cgroup has to be one kernfs dir, otherwise kernel panic is caused,
especially cgroup id is provide from userspace.

Reported-by: Marco Patalano <mpatalan@redhat.com>
Fixes: 6b658c4863 ("scsi: cgroup: Add cgroup_get_from_id()")
Cc: Muneendra <muneendra.kumar@broadcom.com>
Signed-off-by: Ming Lei <ming.lei@redhat.com>
Acked-by: Mukesh Ojha <quic_mojha@quicinc.com>
Cc: stable@vger.kernel.org # v5.14+
Signed-off-by: Tejun Heo <tj@kernel.org>
2022-09-23 07:18:45 -10:00
Linus Torvalds
1707c39ae3 Driver core fixes for 6.0-rc7
Here are two tiny driver core fixes for 6.0-rc7 that resolve some
 oft-reported problems.
 
 The first is a revert of the "fw_devlink.strict=1" default option that
 we keep trying to enable, but we keep finding platforms that this just
 breaks everything on.  So again, we need it reverted and hopefully it
 can be worked on in future releases.
 
 The second is a sysfs file-size bugfix that resolves an issue that many
 people are starting to hit as the fix it is fixing also was backported
 to stable kernels.  The util-linux developers are starting to get
 bugreports about sysfs files that contain no data because of this
 problem, and this fix which has been in linux-next in the bitfield tree
 for a long time, resolves it.  I'm submitting it here as it needs to be
 merged for 6.0-final, not for 6.1-rc1.
 
 Both of these have been in linux-next with no reported issues, only
 reports were that these fixed problems.
 
 Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
 -----BEGIN PGP SIGNATURE-----
 
 iG0EABECAC0WIQT0tgzFv3jCIUoxPcsxR9QN2y37KQUCYy3LhQ8cZ3JlZ0Brcm9h
 aC5jb20ACgkQMUfUDdst+ymQQQCgk1+jPfT3ilkWStWIxl3RVM/jl3YAn3ZAMFPk
 Mjqt3ltW9+Xzh/XniahY
 =OYfO
 -----END PGP SIGNATURE-----

Merge tag 'driver-core-6.0-rc7' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/driver-core

Pull driver core fixes from Greg KH:
 "Here are two tiny driver core fixes for 6.0-rc7 that resolve some
  oft-reported problems.

  The first is a revert of the "fw_devlink.strict=1" default option that
  we keep trying to enable, but we keep finding platforms that this just
  breaks everything on. So again, we need it reverted and hopefully it
  can be worked on in future releases.

  The second is a sysfs file-size bugfix that resolves an issue that
  many people are starting to hit as the fix it is fixing also was
  backported to stable kernels. The util-linux developers are starting
  to get bugreports about sysfs files that contain no data because of
  this problem, and this fix which has been in linux-next in the
  bitfield tree for a long time, resolves it. I'm submitting it here as
  it needs to be merged for 6.0-final, not for 6.1-rc1.

  Both of these have been in linux-next with no reported issues, only
  reports were that these fixed problems"

* tag 'driver-core-6.0-rc7' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/driver-core:
  drivers/base: Fix unsigned comparison to -1 in CPUMAP_FILE_MAX_BYTES
  Revert "driver core: Set fw_devlink.strict=1 by default"
2022-09-23 09:12:18 -07:00
Linus Torvalds
33a4e37ebc USB / Thunderbolt driver fixes and ids for 6.0-rc7
Here are a few small USB and Thunderbolt driver fixes and new device ids
 for 6.0-rc7.
 
 They contain:
 	- new usb-serial driver ids
 	- documentation build warning fix in USB hub code
 	- flexcop-usb long-posted bugfix (the v4l maintainer for this is
 	  MIA so I have finally picked this up as it is a fix for a
 	  reported problem.)
 	- dwc3 64bit DMA bugfix
 	- new thunderbolt device ids
 	- typec build error fix
 
 All of these have been in linux-next with no reported issues.
 
 Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
 -----BEGIN PGP SIGNATURE-----
 
 iG0EABECAC0WIQT0tgzFv3jCIUoxPcsxR9QN2y37KQUCYy3Mew8cZ3JlZ0Brcm9h
 aC5jb20ACgkQMUfUDdst+ykt8ACg0kKcrj40WNlj9iy3TH2FNBIxXXIAoIMUs4Oe
 rw0jU8KQGf+8NAKXwH87
 =Q7cc
 -----END PGP SIGNATURE-----

Merge tag 'usb-6.0-rc7' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb

Pull USB / Thunderbolt driver fixes and ids from Greg KH:
 "Here are a few small USB and Thunderbolt driver fixes and new device
  ids for 6.0-rc7.

  They contain:

   - new usb-serial driver ids

   - documentation build warning fix in USB hub code

   - flexcop-usb long-posted bugfix (the v4l maintainer for this is MIA
     so I have finally picked this up as it is a fix for a reported
     problem.)

   - dwc3 64bit DMA bugfix

   - new thunderbolt device ids

   - typec build error fix

  All of these have been in linux-next with no reported issues"

* tag 'usb-6.0-rc7' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb:
  usb: typec: anx7411: Fix build error without CONFIG_POWER_SUPPLY
  media: flexcop-usb: fix endpoint type check
  USB: serial: option: add Quectel RM520N
  USB: serial: option: add Quectel BG95 0x0203 composition
  thunderbolt: Add support for Intel Maple Ridge single port controller
  usb: dwc3: core: leave default DMA if the controller does not support 64-bit DMA
  USB: core: Fix RST error in hub.c
2022-09-23 09:07:08 -07:00
Linus Torvalds
9395cd7cef Landlock fix for v6.0-rc7
-----BEGIN PGP SIGNATURE-----
 
 iIYEABYIAC4WIQSVyBthFV4iTW/VU1/l49DojIL20gUCYy2I2hAcbWljQGRpZ2lr
 b2QubmV0AAoJEOXj0OiMgvbSO6IA/0JQ+wSbd7M2LgSoaXqSf5jgOTtcwyN5i7CR
 1t6UwB9AAQCkE5iX3+BQpUAMyBTJinISvjf9C0vNyWiLyUlDSxgPBw==
 =CqGg
 -----END PGP SIGNATURE-----

Merge tag 'landlock-6.0-rc7' of git://git.kernel.org/pub/scm/linux/kernel/git/mic/linux

Pull landlock fix from Mickaël Salaün:
 "Fix out-of-tree builds for Landlock tests"

* tag 'landlock-6.0-rc7' of git://git.kernel.org/pub/scm/linux/kernel/git/mic/linux:
  selftests/landlock: Fix out-of-tree builds
2022-09-23 08:59:16 -07:00
Linus Torvalds
a7b7751aeb RISC-V Fixes for 6.0-rc7
* A handful of build fixes for the T-Head errata, including some
   functional issues the compilers found.
 * A fix for a nasty sigreturn bug.
 -----BEGIN PGP SIGNATURE-----
 
 iQJHBAABCAAxFiEEKzw3R0RoQ7JKlDp6LhMZ81+7GIkFAmMtlZYTHHBhbG1lckBk
 YWJiZWx0LmNvbQAKCRAuExnzX7sYifj4EAC/POyM8gOYkiaaAgMvjeNTiJYdvBq/
 ZuWBpnmDfayXyg+OHRpe2EQDJL51oDLA0LejN3V0C3fMOA1/zvrb/2LGbwd8v3Ly
 i/Lm9/18P6MJo3vSZ0A5DEOZKj41QsoGd5PIn8uuYT8nYQhCtm2g2ug8lX5Eb3QH
 pI9xjYZWI3nJ8/ah7NOrtB7LWan8BZdH6VuPBKN6zbG466Td7jT3QFQuyw4Ri0Lk
 rbMifm985EUEs/o9X+ObXmi+5M1PoAw+DVMeFq7VkgkHHBwCuVBlEd80wT6wT//1
 qSPQh5i/zs7GT5o8fgRQ+VJCLBh2s3meIFPa3TZ+fkh17w8Ww7tx+NtcOFgp6jWP
 NcPsaF8tokOwNVJNbFdCjXRAHxc6TuZ8hfjj+IsDxxbit9BMVSXdEpeOjURbLCNX
 HI3qooTCIBYh+9CzK3dF+ep0dnGC/awBnoLoH8UgNVxmitSVyc5PgR4w3NBpjoO8
 Htxl1ESll8nIXam6Rzi0UHgDgmMCRNdrW6vil/QD9UNcBYbkrUWhD/PmTfH+2uYC
 UtfzVCnXpeDRkLbNxBMwBGSsb/kMl1hkHcMbXRRgIQRxzqRPs69K8umcc6Xy+3AB
 timl5kzIeGid0nFG1+H67uGjc8Ea0RW3awel2Y8PmCGJDUNMBmKlizqrwMDfZrB0
 HxxG8vcuPF7zWg==
 =9l0i
 -----END PGP SIGNATURE-----

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

Pull RISC-V fixes from Palmer Dabbelt:

 - A handful of build fixes for the T-Head errata, including some
   functional issues the compilers found

 - A fix for a nasty sigreturn bug

* tag 'riscv-for-linus-6.0-rc7' of git://git.kernel.org/pub/scm/linux/kernel/git/riscv/linux:
  RISC-V: Avoid coupling the T-Head CMOs and Zicbom
  riscv: fix a nasty sigreturn bug...
  riscv: make t-head erratas depend on MMU
  riscv: fix RISCV_ISA_SVPBMT kconfig dependency warning
  RISC-V: Clean up the Zicbom block size probing
2022-09-23 08:51:05 -07:00
Arnd Bergmann
2653853e2a Reset controller fixes for v6.0
Fix the i.MX8MP PCIe PHY PERST bit polarity, issue the Sparx5 "switch"
 reset (which turned out to be a rather more global reset) early on
 startup, stubbing out the reset controller driver, and fix the NPCM8XX
 USB reset sequence by setting IPSRST4 bits in the correct register.
 -----BEGIN PGP SIGNATURE-----
 
 iI0EABYIADUWIQRRO6F6WdpH1R0vGibVhaclGDdiwAUCYy3D5hcccC56YWJlbEBw
 ZW5ndXRyb25peC5kZQAKCRDVhaclGDdiwKXfAP0WI8iTRGZIfqUsfuf+RevV1J5I
 fSkDCp/kSMJGAZECDAD+K4uV9Gb+gP00HQa+Q/oXr1oPhfmwDZ3w3hHZZ49sEwE=
 =OPnR
 -----END PGP SIGNATURE-----
gpgsig -----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCgAdFiEEo6/YBQwIrVS28WGKmmx57+YAGNkFAmMt1IoACgkQmmx57+YA
 GNmhJw//bNlWf5jsplx51Nl+G2BZGMzHqe8Dd+C0lokif6tAag7LfV2vSpCR75v0
 /Qw9oBHHltXKXE373V417vfzn9FZL5E9ICoU+b88PLI/j+NPQ83SNz17uDgOtSyY
 nuyw+RosrvUEryc7m2HWTwbbMz3w2EEzM1K5/x6++04XykbQlP2uvljvS4zro6Vg
 bVXvRzDwjEscdCpVncpJ+kMJi0M9kii8puRia9xXEVu/ZwKlZvezOWFWYZkBCjRC
 IU4YVJJ548wRPSKz3OgvBb5oEVVmrcg7NYeDVls6kcx4YiUL0uSGBzT9rLcvgw4B
 NBjGzYhYyb5tsa9Bo+p70odHk6JHnkKMLDkuInv+YI/FW/vMZVfg+MRB35EyJRFA
 Bvy6OboSommyxjmUV9A020FPWN3U5Xz/tVifWSzsdvXMoLfdLHF6bj1jc9bnvX5j
 65Nixrqj9FVeliR9rkUuUKTEjww6lGF7rnV0EjNsEalRWNaY4Gll9urSc2f8BInR
 aymUXm4c6AoLiOHS8VB2aaRlZnxx1arHLpQWnJXtR4EPLo/DG+z/cPCdeoz3oGbs
 GRfp+wFduJOvykAKrlRnbdkMVprOItPLZnaSvvxj3hI8xEC/ld/P+OKAp77BaCvO
 ajShD3o7TqvGeQweKx7TJF6dz2NqeC1H3NxKcIYdOB6Tpv/NY6Y=
 =+c6Z
 -----END PGP SIGNATURE-----

Merge tag 'reset-fixes-for-v6.0' of git://git.pengutronix.de/pza/linux into arm/fixes

Reset controller fixes for v6.0

Fix the i.MX8MP PCIe PHY PERST bit polarity, issue the Sparx5 "switch"
reset (which turned out to be a rather more global reset) early on
startup, stubbing out the reset controller driver, and fix the NPCM8XX
USB reset sequence by setting IPSRST4 bits in the correct register.

* tag 'reset-fixes-for-v6.0' of git://git.pengutronix.de/pza/linux:
  reset: npcm: fix iprst2 and iprst4 setting
  reset: microchip-sparx5: issue a reset on startup
  reset: imx7: Fix the iMX8MP PCIe PHY PERST support

Link: https://lore.kernel.org/r/20220923143519.41735-1-p.zabel@pengutronix.de
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
2022-09-23 17:45:14 +02:00
Linus Torvalds
317fab7ec5 ARM:
* Fix for kmemleak with pKVM
 
 s390:
 
 * Fixes for VFIO with zPCI
 
 * smatch fix
 
 x86:
 
 * Ensure XSAVE-capable hosts always allow  FP and SSE state to be saved
   and restored via KVM_{GET,SET}_XSAVE
 
 * Fix broken max_mmu_rmap_size stat
 
 * Fix compile error with old glibc that doesn't have gettid()
 -----BEGIN PGP SIGNATURE-----
 
 iQFIBAABCAAyFiEE8TM4V0tmI4mGbHaCv/vSX3jHroMFAmMtvg4UHHBib256aW5p
 QHJlZGhhdC5jb20ACgkQv/vSX3jHroNy2Af/VybWK2uAbaMkV6irQ1YTJIrRPco1
 C+JQdiQklYbjzThfPWNF/MiH+VTObloR1KqztOeQbfcrgwzygO68D3bs0wkAukLA
 mtdcMjdsqNx8r9u533i6S8Dpo0RkHKl+I8+3mHdPHTzlrbCuYJFFFxFNLhE+xbrK
 DP2Gl/xXIGYwOv2nfHA/xxI7TRICv4IxmzQazxlmC27n6BLNSr8qp6jI9lXJQfJ8
 XJh3SbmRux3/cs2oEqONg8DySJh631kI1jGGOmL3qk07ZR7A5KZ+lju0xM7vQIEq
 aR25YNYZux+BPIY/WxT1R0j6pwinBmFp8OoQYCs8DaQ65fdE5gegtJRpow==
 =VADm
 -----END PGP SIGNATURE-----

Merge tag 'for-linus' of git://git.kernel.org/pub/scm/virt/kvm/kvm

Pull kvm fixes from Paolo Bonzini:
 "As everyone back came back from conferences, here are the pending
  patches for Linux 6.0.

  ARM:

   - Fix for kmemleak with pKVM

  s390:

   - Fixes for VFIO with zPCI

   - smatch fix

  x86:

   - Ensure XSAVE-capable hosts always allow FP and SSE state to be
     saved and restored via KVM_{GET,SET}_XSAVE

   - Fix broken max_mmu_rmap_size stat

   - Fix compile error with old glibc that doesn't have gettid()"

* tag 'for-linus' of git://git.kernel.org/pub/scm/virt/kvm/kvm:
  KVM: x86: Inject #UD on emulated XSETBV if XSAVES isn't enabled
  KVM: x86: Always enable legacy FP/SSE in allowed user XFEATURES
  KVM: x86: Reinstate kvm_vcpu_arch.guest_supported_xcr0
  KVM: x86/mmu: add missing update to max_mmu_rmap_size
  selftests: kvm: Fix a compile error in selftests/kvm/rseq_test.c
  KVM: s390: pci: register pci hooks without interpretation
  KVM: s390: pci: fix GAIT physical vs virtual pointers usage
  KVM: s390: Pass initialized arg even if unused
  KVM: s390: pci: fix plain integer as NULL pointer warnings
  KVM: arm64: Use kmemleak_free_part_phys() to unregister hyp_mem_base
2022-09-23 08:42:30 -07:00
Linus Torvalds
526e826285 xen: branch for v6.0-rc7
-----BEGIN PGP SIGNATURE-----
 
 iHUEABYIAB0WIQRTLbB6QfY48x44uB6AXGG7T9hjvgUCYy1wIQAKCRCAXGG7T9hj
 vtbNAQCU6rDtPGB4I60tG9BU+8JKYLnUQ9oOY2OJOWWIO3M44AD+I7YHXyP0Y3Pj
 8L+aTXGX1mHht9jFXpChCYwaBceKGws=
 =B4T9
 -----END PGP SIGNATURE-----

Merge tag 'for-linus-6.0-rc7-tag' of git://git.kernel.org/pub/scm/linux/kernel/git/xen/tip

Pull xen fix from Juergen Gross:
 "A single fix for an issue in the xenbus driver (initialization of
  multi-page rings for Xen PV devices)"

* tag 'for-linus-6.0-rc7-tag' of git://git.kernel.org/pub/scm/linux/kernel/git/xen/tip:
  xen/xenbus: fix xenbus_setup_ring()
2022-09-23 08:31:24 -07:00
Linus Torvalds
22565ae784 drm fixes for v6.0-rc7
i915:
 - avoid a general protection failure when using perf/OA
 - avoid kernel warnings on driver release
 
 amdgpu:
 - SDMA 6.x fix
 - GPUVM TF fix
 - DCN 3.2.x fixes
 - DCN 3.1.x fixes
 - SMU 13.x fixes
 - Clang stack size fixes for recently enabled DML code
 - Fix drm dirty callback change on non-atomic cases
 - USB4 display fix
 
 mediatek:
 - dsi: Add atomic {destroy,duplicate}_state, reset callbacks
 - dsi: Move mtk_dsi_stop() call back to mtk_dsi_poweroff()
 - Fix wrong dither settings
 
 hisilicon:
 - Depend on MMU
 
 mgag200:
 - Fix console on G200ER
 
 panel:
 - Fix innolux_g121i1_l01 bus format
 -----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCAAdFiEEEKbZHaGwW9KfbeusDHTzWXnEhr4FAmMtSP4ACgkQDHTzWXnE
 hr6+6w/6A0yDFsGHgwpjB7uzj06ln2BzT4qiR9LoHbxEwpDsW94HV/9bI6mHjWSz
 ys89J1tYy4iC3fR/UceLPOhIprclCN0gVxxwJ8bGVkMwRnFN5fwf7T6TCyeDGRG5
 A8LcPidxSLaZO8myVqinEtFa4B9lb3cKvYSGEZeZbGU4SorxGem+Xr3DAU0pq4lO
 tZar1Qnojw6ZUG0Izakg1GL0RmYyH2bqdu8C1Aybws/jQ/HCGZfTW7K8G33PTEAm
 rJwXR4oKzCvPre26tdWOIJPDbXKMjRgeHsItO5ZVsyclGH3UxXfA3fLUyk5RJ6FT
 BYSAzjiDktcM2o9FGcOW/BGk2DfVDzzyY20doH2Q/GtY39SRd63GOUBhDlvoAe62
 hJtcdnshawbPO6RmlTrgceV65JxeXH0gBkoWCA/6Hf+uIEa9tkc+G04eTHWcrg38
 rfD96BCVCNOyiGRw46A3fYVuIRmCyFloOcRiepuLusW4XGD/uRztsGeCGHrLO0xp
 gg5AfSkeLi7j+mjVxA6KdR5kIXIoUMoN5AC0MNX4ciMEFYMGSLj86n7gGqPX25W/
 Arm88lvK0dkh8qd2Big4SSQrNkfr2do3gWXySFZY9ugIu6IfyfDQLAi+y0Wl2Ufa
 Nlz/7v+Bm31o8bQhKnF6+gHgv6/ue70jfpKTYvgAm3K2JUf7f3I=
 =DFaR
 -----END PGP SIGNATURE-----

Merge tag 'drm-fixes-2022-09-23-1' of git://anongit.freedesktop.org/drm/drm

Pull drm fixes from Dave Airlie:
 "Regular fixes for the week, i915, mediatek, hisilicon, mgag200 and
  panel have some small fixes.

  amdgpu has more stack size fixes for clang build, and fixes for new
  IPs, but all with low regression chances since they are for stuff new
  in v6.0.

  i915:
   - avoid a general protection failure when using perf/OA
   - avoid kernel warnings on driver release

  amdgpu:
   - SDMA 6.x fix
   - GPUVM TF fix
   - DCN 3.2.x fixes
   - DCN 3.1.x fixes
   - SMU 13.x fixes
   - Clang stack size fixes for recently enabled DML code
   - Fix drm dirty callback change on non-atomic cases
   - USB4 display fix

  mediatek:
   - dsi: Add atomic {destroy,duplicate}_state, reset callbacks
   - dsi: Move mtk_dsi_stop() call back to mtk_dsi_poweroff()
   - Fix wrong dither settings

  hisilicon:
   - Depend on MMU

  mgag200:
   - Fix console on G200ER

  panel:
   - Fix innolux_g121i1_l01 bus format"

* tag 'drm-fixes-2022-09-23-1' of git://anongit.freedesktop.org/drm/drm: (30 commits)
  MAINTAINERS: switch graphics to airlied other addresses
  drm/mediatek: dsi: Move mtk_dsi_stop() call back to mtk_dsi_poweroff()
  drm/amd/display: Reduce number of arguments of dml314's CalculateFlipSchedule()
  drm/amd/display: Reduce number of arguments of dml314's CalculateWatermarksAndDRAMSpeedChangeSupport()
  drm/amdgpu: don't register a dirty callback for non-atomic
  drm/amd/pm: drop the pptable related workarounds for SMU 13.0.0
  drm/amd/pm: add support for 3794 pptable for SMU13.0.0
  drm/amd/display: correct num_dsc based on HW cap
  drm/amd/display: Disable OTG WA for the plane_state NULL case on DCN314
  drm/amd/display: Add shift and mask for ICH_RESET_AT_END_OF_LINE
  drm/amd/display: increase dcn315 pstate change latency
  drm/amd/display: Fix DP MST timeslot issue when fallback happened
  drm/amd/display: Display distortion after hotplug 5K tiled display
  drm/amd/display: Update dummy P-state search to use DCN32 DML
  drm/amd/display: skip audio setup when audio stream is enabled
  drm/amd/display: update gamut remap if plane has changed
  drm/amd/display: Assume an LTTPR is always present on fixed_vs links
  drm/amd/display: fix dcn315 memory channel count and width read
  drm/amd/display: Fix double cursor on non-video RGB MPO
  drm/amd/display: Only consider pixle rate div policy for DCN32+
  ...
2022-09-23 08:18:55 -07:00
Arnd Bergmann
c69badd1d7 Qualcomm ARM64 DTS fixes for 6.0
This corrects invalid IOMMU streams for the SM8150 CDSP FastRPC, moves
 the wakeup-source of SC7280 USB nodes to the correct place, fixes the
 SM8350 UFS PHY serdes size to not overlap with the other subnodes and
 updates the firmware location for the Lenovo ThinkPad X13s to match the
 movement in linux-firmware.
 
 It also updates MAINTAINERS and .mailmap to reflect the changes in my
 email address.
 -----BEGIN PGP SIGNATURE-----
 
 iQJJBAABCAAzFiEEBd4DzF816k8JZtUlCx85Pw2ZrcUFAmMrHooVHGFuZGVyc3Nv
 bkBrZXJuZWwub3JnAAoJEAsfOT8Nma3FXQcP/i9Np/QVhTEcyeGyXcM9Et+gUCK+
 ne/4bz+hXJLqrFbd4eZSeHb+tAg0S6yFnEXGrYPHhoe5iRHZGXoIxCbgTwCWO/SN
 sVwfVa5/ekvCQK+yUaKa1POka2TjKKWfTXj/HZiCYRcezWyxkxFZh00cjD3NiC1u
 WaHCB0YbMnvEC1RabJoh+ZK+N2KXPVQpP9n/MZEMXtyPrCLe59feQyg7xcviJ/cY
 Xwc77YB9lKsLiWzbDOvhwdSrEpb7vFvPXFKj4Pg7xEZ1nINUPmdtjf1v/Z/1luAj
 gyxL92xZytSw5oireRf6Vwio80SPopafTeMvsjjvcO0mnmA1LhAD5srnUi8z8yXE
 XVk9CQ/v4HjXYGJJxuTNUo7J30ar3O8Whbd5i0jRuwUCqu1OsgamXJYtK2WUSVyr
 65idMgDfv01F7WMC59ZoLxvoZpncAO5nu+JozdZ4ryR9Iidl3L/D4ge+gjLLBFvR
 8CN1Y/ZV5qqa+VUbovLod4zrr6tGO27OJ7QNIxblMqEBOFF9OEW+fRezH4R37VsM
 Y9B7LWbPVVV/QNmGjXud4hl/ihz8AcgplXMOR5oMmpy8mp3gHFyi8umMcWpw/u6g
 6DeQ356dSP2wFAgE+xlhEYABxIYdN+3wSrxNElgHldP5QxoYufrqT/Tcg6Nd7iHq
 R4VNA9vp/irXtksF
 =0C1/
 -----END PGP SIGNATURE-----
gpgsig -----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCgAdFiEEo6/YBQwIrVS28WGKmmx57+YAGNkFAmMtxlUACgkQmmx57+YA
 GNkb4A/+M9UqBcaskORpCLzW9CF3NFvD9eUqK1c04vlZySnJAnhSv7FiemRM13Ru
 31k1MVORRH0i5KjReM9yB95nyasDhodmumZgZPoYL+iF236NzekeJ3xn+RvG2mpp
 EOVIIL0LlWVS1FQMr8kGaPJxydUxtocPfeaisEu1TIKS01cA4xQ9DlJrYUU/POkV
 BiRVaZlN2kdQPmEJW8ZaAruNsOo7KmGI0yuQ4IzBMFh20Zu/fOnyORNtrbKCfQqK
 9axTb9M/xtnkuoFxtLrVRF7rAumSr5tjvOqWw7gmSM/2kvK6/RuN5/BLkWh8dMyS
 yvQ3xztyI8IJX6YOZ7qcbcLPobxUHcuqUH/cUMRXqtSSW0jMuVItQ4DHm5qleFZ6
 +1XFsHsI8Y7c2jaxY3V5BV2jd98zwxD0FCSvLNi1Sc+eW1FJXdCiv+fqf8q8302O
 jjto6UW7/aiWOFiTErE+Hddcyq0D14BNVlwBMRmPK2Mk4h5NUmMPmur69uYniTcb
 3+Grt8lY13uO5smhFBUrQ/HjC6bGEeKjOpxTQ/LT0/aWlwBsZcP+/ihOK3EinNLJ
 ROSW63iv2iOhNYZ9A7W4D1CGOH62RAxxfaee568LwG8aCLt47FrQ/g5U+z5zkUHc
 M8loNtUpTKIfw4GxJgGHomVXppFx1JbhTrDY35MsmWEeJjIl5rQ=
 =WotM
 -----END PGP SIGNATURE-----

Merge tag 'qcom-arm64-fixes-for-6.0' of https://git.kernel.org/pub/scm/linux/kernel/git/qcom/linux into arm/fixes

Qualcomm ARM64 DTS fixes for 6.0

This corrects invalid IOMMU streams for the SM8150 CDSP FastRPC, moves
the wakeup-source of SC7280 USB nodes to the correct place, fixes the
SM8350 UFS PHY serdes size to not overlap with the other subnodes and
updates the firmware location for the Lenovo ThinkPad X13s to match the
movement in linux-firmware.

It also updates MAINTAINERS and .mailmap to reflect the changes in my
email address.

* tag 'qcom-arm64-fixes-for-6.0' of https://git.kernel.org/pub/scm/linux/kernel/git/qcom/linux:
  arm64: dts: qcom: sm8350: fix UFS PHY serdes size
  arm64: dts: qcom: sc8280xp-x13s: Update firmware location
  MAINTAINERS: Update Bjorn's email address
  arm64: dts: qcom: sc7280: move USB wakeup-source property
  arm64: dts: qcom: thinkpad-x13s: Fix firmware location
  arm64: dts: qcom: sm8150: Fix fastrpc iommu values

Link: https://lore.kernel.org/r/20220921142939.1310163-1-andersson@kernel.org
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
2022-09-23 16:44:37 +02:00
Linus Walleij
4952aa696a
ARM: dts: integrator: Tag PCI host with device_type
The DT parser is dependent on the PCI device being tagged as
device_type = "pci" in order to parse memory ranges properly.
Fix this up.

Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
Cc: stable@vger.kernel.org
Link: https://lore.kernel.org/r/20220919092608.813511-1-linus.walleij@linaro.org'
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
2022-09-23 16:42:27 +02:00
Brian Norris
cc62d98bd5 Revert "drm: bridge: analogix/dp: add panel prepare/unprepare in suspend/resume time"
This reverts commit 211f276ed3.

For quite some time, core DRM helpers already ensure that any relevant
connectors/CRTCs/etc. are disabled, as well as their associated
components (e.g., bridges) when suspending the system. Thus,
analogix_dp_bridge_{enable,disable}() already get called, which in turn
call drm_panel_{prepare,unprepare}(). This makes these drm_panel_*()
calls redundant.

Besides redundancy, there are a few problems with this handling:

(1) drm_panel_{prepare,unprepare}() are *not* reference-counted APIs and
are not in general designed to be handled by multiple callers --
although some panel drivers have a coarse 'prepared' flag that mitigates
some damage, at least. So at a minimum this is redundant and confusing,
but in some cases, this could be actively harmful.

(2) The error-handling is a bit non-standard. We ignored errors in
suspend(), but handled errors in resume(). And recently, people noticed
that the clk handling is unbalanced in error paths, and getting *that*
right is not actually trivial, given the current way errors are mostly
ignored.

(3) In the particular way analogix_dp_{suspend,resume}() get used (e.g.,
in rockchip_dp_*(), as a late/early callback), we don't necessarily have
a proper PM relationship between the DP/bridge device and the panel
device. So while the DP bridge gets resumed, the panel's parent device
(e.g., platform_device) may still be suspended, and so any prepare()
calls may fail.

So remove the superfluous, possibly-harmful suspend()/resume() handling
of panel state.

Fixes: 211f276ed3 ("drm: bridge: analogix/dp: add panel prepare/unprepare in suspend/resume time")
Link: https://lore.kernel.org/all/Yv2CPBD3Picg%2FgVe@google.com/
Signed-off-by: Brian Norris <briannorris@chromium.org>
Reviewed-by: Douglas Anderson <dianders@chromium.org>
Signed-off-by: Douglas Anderson <dianders@chromium.org>
Link: https://patchwork.freedesktop.org/patch/msgid/20220822180729.1.I8ac5abe3a4c1c6fd5c061686c6e883c22f69022c@changeid
2022-09-23 07:15:18 -07:00
Paolo Bonzini
69604fe76e More pci fixes
Fix for a code analyser warning
 -----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCAAdFiEEwGNS88vfc9+v45Yq41TmuOI4ufgFAmMtmHcACgkQ41TmuOI4
 ufhapA/+OGjJtUKEa/LkCArUMUgJ+ZYy9cwx3Qrkvm7BtEguN35uxO5T7X8pdMDU
 /dYSDwtPT1ob/QmjhwwE0dpgUF8yfkBNLKBK37f6jTznI4mS6UEq/IB1BcCk3ss5
 45xG8rWiXS7oFm9bxtNsa5jkrSf7gIOuEa570tOVtOlBYvtFIH2SiHvcCUY1w48N
 A6docb+vOJnPIBHPR/1q+bBoghO5rplYaX0EiAt3EYThrhAjsXjIFzaQPwXUxgFh
 Nk/3ni1St72sbWDiC7YxjDghMVuW1GuQAlgkDWvy8bdA0IfsaqbyISuyIWZWkRfx
 V8+7OfGVsCB7qhT4C+65fQPqwZwERNwwvAFsx175/Mm9/AXn217+sN52O54olFcM
 dhKI7med1R/LqO2HH9kCGIUfJ3t+0JHpFDwcJyiAZsFbYffnwUQbIW4YcA3O+rje
 cV8/kRhD6ebzrScTOMVH+Rb4Q0N0kL34iHXbI8wcTBKmSFrdRm9YeLtQM2P/HtPA
 GVyg49bfXfA13goM9jaUW/IgT1aSHNRHfbfFKTUB7ph2Wi5ktMizpkn/CQ8L7bm1
 I0JoZfA7ALDufg2Ajyqsqmv3RX2k6ydenmX/AxzQlo34kSXY6X+N+yiPlqhumBqq
 Gs2pmvQoyvAmuShhj+eSZsQYBObgjzN7B/SAbbUBT71GerGyWeQ=
 =Z7gl
 -----END PGP SIGNATURE-----

Merge tag 'kvm-s390-master-6.0-2' of https://git.kernel.org/pub/scm/linux/kernel/git/kvms390/linux into HEAD

More pci fixes
Fix for a code analyser warning
2022-09-23 10:06:08 -04:00
Jakub Kicinski
6bf8e846e4 Merge branch 'net-mt7531-pll-reset-fixes'
Alexander Couzens says:

====================
net: mt7531: pll & reset fixes
====================

Link: https://lore.kernel.org/r/20220917000734.520253-1-lynxis@fe80.eu
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
2022-09-23 06:58:54 -07:00
Alexander Couzens
728c2af6ad net: mt7531: ensure all MACs are powered down before reset
The datasheet [1] explicit describes it as requirement for a reset.

[1] MT7531 Reference Manual for Development Board rev 1.0, page 735

Signed-off-by: Alexander Couzens <lynxis@fe80.eu>
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
2022-09-23 06:58:49 -07:00
Alexander Couzens
42bc4fafe3 net: mt7531: only do PLL once after the reset
Move the PLL init of the switch out of the pad configuration of the port
6 (usally cpu port).

Fix a unidirectional 100 mbit limitation on 1 gbit or 2.5 gbit links for
outbound traffic on port 5 or port 6.

Fixes: c288575f78 ("net: dsa: mt7530: Add the support of MT7531 switch")
Cc: stable@vger.kernel.org
Signed-off-by: Alexander Couzens <lynxis@fe80.eu>
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
2022-09-23 06:58:49 -07:00
Lukas Bulwahn
f8497b3e96 MAINTAINERS: rectify file entry in TEAM DRIVER
Commit bbb774d921 ("net: Add tests for bonding and team address list
management") adds the net team driver tests in the directory:

  tools/testing/selftests/drivers/net/team/

The file entry in MAINTAINERS for the TEAM DRIVER however refers to:

  tools/testing/selftests/net/team/

Hence, ./scripts/get_maintainer.pl --self-test=patterns complains about a
broken file pattern.

Repair this file entry in TEAM DRIVER.

Signed-off-by: Lukas Bulwahn <lukas.bulwahn@gmail.com>
Acked-by: Benjamin Poirier <bpoirier@nvidia.com>
Link: https://lore.kernel.org/r/20220922114053.10883-1-lukas.bulwahn@gmail.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
2022-09-23 05:45:46 -07:00
Will Deacon
13b0566962 vmlinux.lds.h: CFI: Reduce alignment of jump-table to function alignment
Due to undocumented, hysterical raisins on x86, the CFI jump-table
sections in .text are needlessly aligned to PMD_SIZE in the vmlinux
linker script. When compiling a CFI-enabled arm64 kernel with a 64KiB
page-size, a PMD maps 512MiB of virtual memory and so the .text section
increases to a whopping 940MiB and blows the final Image up to 960MiB.
Others report a link failure.

Since the CFI jump-table requires only instruction alignment, reduce the
alignment directives to function alignment for parity with other parts
of the .text section. This reduces the size of the .text section for the
aforementioned 64KiB page size arm64 kernel to 19MiB for a much more
reasonable total Image size of 39MiB.

Cc: Sami Tolvanen <samitolvanen@google.com>
Cc: Mark Rutland <mark.rutland@arm.com>
Cc: "Mohan Rao .vanimina" <mailtoc.mohanrao@gmail.com>
Cc: Kees Cook <keescook@chromium.org>
Cc: Nathan Chancellor <nathan@kernel.org>
Cc: <stable@vger.kernel.org>
Link: https://lore.kernel.org/all/CAL_GTzigiNOMYkOPX1KDnagPhJtFNqSK=1USNbS0wUL4PW6-Uw@mail.gmail.com/
Fixes: cf68fffb66 ("add support for Clang CFI")
Reviewed-by: Mark Rutland <mark.rutland@arm.com>
Tested-by: Mark Rutland <mark.rutland@arm.com>
Reviewed-by: Sami Tolvanen <samitolvanen@google.com>
Reviewed-by: Kees Cook <keescook@chromium.org>
Link: https://lore.kernel.org/r/20220922215715.13345-1-will@kernel.org
Signed-off-by: Will Deacon <will@kernel.org>
2022-09-23 13:39:01 +01:00
Arnd Bergmann
7e1e2acb7b sunxi SRAM controller fixes for
- loading/unloading
 - claiming regions
 - debugfs info
 -----BEGIN PGP SIGNATURE-----
 
 iHUEABYIAB0WIQSPRixG1tysKC2PKM10Ba7+DO8kkwUCYyeI1gAKCRB0Ba7+DO8k
 kww7AP9TfAADMTl0v+ggU+vpkwaI6ENDareh8nKiTWralJe3cgD/fjOrh+L9lquC
 zmCFvKIZNNaPI0/i0jJAP2M9aLGeEQ4=
 =MS0s
 -----END PGP SIGNATURE-----
gpgsig -----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCgAdFiEEo6/YBQwIrVS28WGKmmx57+YAGNkFAmMtpowACgkQmmx57+YA
 GNmCow//Y9gFfgOnzmlGDQjSdh6ZbLwLE+rG0DBghZ6OIAPyo7m5dgvAlAarxFAu
 MP1EmMPgqo6J9pvlla0w4CZoaa4Ae5jvzCpjP3wmd5uANI2Tw6V6VY27mkdsUlXa
 8sgBTkA8wvsBoW1x0XLU1ugPE8okaVvVfkH9ZqZDDNRFdGi6ed+WG+hi2Oyy79oz
 n7mF9wYnYr6DYCIAoDsWhTs6JRqYmTx1EJ7hY8em5eavL8yobBrRv91GSdcoEFZV
 xUFwe1C0SXEXcFSCbPDO0WuUZ//e/0DqP1DkAgqUtXYCDC/aBi7kMUoXIg70EyWQ
 k0gbM1b+JRig5zlesQ5ih0q5X2wNbc1bjDypcYQuSaB71ma0mcj6KED7uy2u/b5J
 12ha2W/7Sf+2qTskKgtAUdSaX/GZfPjDYvde4Z2R7YuvIfGsQIqe7L5HLzkxgAqq
 nMk2QkUeGI8NH15zYOS0+oq7OgmYjX5KKsiGmrzo1IO0KKFtIQlGzPMgWwbv8/h6
 WbNceSaBUkoR9EqDXFYZEICsS9aKBLOvmb06Kc3HUucnnyJCIFjCUUJqAYnrgPJc
 nPKYexDpukAFyjIRfpJoJ8En1xWMJNJRVinnXEuGgw8fCzr1fqGUqsn8PuAfubLs
 CFoecvLhppJz1mVXTNNi7I3SA0hbV+KF2PJ/0wse4HOgtDbM2RA=
 =Qp+A
 -----END PGP SIGNATURE-----

Merge tag 'sunxi-drivers-fixes-for-6.0-1' of https://git.kernel.org/pub/scm/linux/kernel/git/sunxi/linux into arm/fixes

sunxi SRAM controller fixes for
- loading/unloading
- claiming regions
- debugfs info

* tag 'sunxi-drivers-fixes-for-6.0-1' of https://git.kernel.org/pub/scm/linux/kernel/git/sunxi/linux:
  soc: sunxi: sram: Fix debugfs info for A64 SRAM C
  soc: sunxi: sram: Fix probe function ordering issues
  soc: sunxi: sram: Prevent the driver from being unbound
  soc: sunxi: sram: Actually claim SRAM regions

Link: https://lore.kernel.org/r/YyeN0m78+m9nNEah@kista.localdomain
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
2022-09-23 14:29:00 +02:00
Arnd Bergmann
b58e731783 This pull request contains Broadcom SoCs driver fixes for 6.0, please
pull the following:
 
 - Florian fixes a double of_node_put() in the Broadcom STB Bus Interface
   Unit driver
 -----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCgAdFiEEm+Rq3+YGJdiR9yuFh9CWnEQHBwQFAmMng8QACgkQh9CWnEQH
 BwQ+EhAAp/bJ7tcCJJMJhkwL4K94pW7BgX+R1iieDMLCjW5xgWylrM4A/cZTvqU+
 RmG1WSXt7ASVu2PIKf+HWgnYI6CQD4cckMAFrTRN191VQUuN7Hf6ruRD5ijUVdBp
 T2mhAJsS8tesWt7qdscfNy5yWmkTaswO4hber3gMXAM3LKegwcjDMO9yrz+eFiu1
 mJzChahdRzPbggdiQULjlzflw6SxjatKEFbySmyzc5fZURneSZ/PWOj3DWmAYmkU
 IxeynHE571VPKQyTiWNzyHpGOlWJHT94gC5ms9j4XDKJbTRDMSB6x5T2f0VlJTx7
 hYMVRl9/eg/KLsEaSfGOUh5RvJv+F4d6WodSaKXn1E8e3G7X+tlc4ozNobBjP5dj
 sazL+STaQUyLgedZOMabZLc70MFD1ZJMA7Ln2AYPZEMohs7MWsstjoM0/uOHCBJv
 i7PoUs9GWJGtFAKye1C0DUfBqaATkn5vnlJNuPmoQROeh84sWHBGB022ngz6HtIK
 gw/MtS1TrlBVtSO+KpixQF8fPEw/9rjM7Uf3cdzN74nQgPSCJ77iQYusUXJc4/WV
 nDCzpmSGM/gKmYRPRLH8JUjWy0LMDUk7XmQtrDS2sM7P6owosRF42SuR0dfeOe81
 SzFq/D7EFWV68SxlCMZa/MOY2FFhPio82X9qXOU3kxOZ5DP3Qrs=
 =ppt3
 -----END PGP SIGNATURE-----
gpgsig -----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCgAdFiEEo6/YBQwIrVS28WGKmmx57+YAGNkFAmMtpmEACgkQmmx57+YA
 GNmVZA//aMFSfvHfm1HE93Atzex0QrM5rwlr64lyzdje1+jsst1nbf1WLcYwnooX
 UyFpZbTeey5xyjODR3JbwRiYIFB1Sxd/vEcAqgXXe95sYHzdGDQotXtJeZPQhMaZ
 PVT8g/sgt0HMcPPOVb+WUMqNY3DYFQMZJHdqTXmPim6SH9/+cGLw50aRYL8IaC2j
 bD1znFAF/v0NGVrt8jgkfV9W0YTxlB1gqaSCOCnpaDHdnSKzoRquFDOugQtOnzOq
 cQ8slrGh2QzNFsyijIbPdJiWgvhXKWmQrJja48yAsHJGQo1R4jYnXYivlQBeDdRm
 ogWBkM1BWCAsUq3WGHCyEvmeSI0eXmJrwFTMuQkBEEsOKIG+DEmaMzZaWhO/n5nU
 HFn7RX35xv76qSUpB8tf+TJWZhSpXYHT1r7dZ9t3Bw4MQkH+Sn+0jAXlvPcdJvLK
 n3Pg6ml9z6oPZpmj7+fvI4Q7o0orxhN8GMwO+mduUdheiswWgXqYE/8zyap0jve3
 lYP0iUeFfRqsbss7aqCPPgGrk8/UJxGaETBq1n2fansNCXYOI3RO4RmTzUv1iau8
 S+4sUIX8MaCCLPn1dNSyIvLPWt7pnubQIyU5h5LNFRs+2HB8uQ2zqOT6hyfv9bSC
 +6ErpIBKeBuA5PP/hq5iIqIaG3tgvRHh+Xn6cTUqBRr8zUzSnPo=
 =0yl7
 -----END PGP SIGNATURE-----

Merge tag 'arm-soc/for-6.0/drivers-fixes-v2' of https://github.com/Broadcom/stblinux into arm/fixes

This pull request contains Broadcom SoCs driver fixes for 6.0, please
pull the following:

- Florian fixes a double of_node_put() in the Broadcom STB Bus Interface
  Unit driver

* tag 'arm-soc/for-6.0/drivers-fixes-v2' of https://github.com/Broadcom/stblinux:
  soc: bcm: brcmstb: biuctrl: Avoid double of_node_put()

Link: https://lore.kernel.org/r/20220918205038.3017866-1-f.fainelli@gmail.com
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
2022-09-23 14:28:17 +02:00
Arnd Bergmann
415da41225 Two fixes for omaps
A fix to remove usb4 from am5748 as it does not exist on the SoC, and
 a fix for am335x mmc dma that wired direct and should not use the xbar.
 
 Note that the am5748 fix depends on the recent deferred probe regression
 fixes to boot. I ended up picking the merge commit to base it on as it
 describes what got fixed quite nicely rather than a -rc tag.
 -----BEGIN PGP SIGNATURE-----
 
 iQJFBAABCAAvFiEEkgNvrZJU/QSQYIcQG9Q+yVyrpXMFAmMhgrERHHRvbnlAYXRv
 bWlkZS5jb20ACgkQG9Q+yVyrpXPUJg//bzGzEInF3BoA5HNd/epmniNJhvRlcY8T
 ZD8HefWfMpJ17g3RmwZgFui0YU65YDqeoSEYl5AU8STCI52Nk16EKcKs9MrnpARF
 SzHRPKw4y8R4qwjYwUIfB4hyOcX5Dr+vYHmanhvQuRSSa8B2xh94zUUO/OI+cKeI
 GeXBDKGwCBJXJqu98OrfSvQuvDVr2KUCgr/iwXo/RJ9Zqjx1+hgC8B0k6IQaScm2
 hJWzt94qadBcfrd8nfw5QFZyfVRDv5YPQ8hpyjoS7RNg30HR4qSDuFYs6y7iVMLV
 LUdpjr3f9rhWFcQF69J8fKHw5ookfB6kjn3P+Xt5puXbpbmNz2hvSXEoqC/gnVnG
 EWSN+waXlkXH+WVVOn1oMc9B0cjA+u/05z6lHjM2iUOGTQHb5yMGNLB3qrIiAVxB
 /ZYyrIcxNukf5Qqk2bROGOdC4nIrF+TACalbubAGam3+BbmZwJpARRA90qIl5zSX
 4GRk5S9Vvph16w71Dt3CQRVCyl/1VpIr5RMkBA9CKLO3bkSsTsHRUPhGGgDOlFdh
 /FlBRZDNAXtfPVvh4pEA4HdlHKYw53QDZRQoCs2m8l73FypuxQlJlWUfLEltshTE
 7rIYGwK62aysrnoQetmrbJDrfLtEhOnel/+ehpKkecJ+50TWs9Zjg5neUjiq5K3O
 hnAJ/sR2VSc=
 =p5BT
 -----END PGP SIGNATURE-----
gpgsig -----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCgAdFiEEo6/YBQwIrVS28WGKmmx57+YAGNkFAmMtpjwACgkQmmx57+YA
 GNlq0g/8D8InNgCpqLj7KZe/0exuWUwM8pNRx7MVUTlMfiAtEJjahdm+Xxy08B2z
 ORgrj8n7g39t90cqjj8hK6PD/5DzFSrJtdFOMUhXwg8q8MrmfSYoIkAWMn3rrzOc
 N/608zG2fRwECLc+K8uZ9Zi6bTEG6/PKjNADV62ggAnPa9ts6fpw6o8NL1Gs/4Ju
 3QNYOx/S9B9Hn/grZ74ZFqJil/D2PSQj5T9IQXhDbuy6pF5pFuEMRbA3eLphEc4C
 QNRXrZu9MHUBSFPA3iFm11SX2tf2GLjzLYgsdCQM1I5intdyi2DnpuItnkElwYnd
 14fGiQamk3unKLImEM/TQjfZrEcTdIqdvESUCGqmjcsMF4IAbVlO3LeMVM518oX/
 01FmOM0BXAKT6jsuawg8gjzLUNj4bHatM0HXxOskbfvSpIeA5eAVG1Af/1SEg4HY
 GdrwOMgEU7y7ORlLykxCN+8APYpZCfxNRBF+KORxPDAXizYPafM/SU9WCd3ehuEN
 70uzwegMud14mIoA4/Lw3Si0ZWM9+PLCfHFiVwe2g02OtZPCJte7YvvB+GrK9ecy
 dhp5NcgCStEMVnIlYWIIOM/C/PNwUKYYEZRCrCEZH557Dj2+aiq6hc/a7aBjXpik
 BcBJTduYX84b2pHL0IgB6cI+wPzj2jK+4moTJzyGIDQ59Y9eOuM=
 =M5HN
 -----END PGP SIGNATURE-----

Merge tag 'omap-for-6.0/fixes-signed' of git://git.kernel.org/pub/scm/linux/kernel/git/tmlind/linux-omap into arm/fixes

Two fixes for omaps

A fix to remove usb4 from am5748 as it does not exist on the SoC, and
a fix for am335x mmc dma that wired direct and should not use the xbar.

Note that the am5748 fix depends on the recent deferred probe regression
fixes to boot. I ended up picking the merge commit to base it on as it
describes what got fixed quite nicely rather than a -rc tag.

* tag 'omap-for-6.0/fixes-signed' of git://git.kernel.org/pub/scm/linux/kernel/git/tmlind/linux-omap:
  ARM: dts: am5748: keep usb4_tm disabled
  ARM: dts: am33xx: Fix MMCHS0 dma properties

Link: https://lore.kernel.org/r/pull-1663140667-273537@atomide.com
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
2022-09-23 14:27:40 +02:00
Randy Dunlap
1e6989a335 ARM: sunplus: fix serial console kconfig and build problems
Fix kconfig dependency warnings and subsequent build errors:

WARNING: unmet direct dependencies detected for SERIAL_SUNPLUS
  Depends on [n]: TTY [=n] && HAS_IOMEM [=y] && (ARCH_SUNPLUS [=y] || COMPILE_TEST [=n])
  Selected by [y]:
  - SOC_SP7021 [=y] && ARCH_SUNPLUS [=y]

WARNING: unmet direct dependencies detected for SERIAL_SUNPLUS_CONSOLE
  Depends on [n]: TTY [=n] && HAS_IOMEM [=y] && SERIAL_SUNPLUS [=y]
  Selected by [y]:
  - SOC_SP7021 [=y] && ARCH_SUNPLUS [=y]

(samples, not all:)
drivers/tty/serial/sunplus-uart.c:342: undefined reference to `uart_get_baud_rate'
arm-linux-gnueabi-ld: drivers/tty/serial/sunplus-uart.c:379: undefined reference to `uart_update_timeout'
drivers/tty/serial/sunplus-uart.c:526: undefined reference to `uart_console_write'
arm-linux-gnueabi-ld: drivers/tty/serial/sunplus-uart.c:274: undefined reference to `tty_flip_buffer_push'
arm-linux-gnueabi-ld: drivers/tty/serial/sunplus-uart.o:(.data+0xa8): undefined reference to `uart_console_device'
drivers/tty/serial/sunplus-uart.c:720: undefined reference to `uart_register_driver'
arm-linux-gnueabi-ld: drivers/tty/serial/sunplus-uart.c:726: undefined reference to `uart_unregister_driver'
drivers/tty/serial/sunplus-uart.c:551: undefined reference to `uart_parse_options'
arm-linux-gnueabi-ld: drivers/tty/serial/sunplus-uart.c:553: undefined reference to `uart_set_options'

This is the same technique that is used 2 times in
arch/arm/mach-versatile/Kconfig.

Fixes: 0aa94eea8d ("ARM: sunplus: Add initial support for Sunplus SP7021 SoC")
Reported-by: kernel test robot <lkp@intel.com>
Signed-off-by: Randy Dunlap <rdunlap@infradead.org>
Cc: Qin Jian <qinjian@cqplus1.com>
Cc: Necip Fazil Yildiran <fazilyildiran@gmail.com>
Cc: Arnd Bergmann <arnd@arndb.de>
Cc: linux-arm-kernel@lists.infradead.org
Cc: patches@armlinux.org.uk
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
2022-09-23 14:20:00 +02:00
Radhey Shyam Pandey
f22bd29ba1 net: macb: Fix ZynqMP SGMII non-wakeup source resume failure
When GEM is in SGMII mode and disabled as a wakeup source, the power
management controller can power down the entire full power domain(FPD)
if none of the FPD devices are in use.

Incase of FPD off, there are below ethernet link up issues on non-wakeup
suspend/resume. To fix it add phy_exit() in suspend and phy_init() in the
resume path which reinitializes PS GTR SGMII lanes.

$ echo +20 > /sys/class/rtc/rtc0/wakealarm
$ echo mem > /sys/power/state

After resume:

$ ifconfig eth0 up
xilinx-psgtr fd400000.phy: lane 0 (type 10, protocol 5): PLL lock timeout
phy phy-fd400000.phy.0: phy poweron failed --> -110
xilinx-psgtr fd400000.phy: lane 0 (type 10, protocol 5): PLL lock timeout
SIOCSIFFLAGS: Connection timed out
phy phy-fd400000.phy.0: phy poweron failed --> -110

Fixes: 8b73fa3ae0 ("net: macb: Added ZynqMP-specific initialization")
Signed-off-by: Radhey Shyam Pandey <radhey.shyam.pandey@amd.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2022-09-23 12:32:49 +01:00
Patrick Rohr
195624d9c2 tun: support not enabling carrier in TUNSETIFF
This change adds support for not enabling carrier during TUNSETIFF
interface creation by specifying the IFF_NO_CARRIER flag.

Our tests make heavy use of tun interfaces. In some scenarios, the test
process creates the interface but another process brings it up after the
interface is discovered via netlink notification. In that case, it is
not possible to create a tun/tap interface with carrier off without it
racing against the bring up. Immediately setting carrier off via
TUNSETCARRIER is still too late.

Signed-off-by: Patrick Rohr <prohr@google.com>
Cc: Maciej Żenczykowski <maze@google.com>
Cc: Lorenzo Colitti <lorenzo@google.com>
Cc: Jason Wang <jasowang@redhat.com>
Cc: Stephen Hemminger <stephen@networkplumber.org>
Cc: Nicolas Dichtel <nicolas.dichtel@6wind.com>
Reviewed-by: Maciej Żenczykowski <maze@google.com>
Acked-by: Jason Wang <jasowang@redhat.com>
Reviewed-by: Nicolas Dichtel <nicolas.dichtel@6wind.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2022-09-23 12:02:03 +01:00
Francesco Dolcini
051ad2788d drm/bridge: lt8912b: fix corrupted image output
Correct I2C address for the register list in lt8912_write_lvds_config(),
these registers are on the first I2C address (0x48), the current
function is just writing garbage to the wrong registers and this creates
multiple issues (artifacts and output completely corrupted) on some HDMI
displays.

Correct I2C address comes from Lontium documentation and it is the one
used on other out-of-tree LT8912B drivers [1].

[1] https://github.com/boundarydevices/linux/blob/boundary-imx_5.10.x_2.0.0/drivers/video/lt8912.c#L296

Fixes: 30e2ae943c ("drm/bridge: Introduce LT8912B DSI to HDMI bridge")
Signed-off-by: Francesco Dolcini <francesco.dolcini@toradex.com>
Signed-off-by: Philippe Schenker <philippe.schenker@toradex.com>
Acked-by: Adrien Grassein <adrien.grassein@gmail.com>
Signed-off-by: Neil Armstrong <neil.armstrong@linaro.org>
Link: https://patchwork.freedesktop.org/patch/msgid/20220922124306.34729-4-dev@pschenker.ch
2022-09-23 09:19:10 +00:00
Philippe Schenker
6dd1de12e1 drm/bridge: lt8912b: set hdmi or dvi mode
The Lontium LT8912 does have a setting for DVI or HDMI. This patch reads
from EDID what the display needs and sets it accordingly.

Fixes: 30e2ae943c ("drm/bridge: Introduce LT8912B DSI to HDMI bridge")
Signed-off-by: Philippe Schenker <philippe.schenker@toradex.com>
Acked-by: Adrien Grassein <adrien.grassein@gmail.com>
Signed-off-by: Neil Armstrong <neil.armstrong@linaro.org>
Link: https://patchwork.freedesktop.org/patch/msgid/20220922124306.34729-3-dev@pschenker.ch
2022-09-23 09:19:10 +00:00
Philippe Schenker
da73a94fa2 drm/bridge: lt8912b: add vsync hsync
Currently the bridge driver does not take care whether or not the display
needs positive/negative vertical/horizontal syncs. Pass these two flags
to the bridge from the EDID that was read out from the display.

Fixes: 30e2ae943c ("drm/bridge: Introduce LT8912B DSI to HDMI bridge")
Signed-off-by: Philippe Schenker <philippe.schenker@toradex.com>
Acked-by: Adrien Grassein <adrien.grassein@gmail.com>
Signed-off-by: Neil Armstrong <neil.armstrong@linaro.org>
Link: https://patchwork.freedesktop.org/patch/msgid/20220922124306.34729-2-dev@pschenker.ch
2022-09-23 09:19:09 +00:00
Ulf Hansson
3c66563378 Revert "firmware: arm_scmi: Add clock management to the SCMI power domain"
This reverts commit a3b884cef8 ("firmware: arm_scmi: Add clock management
to the SCMI power domain").

Using the GENPD_FLAG_PM_CLK tells genpd to gate/ungate the consumer
device's clock(s) during runtime suspend/resume through the PM clock API.
More precisely, in genpd_runtime_resume() the clock(s) for the consumer
device would become ungated prior to the driver-level ->runtime_resume()
callbacks gets invoked.

This behaviour isn't a good fit for all platforms/drivers. For example, a
driver may need to make some preparations of its device in its
->runtime_resume() callback, like calling clk_set_rate() before the
clock(s) should be ungated. In these cases, it's easier to let the clock(s)
to be managed solely by the driver, rather than at the PM domain level.

For these reasons, let's drop the use GENPD_FLAG_PM_CLK for the SCMI PM
domain, as to enable it to be more easily adopted across ARM platforms.

Fixes: a3b884cef8 ("firmware: arm_scmi: Add clock management to the SCMI power domain")
Cc: Nicolas Pitre <npitre@baylibre.com>
Cc: stable@vger.kernel.org
Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
Tested-by: Peng Fan <peng.fan@nxp.com>
Acked-by: Sudeep Holla <sudeep.holla@arm.com>
Link: https://lore.kernel.org/r/20220919122033.86126-1-ulf.hansson@linaro.org
2022-09-23 10:19:47 +02:00
Dave Airlie
8288206c27 MAINTAINERS: switch graphics to airlied other addresses
My linux.ie address is in a bad place.
also add dri-devel for agpgart.

Signed-off-by: Dave Airlie <airlied@redhat.com>
2022-09-23 15:38:06 +10:00
Dave Airlie
3b38b65ed0 Short summary of fixes pull
* drm/hisilicon: Depend on MMU
  * drm/mgag200: Fix console on G200ER
  * drm/panel: Fix innolux_g121i1_l01 bus format
 -----BEGIN PGP SIGNATURE-----
 
 iQEzBAABCAAdFiEEchf7rIzpz2NEoWjlaA3BHVMLeiMFAmMsbTMACgkQaA3BHVML
 eiPSjQgAvaFF7mRxm8pj+e7/I4UF1mJrJfysND/IhSFzLLDqabkNnRcUAuT43aC9
 pR86BWAPdO6vl/stfvuJiSiom5TcGlk6mhC2FoCgziyNjUwfRpCl1Q7w8x31/FtQ
 ryH5G1+T/aHbHOwyMq6tpFeANnzBj0D/evkd3qQbZD1/n4imPG86uOOhMrkKtzkl
 +XwHtewK3g9Zy0SMBnA2+ih/8BccflRpap3Rd7Ux70ZE8tXI2fz/PXw4xKNqwH9P
 vWqrX3e5kV3sAEgLZRHvwTOxptBR0+l1Jxce662KeTGjmCvvVOlwOF2m63hJ65hv
 kD0nzmUFAEdcCExjHUFcYNotHAmwYw==
 =DNR3
 -----END PGP SIGNATURE-----

Merge tag 'drm-misc-fixes-2022-09-22' of git://anongit.freedesktop.org/drm/drm-misc into drm-fixes

Short summary of fixes pull

 * drm/hisilicon: Depend on MMU
 * drm/mgag200: Fix console on G200ER
 * drm/panel: Fix innolux_g121i1_l01 bus format

Signed-off-by: Dave Airlie <airlied@redhat.com>

From: Thomas Zimmermann <tzimmermann@suse.de>
Link: https://patchwork.freedesktop.org/patch/msgid/YyxtXS588at6S4wg@linux-uq9g
2022-09-23 13:18:26 +10:00
Dave Airlie
73646baf68 Mediatek DRM Fixes for Linux 6.0
1. dsi: Add atomic {destroy,duplicate}_state, reset callbacks
 2. drm/mediatek: Fix wrong dither settings
 3. dsi: Move mtk_dsi_stop() call back to mtk_dsi_poweroff()
 -----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCgAdFiEEACwLKSDmq+9RDv5P4cpzo8lZTiQFAmMroWMACgkQ4cpzo8lZ
 TiQbzw/7BoPLQNXzksNehXqbmxN5XcmbXda/jL2OSXfjIxYOv3D5BMvSksmsZOmY
 ODHH8KQ7Ru7lKqxrltBToitCnHT7ZNTO6qrixogCMbDdewAeAhkTHhYoaUSfly34
 1t+HrdhTA/XQqyDU+v83PWtzD0FrvY3iJ1/l0/8311x66F/vdrNVBkpqNomVRve5
 BiFniFpjU5QP22/PU/VgvS/EcJ07Cy7PC0Ocv9guaaScaHMRl5HCGI3A0uBLqJyl
 NR/Sx6HXrHwKH219Oe1hZrj3RXVj5xp2qdKsiRtJiufniQFilKZjwS2bo+nZrvzz
 dKPPcLJsjjy/hH6S5t5X49Yn5GETBGE1KAB5y6AqrGvhi+vTxwhKhVxRxn+d5JgW
 RN0SiLIhwLaEifU3WyTuG+Zth4aY24Pakcd0lhn71avjXATG1Go/7D31gAUVhNw1
 rCFoiy4xxq2n3QFKfUNWePYn2RC98jF9kYo23aDhPi6tEbsxQ3IyMc2+PhtPQidW
 uXntRZAPd1Gd4B2Y3PXPOfLmes5a8w2HZxcNv3nE5F7hHF4j+x5Zf7jfHKNtxLwG
 dn20ahxXprt7mitWFxA5pIiiv1YciJy4A5jYknuDfa/xTiaPZ7jbmhfv4uZUisZW
 frl4MbV6OUxxfK6WxMdK/nzYdBMyuXfbhLZzN6o3ZBZSp6+SLTQ=
 =qZkC
 -----END PGP SIGNATURE-----

Merge tag 'mediatek-drm-fixes-6.0' of https://git.kernel.org/pub/scm/linux/kernel/git/chunkuang.hu/linux into drm-fixes

Mediatek DRM Fixes for Linux 6.0

1. dsi: Add atomic {destroy,duplicate}_state, reset callbacks
2. drm/mediatek: Fix wrong dither settings
3. dsi: Move mtk_dsi_stop() call back to mtk_dsi_poweroff()

Signed-off-by: Dave Airlie <airlied@redhat.com>

From: Chun-Kuang Hu <chunkuang.hu@kernel.org>
Link: https://patchwork.freedesktop.org/patch/msgid/20220921235624.23580-1-chunkuang.hu@kernel.org
2022-09-23 13:15:34 +10:00
Dave Airlie
387df878fd Merge tag 'amd-drm-fixes-6.0-2022-09-21' of https://gitlab.freedesktop.org/agd5f/linux into drm-fixes
amd-drm-fixes-6.0-2022-09-21:

amdgpu:
- SDMA 6.x fix
- GPUVM TF fix
- DCN 3.2.x fixes
- DCN 3.1.x fixes
- SMU 13.x fixes
- Clang stack size fixes for recently enabled DML code
- Fix drm dirty callback change on non-atomic cases
- USB4 display fix

Signed-off-by: Dave Airlie <airlied@redhat.com>
From: Alex Deucher <alexander.deucher@amd.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20220921220605.6136-1-alexander.deucher@amd.com
2022-09-23 11:12:07 +10:00
Linus Torvalds
bf682942cd SCSI fixes on 20220922
Three small and pretty obvious fixes, all in drivers.
 
 Signed-off-by: James E.J. Bottomley <jejb@linux.ibm.com>
 -----BEGIN PGP SIGNATURE-----
 
 iJwEABMIAEQWIQTnYEDbdso9F2cI+arnQslM7pishQUCYyzJQSYcamFtZXMuYm90
 dG9tbGV5QGhhbnNlbnBhcnRuZXJzaGlwLmNvbQAKCRDnQslM7pishTWYAQDdYNvh
 aS/3M0QRAajT0pXbpElbTEZunoTv8oG5rGtzHAD9Hy0VponMU0Ey9e1twkY7pdjI
 ik3qiy3gi9tu+bqgGuA=
 =cXQI
 -----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:
 "Three small and pretty obvious fixes, all in drivers"

* tag 'scsi-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi:
  scsi: mpt3sas: Fix return value check of dma_get_required_mask()
  scsi: qla2xxx: Fix memory leak in __qlt_24xx_handle_abts()
  scsi: qedf: Fix a UAF bug in __qedf_probe()
2022-09-22 14:43:55 -07:00
Linus Torvalds
3c0f396a38 slab fixes for 6.0-rc7
-----BEGIN PGP SIGNATURE-----
 
 iQEzBAABCAAdFiEEjUuTAak14xi+SF7M4CHKc/GJqRAFAmMsvZoACgkQ4CHKc/GJ
 qRC3UQf/bHHsh/tYV26OrNBJ82V9KlM8V5TNkn2QRfnS9EP3J1y4snENpQ+gZRXf
 QgSt/hgQqhvdazNtNwzUeW4ENymyt78zJfH87Kj36ApB+6xUnX3qIqmPHGn5Bqzn
 Oo1mY4UfYExzq8k9m2L5De/ULNBClItjkYZ1sPGAbMvM8LSSeneABimxq9aey00d
 IENX1mboxju13+Z2nasze7QJkeaJ8emFJY2X2E1A0FGPvcnRSK34t5EtFZnC/wd3
 D2awIw4ebASY1NqBnJfy6ClcyY0dE30pT2eWLLatjDXdesI8oDkqkaeyyWZEXwX5
 gMkJOEaAJcob4LpcsVPikRUrPadGrA==
 =Jao8
 -----END PGP SIGNATURE-----

Merge tag 'slab-for-6.0-rc7' of git://git.kernel.org/pub/scm/linux/kernel/git/vbabka/slab

Pull slab fixes from Vlastimil Babka:

 - Fix a possible use-after-free in SLUB's kmem_cache removal,
   introduced in this cycle, by Feng Tang.

 - WQ_MEM_RECLAIM dependency fix for the workqueue-based cpu slab
   flushing introduced in 5.15, by Maurizio Lombardi.

 - Add missing KASAN hooks in two kmalloc entry paths, by Peter
   Collingbourne.

 - A BUG_ON() removal in SLUB's kmem_cache creation when allocation
   fails (too small to possibly happen in practice, syzbot used fault
   injection), by Chao Yu.

* tag 'slab-for-6.0-rc7' of git://git.kernel.org/pub/scm/linux/kernel/git/vbabka/slab:
  mm: slub: fix flush_cpu_slab()/__free_slab() invocations in task context.
  mm/slab_common: fix possible double free of kmem_cache
  kasan: call kasan_malloc() from __kmalloc_*track_caller()
  mm/slub: fix to return errno if kmalloc() fails
2022-09-22 14:37:58 -07:00
Sean Christopherson
50b2d49baf KVM: x86: Inject #UD on emulated XSETBV if XSAVES isn't enabled
Inject #UD when emulating XSETBV if CR4.OSXSAVE is not set.  This also
covers the "XSAVE not supported" check, as setting CR4.OSXSAVE=1 #GPs if
XSAVE is not supported (and userspace gets to keep the pieces if it
forces incoherent vCPU state).

Add a comment to kvm_emulate_xsetbv() to call out that the CPU checks
CR4.OSXSAVE before checking for intercepts.  AMD'S APM implies that #UD
has priority (says that intercepts are checked before #GP exceptions),
while Intel's SDM says nothing about interception priority.  However,
testing on hardware shows that both AMD and Intel CPUs prioritize the #UD
over interception.

Fixes: 02d4160fbd ("x86: KVM: add xsetbv to the emulator")
Cc: stable@vger.kernel.org
Cc: Vitaly Kuznetsov <vkuznets@redhat.com>
Signed-off-by: Sean Christopherson <seanjc@google.com>
Message-Id: <20220824033057.3576315-4-seanjc@google.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2022-09-22 17:04:20 -04:00
Dr. David Alan Gilbert
a1020a25e6 KVM: x86: Always enable legacy FP/SSE in allowed user XFEATURES
Allow FP and SSE state to be saved and restored via KVM_{G,SET}_XSAVE on
XSAVE-capable hosts even if their bits are not exposed to the guest via
XCR0.

Failing to allow FP+SSE first showed up as a QEMU live migration failure,
where migrating a VM from a pre-XSAVE host, e.g. Nehalem, to an XSAVE
host failed due to KVM rejecting KVM_SET_XSAVE.  However, the bug also
causes problems even when migrating between XSAVE-capable hosts as
KVM_GET_SAVE won't set any bits in user_xfeatures if XSAVE isn't exposed
to the guest, i.e. KVM will fail to actually migrate FP+SSE.

Because KVM_{G,S}ET_XSAVE are designed to allowing migrating between
hosts with and without XSAVE, KVM_GET_XSAVE on a non-XSAVE (by way of
fpu_copy_guest_fpstate_to_uabi()) always sets the FP+SSE bits in the
header so that KVM_SET_XSAVE will work even if the new host supports
XSAVE.

Fixes: ad856280dd ("x86/kvm/fpu: Limit guest user_xfeatures to supported bits of XCR0")
bz: https://bugzilla.redhat.com/show_bug.cgi?id=2079311
Cc: stable@vger.kernel.org
Cc: Leonardo Bras <leobras@redhat.com>
Signed-off-by: Dr. David Alan Gilbert <dgilbert@redhat.com>
[sean: add comment, massage changelog]
Signed-off-by: Sean Christopherson <seanjc@google.com>
Message-Id: <20220824033057.3576315-3-seanjc@google.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2022-09-22 17:04:19 -04:00
Sean Christopherson
ee519b3a2a KVM: x86: Reinstate kvm_vcpu_arch.guest_supported_xcr0
Reinstate the per-vCPU guest_supported_xcr0 by partially reverting
commit 988896bb6182; the implicit assessment that guest_supported_xcr0 is
always the same as guest_fpu.fpstate->user_xfeatures was incorrect.

kvm_vcpu_after_set_cpuid() isn't the only place that sets user_xfeatures,
as user_xfeatures is set to fpu_user_cfg.default_features when guest_fpu
is allocated via fpu_alloc_guest_fpstate() => __fpstate_reset().
guest_supported_xcr0 on the other hand is zero-allocated.  If userspace
never invokes KVM_SET_CPUID2, supported XCR0 will be '0', whereas the
allowed user XFEATURES will be non-zero.

Practically speaking, the edge case likely doesn't matter as no sane
userspace will live migrate a VM without ever doing KVM_SET_CPUID2. The
primary motivation is to prepare for KVM intentionally and explicitly
setting bits in user_xfeatures that are not set in guest_supported_xcr0.

Because KVM_{G,S}ET_XSAVE can be used to svae/restore FP+SSE state even
if the host doesn't support XSAVE, KVM needs to set the FP+SSE bits in
user_xfeatures even if they're not allowed in XCR0, e.g. because XCR0
isn't exposed to the guest.  At that point, the simplest fix is to track
the two things separately (allowed save/restore vs. allowed XCR0).

Fixes: 988896bb61 ("x86/kvm/fpu: Remove kvm_vcpu_arch.guest_supported_xcr0")
Cc: stable@vger.kernel.org
Cc: Leonardo Bras <leobras@redhat.com>
Signed-off-by: Sean Christopherson <seanjc@google.com>
Message-Id: <20220824033057.3576315-2-seanjc@google.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2022-09-22 17:04:19 -04:00
Miaohe Lin
604f533262 KVM: x86/mmu: add missing update to max_mmu_rmap_size
The update to statistic max_mmu_rmap_size is unintentionally removed by
commit 4293ddb788 ("KVM: x86/mmu: Remove redundant spte present check
in mmu_set_spte"). Add missing update to it or max_mmu_rmap_size will
always be nonsensical 0.

Fixes: 4293ddb788 ("KVM: x86/mmu: Remove redundant spte present check in mmu_set_spte")
Signed-off-by: Miaohe Lin <linmiaohe@huawei.com>
Message-Id: <20220907080657.42898-1-linmiaohe@huawei.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2022-09-22 17:03:20 -04:00
Jinrong Liang
561cafebb2 selftests: kvm: Fix a compile error in selftests/kvm/rseq_test.c
The following warning appears when executing:
	make -C tools/testing/selftests/kvm

rseq_test.c: In function ‘main’:
rseq_test.c:237:33: warning: implicit declaration of function ‘gettid’; did you mean ‘getgid’? [-Wimplicit-function-declaration]
          (void *)(unsigned long)gettid());
                                 ^~~~~~
                                 getgid
/usr/bin/ld: /tmp/ccr5mMko.o: in function `main':
../kvm/tools/testing/selftests/kvm/rseq_test.c:237: undefined reference to `gettid'
collect2: error: ld returned 1 exit status
make: *** [../lib.mk:173: ../kvm/tools/testing/selftests/kvm/rseq_test] Error 1

Use the more compatible syscall(SYS_gettid) instead of gettid() to fix it.
More subsequent reuse may cause it to be wrapped in a lib file.

Signed-off-by: Jinrong Liang <cloudliang@tencent.com>
Message-Id: <20220802071240.84626-1-cloudliang@tencent.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2022-09-22 17:02:20 -04:00
Paolo Bonzini
b4ac28a32f KVM/arm64 fixes for 6.0, take #2
- Fix kmemleak usage in Protected KVM (again)
 -----BEGIN PGP SIGNATURE-----
 
 iQJDBAABCgAtFiEEn9UcU+C1Yxj9lZw9I9DQutE9ekMFAmMoo2EPHG1hekBrZXJu
 ZWwub3JnAAoJECPQ0LrRPXpD308QAL5sZ7lzB6sS2Zw4zMxpi1nW0qPJKJuvwaF7
 PZKhZTJhbXUWlSFIBRtcfzR7Aw7fP5W/dcE66TcE8IA5zNd8/O+jrJtE3uul65SG
 3nKaVuU0cYvFiA7rLJsrg+KLqPHYGnKbRO3KQrfpPT8MDs0t/OgXdyiwBycU8Os0
 XWT5anjJRCPpUIUhOW19gBKSMyYrMRlhybrWbY0MAJgtpJTMJyqjosrHWFUeDog8
 0ecDg/FS7SZhRvm6Ruf27fydNkh4mJ2dNZqzpaWTttxOV8+LN2r9ClJP98a4VWYz
 ek55ihLU+XijNozOu3O9OxcC3VULf12R/0SMnXpGdi752H+3fH26iiDmxKiHGSSR
 LV/JVPLrw1OgxAK7Wb/0v29+Z7dD9l7gBGIgvZGT5PhgKGR4W//k1EGkIS0Yh7HI
 lT7URgwagP8qgdJBfmaROdx3V4XEDX17I862aEinstr8HaCvQzgKIXmdUHiW+21P
 4Xk7HcvgJuL/NOhVtZFT8ejAlgWNi4HRyPZ/YHVA2XPbmCZk2KS0Oe0WbX9iX7vT
 SYx/X9J/CJ1+BRiDk/hMQlNMxua/9eTG42iNdg/5zB/medZpb3GlDVmvO5vXIHut
 V2chjnt11rWtzskP4noaGYGd6QlURbSHYPWTG0+XCL9BG0CJ0+Pmu9lMRHwWGnlU
 NJoGm0ZC
 =UygE
 -----END PGP SIGNATURE-----

Merge tag 'kvmarm-fixes-6.0-2' of git://git.kernel.org/pub/scm/linux/kernel/git/kvmarm/kvmarm into HEAD

KVM/arm64 fixes for 6.0, take #2

- Fix kmemleak usage in Protected KVM (again)
2022-09-22 17:01:33 -04:00
Maurizio Lombardi
e45cc28872 mm: slub: fix flush_cpu_slab()/__free_slab() invocations in task context.
Commit 5a836bf6b0 ("mm: slub: move flush_cpu_slab() invocations
__free_slab() invocations out of IRQ context") moved all flush_cpu_slab()
invocations to the global workqueue to avoid a problem related
with deactivate_slab()/__free_slab() being called from an IRQ context
on PREEMPT_RT kernels.

When the flush_all_cpu_locked() function is called from a task context
it may happen that a workqueue with WQ_MEM_RECLAIM bit set ends up
flushing the global workqueue, this will cause a dependency issue.

 workqueue: WQ_MEM_RECLAIM nvme-delete-wq:nvme_delete_ctrl_work [nvme_core]
   is flushing !WQ_MEM_RECLAIM events:flush_cpu_slab
 WARNING: CPU: 37 PID: 410 at kernel/workqueue.c:2637
   check_flush_dependency+0x10a/0x120
 Workqueue: nvme-delete-wq nvme_delete_ctrl_work [nvme_core]
 RIP: 0010:check_flush_dependency+0x10a/0x120[  453.262125] Call Trace:
 __flush_work.isra.0+0xbf/0x220
 ? __queue_work+0x1dc/0x420
 flush_all_cpus_locked+0xfb/0x120
 __kmem_cache_shutdown+0x2b/0x320
 kmem_cache_destroy+0x49/0x100
 bioset_exit+0x143/0x190
 blk_release_queue+0xb9/0x100
 kobject_cleanup+0x37/0x130
 nvme_fc_ctrl_free+0xc6/0x150 [nvme_fc]
 nvme_free_ctrl+0x1ac/0x2b0 [nvme_core]

Fix this bug by creating a workqueue for the flush operation with
the WQ_MEM_RECLAIM bit set.

Fixes: 5a836bf6b0 ("mm: slub: move flush_cpu_slab() invocations __free_slab() invocations out of IRQ context")
Cc: <stable@vger.kernel.org>
Signed-off-by: Maurizio Lombardi <mlombard@redhat.com>
Reviewed-by: Hyeonggon Yoo <42.hyeyoo@gmail.com>
Signed-off-by: Vlastimil Babka <vbabka@suse.cz>
2022-09-22 21:48:48 +02:00
Linus Torvalds
c69cf88cda ARM: SoC fixes for 6.0-rc6
Another set of fixes for fixes for the soc tree:
 
  - A fix for the interrupt number on at91/lan966 ethernet PHYs
 
  - A second round of fixes for NXP i.MX series, including a couple
    of build issues, and board specific DT corrections on
    TQMa8MPQL, imx8mp-venice-gw74xx and imx8mm-verdin for reliability
    and partially broken functionality.
 
  - Several fixes for Rockchip SoCs, addressing a USB issue on BPI-R2-Pro,
    wakeup on Gru-Bob and reliability of high-speed SD cards, among
    other minor issues.
 
  - A fix for a long-running naming mistake that prevented the moxart mmc
    driver from working at all.
 
  - Multiple Arm SCMI firmware fixes for hardening some corner cases.
 -----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCgAdFiEEo6/YBQwIrVS28WGKmmx57+YAGNkFAmMsf8kACgkQmmx57+YA
 GNklew//T+pAuVwhR8OMp3DolbM/CwezgZgEXkuqDS0GvLkuoR71N7y1wEO77CDI
 9/luYQiFnMI8ooBMXLG545EJCZNommtDKWfSMjJnYeVQit3nupJSYaOLkzD949hg
 fg2BhA3mIKJY53m5SHRfZJOr+Q5E1DEmREX7m9e3nXTDY7izWpE2HtlKt26lKTq4
 w4sbchmrC4YRLqkBbSGLczClCakF0/L3QhGUIfBlTdLmhye0PJiQzfhVTKgdb7Jr
 l0T8vt5vg+5f5ib3PrnPQCaA3Azgu0QvImwKr7/vU/Sn6/e/xwV/hcuqQBZPFbbl
 RmSkHb3mBLXogk/EjLiw8y59D22SIbdtE+/tD+FRP+q0gjgPKobRZiqLFijvIWSB
 TtaTsKhotFKFs+pDysF0C/IfpK9MaYcX71WdqfvwlPiGGK7xCt3W+AKzgUmRVfew
 dVMeyBlVL9T3003MpLkiaIoDp8JfJsD3051CCH5tdOtF53PeKsgTUEXtnQezBof2
 80KgGXg2QGbwx+vYPGJqgQKzG7teq06G4BERK/yeFCrOsxrRXzH/icDA3F5xKY5f
 IqQiTqvZeCQvvr8G1iZb6YkhflQHaNktsRCajxERTgPfRzuQFHwF96C/+weGcZBp
 edBtweGCJ7AvV8vmvmvCdMDg9BDfgHOOwiNOKqmVvsIO01Ei8Oc=
 =fI2K
 -----END PGP SIGNATURE-----

Merge tag 'soc-fixes-6.0-rc6' of git://git.kernel.org/pub/scm/linux/kernel/git/soc/soc

Pull ARM SoC fixes from Arnd Bergmann:
 "Another set of fixes for fixes for the soc tree:

   - A fix for the interrupt number on at91/lan966 ethernet PHYs

   - A second round of fixes for NXP i.MX series, including a couple of
     build issues, and board specific DT corrections on TQMa8MPQL,
     imx8mp-venice-gw74xx and imx8mm-verdin for reliability and
     partially broken functionality

   - Several fixes for Rockchip SoCs, addressing a USB issue on
     BPI-R2-Pro, wakeup on Gru-Bob and reliability of high-speed SD
     cards, among other minor issues

   - A fix for a long-running naming mistake that prevented the moxart
     mmc driver from working at all

   - Multiple Arm SCMI firmware fixes for hardening some corner cases"

* tag 'soc-fixes-6.0-rc6' of git://git.kernel.org/pub/scm/linux/kernel/git/soc/soc: (30 commits)
  arm64: dts: imx8mp-venice-gw74xx: fix port/phy validation
  ARM: dts: lan966x: Fix the interrupt number for internal PHYs
  arm64: dts: imx8mp-venice-gw74xx: fix ksz9477 cpu port
  arm64: dts: imx8mp-venice-gw74xx: fix CAN STBY polarity
  dt-bindings: memory-controllers: fsl,imx8m-ddrc: drop Leonard Crestez
  arm64: dts: tqma8mqml: Include phy-imx8-pcie.h header
  arm64: defconfig: enable ARCH_NXP
  arm64: dts: imx8mp-tqma8mpql-mba8mpxl: add missing pinctrl for RTC alarm
  ARM: dts: fix Moxa SDIO 'compatible', remove 'sdhci' misnomer
  arm64: dts: imx8mm-verdin: extend pmic voltages
  arm64: dts: rockchip: Remove 'enable-active-low' from rk3566-quartz64-a
  arm64: dts: rockchip: Remove 'enable-active-low' from rk3399-puma
  arm64: dts: rockchip: fix property for usb2 phy supply on rk3568-evb1-v10
  arm64: dts: rockchip: fix property for usb2 phy supply on rock-3a
  arm64: dts: imx8ulp: add #reset-cells for pcc
  arm64: dts: tqma8mpxl-ba8mpxl: Fix button GPIOs
  arm64: dts: imx8mn: remove GPU power domain reset
  arm64: dts: rockchip: Set RK3399-Gru PCLK_EDP to 24 MHz
  arm64: dts: imx8mm: Reverse CPLD_Dn GPIO label mapping on MX8Menlo
  arm64: dts: rockchip: fix upper usb port on BPI-R2-Pro
  ...
2022-09-22 11:10:11 -07:00
Linus Torvalds
504c25cb76 Including fixes from wifi, netfilter and can.
A handful of awaited fixes here - revert of the FEC changes,
 bluetooth fix, fixes for iwlwifi spew.
 
 We added a warning in PHY/MDIO code which is triggering on
 a couple of platforms in a false-positive-ish way. If we can't
 iron that out over the week we'll drop it and re-add for 6.1.
 
 I've added a new "follow up fixes" section for fixes to fixes
 in 6.0-rcs but it may actually give the false impression that
 those are problematic or that more testing time would have
 caught them. So likely a one time thing.
 
 Follow up fixes:
 
  - nf_tables_addchain: fix nft_counters_enabled underflow
 
  - ebtables: fix memory leak when blob is malformed
 
  - nf_ct_ftp: fix deadlock when nat rewrite is needed
 
 Current release - regressions:
 
  - Revert "fec: Restart PPS after link state change"
  - Revert "net: fec: Use a spinlock to guard `fep->ptp_clk_on`"
 
  - Bluetooth: fix HCIGETDEVINFO regression
 
  - wifi: mt76: fix 5 GHz connection regression on mt76x0/mt76x2
 
  - mptcp: fix fwd memory accounting on coalesce
 
  - rwlock removal fall out:
    - ipmr: always call ip{,6}_mr_forward() from RCU read-side
      critical section
    - ipv6: fix crash when IPv6 is administratively disabled
 
  - tcp: read multiple skbs in tcp_read_skb()
 
  - mdio_bus_phy_resume state warning fallout:
    - eth: ravb: fix PHY state warning splat during system resume
    - eth: sh_eth: fix PHY state warning splat during system resume
 
 Current release - new code bugs:
 
  - wifi: iwlwifi: don't spam logs with NSS>2 messages
 
  - eth: mtk_eth_soc: enable XDP support just for MT7986 SoC
 
 Previous releases - regressions:
 
  - bonding: fix NULL deref in bond_rr_gen_slave_id
 
  - wifi: iwlwifi: mark IWLMEI as broken
 
 Previous releases - always broken:
 
  - nf_conntrack helpers:
    - irc: tighten matching on DCC message
    - sip: fix ct_sip_walk_headers
    - osf: fix possible bogus match in nf_osf_find()
 
  - ipvlan: fix out-of-bound bugs caused by unset skb->mac_header
 
  - core: fix flow symmetric hash
 
  - bonding, team: unsync device addresses on ndo_stop
 
  - phy: micrel: fix shared interrupt on LAN8814
 
 Signed-off-by: Jakub Kicinski <kuba@kernel.org>
 -----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCAAdFiEE6jPA+I1ugmIBA4hXMUZtbf5SIrsFAmMsj3EACgkQMUZtbf5S
 IrsUgQ//eXxuUZeGTg7cgJKPFJelrZ3iL16B1+s2qX94GPIqXRAShgC78iM7IbSe
 y3vR/7YVE7sKXm88wnLefMQVXPp0cE2p0+8++E/j4zcRZsM5sHb2+d3gW6nos2ed
 U8Ldm7LzWUNt/o1ZHDqZWBSoreFkmbFyHO6FVPCuH11tFUJqxJ/SP860mwo6tbuT
 HOoVphKis41IMEXCgybs2V0DAQewba0gejzAmySDy8epNhOj2F4Vo6aadnUCI68U
 HrIFYe2wiEi6MZDsB9zpRXc9seb6ZBKbBjgQnTK7MwfBEQCzxtR2lkNobJM1WbdL
 nYwHBOJ16yX0BnlSpUEepv6iJYY5Q7FS35Wk3Rq5Mik6DaEir6vVSBdRxHpYOkO2
 KPIyyMMAA5E8mAtqH3PcpnwDK+9c3KlZYYKXxIp2IjQm87DpOZJFynwsC3Crmbzo
 C7UTMav2nkHljoapMLUwzqyw2ip+Qo14XA043FDPUru1sXY9CY6q50XZa5GmrNKh
 xyaBdp4Ckj1kOuXUR9jz3Rq8skOZ8lNGHtiCdgPZitWhNKW1YORJihC7/9zdieCR
 1gOE7Dpz/MhVmFn2e8S5O3TkU5lXfALfPDJi4QiML5VLHXd/nCE5sHPiOBWcoo4w
 2djKbIGpLRnO6qMs4NkWNmPbG+/ouvpM+lewqn+xU4TGyn/NTbI=
 =wrep
 -----END PGP SIGNATURE-----

Merge tag 'net-6.0-rc7' of git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net

Pull networking fixes from Jakub Kicinski:
 "Including fixes from wifi, netfilter and can.

  A handful of awaited fixes here - revert of the FEC changes, bluetooth
  fix, fixes for iwlwifi spew.

  We added a warning in PHY/MDIO code which is triggering on a couple of
  platforms in a false-positive-ish way. If we can't iron that out over
  the week we'll drop it and re-add for 6.1.

  I've added a new "follow up fixes" section for fixes to fixes in
  6.0-rcs but it may actually give the false impression that those are
  problematic or that more testing time would have caught them. So
  likely a one time thing.

  Follow up fixes:

   - nf_tables_addchain: fix nft_counters_enabled underflow

   - ebtables: fix memory leak when blob is malformed

   - nf_ct_ftp: fix deadlock when nat rewrite is needed

  Current release - regressions:

   - Revert "fec: Restart PPS after link state change" and the related
     "net: fec: Use a spinlock to guard `fep->ptp_clk_on`"

   - Bluetooth: fix HCIGETDEVINFO regression

   - wifi: mt76: fix 5 GHz connection regression on mt76x0/mt76x2

   - mptcp: fix fwd memory accounting on coalesce

   - rwlock removal fall out:
      - ipmr: always call ip{,6}_mr_forward() from RCU read-side
        critical section
      - ipv6: fix crash when IPv6 is administratively disabled

   - tcp: read multiple skbs in tcp_read_skb()

   - mdio_bus_phy_resume state warning fallout:
      - eth: ravb: fix PHY state warning splat during system resume
      - eth: sh_eth: fix PHY state warning splat during system resume

  Current release - new code bugs:

   - wifi: iwlwifi: don't spam logs with NSS>2 messages

   - eth: mtk_eth_soc: enable XDP support just for MT7986 SoC

  Previous releases - regressions:

   - bonding: fix NULL deref in bond_rr_gen_slave_id

   - wifi: iwlwifi: mark IWLMEI as broken

  Previous releases - always broken:

   - nf_conntrack helpers:
      - irc: tighten matching on DCC message
      - sip: fix ct_sip_walk_headers
      - osf: fix possible bogus match in nf_osf_find()

   - ipvlan: fix out-of-bound bugs caused by unset skb->mac_header

   - core: fix flow symmetric hash

   - bonding, team: unsync device addresses on ndo_stop

   - phy: micrel: fix shared interrupt on LAN8814"

* tag 'net-6.0-rc7' of git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net: (83 commits)
  selftests: forwarding: add shebang for sch_red.sh
  bnxt: prevent skb UAF after handing over to PTP worker
  net: marvell: Fix refcounting bugs in prestera_port_sfp_bind()
  net: sched: fix possible refcount leak in tc_new_tfilter()
  net: sunhme: Fix packet reception for len < RX_COPY_THRESHOLD
  udp: Use WARN_ON_ONCE() in udp_read_skb()
  selftests: bonding: cause oops in bond_rr_gen_slave_id
  bonding: fix NULL deref in bond_rr_gen_slave_id
  net: phy: micrel: fix shared interrupt on LAN8814
  net/smc: Stop the CLC flow if no link to map buffers on
  ice: Fix ice_xdp_xmit() when XDP TX queue number is not sufficient
  net: atlantic: fix potential memory leak in aq_ndev_close()
  can: gs_usb: gs_usb_set_phys_id(): return with error if identify is not supported
  can: gs_usb: gs_can_open(): fix race dev->can.state condition
  can: flexcan: flexcan_mailbox_read() fix return value for drop = true
  net: sh_eth: Fix PHY state warning splat during system resume
  net: ravb: Fix PHY state warning splat during system resume
  netfilter: nf_ct_ftp: fix deadlock when nat rewrite is needed
  netfilter: ebtables: fix memory leak when blob is malformed
  netfilter: nf_tables: fix percpu memory leak at nf_tables_addchain()
  ...
2022-09-22 10:58:13 -07:00
Linus Torvalds
129e715218 EFI fixes (take #2)
- Use the right variable to check for shim insecure mode
 - Wipe setup_data field when booting via EFI
 - Add missing error check to efibc driver
 -----BEGIN PGP SIGNATURE-----
 
 iQGzBAABCgAdFiEE+9lifEBpyUIVN1cpw08iOZLZjyQFAmMsbqYACgkQw08iOZLZ
 jyROTAwAoKK2463ZJb6H4JAPf3NWWy5lTiJE5GnQpf75soJENNJGQil2d2RBKDEs
 v8aBK6RleMTltmNesy7DNEHCi1It5zWNEPUIuo3AfteSHqeAZaebtfZ0JInatdGo
 umw3XriYxIG0XTr6SWktjzQvOrouT/+HqSLE/FdOHjFW3l2WXpWeqrZ69QRirrYL
 /tWVAwT5b8Y3Ds7lma4ivm8BZYEHVFdzHDUfZYh+YW13tRw23c93TNUF9vl9Pa83
 My9ncQIB9UqDZ6KVze/7tQ9BG5WatRgDJb+QlLaBSXX5191qfouj1mW7waoJ+Gs9
 ptQGBWGuOsGj9/85ixh+o9xjZrDq6sZksWI+pcbnJK7zQIrh2wBZI0xIaX79ekOM
 wUtavQ1QezuKntg7kZFgutMnUrqtCbEbQ9RL5JsbndQ8PkZH5v5XygwzBc/6h0pj
 ZgD3CQ04sDvy/UHhIARHDKzNCQldXjUyEVpAWwGlkPqTDqyPthtluzZ53kZbh+HX
 o+/rXcw8
 =Earg
 -----END PGP SIGNATURE-----

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

Pull EFI fixes from Ard Biesheuvel:

 - Use the right variable to check for shim insecure mode

 - Wipe setup_data field when booting via EFI

 - Add missing error check to efibc driver

* tag 'efi-urgent-for-v6.0-2' of git://git.kernel.org/pub/scm/linux/kernel/git/efi/efi:
  efi: libstub: check Shim mode using MokSBStateRT
  efi: x86: Wipe setup_data on pure EFI boot
  efi: efibc: Guard against allocation failure
2022-09-22 10:27:38 -07:00
Linus Torvalds
5e0a93e427 gpio fixes for v6.0-rc7
- fix a NULL-pointer dereference at driver unbind and a potential
   resource leak in error path in gpio-mockup
 - make the irqchip immutable in gpio-ftgpio010
 - fix dereferencing a potentially uninitialized variable in gpio-tqmx86
 - fix interrupt registering in gpiolib's character device code
 -----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCgAdFiEEFp3rbAvDxGAT0sefEacuoBRx13IFAmMsNLoACgkQEacuoBRx
 13LdeBAApTXQb/AYIRKNJ06jB6GbZU0dH+X5fkr5u1EY8zCc2xshOgCiczI8zqir
 n3CoEXuekhpqL4cDr+rXX/fCPgED3s0RDTIrswwPFnvvmlr7yPbVIokecEUbzA40
 I7CKV/MtkDIvw05MGjiDWmk3SQZdWVrh5RaZclyxt3KXWIA6fu6T319tRf1C9UWt
 KQHsku15c8FEtwXjGjSUCEyKp53cXu+SNbUlkxwXbyov8ab+zWSzL0mDICRJkJYo
 Ort2y1G2zUubphQ4HLK3AGPDmhHxl52R+MTg5Mcutx/HfpWvm8+Vy6b58v91ycg2
 r4/8LUprFE3XI4+bIRWqftfl9CrTxLJzKUhUb4okExrGurOR+SHnvkYygUn4uef2
 jmKd0EUHYOsoJUryGYpIPuvXQpR/YoRkYEXNXGbeXghKzAbonYMsPaaUbGaGvwG4
 vgPBKcWPTXVda0bR5Vl1wkeN6422dwU/SQ+vN32Xgl/qszmIHPfzWz+FgpfN4L/R
 X2HMIoQ02h8uc2JC1R9H5bwbvVFrWI47XwIqh8xFf8UYZ7aUEI9hpm9CeVJDpbra
 EkQxft82GJ9GOt8QAakwQdlInoYp7OLEee1QAvaKJV8Psbydk5WarpB9R/0cqldP
 bbnTzrY4J+ZfNz1F1U7jYRAjSnChvW4d3b9AdwTVFdvpWFD4X68=
 =BBWZ
 -----END PGP SIGNATURE-----

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

Pull gpio fixes from Bartosz Golaszewski:

 - fix a NULL-pointer dereference at driver unbind and a potential
   resource leak in error path in gpio-mockup

 - make the irqchip immutable in gpio-ftgpio010

 - fix dereferencing a potentially uninitialized variable in gpio-tqmx86

 - fix interrupt registering in gpiolib's character device code

* tag 'gpio-fixes-for-v6.0-rc7' of git://git.kernel.org/pub/scm/linux/kernel/git/brgl/linux:
  gpiolib: cdev: Set lineevent_state::irq after IRQ register successfully
  gpio: tqmx86: fix uninitialized variable girq
  gpio: ftgpio010: Make irqchip immutable
  gpio: mockup: Fix potential resource leakage when register a chip
  gpio: mockup: fix NULL pointer dereference when removing debugfs
2022-09-22 10:17:29 -07:00
Linus Torvalds
9597f088c9 perf tools fixes for v6.0: 4th batch
- Fix polling of system-wide events related to mixing per-cpu and per-thread
   events.
 
 - Do not check if /proc/modules is unchanged when copying /proc/kcore,
   that doesn't get in the way of post processing analysis.
 
 - Include program header in ELF files generated for JIT files, so that they can
   be opened by tools using elfutils libraries.
 
 - Enter namespaces when synthesizing build-ids.
 
 - Fix some bugs related to a recent cpu_map overhaul where we should be
   using an index and not the cpu number.
 
 - Fix BPF program ELF section name, using the naming expected by libbpf when
   using BPF counters in 'perf stat'.
 
 - Add a new test for perf stat cgroup BPF counter.
 
 - Adjust check on 'perf test wp' for older kernels, where the
   PERF_EVENT_IOC_MODIFY_ATTRIBUTES ioctl isn't supported.
 
 - Sync x86 cpufeatures with the kernel sources, no changes in tooling.
 
 Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
 -----BEGIN PGP SIGNATURE-----
 
 iHUEABYKAB0WIQR2GiIUctdOfX2qHhGyPKLppCJ+JwUCYyuOXgAKCRCyPKLppCJ+
 J7PsAPwMmEKNG08rBuZG64my1sS1hKNP2uAWcii871hFe0jSowEArWd2ErRw5wPw
 Y3uT9gP11NHDN+B87HxVErNkNUp3PQM=
 =S2hR
 -----END PGP SIGNATURE-----

Merge tag 'perf-tools-fixes-for-v6.0-2022-09-21' of git://git.kernel.org/pub/scm/linux/kernel/git/acme/linux

Pull perf tools fixes from Arnaldo Carvalho de Melo:

 - Fix polling of system-wide events related to mixing per-cpu and
   per-thread events.

 - Do not check if /proc/modules is unchanged when copying /proc/kcore,
   that doesn't get in the way of post processing analysis.

 - Include program header in ELF files generated for JIT files, so that
   they can be opened by tools using elfutils libraries.

 - Enter namespaces when synthesizing build-ids.

 - Fix some bugs related to a recent cpu_map overhaul where we should be
   using an index and not the cpu number.

 - Fix BPF program ELF section name, using the naming expected by libbpf
   when using BPF counters in 'perf stat'.

 - Add a new test for perf stat cgroup BPF counter.

 - Adjust check on 'perf test wp' for older kernels, where the
   PERF_EVENT_IOC_MODIFY_ATTRIBUTES ioctl isn't supported.

 - Sync x86 cpufeatures with the kernel sources, no changes in tooling.

* tag 'perf-tools-fixes-for-v6.0-2022-09-21' of git://git.kernel.org/pub/scm/linux/kernel/git/acme/linux:
  perf tools: Honor namespace when synthesizing build-ids
  tools headers cpufeatures: Sync with the kernel sources
  perf kcore_copy: Do not check /proc/modules is unchanged
  libperf evlist: Fix polling of system-wide events
  perf record: Fix cpu mask bit setting for mixed mmaps
  perf test: Skip wp modify test on old kernels
  perf jit: Include program header in ELF files
  perf test: Add a new test for perf stat cgroup BPF counter
  perf stat: Use evsel->core.cpus to iterate cpus in BPF cgroup counters
  perf stat: Fix cpu map index in bperf cgroup code
  perf stat: Fix BPF program section name
2022-09-22 10:12:21 -07:00
Tomer Maimon
ae358d71d4 reset: npcm: fix iprst2 and iprst4 setting
In NPCM8XX USB reset sequence, iprst2 register was set with iprst4 value
and iprst4 register wasn´t set.

This fix sets the correct IP reset values in iprst2 and iprst4 registers
in NPCM8XX USB reset sequence.

Fixes: fc5d2a2f4a ("reset: npcm: Add NPCM8XX support")

Signed-off-by: Tomer Maimon <tmaimon77@gmail.com>
Signed-off-by: Philipp Zabel <p.zabel@pengutronix.de>
Link: https://lore.kernel.org/r/20220922153856.23326-1-tmaimon77@gmail.com
2022-09-22 17:48:35 +02:00
Theodore Ts'o
80fa46d6b9 ext4: limit the number of retries after discarding preallocations blocks
This patch avoids threads live-locking for hours when a large number
threads are competing over the last few free extents as they blocks
getting added and removed from preallocation pools.  From our bug
reporter:

   A reliable way for triggering this has multiple writers
   continuously write() to files when the filesystem is full, while
   small amounts of space are freed (e.g. by truncating a large file
   -1MiB at a time). In the local filesystem, this can be done by
   simply not checking the return code of write (0) and/or the error
   (ENOSPACE) that is set. Over NFS with an async mount, even clients
   with proper error checking will behave this way since the linux NFS
   client implementation will not propagate the server errors [the
   write syscalls immediately return success] until the file handle is
   closed. This leads to a situation where NFS clients send a
   continuous stream of WRITE rpcs which result in ERRNOSPACE -- but
   since the client isn't seeing this, the stream of writes continues
   at maximum network speed.

   When some space does appear, multiple writers will all attempt to
   claim it for their current write. For NFS, we may see dozens to
   hundreds of threads that do this.

   The real-world scenario of this is database backup tooling (in
   particular, github.com/mdkent/percona-xtrabackup) which may write
   large files (>1TiB) to NFS for safe keeping. Some temporary files
   are written, rewound, and read back -- all before closing the file
   handle (the temp file is actually unlinked, to trigger automatic
   deletion on close/crash.) An application like this operating on an
   async NFS mount will not see an error code until TiB have been
   written/read.

   The lockup was observed when running this database backup on large
   filesystems (64 TiB in this case) with a high number of block
   groups and no free space. Fragmentation is generally not a factor
   in this filesystem (~thousands of large files, mostly contiguous
   except for the parts written while the filesystem is at capacity.)

Signed-off-by: Theodore Ts'o <tytso@mit.edu>
Cc: stable@kernel.org
2022-09-22 10:51:19 -04:00