Commit Graph

1324586 Commits

Author SHA1 Message Date
Linus Torvalds
d6ef8b40d0 sound fixes for 6.13-rc5
A collection of small fixes.  Nothing really stands out, fortunately.
 
 - Follow-up fixes for the new compress offload API extension
 - A few ASoC SOF, AMD and Mediatek quirks and fixes
 - A regression fix in legacy SH driver cleanup
 - Fix DMA mapping error handling in the helper code
 - Fix kselftest dependency
 -----BEGIN PGP SIGNATURE-----
 
 iQJCBAABCAAsFiEEIXTw5fNLNI7mMiVaLtJE4w1nLE8FAmdtgNMOHHRpd2FpQHN1
 c2UuZGUACgkQLtJE4w1nLE/hcA//faV801EX6Dp42M19SEm4LLQrWrkqYkg9h+ra
 dGlgcJWQwJrxX6kyFefBiAhu99DuwDuNpUgRZgtPfdGgA2jQaKjwbP+/TMifheh8
 y9ljr1TBZ90IGBcIGa6GhKVkRK/3kRj61FBRXlev3HfXn1PqMY7092wzGjL1lHoc
 c/qxnHdRGlPSdFdXHeXm8VNJ3QYCZlK0nf6wljKTDlCZSj/NdjFttEhSQHQ5Rbg6
 NMglvBuX6GUwJm1M/SiNNJ+8NBigxs4MF1Rgy1nuuC4gndozjDXPWjSIxHsSZCm7
 jpk7giqU1D9nBjxG/7wN2sE42GHKx61oEvJVVS+53zRetXuBFSNbEgGNCJPsjWwS
 TUKMuUfyBfNwV9WKJ8/8IS50Vqdbgf+t1VLHUuGFMq7NkFFpnW+KGnfJL4ZSHyce
 9bAVwkA26mX1YhBhsHq1R4DGOVIVmeIIKH6f6uazN7YNB2y5VFSJIiMUK6ih8OwQ
 NWqCdn5i3qfco/Gi/IZd5kAbT6xWsLViGEJ0rTCsjHJI3zu54i8Xyl5Fp0e8lLJj
 /rr/QzBwIiBLMlj+WcrEc0a+P0izqur/OhYJIeVJbtfVrJLtFv67NRjnaqeyJK1M
 5UevtxAC0r5NrYmQpURW8GGTkMiu/litNiIbHrcCCCWYZhMz6ST4UdqBNW73bOMK
 bHaNyqk=
 =3ZF7
 -----END PGP SIGNATURE-----

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

Pull sound fixes from Takashi Iwai:
 "A collection of small fixes. Nothing really stands out, fortunately.

   - Follow-up fixes for the new compress offload API extension

   - A few ASoC SOF, AMD and Mediatek quirks and fixes

   - A regression fix in legacy SH driver cleanup

   - Fix DMA mapping error handling in the helper code

   - Fix kselftest dependency"

* tag 'sound-6.13-rc5' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound:
  ALSA: sh: Fix wrong argument order for copy_from_iter()
  selftests/alsa: Fix circular dependency involving global-timer
  ALSA: memalloc: prefer dma_mapping_error() over explicit address checking
  ALSA: compress_offload: improve file descriptors installation for dma-buf
  ALSA: compress_offload: use safe list iteration in snd_compr_task_seq()
  ALSA: compress_offload: avoid 64-bit get_user()
  ALSA: compress_offload: import DMA_BUF namespace
  ASoC: mediatek: disable buffer pre-allocation
  ASoC: rt722: add delay time to wait for the calibration procedure
  ASoC: SOF: Intel: hda-dai: Do not release the link DMA on STOP
  ASoC: dt-bindings: realtek,rt5645: Fix CPVDD voltage comment
  ASoC: Intel: sof_sdw: Fix DMI match for Lenovo 21QA and 21QB
  ASoC: Intel: sof_sdw: Fix DMI match for Lenovo 21Q6 and 21Q7
  ASoC: amd: ps: Fix for enabling DMIC on acp63 platform via _DSD entry
2024-12-26 10:49:02 -08:00
Linus Torvalds
23db0ed34f dmaengine fixes for v6.13
Driver fixes for:
  - Kernel doc warning documentation fixes
  - apple driver fix for register access
  - amd driver dropping private dma_ops
  - freescale cleanup path fix
  - refcount fix for mv_xor driver
  - null pointer deref fix for at_xdmac driver
  - GENMASK to GENMASK_ULL fix for loongson2 apb driver
  - Tegra driver fix for correcting dma status
 -----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCgAdFiEE+vs47OPLdNbVcHzyfBQHDyUjg0cFAmdtW8IACgkQfBQHDyUj
 g0fWEQ/5AddE/OIlxBai1K+diRcTxrgHJ6rMl2+4gF3Odhf3+bCnGS8rnYxwzIzO
 eRgovAhJsR5zc519KIPvdm9nj/MlxzCCUktQX/5smLvLrlGqdlPor14/SMsm5ePS
 w1BX550Ho2YoI1mvlcW4Kj4Kvy6e2KAgBZs0gKsHLyS90KLsi9mENmt12RmYtPns
 DKkzy+R8q8Xf5GKAwPGFutbBsCzXocJmodcEbKNnYut9+Wcn3wao1ZUscrXEfT7X
 0AvAT+9rOTIItSHD4NSRqUmcqvcQqIY9ESJtntEABqes3/CBtr0dovZBoJvbpnu2
 iVAkQBeBi0Le9Wprs6q5ODr5BZsHYqjskstMXS48m3CUkShLORtwTJh+4fVDFPFE
 AuGn55nSfXQn/pbFbIoCbU8HzJmNlhFTtuvPji5PgLDi5st2aU3AjZcqdW+zGg9l
 Cwc+1A7AQ+SaZ3iY9aeNeckaeSefyDQiMH5P/1a/SLois8tGLaXJfi/t6vGDiuXp
 NlJJZ5GrMDlN3eKajDU2+qj0rBv8j6tYaL9VeQ3h/5UP1tlhm9gOMionri2do/hF
 XRioKQo8aFW5WadmPVBRhC65x83b3TUDf/KOgDhDh53VjZLNp+c2yAlzkFaUJofb
 EQblwTuASWnA7QnqqUT9juPLBBylbuNaxa0CiB8NCUUkx+vVTfA=
 =1jRj
 -----END PGP SIGNATURE-----

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

Pull dmaengine fixes from Vinod Koul:
 "Bunch of minor driver fixes for drivers in this cycle:

   - Kernel doc warning documentation fixes

   - apple driver fix for register access

   - amd driver dropping private dma_ops

   - freescale cleanup path fix

   - refcount fix for mv_xor driver

   - null pointer deref fix for at_xdmac driver

   - GENMASK to GENMASK_ULL fix for loongson2 apb driver

   - Tegra driver fix for correcting dma status"

* tag 'dmaengine-fix-6.13' of git://git.kernel.org/pub/scm/linux/kernel/git/vkoul/dmaengine:
  dmaengine: tegra: Return correct DMA status when paused
  dmaengine: mv_xor: fix child node refcount handling in early exit
  dmaengine: fsl-edma: implement the cleanup path of fsl_edma3_attach_pd()
  dmaengine: amd: qdma: Remove using the private get and set dma_ops APIs
  dmaengine: apple-admac: Avoid accessing registers in probe
  linux/dmaengine.h: fix a few kernel-doc warnings
  dmaengine: loongson2-apb: Change GENMASK to GENMASK_ULL
  dmaengine: dw: Select only supported masters for ACPI devices
  dmaengine: at_xdmac: avoid null_prt_deref in at_xdmac_prep_dma_memset
2024-12-26 10:43:25 -08:00
Linus Torvalds
6fcb22ef50 phy fixes for 6.13
- devm_phy_xxx fixes for few APIs in the phy core
  - qmp driver register name config
  - init sequence fix for usb driver
  - rockchip driver setting drvdata correctly in samsung hdptx and reset
    fix for naneng combophy
  - regulator dependency fix for mediatek hdmi driver
  - overflow assertion fix for stm32 driver
 -----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCgAdFiEE+vs47OPLdNbVcHzyfBQHDyUjg0cFAmdtV8cACgkQfBQHDyUj
 g0f7/BAApmyGATxMukoP1JPVoL7zTsoqFqzyX5RIz4rlrLMdPTFsF2luldVyslZq
 YXWUVROGZdrZ3vAv5Tu9UZLpX4P5gBidKA7mcRWP9oqgtICF97ChTU9sH6jmLX/B
 s3pY8DtzP51xpplDyMyj/iIAtMNurLj23Z1O+PflrXzL2XSxNNUBoH3BKohP4GGp
 bd1qdFg+nnDWdmD3pxYrGSDX74m49Ww7JHWtzH/VxASL0je9qmCPaS1IwNnSbeuR
 wnLjDE92X5wV70q1ZlWTsiaQoTmS2RyOMD+Xeh1d7Rw8cLvx0zXYOY2MsYn1ywcG
 Z2F0vtOxEUjXXwRGDAy0InmDZGTw4y7oncLI7D9LwAoWEoYHD43SYPyTQT2zHpew
 /ezT1As0l8K5O0XpYWslqviR6tMuLy3SPQFxU2LfPCPDj6pI05BldiMhVXXCEY90
 OPaNjcSyTn9/tznUbx6ftH7mqJp01enMQfbdKs9ozKgHF02Nj69LcD10UQ8lDUUM
 sXID7nQKmwbC3YIPjvTjcyNIhkdySRtZtyMgRLebooL7fXdm+qbieR6P5gT584x3
 Y9CehUySMt/KMh3knRJA4O3j9tV84Zyf5GvgBTQu/SSHCSUA1UlqtL08yEmg2IMk
 vQMoua5S5qDlhHDY1JICm58Lzfl8BNfWQy+10SheIb2pEw5J48Q=
 =W42y
 -----END PGP SIGNATURE-----

Merge tag 'phy-fixes-6.13' of git://git.kernel.org/pub/scm/linux/kernel/git/phy/linux-phy

Pull phy fixes from Vinod Koul:
 "A few core API fixes for devm calls and bunch of driver fixes as
  usual:

   - devm_phy_xxx fixes for few APIs in the phy core

   - qmp driver register name config

   - init sequence fix for usb driver

   - rockchip driver setting drvdata correctly in samsung hdptx and
     reset fix for naneng combophy

   - regulator dependency fix for mediatek hdmi driver

   - overflow assertion fix for stm32 driver"

* tag 'phy-fixes-6.13' of git://git.kernel.org/pub/scm/linux/kernel/git/phy/linux-phy:
  phy: mediatek: phy-mtk-hdmi: add regulator dependency
  phy: freescale: fsl-samsung-hdmi: Fix 64-by-32 division cocci warnings
  phy: core: Fix an OF node refcount leakage in of_phy_provider_lookup()
  phy: core: Fix an OF node refcount leakage in _of_phy_get()
  phy: core: Fix that API devm_phy_destroy() fails to destroy the phy
  phy: core: Fix that API devm_of_phy_provider_unregister() fails to unregister the phy provider
  phy: core: Fix that API devm_phy_put() fails to release the phy
  phy: rockchip: samsung-hdptx: Set drvdata before enabling runtime PM
  phy: stm32: work around constant-value overflow assertion
  phy: qcom-qmp: Fix register name in RX Lane config of SC8280XP
  phy: rockchip: naneng-combphy: fix phy reset
  phy: usb: Toggle the PHY power during init
2024-12-26 10:39:57 -08:00
Linus Torvalds
ab8beb2047 chrome platform changes for 6.13-rc5
* Fixes
 
   - Fix wrong product names for early Framework Laptops.
 -----BEGIN PGP SIGNATURE-----
 
 iIkEABYIADEWIQS0yQeDP3cjLyifNRUrxTEGBto89AUCZ2tngRMcdHp1bmdiaUBr
 ZXJuZWwub3JnAAoJECvFMQYG2jz0Gm0BANRe42/WvkEN3VgSLGrPbw4ldqGGZmcC
 xBj9A8Pr/ik/AQCNA5q++YW5gN1iVuS3p5X0lUHQTisqRUMWQphwTy26Ag==
 =G2JQ
 -----END PGP SIGNATURE-----

Merge tag 'chrome-platform-for-6.13-rc5' of git://git.kernel.org/pub/scm/linux/kernel/git/chrome-platform/linux

Pull chrome platform fix from Tzung-Bi Shih:

 - Fix wrong product names for early Framework Laptops

* tag 'chrome-platform-for-6.13-rc5' of git://git.kernel.org/pub/scm/linux/kernel/git/chrome-platform/linux:
  platform/chrome: cros_ec_lpc: fix product identity for early Framework Laptops
2024-12-26 10:35:13 -08:00
Dustin L. Howett
dcd59d0d7d platform/chrome: cros_ec_lpc: fix product identity for early Framework Laptops
The product names for the Framework Laptop (12th and 13th Generation
Intel Core) are incorrect as of 62be134abf.

Fixes: 62be134abf ("platform/chrome: cros_ec_lpc: switch primary DMI data for Framework Laptop")
Cc: stable@vger.kernel.org # 6.12.x
Signed-off-by: Dustin L. Howett <dustin@howett.net>
Reviewed-by: Thomas Weißschuh <linux@weissschuh.net>
Link: https://lore.kernel.org/r/20241224-platform-chrome-cros_ec_lpc-fix-product-identity-for-early-framework-laptops-v1-1-0d31d6e1d22c@howett.net
Signed-off-by: Tzung-Bi Shih <tzungbi@kernel.org>
2024-12-25 01:47:35 +00:00
Linus Torvalds
9b2ffa6148 Four minor fixes for NAND controller drivers (cleanup path, double
actions, and W=1 warning) as well as a cast to avoid overflows in an mtd
 device driver.
 -----BEGIN PGP SIGNATURE-----
 
 iQEzBAABCAAdFiEE9HuaYnbmDhq/XIDIJWrqGEe9VoQFAmdq2NcACgkQJWrqGEe9
 VoSb7Qf9GxZ6/Eao4ziJD+N35en9TPd3XrQlI29JBfncX/+2eA2MyrJUo0PBLAkg
 M750h0JTRAa7qIMcgKN56wJ5BLSM25ob2y85HqBswBM44QlJb4bdAxTgj5w/uU26
 gYV2cOgzAnh7TwHtjovuaTAH12O+yEYr1fhtDEdPdYgJDSetK3MPBIHyFr7Cy4z/
 eXrEMpYRAU9Y1J/Af3UZFoZ79EhOaenZJ+VI2mtho+y+jgefGTYv7ABFl81pPVlW
 ezy7p5tF5esGzz8qELavT1J60jL15gDAVQ2VQ94flb7o7QN+nFjA+55xSriLCmKF
 co4S7r9KmysVykD3D3HsVTTfHXHDUg==
 =YZbm
 -----END PGP SIGNATURE-----

Merge tag 'mtd/fixes-for-6.13-rc5' of git://git.kernel.org/pub/scm/linux/kernel/git/mtd/linux

Pull mtd fixes from Miquel Raynal:
 "Four minor fixes for NAND controller drivers (cleanup path, double
  actions, and W=1 warning) as well as a cast to avoid overflows in an
  mtd device driver"

* tag 'mtd/fixes-for-6.13-rc5' of git://git.kernel.org/pub/scm/linux/kernel/git/mtd/linux:
  mtd: rawnand: omap2: Fix build warnings with W=1
  mtd: rawnand: arasan: Fix missing de-registration of NAND
  mtd: rawnand: arasan: Fix double assertion of chip-select
  mtd: diskonchip: Cast an operand to prevent potential overflow
  mtd: rawnand: fix double free in atmel_pmecc_create_user()
2024-12-24 09:08:45 -08:00
Arnd Bergmann
17194c2998 phy: mediatek: phy-mtk-hdmi: add regulator dependency
The driver no longer builds when regulator support is unavailable:

arm-linux-gnueabi-ld: drivers/phy/mediatek/phy-mtk-hdmi.o: in function `mtk_hdmi_phy_register_regulators':
phy-mtk-hdmi.c:(.text.unlikely+0x3e): undefined reference to `devm_regulator_register'
arm-linux-gnueabi-ld: drivers/phy/mediatek/phy-mtk-hdmi-mt8195.o: in function `mtk_hdmi_phy_pwr5v_is_enabled':
phy-mtk-hdmi-mt8195.c:(.text+0x326): undefined reference to `rdev_get_drvdata'
arm-linux-gnueabi-ld: drivers/phy/mediatek/phy-mtk-hdmi-mt8195.o: in function `mtk_hdmi_phy_pwr5v_disable':
phy-mtk-hdmi-mt8195.c:(.text+0x346): undefined reference to `rdev_get_drvdata'
arm-linux-gnueabi-ld: drivers/phy/mediatek/phy-mtk-hdmi-mt8195.o: in function `mtk_hdmi_phy_pwr5v_enable':

Fixes: 49393b2da1cd ("phy: mediatek: phy-mtk-hdmi: Register PHY provided regulator")
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Reviewed-by: AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com>
Link: https://lore.kernel.org/r/20241213083056.2596499-1-arnd@kernel.org
Signed-off-by: Vinod Koul <vkoul@kernel.org>
2024-12-24 20:38:53 +05:30
Adam Ford
739214dd1c phy: freescale: fsl-samsung-hdmi: Fix 64-by-32 division cocci warnings
The Kernel test robot returns the following warning:
 do_div() does a 64-by-32 division, please consider using div64_ul instead.

To prevent the 64-by-32 divsion, consolidate both the multiplication
and the do_div into one line which explicitly uses u64 sizes.

Fixes: 1951dbb41d ("phy: freescale: fsl-samsung-hdmi: Support dynamic integer")
Signed-off-by: Adam Ford <aford173@gmail.com>
Reported-by: kernel test robot <lkp@intel.com>
Closes: https://lore.kernel.org/oe-kbuild-all/202412091243.fSObwwPi-lkp@intel.com/

Link: https://lore.kernel.org/r/20241215220555.99113-1-aford173@gmail.com
Signed-off-by: Vinod Koul <vkoul@kernel.org>
2024-12-24 20:37:56 +05:30
Zijun Hu
a2d633cb14 phy: core: Fix an OF node refcount leakage in of_phy_provider_lookup()
For macro for_each_child_of_node(parent, child), refcount of @child has
been increased before entering its loop body, so normally needs to call
of_node_put(@child) before returning from the loop body to avoid refcount
leakage.

of_phy_provider_lookup() has such usage but does not call of_node_put()
before returning, so cause leakage of the OF node refcount.

Fix by simply calling of_node_put() before returning from the loop body.

The APIs affected by this issue are shown below since they indirectly
invoke problematic of_phy_provider_lookup().
phy_get()
of_phy_get()
devm_phy_get()
devm_of_phy_get()
devm_of_phy_get_by_index()

Fixes: 2a4c37016c ("phy: core: Fix of_phy_provider_lookup to return PHY provider for sub node")
Cc: stable@vger.kernel.org
Reviewed-by: Johan Hovold <johan+linaro@kernel.org>
Signed-off-by: Zijun Hu <quic_zijuhu@quicinc.com>
Link: https://lore.kernel.org/r/20241213-phy_core_fix-v6-5-40ae28f5015a@quicinc.com
Signed-off-by: Vinod Koul <vkoul@kernel.org>
2024-12-24 19:55:37 +05:30
Zijun Hu
5ebdc6be16 phy: core: Fix an OF node refcount leakage in _of_phy_get()
_of_phy_get() will directly return when suffers of_device_is_compatible()
error, but it forgets to decrease refcount of OF node @args.np before error
return, the refcount was increased by previous of_parse_phandle_with_args()
so causes the OF node's refcount leakage.

Fix by decreasing the refcount via of_node_put() before the error return.

Fixes: b7563e2796 ("phy: work around 'phys' references to usb-nop-xceiv devices")
Cc: stable@vger.kernel.org
Reviewed-by: Johan Hovold <johan+linaro@kernel.org>
Signed-off-by: Zijun Hu <quic_zijuhu@quicinc.com>
Link: https://lore.kernel.org/r/20241213-phy_core_fix-v6-4-40ae28f5015a@quicinc.com
Signed-off-by: Vinod Koul <vkoul@kernel.org>
2024-12-24 19:55:37 +05:30
Zijun Hu
4dc48c88fc phy: core: Fix that API devm_phy_destroy() fails to destroy the phy
For devm_phy_destroy(), its comment says it needs to invoke phy_destroy()
to destroy the phy, but it will not actually invoke the function since
devres_destroy() does not call devm_phy_consume(), and the missing
phy_destroy() call will cause that the phy fails to be destroyed.

Fortunately, the faulty API has not been used by current kernel tree.
Fix by using devres_release() instead of devres_destroy() within the API.

Fixes: ff76496347 ("drivers: phy: add generic PHY framework")
Reviewed-by: Johan Hovold <johan+linaro@kernel.org>
Signed-off-by: Zijun Hu <quic_zijuhu@quicinc.com>
Link: https://lore.kernel.org/r/20241213-phy_core_fix-v6-3-40ae28f5015a@quicinc.com
Signed-off-by: Vinod Koul <vkoul@kernel.org>
2024-12-24 19:55:37 +05:30
Zijun Hu
c0b82ab95b phy: core: Fix that API devm_of_phy_provider_unregister() fails to unregister the phy provider
For devm_of_phy_provider_unregister(), its comment says it needs to invoke
of_phy_provider_unregister() to unregister the phy provider, but it will
not actually invoke the function since devres_destroy() does not call
devm_phy_provider_release(), and the missing of_phy_provider_unregister()
call will cause:

- The phy provider fails to be unregistered.
- Leak both memory and the OF node refcount.

Fortunately, the faulty API has not been used by current kernel tree.
Fix by using devres_release() instead of devres_destroy() within the API.

Fixes: ff76496347 ("drivers: phy: add generic PHY framework")
Reviewed-by: Johan Hovold <johan+linaro@kernel.org>
Signed-off-by: Zijun Hu <quic_zijuhu@quicinc.com>
Link: https://lore.kernel.org/stable/20241213-phy_core_fix-v6-2-40ae28f5015a%40quicinc.com
Link: https://lore.kernel.org/r/20241213-phy_core_fix-v6-2-40ae28f5015a@quicinc.com
Signed-off-by: Vinod Koul <vkoul@kernel.org>
2024-12-24 19:55:37 +05:30
Zijun Hu
fe4bfa9b6d phy: core: Fix that API devm_phy_put() fails to release the phy
For devm_phy_put(), its comment says it needs to invoke phy_put() to
release the phy, but it will not actually invoke the function since
devres_destroy() does not call devm_phy_release(), and the missing
phy_put() call will cause:

- The phy fails to be released.
- devm_phy_put() can not fully undo what API devm_phy_get() does.
- Leak refcount of both the module and device for below typical usage:

  devm_phy_get(); // or its variant
  ...
  err = do_something();
  if (err)
      goto err_out;
  ...
  err_out:
  devm_phy_put(); // leak refcount here

  The file(s) affected by this issue are shown below since they have such
  typical usage.
  drivers/pci/controller/cadence/pcie-cadence.c
  drivers/net/ethernet/ti/am65-cpsw-nuss.c

Fix by using devres_release() instead of devres_destroy() within the API.

Fixes: ff76496347 ("drivers: phy: add generic PHY framework")
Cc: stable@vger.kernel.org
Cc: Lorenzo Pieralisi <lpieralisi@kernel.org>
Cc: Krzysztof Wilczyński <kw@linux.com>
Cc: Bjorn Helgaas <bhelgaas@google.com>
Cc: David S. Miller <davem@davemloft.net>
Cc: Eric Dumazet <edumazet@google.com>
Cc: Jakub Kicinski <kuba@kernel.org>
Cc: Paolo Abeni <pabeni@redhat.com>
Reviewed-by: Johan Hovold <johan+linaro@kernel.org>
Signed-off-by: Zijun Hu <quic_zijuhu@quicinc.com>
Link: https://lore.kernel.org/r/20241213-phy_core_fix-v6-1-40ae28f5015a@quicinc.com
Signed-off-by: Vinod Koul <vkoul@kernel.org>
2024-12-24 19:55:37 +05:30
Akhil R
ebc008699f dmaengine: tegra: Return correct DMA status when paused
Currently, the driver does not return the correct DMA status when a DMA
pause is issued by the client drivers. This causes GPCDMA users to
assume that DMA is still running, while in reality, the DMA is paused.

Return DMA_PAUSED for tx_status() if the channel is paused in the middle
of a transfer.

Fixes: ee17028009 ("dmaengine: tegra: Add tegra gpcdma driver")
Cc: stable@vger.kernel.org
Signed-off-by: Akhil R <akhilrajeev@nvidia.com>
Signed-off-by: Kartik Rajput <kkartik@nvidia.com>
Link: https://lore.kernel.org/r/20241212124412.5650-1-kkartik@nvidia.com
Signed-off-by: Vinod Koul <vkoul@kernel.org>
2024-12-24 15:49:30 +05:30
Javier Carrasco
362f1bf98a dmaengine: mv_xor: fix child node refcount handling in early exit
The for_each_child_of_node() loop requires explicit calls to
of_node_put() to decrement the child's refcount upon early exits (break,
goto, return).

Add the missing calls in the two early exits before the goto
instructions.

Cc: stable@vger.kernel.org
Fixes: f7d12ef53d ("dma: mv_xor: add Device Tree binding")
Signed-off-by: Javier Carrasco <javier.carrasco.cruz@gmail.com>
Link: https://lore.kernel.org/r/20241011-dma_mv_xor_of_node_put-v1-1-3c2de819f463@gmail.com
Signed-off-by: Vinod Koul <vkoul@kernel.org>
2024-12-24 15:45:01 +05:30
Joe Hattori
ccfa3131d4 dmaengine: fsl-edma: implement the cleanup path of fsl_edma3_attach_pd()
Current implementation of fsl_edma3_attach_pd() does not provide a
cleanup path, resulting in a memory leak. For example,
dev_pm_domain_detach() is not called after dev_pm_domain_attach_by_id(),
and the device link created with the DL_FLAG_STATELESS is not released
explicitly.

Therefore, provide a cleanup function fsl_edma3_detach_pd() and call it
upon failure. Also add a devm_add_action_or_reset() call with this
function after a successful fsl_edma3_attach_pd().

Fixes: 72f5801a4e ("dmaengine: fsl-edma: integrate v3 support")
Signed-off-by: Joe Hattori <joe@pf.is.s.u-tokyo.ac.jp>
Link: https://lore.kernel.org/r/20241221075712.3297200-1-joe@pf.is.s.u-tokyo.ac.jp
Signed-off-by: Vinod Koul <vkoul@kernel.org>
2024-12-24 14:55:57 +05:30
Linus Torvalds
ef49c460ab Modules fixes for v6.13-rc5
Luis asked me to look after the modules maintenance for a while, with the
 plan to rotate it with other recently added modules maintainers/reviewers.
 This is my first pull request to you.
 
 A single fix is present to correct the module vermagic for PREEMPT_RT.
 -----BEGIN PGP SIGNATURE-----
 
 iQFIBAABCAAyFiEEIduBR9MnFA82q/jtumpXJwqY6poFAmdpOt0UHHBldHIucGF2
 bHVAc3VzZS5jb20ACgkQumpXJwqY6pqQOwf/atyA9cyVCnp3ePjefjA0tJ2r59bh
 dEm47kjXZDwlMQ8nBBdT6nA7V0bZ0XF5ToHGwo5Uqgpj+MEilH1xz6KSw+V/uX0R
 YNtFQLN+eiiiNUMBR9R3IMmF+nNgcqEpgtCJDNpgiuCgmtlGr/yRwyqCEt4r9fzJ
 jHRjs6pqcpOzhn5fGrepQLOzVnsn7M0uzYMlkMdSWk2Y821wgJC3f/die9vCGIhg
 G3LdVOgMgKEKIwdZ1S9OYWrPFARiA4/SDX+3apN08FSAcnYi/bUalcjFkufYqkr6
 1q+DdsQJnoqOC4C//6MQzYCCGwQOF2VQQf2HB/GkicUpZjWU7Mk+5Entbg==
 =1BYy
 -----END PGP SIGNATURE-----

Merge tag 'modules-6.13-rc5' of git://git.kernel.org/pub/scm/linux/kernel/git/modules/linux

Pull modules fix from Petr Pavlu:
 "A single fix is present to correct the module vermagic for PREEMPT_RT"

* tag 'modules-6.13-rc5' of git://git.kernel.org/pub/scm/linux/kernel/git/modules/linux:
  preempt: Move PREEMPT_RT before PREEMPT in vermagic.
2024-12-23 13:06:48 -08:00
Linus Torvalds
f07044dd0d nfsd-6.13 fixes:
- Revert one v6.13 fix at the author's request
 - Fix a minor problem with recent NFSv4.2 COPY enhancements
 - Fix an NFSv4.0 callback bug introduced in the v6.13 merge window
 -----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCAAdFiEEKLLlsBKG3yQ88j7+M2qzM29mf5cFAmdpsPkACgkQM2qzM29m
 f5cddw//XUVunVAhTb6PYBNwiOxD0NpTpIjFPiwIZPnpWexQYBBaU9VKekcM//RR
 MSuvvbOYeqHtGUefVcs3NTONvtguNUn9fjvud+A7RFTr/a6QQjl34i4BWXKpqEFj
 WXxlpjBQmLotyxe13d/rqnAu9i13MOzCdOs7O7+Wt81Pk21HNrwlbXQQmyH/e8/p
 5FM2+pbj0W+XdRDkMAZZBM1cbczhDYqaf/8owmLtHs2vqbyHUDs/4AFVdQmySOV7
 FbdvrEo+7O5WCAAxeGxRgS2Ym5D/mll3FPoXziabG0UIxQG6uZVqReuOq8wybgTM
 e4RRa2+HgOi7/AZalvMsBU7Wg2xFyd6nIV5gT4adj/1N8ZeT2MI2IClahEp+DyFY
 uTapapERHXUzMhIl+OtNnHY4gJ/NEJUzCmhUATZVw2l6zBZaQBhu4a4PZvDNvI8g
 4TwS7SzDBVcOg+mzPtbtQxDjBUqsV1e+ROg1ouVWydJGDVSvoMRYzkS27M88DSNT
 SLHVpwbNPzEbXv9su3MOCAaf1Q26/qZMNMA7P1sYfCASA8IHrRuAOFrC6Mm7B64V
 TB7LOe4s6LIzDNU6ZNWXKwT3PxF/G+R5Y0VKqrfXop46DAPP3UlI7TRA8JuS9QGO
 r84QoC/63MTK9666DWyy3EIU7se19QQzo7GsluDXzmI/dwTsAew=
 =v4iF
 -----END PGP SIGNATURE-----

Merge tag 'nfsd-6.13-1' of git://git.kernel.org/pub/scm/linux/kernel/git/cel/linux

Pull nfsd fixes from Chuck Lever::

 - Revert one v6.13 fix at the author's request (to be done differently)

 - Fix a minor problem with recent NFSv4.2 COPY enhancements

 - Fix an NFSv4.0 callback bug introduced in the v6.13 merge window

* tag 'nfsd-6.13-1' of git://git.kernel.org/pub/scm/linux/kernel/git/cel/linux:
  nfsd: restore callback functionality for NFSv4.0
  NFSD: fix management of pending async copies
  nfsd: Revert "nfsd: release svc_expkey/svc_export with rcu_work"
2024-12-23 12:16:15 -08:00
Sebastian Andrzej Siewior
0b7a66a2c8 preempt: Move PREEMPT_RT before PREEMPT in vermagic.
Since the dynamic preemption has been enabled for PREEMPT_RT we have now
CONFIG_PREEMPT and CONFIG_PREEMPT_RT set simultaneously. This affects
the vermagic strings which comes now PREEMPT with PREEMPT_RT enabled.

The PREEMPT_RT module usually can not be loaded on a PREEMPT kernel
because some symbols are missing.
However if the symbols are fine then it continues and it crashes later.
The problem is that the struct module has a different layout and the
num_exentries or init members are at a different position leading to a
crash later on. This is not necessary caught by the size check in
elf_validity_cache_index_mod() because the mem member has an alignment
requirement of __module_memory_align which is big enough keep the total
size unchanged. Therefore we should keep the string accurate instead of
removing it.

Move the PREEMPT_RT check before the PREEMPT so that it takes precedence
if both symbols are enabled.

Fixes: 35772d627b ("sched: Enable PREEMPT_DYNAMIC for PREEMPT_RT")
Signed-off-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de>
Reviewed-by: Petr Pavlu <petr.pavlu@suse.com>
Link: https://lore.kernel.org/r/20241205160602.3lIAsJRT@linutronix.de
Signed-off-by: Petr Pavlu <petr.pavlu@suse.com>
2024-12-23 10:46:38 +01:00
Linus Torvalds
4bbf9020be Linux 6.13-rc4 2024-12-22 13:22:21 -08:00
Linus Torvalds
b1fdbe77be KVM x86 fixes for 6.13:
- Disable AVIC on SNP-enabled systems that don't allow writes to the virtual
   APIC page, as such hosts will hit unexpected RMP #PFs in the host when
   running VMs of any flavor.
 
 - Fix a WARN in the hypercall completion path due to KVM trying to determine
   if a guest with protected register state is in 64-bit mode (KVM's ABI is to
   assume such guests only make hypercalls in 64-bit mode).
 
 - Allow the guest to write to supported bits in MSR_AMD64_DE_CFG to fix a
   regression with Windows guests, and because KVM's read-only behavior appears
   to be entirely made up.
 
 - Treat TDP MMU faults as spurious if the faulting access is allowed given the
   existing SPTE.  This fixes a benign WARN (other than the WARN itself) due to
   unexpectedly replacing a writable SPTE with a read-only SPTE.
 
 - Emit a warning when KVM is configured with ignore_msrs=1 and also to hide the
   MSRs that the guest is looking for from the kernel logs.  ignore_msrs can
   trick guests into assuming that certain processor features are present, and
   this in turn leads to bogus bug reports.
 -----BEGIN PGP SIGNATURE-----
 
 iQFIBAABCAAyFiEE8TM4V0tmI4mGbHaCv/vSX3jHroMFAmdoSTgUHHBib256aW5p
 QHJlZGhhdC5jb20ACgkQv/vSX3jHroM+IggAndK6byvsGjU0lM5v4WhKMnD7KZXi
 PsXuzv7LQUtbOaosowbBDUfMkZXwewmgUjBWmJL8WFlVePk7+8Aj29Zwd4vH3cHI
 KZ/AeyC6VwH1CFLZMSoHgG2dCl8hUUkUldZLAdYKigTRMlw5FmnmIfhqx/mpxiMz
 xHs9TU+NZpaQVXSzq9P1AXkJX+zZvyYlGXrTRtJ541AwYPWsq1MBr1megtBi59ws
 zEgCOyBpDHWQEasbtwHjPNNH+rCi8SEq2QCrSGHpTXWLS9kXj32wLldWb6E3L5ta
 c1/Q9mQDpVXQNidnAWyhukVmbETQDkpB+j9Mfd+bwIy1+zh6iSEe9dWM9g==
 =/fW+
 -----END PGP SIGNATURE-----

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

Pull KVM x86 fixes from Paolo Bonzini:

 - Disable AVIC on SNP-enabled systems that don't allow writes to the
   virtual APIC page, as such hosts will hit unexpected RMP #PFs in the
   host when running VMs of any flavor.

 - Fix a WARN in the hypercall completion path due to KVM trying to
   determine if a guest with protected register state is in 64-bit mode
   (KVM's ABI is to assume such guests only make hypercalls in 64-bit
   mode).

 - Allow the guest to write to supported bits in MSR_AMD64_DE_CFG to fix
   a regression with Windows guests, and because KVM's read-only
   behavior appears to be entirely made up.

 - Treat TDP MMU faults as spurious if the faulting access is allowed
   given the existing SPTE. This fixes a benign WARN (other than the
   WARN itself) due to unexpectedly replacing a writable SPTE with a
   read-only SPTE.

 - Emit a warning when KVM is configured with ignore_msrs=1 and also to
   hide the MSRs that the guest is looking for from the kernel logs.
   ignore_msrs can trick guests into assuming that certain processor
   features are present, and this in turn leads to bogus bug reports.

* tag 'for-linus' of git://git.kernel.org/pub/scm/virt/kvm/kvm:
  KVM: x86: let it be known that ignore_msrs is a bad idea
  KVM: VMX: don't include '<linux/find.h>' directly
  KVM: x86/mmu: Treat TDP MMU faults as spurious if access is already allowed
  KVM: SVM: Allow guest writes to set MSR_AMD64_DE_CFG bits
  KVM: x86: Play nice with protected guests in complete_hypercall_exit()
  KVM: SVM: Disable AVIC on SNP-enabled system without HvInUseWrAllowed feature
2024-12-22 12:16:41 -08:00
Paolo Bonzini
8afa5b10af KVM x86 fixes for 6.13:
- Disable AVIC on SNP-enabled systems that don't allow writes to the virtual
    APIC page, as such hosts will hit unexpected RMP #PFs in the host when
    running VMs of any flavor.
 
  - Fix a WARN in the hypercall completion path due to KVM trying to determine
    if a guest with protected register state is in 64-bit mode (KVM's ABI is to
    assume such guests only make hypercalls in 64-bit mode).
 
  - Allow the guest to write to supported bits in MSR_AMD64_DE_CFG to fix a
    regression with Windows guests, and because KVM's read-only behavior appears
    to be entirely made up.
 
  - Treat TDP MMU faults as spurious if the faulting access is allowed given the
    existing SPTE.  This fixes a benign WARN (other than the WARN itself) due to
    unexpectedly replacing a writable SPTE with a read-only SPTE.
 -----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCgAdFiEEKTobbabEP7vbhhN9OlYIJqCjN/0FAmdkzW0ACgkQOlYIJqCj
 N/3VXhAAjfP7w4TdJGX0yOPUmQWXATq6DC+zKW1K3dhfu9QwVXD6TLykdnQddiUg
 k0yOgIpwzIEj1U6l1DamjQj2QdoBqeTjTg8jBujiQTsQH/Gc7FvbcFy70ZKZS/js
 IQ+g+1av8XXnLVb5xtVMRWwEtca2BeygSVjRA8/QtIWog0rProfS35/wd3uq04Hm
 Z4J6hf8N2DSELUrq0uIHvTFr8/a03oQnaNNrPyRmbvBb8m20no3A/ws6tAB4YfyN
 HxQao+CJrSQ+4dinZSGa2s6TLBIbbH5QRtwgeSpbLdeKnRYyrWtThIrKB2uDKKYn
 1fsn9mdIi3oAzl3mX2JLQNlx18tCOSrnmYIJCzBAQDaeUOlMNYge4CYeKOqYMJyo
 vayNFz9VZwDiUcBLMWy81EyVcKlqQE8U2icgKqEN8jVdmKW36bOcAfFiK/97iPrc
 7TkS4azHozoTAHdggWqReraDnjRz4PysjIA/yaMh2G/p1ZexL6OX+GwgF1YrD4w3
 zVL8UmXkjiPi+VS6ayUiYDYB5R1kJ13Zq3UpYOJ2MG6Zg2we+UXynQkehS/BHwkp
 2aiflhq55cVv6oZoNJeOuokyvXRAuXf8t0Got/rqGzjKGGNLPRCxD/7K1PzN1YsZ
 NH5zmS2GsqA89L+Qc2l0Ohuz4kX1S2BEB+1pnxFkQc+CdjmIG9A=
 =S9jc
 -----END PGP SIGNATURE-----

Merge tag 'kvm-x86-fixes-6.13-rcN' of https://github.com/kvm-x86/linux into HEAD

KVM x86 fixes for 6.13:

 - Disable AVIC on SNP-enabled systems that don't allow writes to the virtual
   APIC page, as such hosts will hit unexpected RMP #PFs in the host when
   running VMs of any flavor.

 - Fix a WARN in the hypercall completion path due to KVM trying to determine
   if a guest with protected register state is in 64-bit mode (KVM's ABI is to
   assume such guests only make hypercalls in 64-bit mode).

 - Allow the guest to write to supported bits in MSR_AMD64_DE_CFG to fix a
   regression with Windows guests, and because KVM's read-only behavior appears
   to be entirely made up.

 - Treat TDP MMU faults as spurious if the faulting access is allowed given the
   existing SPTE.  This fixes a benign WARN (other than the WARN itself) due to
   unexpectedly replacing a writable SPTE with a read-only SPTE.
2024-12-22 12:07:16 -05:00
Paolo Bonzini
398b7b6cb9 KVM: x86: let it be known that ignore_msrs is a bad idea
When running KVM with ignore_msrs=1 and report_ignored_msrs=0, the user has
no clue that that the guest is being lied to.  This may cause bug reports
such as https://gitlab.com/qemu-project/qemu/-/issues/2571, where enabling
a CPUID bit in QEMU caused Linux guests to try reading MSR_CU_DEF_ERR; and
being lied about the existence of MSR_CU_DEF_ERR caused the guest to assume
other things about the local APIC which were not true:

  Sep 14 12:02:53 kernel: mce: [Firmware Bug]: Your BIOS is not setting up LVT offset 0x2 for deferred error IRQs correctly.
  Sep 14 12:02:53 kernel: unchecked MSR access error: RDMSR from 0x852 at rIP: 0xffffffffb548ffa7 (native_read_msr+0x7/0x40)
  Sep 14 12:02:53 kernel: Call Trace:
  ...
  Sep 14 12:02:53 kernel:  native_apic_msr_read+0x20/0x30
  Sep 14 12:02:53 kernel:  setup_APIC_eilvt+0x47/0x110
  Sep 14 12:02:53 kernel:  mce_amd_feature_init+0x485/0x4e0
  ...
  Sep 14 12:02:53 kernel: [Firmware Bug]: cpu 0, try to use APIC520 (LVT offset 2) for vector 0xf4, but the register is already in use for vector 0x0 on this cpu

Without reported_ignored_msrs=0 at least the host kernel log will contain
enough information to avoid going on a wild goose chase.  But if reports
about individual MSR accesses are being silenced too, at least complain
loudly the first time a VM is started.

Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2024-12-22 12:06:01 -05:00
Wolfram Sang
37d1d99b88 KVM: VMX: don't include '<linux/find.h>' directly
The header clearly states that it does not want to be included directly,
only via '<linux/bitmap.h>'. Replace the include accordingly.

Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com>
Message-ID: <20241217070539.2433-2-wsa+renesas@sang-engineering.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2024-12-22 12:04:57 -05:00
Linus Torvalds
bcde95ce32 Devicetree fixes for 6.13, part 1:
- Disable #address-cells/#size-cells warning on coreboot (Chromebooks)
   platforms
 
 - Add missing root #address-cells/#size-cells in default empty DT
 
 - Fix uninitialized variable in of_irq_parse_one()
 
 - Fix interrupt-map cell length check in of_irq_parse_imap_parent()
 
 - Fix refcount handling in __of_get_dma_parent()
 
 - Fix error path in of_parse_phandle_with_args_map()
 
 - Fix dma-ranges handling with flags cells
 
 - Drop explicit fw_devlink handling of 'interrupt-parent'
 
 - Fix "compression" typo in fixed-partitions binding
 
 - Unify "fsl,liodn" property type definitions
 -----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCgAdFiEEktVUI4SxYhzZyEuo+vtdtY28YcMFAmdoKtIACgkQ+vtdtY28
 YcPM9w//foQifBxhfhjGFOZT/nZhlQu2EJT4eJ02hmFSDyvSBHTTdWELcjOKaGO7
 QDex/Pw8gv1x0XMywaAOcCcZlQKUd0R9KjC+bWi+lC+f1MGyj5Pd1O2/jtZLJbuB
 BwGm/h4rxzM0nNDhD+mQwC/pZId0+ATA9kV4iR4RexWTxWdeYV8KDc7zA1pxi/aI
 PpKEQ6aapXCNjwYGANzs3ylA5AUHijQHOs9L64ACPAIJTN5ZOZvB1mZ33vp4NHl6
 yNdNnZ8xZl8vecTM3rYTX9/yDRU18ME4gE72Hz5PfJ7aO7Xy8ebc4JCFTP8Iefwl
 ivVYsFFKIvqKArE0NRDxqYYmOpBob8id7nDuAZ2wmx0LLNgM/bkrk1ysuUwoMeQd
 aP/sGZ3+roKLDpBBTnOmTw89YWYkaLFXVwU4TbN7UIzqSYX5onGzSagN3fEnmHQu
 Q6hehVa9M758hwxiVK4S4z79RKTVwq8u1BLMe/s765xDKpvJGVwH4QlV+MfKLcn9
 jbG2hT/mYwAQebmNqVWI7dAb8dt7zXijebuJCGPMW4RquBNGi+59MRAd4HrkJ2i4
 DABbp3A5OqlyN05ilpB89w+GsPCgDL179mTy0MxRGY4O6GIqKdcBGjzqPHPW6UQf
 o9zdnw5ZnP9YicApGLwGgMpdoUS7voWyyrHGw+4i9oiOKLldVww=
 =CFJI
 -----END PGP SIGNATURE-----

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

Pull devicetree fixes from Rob Herring:

 - Disable #address-cells/#size-cells warning on coreboot (Chromebooks)
   platforms

 - Add missing root #address-cells/#size-cells in default empty DT

 - Fix uninitialized variable in of_irq_parse_one()

 - Fix interrupt-map cell length check in of_irq_parse_imap_parent()

 - Fix refcount handling in __of_get_dma_parent()

 - Fix error path in of_parse_phandle_with_args_map()

 - Fix dma-ranges handling with flags cells

 - Drop explicit fw_devlink handling of 'interrupt-parent'

 - Fix "compression" typo in fixed-partitions binding

 - Unify "fsl,liodn" property type definitions

* tag 'devicetree-fixes-for-6.13-1' of git://git.kernel.org/pub/scm/linux/kernel/git/robh/linux:
  of: Add coreboot firmware to excluded default cells list
  of/irq: Fix using uninitialized variable @addr_len in API of_irq_parse_one()
  of/irq: Fix interrupt-map cell length check in of_irq_parse_imap_parent()
  of: Fix refcount leakage for OF node returned by __of_get_dma_parent()
  of: Fix error path in of_parse_phandle_with_args_map()
  dt-bindings: mtd: fixed-partitions: Fix "compression" typo
  of: Add #address-cells/#size-cells in the device-tree root empty node
  dt-bindings: Unify "fsl,liodn" type definitions
  of: address: Preserve the flags portion on 1:1 dma-ranges mapping
  of/unittest: Add empty dma-ranges address translation tests
  of: property: fw_devlink: Do not use interrupt-parent directly
2024-12-22 08:40:23 -08:00
Linus Torvalds
48f506ad0b soc: fixes for 6.13, part 2
Two more small fixes, correcting the cacheline size on Raspberry Pi 5
 and fixing a logic mistake in the microchip mpfs firmware driver.
 -----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCgAdFiEEiK/NIGsWEZVxh/FrYKtH/8kJUicFAmdnPmkACgkQYKtH/8kJ
 UicYsw//V/P84VpktPuSbZ4Uy41ns35DNmkSmZRGl5qTjTND6yjdl1ZkngzhHfC5
 7yrq6OcHseErfUsv4OKpRYtsmSEl/hJcVKQTKP3m9qZ+TCpym0bmQc+pbnbNtwXI
 1Um9Y5QL0yKw60elNW4ysJ+vUGlgMBIQG0gtz4aNu0BeLR2pEbs+WsodTm0z5Z8j
 AptHtB2Z1+ODM+uxJ44sVEd+uyC8cc3u8yWgMKNXVTPbI9xGm7IOoXb95rJGyFid
 WLgyU7ZDvPOMUwwbsp87bY0PUP8fQpMrxqnz51/TbzJiMs1U6Ikmg4imIPjAemh0
 yb+8sH8M1mY8nV4efP/W5BEftGo1fc1yrzlEkb0Bgds10Ys4ra2JI/s5QJ7VOAY9
 pZ/ajSiGjQ9elvd/es4KKbKwDnlccw77TaauKEkTyD6ZVmNZR7/s8IZ2/Zy//k3A
 2bXP07GSgSH7Z5FUB3ExlDWRGoqjmzF9z8D7x3/MTL1pmWImXfDcclzAA5lj9yhM
 /LkploVbEcZ5ArV7oISu7GUfrxsxLNgobzEVUt2iRylw18YZJFFcvTlez5R0n4Zg
 fMiVW+fhpun5FJkGDL3B/BU2c+RUkL0RiIwElnUOBRXIrRyI4XjCTbw9vnPKZxHk
 XQkV+OZzlogq3TdtHqJ94Nwt3UKzSSMF4aAVOvcAzusHjMnyBdk=
 =UZKA
 -----END PGP SIGNATURE-----

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

Pull SoC fixes from Arnd Bergmann:
 "Two more small fixes, correcting the cacheline size on Raspberry Pi 5
  and fixing a logic mistake in the microchip mpfs firmware driver"

* tag 'soc-fixes-6.13-2' of git://git.kernel.org/pub/scm/linux/kernel/git/soc/soc:
  arm64: dts: broadcom: Fix L2 linesize for Raspberry Pi 5
  firmware: microchip: fix UL_IAP lock check in mpfs_auto_update_state()
2024-12-21 15:45:06 -08:00
Linus Torvalds
4aa748dd1a 25 hotfixes. 16 are cc:stable. 19 are MM and 6 are non-MM.
The usual bunch of singletons and doubletons - please see the relevant
 changelogs for details.
 -----BEGIN PGP SIGNATURE-----
 
 iHUEABYKAB0WIQTTMBEPP41GrTpTJgfdBJ7gKXxAjgUCZ2cghQAKCRDdBJ7gKXxA
 jgrsAQCvlSmHYYLXBE1A6cram4qWgEP/2vD94d6sVv9UipO/FAEA8y1K7dbT2AGX
 A5ESuRndu5Iy76mb6Tiarqa/yt56QgU=
 =ZYVx
 -----END PGP SIGNATURE-----

Merge tag 'mm-hotfixes-stable-2024-12-21-12-09' of git://git.kernel.org/pub/scm/linux/kernel/git/akpm/mm

Pull misc fixes from Andrew Morton:
 "25 hotfixes.  16 are cc:stable.  19 are MM and 6 are non-MM.

  The usual bunch of singletons and doubletons - please see the relevant
  changelogs for details"

* tag 'mm-hotfixes-stable-2024-12-21-12-09' of git://git.kernel.org/pub/scm/linux/kernel/git/akpm/mm: (25 commits)
  mm: huge_memory: handle strsep not finding delimiter
  alloc_tag: fix set_codetag_empty() when !CONFIG_MEM_ALLOC_PROFILING_DEBUG
  alloc_tag: fix module allocation tags populated area calculation
  mm/codetag: clear tags before swap
  mm/vmstat: fix a W=1 clang compiler warning
  mm: convert partially_mapped set/clear operations to be atomic
  nilfs2: fix buffer head leaks in calls to truncate_inode_pages()
  vmalloc: fix accounting with i915
  mm/page_alloc: don't call pfn_to_page() on possibly non-existent PFN in split_large_buddy()
  fork: avoid inappropriate uprobe access to invalid mm
  nilfs2: prevent use of deleted inode
  zram: fix uninitialized ZRAM not releasing backing device
  zram: refuse to use zero sized block device as backing device
  mm: use clear_user_(high)page() for arch with special user folio handling
  mm: introduce cpu_icache_is_aliasing() across all architectures
  mm: add RCU annotation to pte_offset_map(_lock)
  mm: correctly reference merged VMA
  mm: use aligned address in copy_user_gigantic_page()
  mm: use aligned address in clear_gigantic_page()
  mm: shmem: fix ShmemHugePages at swapout
  ...
2024-12-21 15:31:56 -08:00
Steven Rostedt
e84a3bf7f4 staging: gpib: Fix allyesconfig build failures
My tests run an allyesconfig build and it failed with the following errors:

    LD [M]  samples/kfifo/dma-example.ko
  ld.lld: error: undefined symbol: nec7210_board_reset
  ld.lld: error: undefined symbol: nec7210_read
  ld.lld: error: undefined symbol: nec7210_write

It appears that some modules call the function nec7210_board_reset()
that is defined in nec7210.c.  In an allyesconfig build, these other
modules are built in.  But the file that holds nec7210_board_reset()
has:

  obj-m += nec7210.o

Where that "-m" means it only gets built as a module. With the other
modules built in, they have no access to nec7210_board_reset() and the build
fails.

This isn't the only function. After fixing that one, I hit another:

  ld.lld: error: undefined symbol: push_gpib_event
  ld.lld: error: undefined symbol: gpib_match_device_path

Where push_gpib_event() was also used outside of the file it was defined
in, and that file too only was built as a module.

Since the directory that nec7210.c is only traversed when
CONFIG_GPIB_NEC7210 is set, and the directory with gpib_common.c is only
traversed when CONFIG_GPIB_COMMON is set, use those configs as the
option to build those modules.  When it is an allyesconfig, then they
will both be built in and their functions will be available to the other
modules that are also built in.

Fixes: 3ba84ac69b ("staging: gpib: Add nec7210 GPIB chip driver")
Fixes: 9dde4559e9 ("staging: gpib: Add GPIB common core driver")
Signed-off-by: Steven Rostedt (Google) <rostedt@goodmis.org>
Reviewed-by: Palmer Dabbelt <palmer@rivosinc.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2024-12-21 11:30:13 -08:00
Linus Torvalds
a016546ba6 Kbuild fixes for v6.13 (2nd)
- Remove stale code in usr/include/headers_check.pl
 
  - Fix issues in the user-mode-linux Debian package
 
  - Fix false-positive "export twice" errors in modpost
 -----BEGIN PGP SIGNATURE-----
 
 iQJJBAABCgAzFiEEbmPs18K1szRHjPqEPYsBB53g2wYFAmdmyq4VHG1hc2FoaXJv
 eUBrZXJuZWwub3JnAAoJED2LAQed4NsGbEcQAJGVUhg9pWwCVmmj69B+Sj1sOM21
 CJP+0B3sEQCzMICkG84h2NwOdGCRcF7AkGVPOfiVAzGbC7B1+iuSgyTb7RLOouhr
 Z69PqwsMluG8pQRkAI76MVrL/N8695x6r50xc1xR9J9MgIEL0+7QBLRHF+IFlpZl
 75/EuvzxzMsAa11io7T5krcn7IpuRuLV1LgNicPG5fuEM7DNZqzufZDOzbAQaNO3
 wrLvRSfJ6cmKq6I3hNImN39H1ccDvZJcIKu4bSpITG9wmYpYt69lhKG19qpdT0s9
 hVIgXnU0hEtdLMCNlH6Tp6R+iytiQ7EQ6B8F3Xr0bpmwBZIvBwresXfCZzbZHoIy
 ioOG0g8lFgDqNWnAH7+QvGjZ7Cn1lexaQNtt+ullx+g+jCMytyFWN6dw+XPJxorY
 HK1oE91geFtpc4emQFn/xo47NqX1LshNPiMMWuJdZwXFdIpbkhkECFf/QRfDWkmr
 jsOqmOJZpxHNwOq4VQuqxhBr5LYy6WVTX43anTL95SRO+ArqDy1nym4LO3Oh0FSp
 WRnuJ5kcdRrYKdji/xCZ8CafLaDmGbRKg1stXukS7jWAJALBKvndafr7X6BKLmD9
 j5UU2tBi24HDTnDjiQTP7/ElUrkecOkis6dHzqvtfJDlcFTPNLnHuBfqdjit2U9j
 8keM+ZF0ys0DHIvb
 =X4LY
 -----END PGP SIGNATURE-----

Merge tag 'kbuild-fixes-v6.13-2' of git://git.kernel.org/pub/scm/linux/kernel/git/masahiroy/linux-kbuild

Pull Kbuild fixes from Masahiro Yamada:

 - Remove stale code in usr/include/headers_check.pl

 - Fix issues in the user-mode-linux Debian package

 - Fix false-positive "export twice" errors in modpost

* tag 'kbuild-fixes-v6.13-2' of git://git.kernel.org/pub/scm/linux/kernel/git/masahiroy/linux-kbuild:
  modpost: distinguish same module paths from different dump files
  kbuild: deb-pkg: Do not install maint scripts for arch 'um'
  kbuild: deb-pkg: add debarch for ARCH=um
  kbuild: Drop support for include/asm-<arch> in headers_check.pl
2024-12-21 11:24:32 -08:00
Linus Torvalds
9c707ba99f BPF fixes:
- Fix inlining of bpf_get_smp_processor_id helper for !CONFIG_SMP
   systems (Andrea Righi)
 
 - Fix BPF USDT selftests helper code to use asm constraint "m"
   for LoongArch (Tiezhu Yang)
 
 - Fix BPF selftest compilation error in get_uprobe_offset when
   PROCMAP_QUERY is not defined (Jerome Marchand)
 
 - Fix BPF bpf_skb_change_tail helper when used in context of
   BPF sockmap to handle negative skb header offsets (Cong Wang)
 
 - Several fixes to BPF sockmap code, among others, in the area
   of socket buffer accounting (Levi Zim, Zijian Zhang, Cong Wang)
 
 Signed-off-by: Daniel Borkmann <daniel@iogearbox.net>
 -----BEGIN PGP SIGNATURE-----
 
 iIsEABYKADMWIQTFp0I1jqZrAX+hPRXbK58LschIgwUCZ2YJABUcZGFuaWVsQGlv
 Z2VhcmJveC5uZXQACgkQ2yufC7HISINDEgD+N4uVg+rp8Z8pg9jcai4WUERmRG20
 NcQTfBXczLHkwIcBALvn7NVvbTAINJzBTnukbjX3XbWFz2cJ/xHxDYXycP4I
 =SwXG
 -----END PGP SIGNATURE-----

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

Pull BPF fixes from Daniel Borkmann:

 - Fix inlining of bpf_get_smp_processor_id helper for !CONFIG_SMP
   systems (Andrea Righi)

 - Fix BPF USDT selftests helper code to use asm constraint "m" for
   LoongArch (Tiezhu Yang)

 - Fix BPF selftest compilation error in get_uprobe_offset when
   PROCMAP_QUERY is not defined (Jerome Marchand)

 - Fix BPF bpf_skb_change_tail helper when used in context of BPF
   sockmap to handle negative skb header offsets (Cong Wang)

 - Several fixes to BPF sockmap code, among others, in the area of
   socket buffer accounting (Levi Zim, Zijian Zhang, Cong Wang)

* tag 'bpf-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf:
  selftests/bpf: Test bpf_skb_change_tail() in TC ingress
  selftests/bpf: Introduce socket_helpers.h for TC tests
  selftests/bpf: Add a BPF selftest for bpf_skb_change_tail()
  bpf: Check negative offsets in __bpf_skb_min_len()
  tcp_bpf: Fix copied value in tcp_bpf_sendmsg
  skmsg: Return copied bytes in sk_msg_memcopy_from_iter
  tcp_bpf: Add sk_rmem_alloc related logic for tcp_bpf ingress redirection
  tcp_bpf: Charge receive socket buffer in bpf_tcp_ingress()
  selftests/bpf: Fix compilation error in get_uprobe_offset()
  selftests/bpf: Use asm constraint "m" for LoongArch
  bpf: Fix bpf_get_smp_processor_id() on !CONFIG_SMP
2024-12-21 11:07:19 -08:00
Linus Torvalds
876685ce5e [GIT PULL for 6.13-rc4] media fixes
-----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCAAdFiEE+QmuaPwR3wnBdVwACF8+vY7k4RUFAmdmpZwACgkQCF8+vY7k
 4RUxow//XnmsqrDDXfuRrY0wRoz+fnglulwnwiKWCEN8T9Zwa02NNPeSjvc9f3U4
 Dj3fSw1AVu1s0Z92286XPe+UMX1Pqlx/5rLWPiGu3IQ7570dj4RFfxQPGmtu9lGd
 BUU8p5Loo3rtS9rq/0RZmoioenEujp8Q16GNZO9W+m8rMmmV1xmiSj1jPh9mpMFu
 3Qb6sarablsnEckdz5zdAzKsY8eZCtc/iBKmttVwHOu4xs7PUz/u3p5bC4hdO3sH
 CiBUL0Tmxj73Bm+ZLJeijlcc9mUe/notOJrofOOmmBdcNMt8yM4MflF2vGfkQrBC
 mikIS0HxzPzO5m83l16ylPWBcvELjIXzOsJPSjTUNBYEmUDVtmlNTynOnBNLiu0c
 BGJxNQS4gxTPS+uh9yhmrFhKDbMTrULMEJ6s8Nw9uB1lJKGkAyxJFuAbIIvVfK3q
 rEYGbE4DPWXbj+x5Z5JwqdMJ75rkiY24JNlPy2VlsIUUmZ/9tVNdyAR5cBJXk99g
 n1wFn7WKoJ2PpaQPrqmvnrN49qQ2zEVRVablDqr+iZBkPXEKh+fUICq7Jxm7LfMR
 +pP3G4b18sdi5elC1ol6Lp2Wke7YBL8bIhZpFznDlin9qEqTMsLaTFkXzPgrw/qZ
 iRJkZ5nPm/Slmx+wF8gPNbpiUnvVY7OeoQ42NQ+rC23NLp8iA4M=
 =C3l4
 -----END PGP SIGNATURE-----

Merge tag 'media/v6.13-3' of git://git.kernel.org/pub/scm/linux/kernel/git/mchehab/linux-media

Pull media fixes from Mauro Carvalho Chehab:

 - fix a clang build issue with mediatec vcodec

 - add missing variable initialization to dib3000mb write function

* tag 'media/v6.13-3' of git://git.kernel.org/pub/scm/linux/kernel/git/mchehab/linux-media:
  media: mediatek: vcodec: mark vdec_vp9_slice_map_counts_eob_coef noinline
  media: dvb-frontends: dib3000mb: fix uninit-value in dib3000_write_reg
2024-12-21 10:56:34 -08:00
Linus Torvalds
a99b4a369a PCI fixes for Linux 6.13
-----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCAAdFiEEEtJ9XYyOm/GqvHx8fGR2jT3jNOcFAmdmsgwACgkQfGR2jT3j
 NOcr7A//RB1SINcsO4gaw+hU5GypC2/P0LOsuufV0+6pGA3iN9XIafbiw8NeSENf
 7kH8IQYkdtkhRs7mPoSTzGhsupMuqbHJ4TjVVztJzGTl6KRo8O1WAF4XQN9jd+Mg
 aomkA4KuT3Ss4yzl549hJ7RNzkhot7O3y1xRA9P3PtdvvFSyTboB7hYmjP9DLQ8F
 EuWXIds2JfZrid6Ru01gSvuI+vFt8ZDw+F6fJCITQQvHzaUzy3GcQtl6MoKQklMc
 PtuNoZYaiLyjROb51cS1M4B631JI4bbQ8j5hELYidNDdcdXBHpeW7RMuDhlkeNSK
 MTt7Zu7kd2UsBuSpu0v7i9u79QTTgMn0te5i0gpfZW9T+YlU7gLp0XF1gajecvGz
 QY8xJnTOy8JEv15bx+P5mHKGmKYQCbo4zFMWaKgIlS6ge4i3ZXjX2C2n2GpS7bg6
 8zJ9lXbRUXbBeKf8XSJ0cehtgBIROZBLSrVF8WRLI0uHyVhLqMF7iSJ5FrbVz1u2
 34BTLYKuewU7T5gvl+BSfhF7CERUrRqVwPYiHiziJyD+R57dA7YCAAcZCAB/ChlB
 4pIDrTHidcHuFCknT9WS7ZJOzcle63ci/vQ0gs09ZLCNEcU5Ttj0klbm3tsYD0WX
 G2wxLHsC7+j0ycE739yWTdneMb9uKycm+/RkBdBKBJdCGXWdlSA=
 =zLos
 -----END PGP SIGNATURE-----

Merge tag 'pci-v6.13-fixes-2' of git://git.kernel.org/pub/scm/linux/kernel/git/pci/pci

Pull PCI fixes from Krzysztof Wilczyński:
 "Two small patches that are important for fixing boot time hang on
  Intel JHL7540 'Titan Ridge' platforms equipped with a Thunderbolt
  controller.

  The boot time issue manifests itself when a PCI Express bandwidth
  control is unnecessarily enabled on the Thunderbolt controller
  downstream ports, which only supports a link speed of 2.5 GT/s in
  accordance with USB4 v2 specification (p. 671, sec. 11.2.1, "PCIe
  Physical Layer Logical Sub-block").

  As such, there is no need to enable bandwidth control on such
  downstream port links, which also works around the issue.

  Both patches were tested by the original reporter on the hardware on
  which the failure origin golly manifested itself. Both fixes were
  proven to resolve the reported boot hang issue, and both patches have
  been in linux-next this week with no reported problems"

* tag 'pci-v6.13-fixes-2' of git://git.kernel.org/pub/scm/linux/kernel/git/pci/pci:
  PCI/bwctrl: Enable only if more than one speed is supported
  PCI: Honor Max Link Speed when determining supported speeds
2024-12-21 10:51:04 -08:00
Linus Torvalds
78b1346123 Power management fixes for 6.13-rc4
- Detect preferred core support in amd-pstate  before driver
    registration to avoid initialization ordering issues (K Prateek
    Nayak).
 
  - Fix issues with with boost numerator handling in amd-pstate leading
    to inconsistently programmed CPPC max performance values (Mario
    Limonciello).
 -----BEGIN PGP SIGNATURE-----
 
 iQJGBAABCAAwFiEE4fcc61cGeeHD/fCwgsRv/nhiVHEFAmdl1RMSHHJqd0Byand5
 c29ja2kubmV0AAoJEILEb/54YlRxapEQAKlXuqhjYEl2x1RuGuHO81YEMjoDIBHQ
 1Mhfzidz+QZgLj3cJXdSDinz/JFeSyMmObKKp3VTtysIsxf1N0OohpOW6jVr5GX5
 PzOe15bWwCO12hriAEH4TcImejzJaTv9l/GjeI+GtvA2sFB3TqnuwcKVUUciZ/tf
 pVV+oPsi1XjFVbjpwATu0BHNd+oOMgsVBDE6/A2NiRGz/4pHbfPCn1+V4CfMvgHv
 Zh7g0s+kLAikxf4iT6ExFyXM3H6lUsUBeBLkXrCzG0rsFE681Slrm6R+eKfqrQHS
 0ijJyZyumol4JnAZ0Sn/VxWQ3/A++EbELJrft2+ZK99NiuBhasucHBuHSQL9kF4D
 PpZxSTA+aEAY4EwolhSqgvl9Yz5RPOa/tKWwinfMErKgA9bt4ibnHr3dQSILqu10
 dO5TRdM0VIRUh+6lVxqsNRRib5BZlZJjp05/RZiH79DWS1saPiSkQBO0elLkscsk
 zwOHi/XAq+DbwsriWpSMGFX07CNZXdDih9oVYqsLsr7tOl4hMpCZSUs1613PL66j
 kih8YqBykgdSH8YAKP9StZeu32pjDHRwQfuPTC5wN6rNU5n11botO+SnGILRZSP3
 27lpkCeMAnvdNpRvj2PsohDywlMnD4XzzN+5vxGncPRAKGwTg8bXRgiRjr5SHJR7
 +gmHVhvrpdMA
 =Blf/
 -----END PGP SIGNATURE-----

Merge tag 'pm-6.13-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm

Pull power management fixes from Rafael Wysocki:
 "These fix some amd-pstate driver issues:

   - Detect preferred core support in amd-pstate before driver
     registration to avoid initialization ordering issues (K Prateek
     Nayak)

   - Fix issues with with boost numerator handling in amd-pstate leading
     to inconsistently programmed CPPC max performance values (Mario
     Limonciello)"

* tag 'pm-6.13-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm:
  cpufreq/amd-pstate: Use boost numerator for upper bound of frequencies
  cpufreq/amd-pstate: Store the boost numerator as highest perf again
  cpufreq/amd-pstate: Detect preferred core support before driver registration
2024-12-21 10:47:47 -08:00
Linus Torvalds
be6bb3619e Thermal control fixes for 6.13-rc4
Fix two issues with the user thermal thresholds feature introduced
 in this development cycle (Daniel Lezcano).
 -----BEGIN PGP SIGNATURE-----
 
 iQJGBAABCAAwFiEE4fcc61cGeeHD/fCwgsRv/nhiVHEFAmdl1h4SHHJqd0Byand5
 c29ja2kubmV0AAoJEILEb/54YlRxCYoP/iPLKylOVCn1/PjzEfYSVDkGdOQEusRo
 Abwq0agYbyAPsWGOXgGVRUpHFh2otpTKM2W77Q3YNs7DmgeHAPUAxx1uhy+c3d2N
 dlGpj8ZdQrBWE+98SdMsooMb9+GMMX94nTXng9qvlpKFqSyjVM9oUuLsOu/vshkf
 esWmLQlnmCaenW7cEaL/xV3izRLJBrdvq+SFa7Rh991VzhV24n7ucItctTJKzJHN
 ZqH+pSvcFU2Kr2Quf3GnoY+HHfY3691lSpT+HwLEm3IdMrk3opt5pCxM8eA1D4Cn
 nHYOVRfyW54ZDBSNP1upUMJq77cBQRxzMZCGjPxyH75qzC4qwVJZhLShetPOe37i
 doQssU/TkYedR+p/z6EQBqA4LukUoYRl8tGyD+5WxKEzj0QlBAxFRsmVrFln4CMf
 pIlKTB9ZYyXVUBd7iMSMTF0tqp+GTd6FF6v5N7bmH72LQbMX3anmXEzS41suDENE
 tuFSM1j3n6EYkrWhKnqezRyh5OPVYfo55p2GTN1OgETb+k/kB/uQQZHnscvx/SDC
 GkNsAIIkLvUIWpYldfh+CRW2xX+jvZ1Ys7Hn3iVKf2RDYB6LO4Xk3n1E85mGcp3S
 rzIl2hdj2+v6iL6fsDgF2SM09DmC3GTlvTsVENhpZ9sYWIPuAaCAEYAcg1q+oLGC
 GLKuPwzgics0
 =O+vp
 -----END PGP SIGNATURE-----

Merge tag 'thermal-6.13-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm

Pull thermal control fixes from Rafael Wysocki:
 "Fix two issues with the user thermal thresholds feature introduced in
  this development cycle (Daniel Lezcano)"

* tag 'thermal-6.13-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm:
  thermal/thresholds: Fix boundaries and detection routine
  thermal/thresholds: Fix uapi header macros leading to a compilation error
2024-12-21 10:44:44 -08:00
Linus Torvalds
5100b6f9e7 ACPI fix for 6.13-rc4
Unbreak ACPI EC support on LoongArch that has been broken earlier
 in this development cycle (Huacai Chen).
 -----BEGIN PGP SIGNATURE-----
 
 iQJGBAABCAAwFiEE4fcc61cGeeHD/fCwgsRv/nhiVHEFAmdl1b8SHHJqd0Byand5
 c29ja2kubmV0AAoJEILEb/54YlRxT1wQAKhMdsDLrhVL+lxccFXZEc6tNQYz7T2h
 NMlFBet2gYLX5W65163YDDVqSsUMHMQVxDrzXUW7ZUfc+zatXnOXB3Qn3u9+5XPG
 hjEBjVjOgPGwizmtJc+oyPqkdzBfeFHwGXCq1APCkCwi4Oc2NhuRs49hVw53LTfh
 G5Dtsx3UrC8HBT1r5M5lJ3st6F4z+a+LCa5SRgDp5FIhgtFikwcxq4YxjXmTp8fq
 Gl4uaqwKv3SKRYxqOsY1Tp9sEAOyQViQ3pLSetXrj+Y58Vc4laSf+4fJzrDLJcfy
 +zwClWzRL7T7l9z9jWeguaZoJtafhcd1GIiZb1DurBdtlCy74dUBq0Go746Di+6K
 7dzMgjk4SOAGMv4IwkdhlSlPXqHqGSuev+WNDYggtNV3/CnAfGNJWQtIyG8XmC+n
 6s/GgaODU30pqakZATLcCPBcuMfmDc43ywl9JbEl5nufK+COCb1tnzuVgFzyfERY
 IEA/RYEvx7dw9AorPeMZuq6FdCMkrGDPx0PZkRF5S5GE/zDEdEIC2WlfGi8geCn6
 SffX0ijqWI8tIU8fBtYIJ0VzKrmRXHbKB1MhraiamcLNpAquqlKwqT9iuR/bXWuf
 lj6GCaRvZph+hrSP7A2mzeLpGYoubvORpPMfAV3YlXsHKeFKmxnW1iAO2Hym9box
 wcWGi2FM/Yfe
 =o1pK
 -----END PGP SIGNATURE-----

Merge tag 'acpi-6.13-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm

Pull ACPI fix from Rafael Wysocki:
 "Unbreak ACPI EC support on LoongArch that has been broken earlier in
  this development cycle (Huacai Chen)"

* tag 'acpi-6.13-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm:
  ACPI: EC: Enable EC support on LoongArch by default
2024-12-21 10:42:35 -08:00
Linus Torvalds
baa172c77a four smb3 client fixes
-----BEGIN PGP SIGNATURE-----
 
 iQGzBAABCgAdFiEE6fsu8pdIjtWE/DpLiiy9cAdyT1EFAmdmM9YACgkQiiy9cAdy
 T1FUVAv9GkoUno9PxDbaBEnjturb5b4EavqUKbS1QN5/RrE4ng82goUNQ7mZ7Il2
 PBuTnTBfeKKg6BbwmOhJpbWKtTQ3wty1H+s9o47U5cdbTGKc2wDrHvPaDK4D4EG4
 mj32OhjoqOKlpGzzNOxME3aPK7wvqz9kLgUPl9i5NovPhK8P/gZrZx1urYJVodYU
 dvE+/ZQziDMwYCOXc4qjl+wWHFm1yo5cwLO4fpcRJBTP7oIeUmT+kRPdLeW+XJHh
 wpR3K+3JwlcF25wf0au43jWLvhG6DuRwYzPGMROyVkVmC9nlEdmyvS5GERmdYSXa
 5IQOzuAdu4b4DJLsM5PyG275C/3FZna+Whf7nwX+qjLyTR7PeuzraWuV/3zYkYWG
 bRbgMBzDvWyGXkTkn2eZFsnjB2NCXXG8iJ7sU5QXvp5ElMXhVdOCfObJti72UYw4
 yxu/ms3yQ2NU7ahZtisoWxJLkwk2xSoV1h9kLQul0AkTEQwCdglIvHxv31v02OPj
 /mu2DDoW
 =556n
 -----END PGP SIGNATURE-----

Merge tag '6.13-rc3-SMB3-client-fixes' of git://git.samba.org/sfrench/cifs-2.6

Pull smb client fixes from Steve French:

 - fix regression in display of write stats

 - fix rmmod failure with network namespaces

 - two minor cleanups

* tag '6.13-rc3-SMB3-client-fixes' of git://git.samba.org/sfrench/cifs-2.6:
  smb: fix bytes written value in /proc/fs/cifs/Stats
  smb: client: fix TCP timers deadlock after rmmod
  smb: client: Deduplicate "select NETFS_SUPPORT" in Kconfig
  smb: use macros instead of constants for leasekey size and default cifsattrs value
2024-12-21 09:35:18 -08:00
Linus Torvalds
4a5da3f5d3 NFS client bugfixes for Linux 6.13
Bugfixes:
 - NFS/pnfs: Fix a live lock between recalled layouts and layoutget
 - Fix a build warning about an undeclared symbol 'nfs_idmap_cache_timeout'
 -----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCAAdFiEESQctxSBg8JpV8KqEZwvnipYKAPIFAmdl6zUACgkQZwvnipYK
 APLlzw/+MNyMeeWk8ZLbaMscr4YBAqot9O6ntW3zVANd+r7JlwdxECBiiPh8Eenq
 UPh5/wVx/6ZKimQfrVeM7I7jHJW0Y3eziZFmB1xN8nZmder8PmXiy98zNh4vbujO
 h+jjih5WgM1rICYeMouc1tqW5bMgH2dcHVthv21rUeMjrn0mV1SnlReKBmxUDACa
 b/RzhnQf5ZoqNzL7WVMed4PGnWXBNaKaai0Cn1hg61FzuPgegML6+5GcYTEiNLiu
 5qVMlJEQUoJgRaeYEmv4/EoYK3ukxwmK+f8wLHV7QviuE9PkHfVJsmmK6sZO3R3C
 yIZ7RluhcVHPlvhHbYgVPNwF7uUVrdiseN+IUDkgqDWUlbD19zSJ/r+4GyfnRql4
 6w75HAK/G+0JeEjtqWOnx8nYxlLDRRY6O+uWRwA5xa4eStiN28IG7RsyD5D83F1O
 RJ+PKkUUpv2I94Lebl3ZGsFtH5XBI7ZPbIIr3yL3YV42B3TNBgsFCV3SybdTK1WD
 Ev9Fsg3YJ0MP2CIJonIIahdu4uDIDhNNCOPBsRfnW/r8LwEs0V2KvOWDUxTwh5p3
 6HTjnVsp+eenr3SRo4TTUjEy9peuaLne2bMUasPd4iYFQK0ybuSAftdOE57jpKZf
 ug+UJXXqp9Lt+061VmY+RX7E2l8MAI45vQmann9trQdMfqEP2k4=
 =O6wX
 -----END PGP SIGNATURE-----

Merge tag 'nfs-for-6.13-2' of git://git.linux-nfs.org/projects/trondmy/linux-nfs

Pull NFS client fixes from Trond Myklebust:

 - NFS/pnfs: Fix a live lock between recalled layouts and layoutget

 - Fix a build warning about an undeclared symbol 'nfs_idmap_cache_timeout'

* tag 'nfs-for-6.13-2' of git://git.linux-nfs.org/projects/trondmy/linux-nfs:
  fs/nfs: fix missing declaration of nfs_idmap_cache_timeout
  NFS/pnfs: Fix a live lock between recalled layouts and layoutget
2024-12-21 09:32:24 -08:00
Linus Torvalds
7684392f17 A handful of important CephFS fixes from Max, Alex and myself: memory
corruption due to a buffer overrun, potential infinite loop and several
 memory leaks on the error paths.  All but one marked for stable.
 -----BEGIN PGP SIGNATURE-----
 
 iQFHBAABCAAxFiEEydHwtzie9C7TfviiSn/eOAIR84sFAmdlxvsTHGlkcnlvbW92
 QGdtYWlsLmNvbQAKCRBKf944AhHzi4vXB/9Y91WEVWK/ZX525z3sXbh0UK6yubPQ
 LRlHZ+01TE1uLTpU7wrv3rIApqqHDkL65au8Qc4/Cdxp3uJxZWFCs+0HuWwSeQ68
 TmSFicQAPxii/IqqB9oLWtXvLNQkJ+kAlnpHwgka7eGZco+biOVaB+OcSViTaGXd
 Sczfc42zxdSR342Zz9GnLzBDygtu983c3frcFMYG2qqhd1ZyvVittASUR2dP8krl
 qZUoKaQjBC7z4C5X2iwJ+89m/0UjE0sxQr1tY7qhX0yetbElD5Ddke+lE2yjzVsF
 tD4IasZaTWvN5Ywh6H3uQzfySWUVrdwzErJBw7g+h7IA1Ok6J9zqB1r+
 =vleo
 -----END PGP SIGNATURE-----

Merge tag 'ceph-for-6.13-rc4' of https://github.com/ceph/ceph-client

Pull ceph fixes from Ilya Dryomov:
 "A handful of important CephFS fixes from Max, Alex and myself: memory
  corruption due to a buffer overrun, potential infinite loop and
  several memory leaks on the error paths. All but one marked for
  stable"

* tag 'ceph-for-6.13-rc4' of https://github.com/ceph/ceph-client:
  ceph: allocate sparse_ext map only for sparse reads
  ceph: fix memory leak in ceph_direct_read_write()
  ceph: improve error handling and short/overflow-read logic in __ceph_sync_read()
  ceph: validate snapdirname option length when mounting
  ceph: give up on paths longer than PATH_MAX
  ceph: fix memory leaks in __ceph_sync_read()
2024-12-21 09:29:46 -08:00
Masahiro Yamada
9435dc77a3 modpost: distinguish same module paths from different dump files
Since commit 13b25489b6 ("kbuild: change working directory to external
module directory with M="), module paths are always relative to the top
of the external module tree.

The module paths recorded in Module.symvers are no longer globally unique
when they are passed via KBUILD_EXTRA_SYMBOLS for building other external
modules, which may result in false-positive "exported twice" errors.
Such errors should not occur because external modules should be able to
override in-tree modules.

To address this, record the dump file path in struct module and check it
when searching for a module.

Fixes: 13b25489b6 ("kbuild: change working directory to external module directory with M=")
Reported-by: Jon Hunter <jonathanh@nvidia.com>
Closes: https://lore.kernel.org/all/eb21a546-a19c-40df-b821-bbba80f19a3d@nvidia.com/
Signed-off-by: Masahiro Yamada <masahiroy@kernel.org>
Tested-by: Jon Hunter <jonathanh@nvidia.com>
2024-12-21 12:42:10 +09:00
Nicolas Schier
54956567a0 kbuild: deb-pkg: Do not install maint scripts for arch 'um'
Stop installing Debian maintainer scripts when building a
user-mode-linux Debian package.

Debian maintainer scripts are used for e.g. requesting rebuilds of
initrd, rebuilding DKMS modules and updating of grub configuration.  As
all of this is not relevant for UML but also may lead to failures while
processing the kernel hooks, do no more install maintainer scripts for
the UML package.

Suggested-by: Masahiro Yamada <masahiroy@kernel.org>
Signed-off-by: Nicolas Schier <nicolas@fjasle.eu>
Signed-off-by: Masahiro Yamada <masahiroy@kernel.org>
2024-12-21 12:42:10 +09:00
Masahiro Yamada
a34e92d2e8 kbuild: deb-pkg: add debarch for ARCH=um
'make ARCH=um bindeb-pkg' shows the following warning.

  $ make ARCH=um bindeb-pkg
     [snip]
    GEN     debian

  ** ** **  WARNING  ** ** **

  Your architecture doesn't have its equivalent
  Debian userspace architecture defined!
  Falling back to the current host architecture (amd64).
  Please add support for um to ./scripts/package/mkdebian ...

This commit hard-codes i386/amd64 because UML is only supported for x86.

Signed-off-by: Masahiro Yamada <masahiroy@kernel.org>
Reviewed-by: Nicolas Schier <nicolas@fjasle.eu>
2024-12-21 12:42:04 +09:00
Geert Uytterhoeven
d67393f4d2 kbuild: Drop support for include/asm-<arch> in headers_check.pl
"include/asm-<arch>" was replaced by "arch/<arch>/include/asm" a long
time ago.  All assembler header files are now included using
"#include <asm/*>", so there is no longer a need to rewrite paths.

Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be>
Signed-off-by: Masahiro Yamada <masahiroy@kernel.org>
2024-12-21 11:43:17 +09:00
Cong Wang
4a58963d10 selftests/bpf: Test bpf_skb_change_tail() in TC ingress
Similarly to the previous test, we also need a test case to cover
positive offsets as well, TC is an excellent hook for this.

Signed-off-by: Cong Wang <cong.wang@bytedance.com>
Signed-off-by: Daniel Borkmann <daniel@iogearbox.net>
Tested-by: Zijian Zhang <zijianzhang@bytedance.com>
Acked-by: John Fastabend <john.fastabend@gmail.com>
Link: https://lore.kernel.org/bpf/20241213034057.246437-5-xiyou.wangcong@gmail.com
2024-12-20 23:13:31 +01:00
Cong Wang
472759c9f5 selftests/bpf: Introduce socket_helpers.h for TC tests
Pull socket helpers out of sockmap_helpers.h so that they can be reused
for TC tests as well. This prepares for the next patch.

Signed-off-by: Cong Wang <cong.wang@bytedance.com>
Signed-off-by: Daniel Borkmann <daniel@iogearbox.net>
Acked-by: John Fastabend <john.fastabend@gmail.com>
Link: https://lore.kernel.org/bpf/20241213034057.246437-4-xiyou.wangcong@gmail.com
2024-12-20 23:13:31 +01:00
Cong Wang
9ee0c7b865 selftests/bpf: Add a BPF selftest for bpf_skb_change_tail()
As requested by Daniel, we need to add a selftest to cover
bpf_skb_change_tail() cases in skb_verdict. Here we test trimming,
growing and error cases, and validate its expected return values and the
expected sizes of the payload.

Signed-off-by: Cong Wang <cong.wang@bytedance.com>
Signed-off-by: Daniel Borkmann <daniel@iogearbox.net>
Acked-by: John Fastabend <john.fastabend@gmail.com>
Link: https://lore.kernel.org/bpf/20241213034057.246437-3-xiyou.wangcong@gmail.com
2024-12-20 23:13:31 +01:00
Cong Wang
9ecc4d858b bpf: Check negative offsets in __bpf_skb_min_len()
skb_network_offset() and skb_transport_offset() can be negative when
they are called after we pull the transport header, for example, when
we use eBPF sockmap at the point of ->sk_data_ready().

__bpf_skb_min_len() uses an unsigned int to get these offsets, this
leads to a very large number which then causes bpf_skb_change_tail()
failed unexpectedly.

Fix this by using a signed int to get these offsets and ensure the
minimum is at least zero.

Fixes: 5293efe62d ("bpf: add bpf_skb_change_tail helper")
Signed-off-by: Cong Wang <cong.wang@bytedance.com>
Signed-off-by: Daniel Borkmann <daniel@iogearbox.net>
Acked-by: John Fastabend <john.fastabend@gmail.com>
Link: https://lore.kernel.org/bpf/20241213034057.246437-2-xiyou.wangcong@gmail.com
2024-12-20 23:13:31 +01:00
Linus Torvalds
499551201b Fix a sparse warning in the arm64 signal code dealing with the user
shadow stack register, GCSPR_EL0.
 -----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCgAdFiEE5RElWfyWxS+3PLO2a9axLQDIXvEFAmdlufgACgkQa9axLQDI
 XvHS9Q//WmBcPgp99ZgmHwV4x9VZz4lBiZphBp2+WYNmYFjkEcNDggs8nWs+JwgR
 Y1isI5fLEuNYCqjoejtT5iPY3i9YAtiOtq8J7xnlZ35r3Ycur28f4C28ZxQnpHGH
 xaFO7deNTGhUkLvHaxIDxAyu8iHcJL+Q4XwuuTozedHPGwCHb5uyYHZB1fvYTrB0
 x4yxJDBehsN9x/xQPNYlaaXpYG3i0as/1DQod7kKIDckxnGOOk1s1sTPPMTsOMAv
 W9xvUPUmzoRvn7nH1ErT7X3O8LzbACy6RDg1iGzdMINTuLDDM9n55i2tl0TToqqq
 9h5IQ7ZSsPPixrPGarSZMhKnRKLHd0psFwfzhaWdPSGn4MHQInhkIP4vK05ycpxc
 E3AzbQMTb8ABVwW57XeJYnJJ28wY2QvQp0mm96xjSHfhYwafx4heTAM/4jzw5ZwC
 JsIbQsy603Ir7JhSV3rNozAUPI8GdQzXBYZ5PtW0AIbyJHAWP2R+/Q5kGK2IJd7a
 T5fzCLNSd0u7soY/4J856HYsDYw0SC0f6ua9BbaIC99vOlG9PhO/MJIkr+FsPeQq
 O3zH/xg/LGWQYudAoXYJhY6YuQ18mpdMw++/cNci2wWdhApf2sQLrhkO1Kz1numd
 WDDO13hyQZQMeulTeTrkS0teQmhuVeGvgb3vxLJzYi4OIEr8Iv4=
 =sJbw
 -----END PGP SIGNATURE-----

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

Pull arm64 fix from Catalin Marinas:
 "Fix a sparse warning in the arm64 signal code dealing with the user
  shadow stack register, GCSPR_EL0"

* tag 'arm64-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/arm64/linux:
  arm64/signal: Silence sparse warning storing GCSPR_EL0
2024-12-20 14:10:01 -08:00
Levi Zim
5153a75ef3 tcp_bpf: Fix copied value in tcp_bpf_sendmsg
bpf kselftest sockhash::test_txmsg_cork_hangs in test_sockmap.c triggers a
kernel NULL pointer dereference:

BUG: kernel NULL pointer dereference, address: 0000000000000008
 ? __die_body+0x6e/0xb0
 ? __die+0x8b/0xa0
 ? page_fault_oops+0x358/0x3c0
 ? local_clock+0x19/0x30
 ? lock_release+0x11b/0x440
 ? kernelmode_fixup_or_oops+0x54/0x60
 ? __bad_area_nosemaphore+0x4f/0x210
 ? mmap_read_unlock+0x13/0x30
 ? bad_area_nosemaphore+0x16/0x20
 ? do_user_addr_fault+0x6fd/0x740
 ? prb_read_valid+0x1d/0x30
 ? exc_page_fault+0x55/0xd0
 ? asm_exc_page_fault+0x2b/0x30
 ? splice_to_socket+0x52e/0x630
 ? shmem_file_splice_read+0x2b1/0x310
 direct_splice_actor+0x47/0x70
 splice_direct_to_actor+0x133/0x300
 ? do_splice_direct+0x90/0x90
 do_splice_direct+0x64/0x90
 ? __ia32_sys_tee+0x30/0x30
 do_sendfile+0x214/0x300
 __se_sys_sendfile64+0x8e/0xb0
 __x64_sys_sendfile64+0x25/0x30
 x64_sys_call+0xb82/0x2840
 do_syscall_64+0x75/0x110
 entry_SYSCALL_64_after_hwframe+0x4b/0x53

This is caused by tcp_bpf_sendmsg() returning a larger value(12289) than
size (8192), which causes the while loop in splice_to_socket() to release
an uninitialized pipe buf.

The underlying cause is that this code assumes sk_msg_memcopy_from_iter()
will copy all bytes upon success but it actually might only copy part of
it.

This commit changes it to use the real copied bytes.

Signed-off-by: Levi Zim <rsworktech@outlook.com>
Signed-off-by: Daniel Borkmann <daniel@iogearbox.net>
Tested-by: Björn Töpel <bjorn@kernel.org>
Reviewed-by: John Fastabend <john.fastabend@gmail.com>
Link: https://lore.kernel.org/bpf/20241130-tcp-bpf-sendmsg-v1-2-bae583d014f3@outlook.com
2024-12-20 22:53:36 +01:00
Levi Zim
fdf478d236 skmsg: Return copied bytes in sk_msg_memcopy_from_iter
Previously sk_msg_memcopy_from_iter returns the copied bytes from the
last copy_from_iter{,_nocache} call upon success.

This commit changes it to return the total number of copied bytes on
success.

Signed-off-by: Levi Zim <rsworktech@outlook.com>
Signed-off-by: Daniel Borkmann <daniel@iogearbox.net>
Tested-by: Björn Töpel <bjorn@kernel.org>
Reviewed-by: John Fastabend <john.fastabend@gmail.com>
Link: https://lore.kernel.org/bpf/20241130-tcp-bpf-sendmsg-v1-1-bae583d014f3@outlook.com
2024-12-20 22:53:36 +01:00
Linus Torvalds
d74276290c hwmon fixes for v6.13-rc4
* Fix reporting of negative temperature, current, and voltage values
   in tmp513 driver
 -----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCAAdFiEEiHPvMQj9QTOCiqgVyx8mb86fmYEFAmdlpv4ACgkQyx8mb86f
 mYGBUhAAgtN+PPS8LK2awOutm/RO/e5gI/GCBVJZxs26lgjq1G6g8/vdhVKvuSk8
 yui31TJOWsProbNzPuKKuXMZfD0b5pgsqWc2U/R7qMBJrKoZ10V2SEJKQfQJikh7
 5KzcQkov5xwtZpyUiLpzA/3/sO392wJFNLxvpDWnKC9ca59l4CU7MFcOs8gENbnF
 DC9N5S0rvRxaQ90pNQJGUOlFMl8YexAPAhoP6yYApW2wV5Fqu8DBuKl9ZGzUVr8L
 r9kIsxXRztSknYNwBuNo2hLGtkv+LaEcF54JJhhYC38g4O7s575h+37vFDKdjXQT
 pbgmXCmjKk6BLJ6gZM85eQD3XsiZSESRq9wwWs7BuXqYf1UyrOJ2SLhN4icDSJlq
 Sd8fr+UOEMcOim/7LMkuIlRUcxS5iASc/yawTIuBmc1hvyRopDt89LnFaxnJB8Vd
 IImE/hs1DqAt91MDL0R9/pBhMo04YEJitCAltQjFvyfFjzyXHEgAbWpXE9+gLSF/
 7z74LWjg/3GysWqTHuXXKdhmiOuNudHYAJFPe7FqwddfCYws+VH5drtKaBK4wQc5
 6m5f9d7N1ItoTy/C+zdGeLhUrBb/nAUk/w0j4FHl5tkC+PFo2cLBupXcyXkl+vJC
 qCyP5LJDa31iHarhRfOjrqSbptJbJgkPsh1vrKBcnpTaRhuj3KA=
 =82D+
 -----END PGP SIGNATURE-----

Merge tag 'hwmon-for-v6.13-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/groeck/linux-staging

Pull hwmon fixes from Guenter Roeck:

 - Fix reporting of negative temperature, current, and voltage values in
   the tmp513 driver

* tag 'hwmon-for-v6.13-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/groeck/linux-staging:
  hwmon: (tmp513) Fix interpretation of values of Temperature Result and Limit Registers
  hwmon: (tmp513) Fix Current Register value interpretation
  hwmon: (tmp513) Fix interpretation of values of Shunt Voltage and Limit Registers
2024-12-20 13:48:41 -08:00