Commit Graph

6782 Commits

Author SHA1 Message Date
Linus Torvalds
b8979c6b4d soc: driver updates for 6.12
The driver updates seem larger this time around, with changes
 is many of the SoC specific drivers, both the custom drivers/soc
 ones and the closely related subsystems (memory, bus, firmware,
 reset, ...).
 
 The at91 platform gains support for sam9x7 chips in the soc and
 power management code. This is the latest variant of one of the
 oldest still supported SoC families, using the ARM9 (ARMv5) core.
 
 As usual, the qualcomm snapdragon platform gets a ton of updates in many
 of their drivers to add more features and additional SoC support. Most
 of these are somewhat firmware related as the platform has a number of
 firmware based interfaces to the kernel. A notable addition here is the
 inclusion of trace events to two of these drivers.
 
 Herve Codina and Christophe Leroy are now sending updates for
 drivers/soc/fsl/ code through the SoC tree, this contains both PowerPC
 and Arm specific platforms and has previously been problematic to
 maintain. The first update here contains support for newer PowerPC
 variants and some cleanups.
 
 The turris mox firmware driver has a number of updates, mostly cleanups.
 
 The Arm SCMI firmware driver gets a major rework to modularize
 the existing code into separately loadable drivers for the various
 transports, the addition of custom NXP i.MX9 interfaces and a
 number of smaller updates.
 
 The Arm FF-A firmware driver gets a feature update to support
 the v1.2 version of the specification.
 
 The reset controller drivers have some smaller cleanups and a newly
 added driver for the Intel/Mobileye EyeQ5/EyeQ6 MIPS SoCs.
 
 The memory controller drivers get some cleanups and refactoring
 for Tegra, TI, Freescale/NXP and a couple more platforms.
 
 Finally there are lots of minor updates to firmware (raspberry pi,
 tegra, imx), bus (sunxi, omap, tegra) and soc (rockchips, tegra, amlogic,
 mediatek) drivers and their DT bindings.
 -----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCgAdFiEEiK/NIGsWEZVxh/FrYKtH/8kJUicFAmboJicACgkQYKtH/8kJ
 Uicc+RAAlc6lY0CKqZhAKzyGsjEHzPYcTN5axNf1WrTdgv3assF+yEeiQtkd+Re7
 IIbtrWYWmLouOazRm5y7OjOUUy78FRThgRaVlZLPiCZze3rlZjIHj2XJx7R1hdjv
 aXBSe13i1KfmOsIDVNxAJbFa5UveeAvKKxRb6SJtSwl46KGhhgI3Jwq347sR7bYY
 QpiVMRVZTkH7++hlE9KE5qv+I6QVlbhneU1ErHjy0g4av+UycQe0eJFOtZV+Y5Aj
 7k65D3GC33eOAK56iDCUH9OfYLFu7k3LF7V0zdLIhel1tFuoYUbjkC5iQr4VAMjc
 Ysw0vwXdnUoG3oDiGLOIK4u56flWqT7I8gSQwRhtp6Ikc47gdlA2zJLE4MNN/4Yh
 fMP9LUxzr0sJ67LUq4urtnRfVtgKRRZ44v6A+CHY0l3x6rqeNbkJd38mXeVMMIWo
 gW8cf/fJsEdNE+1neGXq7lRrUmCwvkYUAd7y3gt1BiUq/Abas6ityvzk9Xig87I2
 uq3p5nASgrl+o8OlmIBT770BeS2jY8tAGJm1ocCtYN2ZWGh37LeES4Bo/58BPTGE
 tydBhlBK41h2dUCYQRZFNUt/2/xCELQ2X4mUiOaL2gqmiJq3Q6fdR1d+DAOB+4a5
 KL1yt5yIrBl0XMQ76kir3VmqTeKNka7aS23yefgTZfQAVb+JDw4=
 =EauF
 -----END PGP SIGNATURE-----

Merge tag 'soc-drivers-6.12' of git://git.kernel.org/pub/scm/linux/kernel/git/soc/soc

Pull SoC driver updates from Arnd Bergmann:
 "The driver updates seem larger this time around, with changes is many
  of the SoC specific drivers, both the custom drivers/soc ones and the
  closely related subsystems (memory, bus, firmware, reset, ...).

  The at91 platform gains support for sam9x7 chips in the soc and power
  management code. This is the latest variant of one of the oldest still
  supported SoC families, using the ARM9 (ARMv5) core.

  As usual, the qualcomm snapdragon platform gets a ton of updates in
  many of their drivers to add more features and additional SoC support.
  Most of these are somewhat firmware related as the platform has a
  number of firmware based interfaces to the kernel. A notable addition
  here is the inclusion of trace events to two of these drivers.

  Herve Codina and Christophe Leroy are now sending updates for
  drivers/soc/fsl/ code through the SoC tree, this contains both PowerPC
  and Arm specific platforms and has previously been problematic to
  maintain. The first update here contains support for newer PowerPC
  variants and some cleanups.

  The turris mox firmware driver has a number of updates, mostly
  cleanups.

  The Arm SCMI firmware driver gets a major rework to modularize the
  existing code into separately loadable drivers for the various
  transports, the addition of custom NXP i.MX9 interfaces and a number
  of smaller updates.

  The Arm FF-A firmware driver gets a feature update to support the v1.2
  version of the specification.

  The reset controller drivers have some smaller cleanups and a newly
  added driver for the Intel/Mobileye EyeQ5/EyeQ6 MIPS SoCs.

  The memory controller drivers get some cleanups and refactoring for
  Tegra, TI, Freescale/NXP and a couple more platforms.

  Finally there are lots of minor updates to firmware (raspberry pi,
  tegra, imx), bus (sunxi, omap, tegra) and soc (rockchips, tegra,
  amlogic, mediatek) drivers and their DT bindings"

* tag 'soc-drivers-6.12' of git://git.kernel.org/pub/scm/linux/kernel/git/soc/soc: (212 commits)
  firmware: imx: remove duplicate scmi_imx_misc_ctrl_get()
  platform: cznic: turris-omnia-mcu: Fix error check in omnia_mcu_register_trng()
  bus: sunxi-rsb: Simplify code with dev_err_probe()
  soc: fsl: qe: ucc: Export ucc_mux_set_grant_tsa_bkpt
  soc: fsl: cpm1: qmc: Fix dependency on fsl_soc.h
  dt-bindings: arm: rockchip: Add rk3576 compatible string to pmu.yaml
  soc: fsl: qbman: Remove redundant warnings
  soc: fsl: qbman: Use iommu_paging_domain_alloc()
  MAINTAINERS: Add QE files related to the Freescale QMC controller
  soc: fsl: cpm1: qmc: Handle QUICC Engine (QE) soft-qmc firmware
  soc: fsl: cpm1: qmc: Add support for QUICC Engine (QE) implementation
  soc: fsl: qe: Add missing PUSHSCHED command
  soc: fsl: qe: Add resource-managed muram allocators
  soc: fsl: cpm1: qmc: Introduce qmc_version
  soc: fsl: cpm1: qmc: Rename SCC_GSMRL_MODE_QMC
  soc: fsl: cpm1: qmc: Handle RPACK initialization
  soc: fsl: cpm1: qmc: Rename qmc_chan_command()
  soc: fsl: cpm1: qmc: Introduce qmc_{init,exit}_xcc() and their CPM1 version
  soc: fsl: cpm1: qmc: Introduce qmc_init_resource() and its CPM1 version
  soc: fsl: cpm1: qmc: Re-order probe() operations
  ...
2024-09-17 10:48:09 +02:00
Linus Torvalds
303ba85c60 spi: Updates for v6.12
This is quite a quiet release for sPI.  The one new core feature here is
 support for configuring the state of the MOSI pin when the bus is idle,
 there are some devices which are very fragile in this regard even when
 the chip select signal is not asserted.  Otherwise we have some new
 driver support, a bunch of small fixes and some general cleanup work.
 
  - Support for configuring the state of the MOSI pin when the the bus is
    idle.
  - Add the Elgin JG0309-01 in spidev.
  - Support for Marvell xSPI, Mediatek MTK7981, Microchip PIC64GX,
    NXP i.MX8ULP, and Rockchip RK3576 controllers.
 
 I also accidentally pulled in an IIO DT bindings update due to a typo
 when applying the MOSI idle state patches.
 -----BEGIN PGP SIGNATURE-----
 
 iQEzBAABCgAdFiEEreZoqmdXGLWf4p/qJNaLcl1Uh9AFAmbnaTcACgkQJNaLcl1U
 h9BsXwf/bqArB1QiWT1t34WMKcowO6r0eCjRNSrpqcsOIprUa/0OYxXqsPJzigKV
 g9HF0w2uh15NByTv+KulH4r0QPa9JOeFHFx31+bec8PFdJoUwcNjWNUi7EaQgOLp
 /XzdahLhPhiBIraCts2JdRD8+4C9JlU0VeRdDRFMjl5+SB8Fjqx6mQ/rw68fEZGG
 YvUTIVNT2h00W6aMKmKN0rni5ny2qNIDm6sVj/dWSWbQCPcYjVG3kxI2dmlKIm3S
 ccKp4JHoOYpu9egp+t134bi/iLfOwP+vsmqWPqoI7J1cx78E9gH3QBf02KmTDbux
 m/02FtCFDh5hyXke9yn/QIZvO2bKzA==
 =UtQA
 -----END PGP SIGNATURE-----

Merge tag 'spi-v6.12' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/spi

Pull spi updates from Mark Brown:
 "This is quite a quiet release for SPI. The one new core feature here
  is support for configuring the state of the MOSI pin when the bus is
  idle, there are some devices which are very fragile in this regard
  even when the chip select signal is not asserted. Otherwise we have
  some new driver support, a bunch of small fixes and some general
  cleanup work.

   - Support for configuring the state of the MOSI pin when the the bus
     is idle

   - Add the Elgin JG0309-01 in spidev

   - Support for Marvell xSPI, Mediatek MTK7981, Microchip PIC64GX, NXP
     i.MX8ULP, and Rockchip RK3576 controllers

  I also accidentally pulled in an IIO DT bindings update due to a typo
  when applying the MOSI idle state patches"

* tag 'spi-v6.12' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/spi: (65 commits)
  spi: geni-qcom: Use devm functions to simplify code
  spi: remove spi_controller_is_slave() and spi_slave_abort()
  platform/olpc: olpc-xo175-ec: switch to use spi_target_abort().
  spi: slave-mt27xx: switch to use target_abort
  spi: spidev: switch to use spi_target_abort()
  spi: slave-system-control: switch to use spi_target_abort()
  spi: slave-time: switch to use spi_target_abort()
  spi: switch to use spi_controller_is_target()
  spi: fspi: add support for imx8ulp
  spi: fspi: involve lut_num for struct nxp_fspi_devtype_data
  dt-bindings: spi: nxp-fspi: add imx8ulp support
  spi: spidev_fdx: Fix the wrong format specifier
  spi: mxs: Switch to RUNTIME/SYSTEM_SLEEP_PM_OPS()
  spi: dt-bindings: Add rockchip,rk3576-spi compatible
  spi: Revert "spi: Insert the missing pci_dev_put()before return"
  spi: zynq-qspi: Replace kzalloc with kmalloc for buffer allocation
  spi: ppc4xx: Sort headers
  spi: ppc4xx: Revert "handle irq_of_parse_and_map() errors"
  spi: zynqmp-gqspi: Simplify with dev_err_probe()
  spi: zynqmp-gqspi: Use devm_spi_alloc_host()
  ...
2024-09-17 10:31:31 +02:00
Linus Torvalds
9ea925c806 Updates for timers and timekeeping:
- Core:
 
 	- Overhaul of posix-timers in preparation of removing the
 	  workaround for periodic timers which have signal delivery
 	  ignored.
 
         - Remove the historical extra jiffie in msleep()
 
 	  msleep() adds an extra jiffie to the timeout value to ensure
 	  minimal sleep time. The timer wheel ensures minimal sleep
 	  time since the large rewrite to a non-cascading wheel, but the
 	  extra jiffie in msleep() remained unnoticed. Remove it.
 
         - Make the timer slack handling correct for realtime tasks.
 
 	  The procfs interface is inconsistent and does neither reflect
 	  reality nor conforms to the man page. Show the correct 0 slack
 	  for real time tasks and enforce it at the core level instead of
 	  having inconsistent individual checks in various timer setup
 	  functions.
 
         - The usual set of updates and enhancements all over the place.
 
   - Drivers:
 
         - Allow the ACPI PM timer to be turned off during suspend
 
 	- No new drivers
 
 	- The usual updates and enhancements in various drivers
 -----BEGIN PGP SIGNATURE-----
 
 iQJHBAABCgAxFiEEQp8+kY+LLUocC4bMphj1TA10mKEFAmbn7jQTHHRnbHhAbGlu
 dXRyb25peC5kZQAKCRCmGPVMDXSYobqnD/9COlU0nwsulABI/aNIrsh6iYvnCC9v
 14CcNta7Qn+157Wfw9BWOyHdNhR1/fPCXE8jJ71zTyIOeW27HV2JyTtxTwe9ZcdK
 ViHAaj7YcIjcVUEC3StCoRCPnvLslEw4qJA5AOQuDyMivdQn+YVa2c0baJxKaXZt
 xk4HZdMj4NAS0jRKnoZSwtKW/+Oz6rR4GAWrZo+Zs1/8ur3HfqnQfi8lJ1hJtLLW
 V7XDCVRvamVi6Ah3ocYPPp/1P6yeQDA1ge9aMddqaza5STWISXRtSnFMUmYP3rbS
 FaL8TyL+ilfny8pkGB2WlG6nLuSbtvogtdEh1gG1k1RmZt44kAtk8ba/KiWFPBSb
 zK9cjojRMBS71f9G4kmb5F4rnXoLsg1YbD1Nzhz3wq2Cs1Z90dc2QwMren0zoQ1x
 Fn56ueRyAiagBlnrSaKyso/2RvqJTNoSdi3RkpjYeAph0UoDCqvTvKjGAf1mWiw1
 T/1lUWSVqWHnzZbM7XXzzajIN9bl6A7bbqlcAJ2O9vZIDt7273DG+bQym9Vh6Why
 0LTGGERHxzKBsG7WRg+2Gmvv6S18UPKRo8tLtlA758rHlFuPTZCShWrIriwSNl1K
 Hxon+d4BparSnm1h9W/NHPKJA574UbWRCBjdk58IkAj8DxZZY4ORD9SMP+ggkV7G
 F6p9cgoDNP9KFg==
 =jE0N
 -----END PGP SIGNATURE-----

Merge tag 'timers-core-2024-09-16' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip

Pull timer updates from Thomas Gleixner:
 "Core:

   - Overhaul of posix-timers in preparation of removing the workaround
     for periodic timers which have signal delivery ignored.

   - Remove the historical extra jiffie in msleep()

     msleep() adds an extra jiffie to the timeout value to ensure
     minimal sleep time. The timer wheel ensures minimal sleep time
     since the large rewrite to a non-cascading wheel, but the extra
     jiffie in msleep() remained unnoticed. Remove it.

   - Make the timer slack handling correct for realtime tasks.

     The procfs interface is inconsistent and does neither reflect
     reality nor conforms to the man page. Show the correct 0 slack for
     real time tasks and enforce it at the core level instead of having
     inconsistent individual checks in various timer setup functions.

   - The usual set of updates and enhancements all over the place.

  Drivers:

   - Allow the ACPI PM timer to be turned off during suspend

   - No new drivers

   - The usual updates and enhancements in various drivers"

* tag 'timers-core-2024-09-16' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: (43 commits)
  ntp: Make sure RTC is synchronized when time goes backwards
  treewide: Fix wrong singular form of jiffies in comments
  cpu: Use already existing usleep_range()
  timers: Rename next_expiry_recalc() to be unique
  platform/x86:intel/pmc: Fix comment for the pmc_core_acpi_pm_timer_suspend_resume function
  clocksource/drivers/jcore: Use request_percpu_irq()
  clocksource/drivers/cadence-ttc: Add missing clk_disable_unprepare in ttc_setup_clockevent
  clocksource/drivers/asm9260: Add missing clk_disable_unprepare in asm9260_timer_init
  clocksource/drivers/qcom: Add missing iounmap() on errors in msm_dt_timer_init()
  clocksource/drivers/ingenic: Use devm_clk_get_enabled() helpers
  platform/x86:intel/pmc: Enable the ACPI PM Timer to be turned off when suspended
  clocksource: acpi_pm: Add external callback for suspend/resume
  clocksource/drivers/arm_arch_timer: Using for_each_available_child_of_node_scoped()
  dt-bindings: timer: rockchip: Add rk3576 compatible
  timers: Annotate possible non critical data race of next_expiry
  timers: Remove historical extra jiffie for timeout in msleep()
  hrtimer: Use and report correct timerslack values for realtime tasks
  hrtimer: Annotate hrtimer_cpu_base_.*_expiry() for sparse.
  timers: Add sparse annotation for timer_sync_wait_running().
  signal: Replace BUG_ON()s
  ...
2024-09-17 07:25:37 +02:00
Linus Torvalds
d22300518d Thermal control updates for 6.12-rc1
- Update some thermal drivers to eliminate thermal_zone_get_trip()
    calls from them and get rid of that function (Rafael Wysocki).
 
  - Update the thermal sysfs code to store trip point attributes in trip
    descriptors and get to trip points via attribute pointers (Rafael
    Wysocki).
 
  - Move the computation of the low and high boundaries for
    thermal_zone_set_trips() to __thermal_zone_device_update() (Daniel
    Lezcano).
 
  - Introduce a debugfs-based facility for thermal core testing (Rafael
    Wysocki).
 
  - Replace the thermal zone .bind() and .unbind() callbacks for binding
    cooling devices to thermal zones with one .should_bind() callback
    used for deciding whether or not a given cooling devices should be
    bound to a given trip point in a given thermal zone (Rafael Wysocki).
 
  - Eliminate code that has no more users after the other changes, drop
    some redundant checks from the thermal core and clean it up (Rafael
    Wysocki).
 
  - Fix rounding of delay jiffies in the thermal core (Rafael Wysocki).
 
  - Refuse to accept trip point temperature or hysteresis that would lead
    to an invalid threshold value when setting them via sysfs (Rafael
    Wysocki).
 
  - Adjust states of all uninitialized instances in the .manage()
    callback of the Bang-bang thermal governor (Rafael Wysocki).
 
  - Drop a couple of redundant checks along with the code depending on
    them from the thermal core (Rafael Wysocki).
 
  - Rearrange the thermal core to avoid redundant checks and simplify
    control flow in a couple of code paths (Rafael Wysocki).
 
  - Add power domain DT bindings for new Amlogic SoCs (Georges Stark).
 
  - Switch from CONFIG_PM_SLEEP guards to pm_sleep_ptr() in the ST
    driver and add a Kconfig dependency on THERMAL_OF subsystem for the
    STi driver (Raphael Gallais-Pou).
 
  - Simplify the error code path in the probe functions in the brcmstb
    driver with the helo of dev_err_probe() (Yan Zhen).
 
  - Make imx_sc_thermal use dev_err_probe() (Alexander Stein).
 
  - Remove trailing space after \n newline in the Renesas driver (Colin
    Ian King).
 
  - Add DT binding compatible string for the SA8255p to the tsens thermal
    driver (Nikunj Kela).
 
  - Use the devm_clk_get_enabled() helpers to simplify the init routine
    in the sprd thermal driver (Huan Yang).
 
  - Remove __maybe_unused notations for the functions by using the new
    RUNTIME_PM_OPS() and SYSTEM_SLEEP_PM_OPS() macros on the IMx and
    Qoriq drivers (Fabio Estevam)
 
  - Remove unused declarations from the ti-soc-thermal driver's header
    file as the functions in question were removed previously (Zhang
    Zekun).
 -----BEGIN PGP SIGNATURE-----
 
 iQJGBAABCAAwFiEE4fcc61cGeeHD/fCwgsRv/nhiVHEFAmbjJz8SHHJqd0Byand5
 c29ja2kubmV0AAoJEILEb/54YlRx3vAP/iS4NTxdF7RJk1ocNCHDyX5pwcS51vZ4
 6OfU4EDEieCZMmgIUUexjGvnhwDBy1CRhYD3BeRAmj9AL+89Dpm5DcXPLVcCf2P9
 wnVrTDfEE2udGvJIJnpKcwsWR96/zot4mt5PSPprtUvDnskTqYlflZYF1FhA1DiS
 rPPKa553wdBAja1ypyGcP/N4nq3DQpcIFi1VQVUgnmdcAe50CA8yd8aQukWcfXoO
 L5pmHMOqPWdP1pxwxx1uUzHX9BRlPVHsxpNfKojcwrv9rZQ99Nkyy+M28/DTQEaT
 I17tdANTv04GUzzu421D2KREeXNsq3GtXtBRQhUegNZiQQxXe/wCB2UU/EFZDEQg
 MSXmGmensDV1xsEBuUy3x99vVsdZND0mnY0R3Gk2LvIWPEoRVMWkS3NUD2cqq48R
 0C0kERkxlAaGQU/GpEZZTun/u3LeicNUKs4vOaFsqADEzoiDKm/kLMhdKzU4FVDD
 wGJLIkTJInVL2sMWYuYeTxnx03Qs0aCYW5TTTzJUqkU15fx8/smLDe3cM5Px2Hbk
 HvRVGXPK0uz6CJdPcUqbdV0916INLyzdrfAGdRy2gFUp7DjBHROhQHSAkxQYiRfL
 W00ZSI8FSMx3+pv0HYmr4WNNk6gNrVyXBmRLLZAE2Th7c9tVw9pEMzXF5lnpYbII
 FFc6OY/gNxyr
 =mr7q
 -----END PGP SIGNATURE-----

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

Pull thermal control updates from Rafael Wysocki:
 "These mostly continue to rework the thermal core and the thermal zone
  driver interface to make the code more straightforward and reduce
  bloat

  The most significant piece of this work is a change of the code
  related to binding cooling devices to thermal zones which, among other
  things, replaces two previously existing thermal zone operations with
  one allowing driver implementations to be much simpler

  There is also a new thermal core testing module allowing mock thermal
  zones to be created and controlled via debugfs in order to exercise
  the thermal core functionality. It is expected to be used for
  implementing thermal core self tests in the future

  Apart from the above, there are assorted thermal driver updates

  Specifics:

   - Update some thermal drivers to eliminate thermal_zone_get_trip()
     calls from them and get rid of that function (Rafael Wysocki)

   - Update the thermal sysfs code to store trip point attributes in
     trip descriptors and get to trip points via attribute pointers
     (Rafael Wysocki)

   - Move the computation of the low and high boundaries for
     thermal_zone_set_trips() to __thermal_zone_device_update() (Daniel
     Lezcano)

   - Introduce a debugfs-based facility for thermal core testing (Rafael
     Wysocki)

   - Replace the thermal zone .bind() and .unbind() callbacks for
     binding cooling devices to thermal zones with one .should_bind()
     callback used for deciding whether or not a given cooling devices
     should be bound to a given trip point in a given thermal zone
     (Rafael Wysocki)

   - Eliminate code that has no more users after the other changes, drop
     some redundant checks from the thermal core and clean it up (Rafael
     Wysocki)

   - Fix rounding of delay jiffies in the thermal core (Rafael Wysocki)

   - Refuse to accept trip point temperature or hysteresis that would
     lead to an invalid threshold value when setting them via sysfs
     (Rafael Wysocki)

   - Adjust states of all uninitialized instances in the .manage()
     callback of the Bang-bang thermal governor (Rafael Wysocki)

   - Drop a couple of redundant checks along with the code depending on
     them from the thermal core (Rafael Wysocki)

   - Rearrange the thermal core to avoid redundant checks and simplify
     control flow in a couple of code paths (Rafael Wysocki)

   - Add power domain DT bindings for new Amlogic SoCs (Georges Stark)

   - Switch from CONFIG_PM_SLEEP guards to pm_sleep_ptr() in the ST
     driver and add a Kconfig dependency on THERMAL_OF subsystem for the
     STi driver (Raphael Gallais-Pou)

   - Simplify the error code path in the probe functions in the brcmstb
     driver with the helo of dev_err_probe() (Yan Zhen)

   - Make imx_sc_thermal use dev_err_probe() (Alexander Stein)

   - Remove trailing space after \n newline in the Renesas driver (Colin
     Ian King)

   - Add DT binding compatible string for the SA8255p to the tsens
     thermal driver (Nikunj Kela)

   - Use the devm_clk_get_enabled() helpers to simplify the init routine
     in the sprd thermal driver (Huan Yang)

   - Remove __maybe_unused notations for the functions by using the new
     RUNTIME_PM_OPS() and SYSTEM_SLEEP_PM_OPS() macros on the IMx and
     Qoriq drivers (Fabio Estevam)

   - Remove unused declarations from the ti-soc-thermal driver's header
     file as the functions in question were removed previously (Zhang
     Zekun)"

* tag 'thermal-6.12-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm: (48 commits)
  thermal: core: Drop thermal_zone_device_is_enabled()
  thermal: core: Check passive delay in monitor_thermal_zone()
  thermal: core: Drop dead code from monitor_thermal_zone()
  thermal: core: Drop redundant lockdep_assert_held()
  thermal: gov_bang_bang: Adjust states of all uninitialized instances
  thermal: sysfs: Add sanity checks for trip temperature and hysteresis
  thermal/drivers/imx_sc_thermal: Use dev_err_probe
  thermal/drivers/ti-soc-thermal: Remove unused declarations
  thermal/drivers/imx: Remove __maybe_unused notations
  thermal/drivers/qoriq: Remove __maybe_unused notations
  thermal/drivers/sprd: Use devm_clk_get_enabled() helpers
  dt-bindings: thermal: tsens: document support on SA8255p
  thermal/drivers/renesas: Remove trailing space after \n newline
  thermal/drivers/brcmstb_thermal: Simplify with dev_err_probe()
  thermal/drivers/sti: Depend on THERMAL_OF subsystem
  thermal/drivers/st: Switch from CONFIG_PM_SLEEP guards to pm_sleep_ptr()
  dt-bindings: thermal: amlogic,thermal: add optional power-domains
  thermal: core: Drop tz field from struct thermal_instance
  thermal: core: Drop redundant checks from thermal_bind_cdev_to_trip()
  thermal: core: Rename cdev-to-thermal-zone bind/unbind functions
  ...
2024-09-16 08:05:54 +02:00
Linus Torvalds
42c5b51949 platform-drivers-x86 for v6.11-7
Fixes:
 - asus-wmi: Disable OOBE that interferes with backlight control
 - panasonic-laptop: Two fixes to SINF array handling
 
 The following is an automated shortlog grouped by driver:
 
 asus-wmi:
  -  Disable OOBE experience on Zenbook S 16
 
 panasonic-laptop:
  -  Allocate 1 entry extra in the sinf array
  -  Fix SINF array out of bounds accesses
 -----BEGIN PGP SIGNATURE-----
 
 iHUEABYIAB0WIQSCSUwRdwTNL2MhaBlZrE9hU+XOMQUCZuKxBgAKCRBZrE9hU+XO
 MZWtAP9CFIg02ZzY8ZadQMhV3CmOfojLp9S8mYN9BS91iO9eYwD/deECQ1hG+UHp
 wRjs+8BA9jUtWT3iLyFcA2ZnAdZPCwA=
 =rCeo
 -----END PGP SIGNATURE-----

Merge tag 'platform-drivers-x86-v6.11-7' of git://git.kernel.org/pub/scm/linux/kernel/git/pdx86/platform-drivers-x86

Pull x86 platform driver fixes from Ilpo Järvinen:

 - asus-wmi: Disable OOBE that interferes with backlight control

 - panasonic-laptop: Two fixes to SINF array handling

* tag 'platform-drivers-x86-v6.11-7' of git://git.kernel.org/pub/scm/linux/kernel/git/pdx86/platform-drivers-x86:
  platform/x86: asus-wmi: Disable OOBE experience on Zenbook S 16
  platform/x86: panasonic-laptop: Allocate 1 entry extra in the sinf array
  platform/x86: panasonic-laptop: Fix SINF array out of bounds accesses
2024-09-12 12:34:39 -07:00
Mark Brown
f10d52087c
spi: Merge up fixes
A patch for Qualcomm depends on some fixes.
2024-09-12 12:38:44 +01:00
Linus Torvalds
77f5878967 ARM: SoC fixes for 6.11, part 3
The bulk of the changes this time are for device tree files in the
 rockchips platform, addressing correctness issues on individual
 boards, plus one change in the rk356x SoC file to make it match
 the binding.
 
 The only other changes that came in are
 
  - a CPU frequencey scaling fix for JH7110 (RISC-V)
  - a build fix for the cznic hwrandom driver
  - a fix for a deadlock in qualcomm uefi secure
    application firmware driver
 -----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCgAdFiEEiK/NIGsWEZVxh/FrYKtH/8kJUicFAmbhsaQACgkQYKtH/8kJ
 Uif7IBAAwTdAjhxjiBk5ktIkrhNRG9VCvXDwr9Ji70yphxufSIZDQSa+pdN5EFyR
 EgWCTQkZ2Ctw7s9lQmC0Tu3Lxmpu5Q7838UJqlEon2K2yJkKfLG+OSqSwNU6l44u
 GcTND3kGUDTm+uot5Ne0F7dnPiLBWmithKa75/TIoza07Ekz4ynb2fYRuW6JURZ4
 6WCTziL0jCFcUALtjibgno3lG06AwrQWEKd3n53ws9ttnNtpWMzfkDnuF4dBcPod
 vEmTOIaJkEKV80nwupZw8aCKGxe8mARej2kGPZgm9heNfnQk/V7e/1wCm0q8tw3t
 kfUYLN9I/aXTcZyLwixCAVeWhCtONrYBHbZTjXVO2bONtGatiQKgJ1LwhjAOUVMV
 iG20E3P+9OIZ3VIQ9k0Sc3Ys3Sw9Vdd9y01pzv+SyzewnI0h9qHXOrkChx36iwSH
 wsJ9vqZUtLgxcYDYR9JEBEfK9Qaz7X59xtfw75jbiQDzIitvATxA+7HT+7/UPDuA
 d6y5e9i/27+UebImNNtK1+XgHH0qkdBOFA7CHWsvijKgI2GiNkFa1CALBio37dVz
 IBGMFTTHPsCKFiTfy7d4O6VgUeUOjhWXbVEScE7QoHmaQQZ8w0MD6uvOJ8m4cIAt
 V2xbw1EUplldhwRQtsUbsYbopkJBzk+1AWGcIx5ccd3nWCIJkew=
 =Waa0
 -----END PGP SIGNATURE-----

Merge tag 'arm-fixes-6.11-3' of git://git.kernel.org/pub/scm/linux/kernel/git/soc/soc

Pull ARM SoC fixes from Arnd Bergmann:
 "The bulk of the changes this time are for device tree files in the
  rockchips platform, addressing correctness issues on individual
  boards, plus one change in the rk356x SoC file to make it match the
  binding.

  The only other changes that came in are

   - a CPU frequencey scaling fix for JH7110 (RISC-V)

   - a build fix for the cznic hwrandom driver

   - a fix for a deadlock in qualcomm uefi secure application firmware
     driver"

* tag 'arm-fixes-6.11-3' of git://git.kernel.org/pub/scm/linux/kernel/git/soc/soc:
  platform: cznic: turris-omnia-mcu: fix HW_RANDOM dependency
  riscv: dts: starfive: jh7110-common: Fix lower rate of CPUfreq by setting PLL0 rate to 1.5GHz
  firmware: qcom: uefisecapp: Fix deadlock in qcuefi_acquire()
  arm64: dts: rockchip: Fix compatibles for RK3588 VO{0,1}_GRF
  dt-bindings: soc: rockchip: Fix compatibles for RK3588 VO{0,1}_GRF
  arm64: dts: rockchip: override BIOS_DISABLE signal via GPIO hog on RK3399 Puma
  arm64: dts: rockchip: fix eMMC/SPI corruption when audio has been used on RK3399 Puma
  arm64: dts: rockchip: fix PMIC interrupt pin in pinctrl for ROCK Pi E
  arm64: dts: rockchip: Remove broken tsadc pinctrl binding for rk356x
2024-09-11 11:26:56 -07:00
Arnd Bergmann
b97acde6f9
platform: cznic: turris-omnia-mcu: fix HW_RANDOM dependency
There is still a build failure when the rwrng support is in a loadable
module but the mcu driver is built-in:

arm-linux-gnueabi-ld: drivers/platform/cznic/turris-omnia-mcu-trng.o: in function `omnia_mcu_register_trng':
turris-omnia-mcu-trng.c:(.text.omnia_mcu_register_trng+0x11c): undefined reference to `devm_hwrng_register'

Change the dependency to explicitly disallow the broken
configuration.

Fixes: 41bb142a40 ("platform: cznic: turris-omnia-mcu: Add support for MCU provided TRNG")
Reviewed-by: Marek Behún <kabel@kernel.org>
Link: https://lore.kernel.org/r/20240909110417.247453-1-arnd@kernel.org
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
2024-09-11 08:54:21 +00:00
Bas Nieuwenhuizen
d6de45e3c6
platform/x86: asus-wmi: Disable OOBE experience on Zenbook S 16
The OOBE experience fades the keyboard backlight in & out continuously,
and make the backlight uncontrollable using its device.

Workaround taken from
https://wiki.archlinux.org/index.php?title=ASUS_Zenbook_UM5606&diff=next&oldid=815547

Signed-off-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
Reviewed-by: Luke D. Jones <luke@ljones.dev>
Link: https://lore.kernel.org/r/20240909223503.1445779-1-bas@basnieuwenhuizen.nl
Reviewed-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>
Signed-off-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>
2024-09-10 15:43:58 +03:00
Thomas Gleixner
2f7eedca6c Merge branch 'linus' into timers/core
To update with the latest fixes.
2024-09-10 13:49:53 +02:00
Yang Yingliang
5b2e4d1515
platform/olpc: olpc-xo175-ec: switch to use spi_target_abort().
Switch to use modern name function spi_target_abort().

No functional changed.

Signed-off-by: Yang Yingliang <yangyingliang@huawei.com>
Acked-by: Hans de Goede <hdegoede@redhat.com>
Link: https://patch.msgid.link/20240910022618.1397-7-yangyingliang@huaweicloud.com
Signed-off-by: Mark Brown <broonie@kernel.org>
2024-09-10 12:41:41 +01:00
Hans de Goede
33297cef31
platform/x86: panasonic-laptop: Allocate 1 entry extra in the sinf array
Some DSDT-s have an off-by-one bug where the SINF package count is
one higher than the SQTY reported value, allocate 1 entry extra.

Also make the SQTY <-> SINF package count mismatch error more verbose
to help debugging similar issues in the future.

This fixes the panasonic-laptop driver failing to probe() on some
devices with the following errors:

[    3.958887] SQTY reports bad SINF length SQTY: 37 SINF-pkg-count: 38
[    3.958892] Couldn't retrieve BIOS data
[    3.983685] Panasonic Laptop Support - With Macros: probe of MAT0019:00 failed with error -5

Fixes: 709ee531c1 ("panasonic-laptop: add Panasonic Let's Note laptop extras driver v0.94")
Cc: stable@vger.kernel.org
Tested-by: James Harmison <jharmison@redhat.com>
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Link: https://lore.kernel.org/r/20240909113227.254470-2-hdegoede@redhat.com
Reviewed-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>
Signed-off-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>
2024-09-09 20:50:21 +03:00
Hans de Goede
f52e98d16e
platform/x86: panasonic-laptop: Fix SINF array out of bounds accesses
The panasonic laptop code in various places uses the SINF array with index
values of 0 - SINF_CUR_BRIGHT(0x0d) without checking that the SINF array
is big enough.

Not all panasonic laptops have this many SINF array entries, for example
the Toughbook CF-18 model only has 10 SINF array entries. So it only
supports the AC+DC brightness entries and mute.

Check that the SINF array has a minimum size which covers all AC+DC
brightness entries and refuse to load if the SINF array is smaller.

For higher SINF indexes hide the sysfs attributes when the SINF array
does not contain an entry for that attribute, avoiding show()/store()
accessing the array out of bounds and add bounds checking to the probe()
and resume() code accessing these.

Fixes: e424fb8cc4 ("panasonic-laptop: avoid overflow in acpi_pcc_hotkey_add()")
Cc: stable@vger.kernel.org
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Link: https://lore.kernel.org/r/20240909113227.254470-1-hdegoede@redhat.com
Reviewed-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>
Signed-off-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>
2024-09-09 20:50:12 +03:00
Marek Maslanka
2376d871f8 platform/x86:intel/pmc: Fix comment for the pmc_core_acpi_pm_timer_suspend_resume function
Change incorrect kernel-doc comment to regular comment for the
pmc_core_acpi_pm_timer_suspend_resume function.

Signed-off-by: Marek Maslanka <mmaslanka@google.com>
Reported-by: kernel test robot <lkp@intel.com>
Closes: https://lore.kernel.org/oe-kbuild-all/202409031410.a9beukFc-lkp@intel.com/
Link: https://lore.kernel.org/r/20240904094753.1615549-1-mmaslanka@google.com
Signed-off-by: Daniel Lezcano <daniel.lezcano@linaro.org>
2024-09-06 14:49:21 +02:00
Marek Maslanka
e86c8186d0 platform/x86:intel/pmc: Enable the ACPI PM Timer to be turned off when suspended
Allow to disable ACPI PM Timer on suspend and enable on resume. A
disabled timer helps optimise power consumption when the system is
suspended. On resume the timer is only reactivated if it was activated
prior to suspend, so unless the ACPI PM timer is enabled in the BIOS,
this won't change anything.

The ACPI PM timer is used by Intel's iTCO/wdat_wdt watchdog to drive the
watchdog, so it doesn't need to run during suspend.

Signed-off-by: Marek Maslanka <mmaslanka@google.com>
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Link: https://lore.kernel.org/r/20240812184208.1080710-1-mmaslanka@google.com
Signed-off-by: Daniel Lezcano <daniel.lezcano@linaro.org>
2024-09-06 14:49:20 +02:00
Linus Torvalds
ad61873688 platform-drivers-x86 for v6.11-6
Changes:
 - amd/pmf: ASUS GA403 quirk matching tweak
 - dell-smbios: Fix to the init function rollback path
 
 The following is an automated shortlog grouped by driver:
 
 amd: pmf:
  -  Make ASUS GA403 quirk generic
 
 dell-smbios:
  -  Fix error path in dell_smbios_init()
 -----BEGIN PGP SIGNATURE-----
 
 iHUEABYIAB0WIQSCSUwRdwTNL2MhaBlZrE9hU+XOMQUCZtlyNgAKCRBZrE9hU+XO
 Mey1AQDj6LTAoIQkcGw9airgUfAG2H69DaB0KYkiGj59FDrAqQEAzAZ11bttkqon
 e4KsvC8K4tZhhHPQsbuUB97sDmcBwAw=
 =W6Fk
 -----END PGP SIGNATURE-----

Merge tag 'platform-drivers-x86-v6.11-6' of git://git.kernel.org/pub/scm/linux/kernel/git/pdx86/platform-drivers-x86

Pull x86 platform driver fixes from Ilpo Järvinen:

 - amd/pmf: ASUS GA403 quirk matching tweak

 - dell-smbios: Fix to the init function rollback path

* tag 'platform-drivers-x86-v6.11-6' of git://git.kernel.org/pub/scm/linux/kernel/git/pdx86/platform-drivers-x86:
  platform/x86/amd: pmf: Make ASUS GA403 quirk generic
  platform/x86: dell-smbios: Fix error path in dell_smbios_init()
2024-09-05 09:57:50 -07:00
Dan Carpenter
2d516b8fc0 platform: cznic: turris-omnia-mcu: Fix error check in omnia_mcu_register_trng()
The gpiod_to_irq() function never returns zero.  It returns negative
error codes or a positive IRQ number.  Update the checking to check
for negatives.

Fixes: 41bb142a40 ("platform: cznic: turris-omnia-mcu: Add support for MCU provided TRNG")
Signed-off-by: Dan Carpenter <dan.carpenter@linaro.org>
Reviewed-by: Marek Behún <kabel@kernel.org>
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
2024-09-05 16:31:59 +00:00
Luke D. Jones
d34af755a5
platform/x86/amd: pmf: Make ASUS GA403 quirk generic
The original quirk should match to GA403U so that the full
range of GA403U models can benefit.

Signed-off-by: Luke D. Jones <luke@ljones.dev>
Link: https://lore.kernel.org/r/20240831003905.1060977-1-luke@ljones.dev
Reviewed-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>
Signed-off-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>
2024-09-03 17:31:08 +03:00
Aleksandr Mishin
ffc17e1479
platform/x86: dell-smbios: Fix error path in dell_smbios_init()
In case of error in build_tokens_sysfs(), all the memory that has been
allocated is freed at end of this function. But then free_group() is
called which performs memory deallocation again.

Also, instead of free_group() call, there should be exit_dell_smbios_smm()
and exit_dell_smbios_wmi() calls, since there is initialization, but there
is no release of resources in case of an error.

Fix these issues by replacing free_group() call with
exit_dell_smbios_wmi() and exit_dell_smbios_smm().

Found by Linux Verification Center (linuxtesting.org) with SVACE.

Fixes: 33b9ca1e53 ("platform/x86: dell-smbios: Add a sysfs interface for SMBIOS tokens")
Signed-off-by: Aleksandr Mishin <amishin@t-argos.ru>
Link: https://lore.kernel.org/r/20240830065428.9544-1-amishin@t-argos.ru
Reviewed-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>
Signed-off-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>
2024-08-30 12:58:18 +03:00
Rafael J. Wysocki
f5c0597434 Merge branch 'thermal-core'
Merge thermal core updates for 6.12 which, among other things, rework
the thermal driver interface for binding cooling devices to thermal
zones and add a thermal core testing module:

 - Update some thermal drivers to eliminate thermal_zone_get_trip()
   calls from them and get rid of that function (Rafael Wysocki).

 - Update the thermal sysfs code to store trip point attributes in trip
   descriptors and get to trip points via attribute pointers (Rafael
   Wysocki).

 - Move the computation of the low and high boundaries for
   thermal_zone_set_trips() to __thermal_zone_device_update() (Daniel
   Lezcano).

 - Introduce a debugfs-based facility for thermal core testing (Rafael
   Wysocki).

 - Replace the thermal zone .bind() and .unbind() callbacks for binding
   cooling devices to thermal zones with one .should_bind() callback
   used for deciding whether or not a given cooling devices should be
   bound to a given trip point in a given thermal zone (Rafael Wysocki).

 - Eliminate code that has no more users after the other changes, drop
   some redundant checks from the thermal core and clean it up (Rafael
   Wysocki).

 - Fix rounding of delay jiffies in the thermal core (Rafael Wysocki).

* thermal-core: (31 commits)
  thermal: core: Drop tz field from struct thermal_instance
  thermal: core: Drop redundant checks from thermal_bind_cdev_to_trip()
  thermal: core: Rename cdev-to-thermal-zone bind/unbind functions
  thermal: core: Fix rounding of delay jiffies
  thermal: core: Clean up trip bind/unbind functions
  thermal: core: Drop unused bind/unbind functions and callbacks
  thermal/of: Use the .should_bind() thermal zone callback
  thermal: imx: Use the .should_bind() thermal zone callback
  mlxsw: core_thermal: Use the .should_bind() thermal zone callback
  platform/x86: acerhdf: Use the .should_bind() thermal zone callback
  thermal: core: Unexport thermal_bind_cdev_to_trip() and thermal_unbind_cdev_from_trip()
  thermal: ACPI: Use the .should_bind() thermal zone callback
  thermal: core: Introduce .should_bind() thermal zone callback
  thermal: core: Move thermal zone locking out of bind/unbind functions
  thermal: sysfs: Use the dev argument in instance-related show/store
  thermal: core: Drop redundant thermal instance checks
  thermal: core: Rearrange checks in thermal_bind_cdev_to_trip()
  thermal: core: Fold two functions into their respective callers
  thermal: Introduce a debugfs-based testing facility
  thermal/core: Compute low and high boundaries in thermal_zone_device_update()
  ...
2024-08-29 11:45:08 +02:00
Linus Torvalds
f9a59dd097 platform-drivers-x86 for v6.11-5
Changes:
 - platform/x86/amd/pmc: AMD 1Ah model 60h series support (2nd attempt).
 - asus-wmi: Prevent spurious rfkill on Asus Zenbook Duo.
 - x86-android-tablets: Relax DMI match to cover another model.
 
 The following is an automated shortlog grouped by driver:
 
 amd/pmc:
  -  Extend support for PMC features on new AMD platform
  -  Fix SMU command submission path on new AMD platform
 
 asus-wmi:
  -  Fix spurious rfkill on UX8406MA
 
 x86-android-tablets:
  -  Make Lenovo Yoga Tab 3 X90F DMI match less strict
 -----BEGIN PGP SIGNATURE-----
 
 iHUEABYIAB0WIQSCSUwRdwTNL2MhaBlZrE9hU+XOMQUCZs7zjgAKCRBZrE9hU+XO
 MT+QAQCjWjX2mETui5B0ey6oBJUe3PmUzUQ0OE90bJDbDy/6oQD+I+TjPz4m/CLe
 Nyk3fTb6373B+ZhdAfVMzRwEKWV+/Q4=
 =WLMw
 -----END PGP SIGNATURE-----

Merge tag 'platform-drivers-x86-v6.11-5' of git://git.kernel.org/pub/scm/linux/kernel/git/pdx86/platform-drivers-x86

Pull x86 platform drivers fixes from Ilpo Järvinen:

 - platform/x86/amd/pmc: AMD 1Ah model 60h series support (2nd attempt)

 - asus-wmi: Prevent spurious rfkill on Asus Zenbook Duo

 - x86-android-tablets: Relax DMI match to cover another model

* tag 'platform-drivers-x86-v6.11-5' of git://git.kernel.org/pub/scm/linux/kernel/git/pdx86/platform-drivers-x86:
  platform/x86: x86-android-tablets: Make Lenovo Yoga Tab 3 X90F DMI match less strict
  platform/x86: asus-wmi: Fix spurious rfkill on UX8406MA
  platform/x86/amd/pmc: Extend support for PMC features on new AMD platform
  platform/x86/amd/pmc: Fix SMU command submission path on new AMD platform
2024-08-29 07:12:02 +12:00
Hans de Goede
a3379eca24
platform/x86: x86-android-tablets: Make Lenovo Yoga Tab 3 X90F DMI match less strict
There are 2G and 4G RAM versions of the Lenovo Yoga Tab 3 X90F and it
turns out that the 2G version has a DMI product name of
"CHERRYVIEW D1 PLATFORM" where as the 4G version has
"CHERRYVIEW C0 PLATFORM". The sys-vendor + product-version check are
unique enough that the product-name check is not necessary.

Drop the product-name check so that the existing DMI match for the 4G
RAM version also matches the 2G RAM version.

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Link: https://lore.kernel.org/r/20240825132415.8307-1-hdegoede@redhat.com
Reviewed-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>
Signed-off-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>
2024-08-26 14:34:33 +03:00
Mathieu Fenniak
9286dfd573
platform/x86: asus-wmi: Fix spurious rfkill on UX8406MA
The Asus Zenbook Duo (UX8406MA) has a keyboard which can be
placed on the laptop to connect it via USB, or can be removed from the
laptop to reveal a hidden secondary display in which case the keyboard
operates via Bluetooth.

When it is placed on the secondary display to connect via USB, it emits
a keypress for a wireless disable. This causes the rfkill system to be
activated disconnecting the current wifi connection, which doesn't
reflect the user's true intention.

Detect this hardware and suppress any wireless switches from the
keyboard; this keyboard does not have a wireless toggle capability so
these presses are always spurious.

Signed-off-by: Mathieu Fenniak <mathieu@fenniak.net>
Reviewed-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>
Link: https://lore.kernel.org/r/20240823135630.128447-1-mathieu@fenniak.net
Signed-off-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>
2024-08-26 14:34:00 +03:00
Linus Torvalds
b09f6ca99c ACPI fix for 6.11-rc5
Fix backlight control on a Dell All In One system where a backlight
 controller board is attached to a UART port and the dell-uart-backlight
 driver binds to it, but the backlight is actually controlled by other
 means (Hans de Goede).
 -----BEGIN PGP SIGNATURE-----
 
 iQJGBAABCAAwFiEE4fcc61cGeeHD/fCwgsRv/nhiVHEFAmbIm3kSHHJqd0Byand5
 c29ja2kubmV0AAoJEILEb/54YlRx08oP/3/rEtXJKzViI6nSmAJ5db9HVh8NiOVL
 aVuJRjnDnNEw/rv2M8mlpb/bEmDsH71d+9BeIrD9/zgtU930RlbJvrCIWngBQJE8
 xUDQyTh4i9ZOQouV/Er06DLB/j8Ibhma9URlVtFC5eI94Gg21qHGbU7M2/UO9RtW
 YIt+dx75S2KUKxhv9rqbvDg5LbFuBiNSThxljfNsf0fEdKB1kHIjZ2cH7tDFhk2s
 4KyrqcElyXgczByLUNnmGTMfT/+RyqfOLI1pCEID3YPgBA0n4tAF0YXuxadYktH1
 toDMRLTDHJ5smR5ee6HgHdcJoWZ9lTj80pdmZlFmGpUO04mBqmSFV2VZc1amonW5
 Z/jX19vzBJu6ywnE9lBO0cm26WBmj/4ImvzWgggHTTp17T940iU0F1BYCSmrs+O9
 EnC8cocUSeWKwj/1HNiFmPRttORS2XEiWJKi1jAAC+Dk+9xzRIhnPiMFT5b137kO
 g/kVs97RN3od2EyYK4fjU/drS9PzZVa7c42hRDTeBLy0zZaXDCgjYrKvekbVkZL9
 P/D4miz6o1P6+q4h/DzJfUDhAq5myyZzuCx5s3Dts9CHkqr5yZEYUyTGkodBU5Ic
 I28XUON7VqOOr2EVGCedh0zne0Mps9ev5SMbcYWpMO+tY3pWda7qK6Z76sGpQf5A
 PSsz1ja68uJL
 =mPqe
 -----END PGP SIGNATURE-----

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

Pull ACPI fix from Rafael Wysocki:
 "Fix backlight control on a Dell All In One system where a backlight
  controller board is attached to a UART port and the dell-uart
  backlight driver binds to it, but the backlight is actually controlled
  by other means (Hans de Goede)"

* tag 'acpi-6.11-rc5' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm:
  ACPI: video: Add backlight=native quirk for Dell OptiPlex 7760 AIO
  platform/x86: dell-uart-backlight: Use acpi_video_get_backlight_type()
  ACPI: video: Add Dell UART backlight controller detection
2024-08-24 07:39:35 +08:00
Shyam Sundar S K
a24cd5cfd1
platform/x86/amd/pmc: Extend support for PMC features on new AMD platform
PMC driver has capability to get the idle mask values and STB data from
the PMFW. Extend this support to the platforms that belong to family 1Ah
model 60h series.

Co-developed-by: Sanket Goswami <Sanket.Goswami@amd.com>
Signed-off-by: Sanket Goswami <Sanket.Goswami@amd.com>
Signed-off-by: Shyam Sundar S K <Shyam-sundar.S-k@amd.com>
Reviewed-by: Mario Limonciello <mario.limonciello@amd.com>
Link: https://lore.kernel.org/r/20240822095357.395808-2-Shyam-sundar.S-k@amd.com
Reviewed-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>
Signed-off-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>
2024-08-23 16:13:10 +03:00
Shyam Sundar S K
ba7b6633e9
platform/x86/amd/pmc: Fix SMU command submission path on new AMD platform
The commit 426463d94d ("platform/x86/amd/pmc: Send OS_HINT command for
new AMD platform") was introduced to enable sending mailbox commands to
PMFW on newer platforms. However, it was later discovered that the commit
did not configure the correct message port ID (i.e., S2D or PMC). Without
this configuration, all command submissions to PMFW are treated as
invalid, leading to command failures.

To address this issue, the CPU ID association for the new platform needs
to be added in amd_pmc_get_ip_info(). This ensures that the correct SMU
port IDs are selected.

Fixes: 426463d94d ("platform/x86/amd/pmc: Send OS_HINT command for new AMD platform")
Co-developed-by: Sanket Goswami <Sanket.Goswami@amd.com>
Signed-off-by: Sanket Goswami <Sanket.Goswami@amd.com>
Signed-off-by: Shyam Sundar S K <Shyam-sundar.S-k@amd.com>
Reviewed-by: Mario Limonciello <mario.limonciello@amd.com>
Link: https://lore.kernel.org/r/20240822095357.395808-1-Shyam-sundar.S-k@amd.com
Reviewed-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>
Signed-off-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>
2024-08-23 16:13:04 +03:00
Rafael J. Wysocki
13b6b63d6b platform/x86: acerhdf: Use the .should_bind() thermal zone callback
Make the acerhdf driver use the .should_bind() thermal zone
callback to provide the thermal core with the information on whether or
not to bind the given cooling device to the given trip point in the
given thermal zone.  If it returns 'true', the thermal core will bind
the cooling device to the trip and the corresponding unbinding will be
taken care of automatically by the core on the removal of the involved
thermal zone or cooling device.

The previously existing acerhdf_bind() function bound cooling devices
to thermal trip point 0 only, so the new callback needs to return 'true'
for trip point 0.  However, it is straightforward to observe that trip
point 0 is an active trip point and the only other trip point in the
driver's thermal zone is a critical one, so it is sufficient to return
'true' from that callback if the type of the given trip point is
THERMAL_TRIP_ACTIVE.

Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Acked-by: Hans de Goede <hdegoede@redhat.com>
Tested-by: Peter Kästle <peter@piie.net>
Reviewed-by: Daniel Lezcano <daniel.lezcano@linaro.org>
Link: https://patch.msgid.link/3779411.MHq7AAxBmi@rjwysocki.net
2024-08-22 17:43:14 +02:00
Linus Torvalds
872cf28b8d platform-drivers-x86 for v6.11-4
Changes:
 - ISST: Fix an error-handling corner case.
 - platform/surface: aggregator: Minor corner case fix and new HW support.
 
 The following is an automated shortlog grouped by driver:
 
 asus-wmi:
  -  Add quirk for ROG Ally X
 
 ISST:
  -  Fix return value on last invalid resource
 
 surface: aggregator:
  -  Fix warning when controller is destroyed in probe
 
 surface: aggregator_registry:
  -  Add fan and thermal sensor support for Surface Laptop 5
  -  Add support for Surface Laptop 6
  -  Add support for Surface Laptop Go 3
  -  Add support for Surface Laptop Studio 2
  -  Add Support for Surface Pro 10
 -----BEGIN PGP SIGNATURE-----
 
 iHUEABYIAB0WIQSCSUwRdwTNL2MhaBlZrE9hU+XOMQUCZsWaDwAKCRBZrE9hU+XO
 MRSzAQDvXc77garXWSvOxZgHgReoASYgeFHJar7V96VQTH76HQEA1qJ/8+SN8CAw
 Voc10wW+FniTh3FY0f5rmgr8tPXh9Q0=
 =zn/Q
 -----END PGP SIGNATURE-----

Merge tag 'platform-drivers-x86-v6.11-4' of git://git.kernel.org/pub/scm/linux/kernel/git/pdx86/platform-drivers-x86

Pull x86 platform driver fixes from Ilpo Järvinen:

 - ISST: Fix an error-handling corner case

 - platform/surface: aggregator: Minor corner case fix and new HW
   support

* tag 'platform-drivers-x86-v6.11-4' of git://git.kernel.org/pub/scm/linux/kernel/git/pdx86/platform-drivers-x86:
  platform/x86: ISST: Fix return value on last invalid resource
  platform/surface: aggregator: Fix warning when controller is destroyed in probe
  platform/surface: aggregator_registry: Add support for Surface Laptop 6
  platform/surface: aggregator_registry: Add fan and thermal sensor support for Surface Laptop 5
  platform/surface: aggregator_registry: Add support for Surface Laptop Studio 2
  platform/surface: aggregator_registry: Add support for Surface Laptop Go 3
  platform/surface: aggregator_registry: Add Support for Surface Pro 10
  platform/x86: asus-wmi: Add quirk for ROG Ally X
2024-08-22 06:34:27 +08:00
Srinivas Pandruvada
46ee21e9f5
platform/x86: ISST: Fix return value on last invalid resource
When only the last resource is invalid, tpmi_sst_dev_add() is returing
error even if there are other valid resources before. This function
should return error when there are no valid resources.

Here tpmi_sst_dev_add() is returning "ret" variable. But this "ret"
variable contains the failure status of last call to sst_main(), which
failed for the invalid resource. But there may be other valid resources
before the last entry.

To address this, do not update "ret" variable for sst_main() return
status.

If there are no valid resources, it is already checked for by !inst
below the loop and -ENODEV is returned.

Fixes: 9d1d36268f ("platform/x86: ISST: Support partitioned systems")
Signed-off-by: Srinivas Pandruvada <srinivas.pandruvada@linux.intel.com>
Cc: stable@vger.kernel.org # 6.10+
Link: https://lore.kernel.org/r/20240816163626.415762-1-srinivas.pandruvada@linux.intel.com
Reviewed-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>
Signed-off-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>
2024-08-20 14:19:09 +03:00
Hans de Goede
b5f0943001 platform/x86: dell-uart-backlight: Use acpi_video_get_backlight_type()
The dell-uart-backlight driver supports backlight control on Dell All In
One (AIO) models using a backlight controller board connected to an UART.

In DSDT this uart port will be defined as:

   Name (_HID, "DELL0501")
   Name (_CID, EisaId ("PNP0501")

Now the first AIO has turned up which has not only the DSDT bits for this,
but also an actual controller attached to the UART, yet it is not using
this controller for backlight control.

Use the acpi_video_get_backlight_type() function from the ACPI video-detect
code to check if the dell-uart-backlight driver should actually be used.
This allows reusing the existing ACPI video-detect infra to override
the backlight control method on the commandline or with DMI quirks.

Fixes: 484bae9e4d ("platform/x86: Add new Dell UART backlight driver")
Cc: All applicable <stable@vger.kernel.org>
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Reviewed-by: Andy Shevchenko <andy@kernel.org>
Link: https://patch.msgid.link/20240814190159.15650-3-hdegoede@redhat.com
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
2024-08-19 15:58:45 +02:00
Maximilian Luz
bc923d594d
platform/surface: aggregator: Fix warning when controller is destroyed in probe
There is a small window in ssam_serial_hub_probe() where the controller
is initialized but has not been started yet. Specifically, between
ssam_controller_init() and ssam_controller_start(). Any failure in this
window, for example caused by a failure of serdev_device_open(),
currently results in an incorrect warning being emitted.

In particular, any failure in this window results in the controller
being destroyed via ssam_controller_destroy(). This function checks the
state of the controller and, in an attempt to validate that the
controller has been cleanly shut down before we try and deallocate any
resources, emits a warning if that state is not SSAM_CONTROLLER_STOPPED.

However, since we have only just initialized the controller and have not
yet started it, its state is SSAM_CONTROLLER_INITIALIZED. Note that this
is the only point at which the controller has this state, as it will
change after we start the controller with ssam_controller_start() and
never revert back. Further, at this point no communication has taken
place and the sender and receiver threads have not been started yet (and
we may not even have an open serdev device either).

Therefore, it is perfectly safe to call ssam_controller_destroy() with a
state of SSAM_CONTROLLER_INITIALIZED. This, however, means that the
warning currently being emitted is incorrect. Fix it by extending the
check.

Fixes: c167b9c7e3 ("platform/surface: Add Surface Aggregator subsystem")
Signed-off-by: Maximilian Luz <luzmaximilian@gmail.com>
Link: https://lore.kernel.org/r/20240811124645.246016-1-luzmaximilian@gmail.com
Reviewed-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>
Signed-off-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>
2024-08-13 11:20:19 +03:00
Maximilian Luz
99ae7b9ba0
platform/surface: aggregator_registry: Add support for Surface Laptop 6
Add SAM client device nodes for the Surface Laptop Studio 6 (SL6). The
SL6 is similar to the SL5, with the typical battery/AC, platform
profile, and HID nodes. It also has support for the newly supported fan
interface.

Signed-off-by: Maximilian Luz <luzmaximilian@gmail.com>
Link: https://lore.kernel.org/r/20240811131948.261806-6-luzmaximilian@gmail.com
Reviewed-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>
Signed-off-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>
2024-08-13 11:01:20 +03:00
Maximilian Luz
002adda09b
platform/surface: aggregator_registry: Add fan and thermal sensor support for Surface Laptop 5
The EC on the Surface Laptop 5 exposes the fan interface. With the
recently introduced driver for it, we can now also enable it here. In
addition, also enable the thermal sensor interface.

Signed-off-by: Maximilian Luz <luzmaximilian@gmail.com>
Link: https://lore.kernel.org/r/20240811131948.261806-5-luzmaximilian@gmail.com
Reviewed-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>
Signed-off-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>
2024-08-13 11:01:18 +03:00
Maximilian Luz
28d04b4a2c
platform/surface: aggregator_registry: Add support for Surface Laptop Studio 2
Add SAM client device nodes for the Surface Laptop Studio 2 (SLS2). The
SLS2 is quite similar to the SLS1, but it does not provide the touchpad
as a SAM-HID device. Therefore, add a new node group for the SLS2 and
update the comments accordingly. In addition, it uses the new fan
control interface.

Signed-off-by: Maximilian Luz <luzmaximilian@gmail.com>
Link: https://lore.kernel.org/r/20240811131948.261806-4-luzmaximilian@gmail.com
Reviewed-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>
Signed-off-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>
2024-08-13 11:01:16 +03:00
Maximilian Luz
ed235163c3
platform/surface: aggregator_registry: Add support for Surface Laptop Go 3
Add SAM client device nodes for the Surface Laptop Go 3. It seems to use
the same SAM client devices as the Surface Laptop Go 1 and 2, so re-use
their node group.

Signed-off-by: Maximilian Luz <luzmaximilian@gmail.com>
Link: https://lore.kernel.org/r/20240811131948.261806-3-luzmaximilian@gmail.com
Reviewed-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>
Signed-off-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>
2024-08-13 11:01:14 +03:00
Maximilian Luz
9c8e022567
platform/surface: aggregator_registry: Add Support for Surface Pro 10
Add SAM client device nodes for the Surface Pro 10. It seems to use the
same SAM client devices as the Surface Pro 9, so re-use its node group.

Signed-off-by: Maximilian Luz <luzmaximilian@gmail.com>
Link: https://lore.kernel.org/r/20240811131948.261806-2-luzmaximilian@gmail.com
Reviewed-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>
Signed-off-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>
2024-08-13 11:01:11 +03:00
Luke D. Jones
d2dfed310a
platform/x86: asus-wmi: Add quirk for ROG Ally X
The new ROG Ally X functions the same as the previus model so we can use
the same method to ensure the MCU USB devices wake and reconnect
correctly.

Given that two devices marks the start of a trend, this patch also adds
a quirk table to make future additions easier if the MCU is the same.

Signed-off-by: Luke D. Jones <luke@ljones.dev>
Reviewed-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>
Link: https://lore.kernel.org/r/20240805234603.38736-1-luke@ljones.dev
Signed-off-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>
2024-08-13 11:00:26 +03:00
Linus Torvalds
d74da84604 platform-drivers-x86 for v6.11-3
Fixes:
 - ideapad-laptop / lenovo-ymc: Protect VPC calls with a mutex
 - amd/pmf: Query HPD data also when ALS is disabled
 
 The following is an automated shortlog grouped by driver:
 
 amd/pmf:
  -  Fix to Update HPD Data When ALS is Disabled
 
 ideapad-laptop:
  -  add a mutex to synchronize VPC commands
  -  introduce a generic notification chain
  -  move ymc_trigger_ec from lenovo-ymc
 -----BEGIN PGP SIGNATURE-----
 
 iHUEABYIAB0WIQSCSUwRdwTNL2MhaBlZrE9hU+XOMQUCZrnHXQAKCRBZrE9hU+XO
 MTcjAP91S8mHmZ81J1029xMC8qKwu4nY1G+bURHphTbqLFTg6gD/XFuqdUKT2n0+
 GgGg7FV+GrS8rZT1oqqRI/2OXg2LugU=
 =1XJi
 -----END PGP SIGNATURE-----

Merge tag 'platform-drivers-x86-v6.11-3' of git://git.kernel.org/pub/scm/linux/kernel/git/pdx86/platform-drivers-x86

Pull x86 platform driver fixes from Ilpo Järvinen:
 "While the ideapad concurrency fix itself is relatively
  straightforward, it required moving code around and adding a bit of
  supporting infrastructure to have a clean inter-driver interface. This
  shows up in the diffstats.

   - ideapad-laptop / lenovo-ymc: Protect VPC calls with a mutex

   - amd/pmf: Query HPD data also when ALS is disabled"

* tag 'platform-drivers-x86-v6.11-3' of git://git.kernel.org/pub/scm/linux/kernel/git/pdx86/platform-drivers-x86:
  platform/x86: ideapad-laptop: add a mutex to synchronize VPC commands
  platform/x86: ideapad-laptop: move ymc_trigger_ec from lenovo-ymc
  platform/x86: ideapad-laptop: introduce a generic notification chain
  platform/x86/amd/pmf: Fix to Update HPD Data When ALS is Disabled
2024-08-12 08:21:52 -07:00
Linus Torvalds
0f135d3e30 ARM: soc fixes for 6.11, part 1
There are three sets of patches for the soc tree:
 
  - Marek Behún addresses multiple build time regressions caused
    by changes to the cznic turris-omnia support
 
  - Dmitry Torokhov fixes a regression in the legacy "gumstix"
    board code he cleaned up earlier
 
  - The TI K3 maintainers found multiple bugs in the in gpio,
    audio and pcie devicetree nodes.
 -----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCgAdFiEEiK/NIGsWEZVxh/FrYKtH/8kJUicFAma2O9cACgkQYKtH/8kJ
 Uic5lxAAm+b0+LEFjs3YRJgb0EM6WIOYLG1MDoaHO/jvX4eQuTxvaTXTMBqpZlnU
 q2L+rMVG5G3u8y+ltw+v5BiOS9OaUYyad0isX/vjeNKa+O4ijbQTZ0+CSGXzsnI0
 VaCgpyd0FmksHTsCLYg6/acb7rHJnOuDdPLWAB45+5ul4J574HFhE06R83kma4IH
 nDacY4UZjMB9+o8Dpd3ZU61ifYCwWGrrGobZtVyevqpC2wFsKkRb8O7Ygp8AENzQ
 3PEeEnorwTXvxnV3tLIZnDDhCXesxBZz0Jk/Z27vPTvGZ+fx+TTPtmQiH1oeR272
 1oI1cHB23XVeai2rung4mt8GfhXFWd9t8Jto/wM1+vIqeWkyBw/9J2sUfKPeAWIT
 SwtmYksziAhdG4huWvA7ANOxOQoVWD5DoczkIoJ+wbV7x9OsByZz//y5PrAo0F6q
 THrlvPYM1UyMhudKmFUV6yg93HFH8oLqNt0Llet/5XsCFjB6oQY1OSEur9b5aRDl
 24UgQICqvfWXkFUUnqRpYP4x06bglUZS28+33Za91oA8QVmT8W9uE4IjemIKqPN7
 +FZrqnfFdflDGpFUHsnSqFqfF+62EUXvwvzuLagJT6QLp1skhiyFSIlI+22FPcJx
 ooa403e9moZcKKKdgUwK75BjGZPnqHlrxS39qVMnKL89e/p97sc=
 =jBZN
 -----END PGP SIGNATURE-----

Merge tag 'arm-fixes-6.11-1' of git://git.kernel.org/pub/scm/linux/kernel/git/soc/soc

Pull ARM SoC fixes from Arnd Bergmann:
 "There are three sets of patches for the soc tree:

   - Marek Behún addresses multiple build time regressions caused by
     changes to the cznic turris-omnia support

   - Dmitry Torokhov fixes a regression in the legacy "gumstix" board
     code he cleaned up earlier

   - The TI K3 maintainers found multiple bugs in the in gpio, audio and
     pcie devicetree nodes"

* tag 'arm-fixes-6.11-1' of git://git.kernel.org/pub/scm/linux/kernel/git/soc/soc:
  ARM: pxa/gumstix: fix attaching properties to vbus gpio device
  doc: platform: cznic: turris-omnia-mcu: Use double backticks for attribute value
  doc: platform: cznic: turris-omnia-mcu: Fix sphinx-build warning
  platform: cznic: turris-omnia-mcu: Make GPIO code optional
  platform: cznic: turris-omnia-mcu: Make poweroff and wakeup code optional
  platform: cznic: turris-omnia-mcu: Make TRNG code optional
  platform: cznic: turris-omnia-mcu: Make watchdog code optional
  arm64: dts: ti: k3-j784s4-main: Correct McASP DMAs
  arm64: dts: ti: k3-j722s: Fix gpio-range for main_pmx0
  arm64: dts: ti: k3-am62p: Fix gpio-range for main_pmx0
  arm64: dts: ti: k3-am62p: Add gpio-ranges for mcu_gpio0
  arm64: dts: ti: k3-am62-verdin-dahlia: Keep CTRL_SLEEP_MOCI# regulator on
  arm64: dts: ti: k3-j784s4-evm: Consolidate serdes0 references
  arm64: dts: ti: k3-j784s4-evm: Assign only lanes 0 and 1 to PCIe1
2024-08-09 10:06:43 -07:00
Gergo Koteles
7cc06e7294
platform/x86: ideapad-laptop: add a mutex to synchronize VPC commands
Calling VPC commands consists of several VPCW and VPCR ACPI calls.
These calls and their results can get mixed up if they are called
simultaneously from different threads, like acpi notify handler,
sysfs, debugfs, notification chain.

The commit e2ffcda162 ("ACPI: OSL: Allow Notify () handlers to run on
all CPUs") made the race issues much worse than before it but some
races were possible even before that commit.

Add a mutex to synchronize VPC commands.

Fixes: e2ffcda162 ("ACPI: OSL: Allow Notify () handlers to run on all CPUs")
Fixes: e82882cdd2 ("platform/x86: Add driver for Yoga Tablet Mode switch")
Signed-off-by: Gergo Koteles <soyer@irl.hu>
Link: https://lore.kernel.org/r/f26782fa1194ad11ed5d9ba121a804e59b58b026.1721898747.git.soyer@irl.hu
Reviewed-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>
Signed-off-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>
2024-08-08 15:03:09 +03:00
Gergo Koteles
cde7886b35
platform/x86: ideapad-laptop: move ymc_trigger_ec from lenovo-ymc
Some models need to trigger the EC after each YMC event for the yoga
mode control to work properly. EC triggering consist of a VPC call from
the lenovo-ymc module. Except for this, all VPC calls are in the
ideapad-laptop module.

Since ideapad-laptop has a notification chain, a new YMC_EVENT action
can be added and triggered from the lenovo-ymc module. Then the
ideapad-laptop can trigger the EC.

If the triggering is in the ideapad-laptop module, then the ec_trigger
module parameter should be there as well.

Move the ymc_trigger_ec functionality and the ec_trigger module
parameter to the ideapad-laptop module.

Signed-off-by: Gergo Koteles <soyer@irl.hu>
Reviewed-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>
Link: https://lore.kernel.org/r/d980ab3ac32b5e554f456b0ff17279bfdbe2a203.1721898747.git.soyer@irl.hu
Signed-off-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>
2024-08-08 14:56:44 +03:00
Gergo Koteles
613e3900c2
platform/x86: ideapad-laptop: introduce a generic notification chain
There are several cases where a notification chain can simplify Lenovo
WMI drivers.

Add a generic notification chain into ideapad-laptop.

Signed-off-by: Gergo Koteles <soyer@irl.hu>
Link: https://lore.kernel.org/r/c5a43efae8a32bd034c3d19c0a686941347575a7.1721898747.git.soyer@irl.hu
Reviewed-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>
Signed-off-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>
2024-08-08 14:56:42 +03:00
Shyam Sundar S K
78296429e2
platform/x86/amd/pmf: Fix to Update HPD Data When ALS is Disabled
If the Ambient Light Sensor (ALS) is disabled, the current code in the PMF
driver does not query for Human Presence Detection (HPD) data in
amd_pmf_get_sensor_info(). As a result, stale HPD data is used by PMF-TA
to evaluate policy conditions, leading to unexpected behavior in the policy
output actions.

To resolve this issue, modify the PMF driver to query HPD data
independently of ALS.

Since user_present is a boolean, modify the current code to return true if
the user is present and false if the user is away or if the sensor is not
detected, and report this status to the PMF TA firmware accordingly.

With this change, amd_pmf_get_sensor_info() now returns void instead of
int.

Fixes: cedecdba60 ("platform/x86/amd/pmf: Get ambient light information from AMD SFH driver")
Co-developed-by: Patil Rajesh Reddy <Patil.Reddy@amd.com>
Signed-off-by: Patil Rajesh Reddy <Patil.Reddy@amd.com>
Signed-off-by: Shyam Sundar S K <Shyam-sundar.S-k@amd.com>
Link: https://lore.kernel.org/r/20240730142316.3846259-1-Shyam-sundar.S-k@amd.com
Reviewed-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>
Signed-off-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>
2024-08-08 14:53:35 +03:00
Marek Behún
af340b7aa2 platform: cznic: turris-omnia-mcu: Make GPIO code optional
Make the GPIO part of the driver optional, under a boolean config
option. Move the dependency to GPIOLIB and OF and the selection of
GPIOLIB_IRQCHIP to this new option.

This makes the turris-omnia-mcu driver available for compilation even if
GPIOLIB or OF are disabled.

Fixes: ed46f1f773 ("platform: cznic: turris-omnia-mcu: fix Kconfig dependencies")
Signed-off-by: Marek Behún <kabel@kernel.org>
Link: https://lore.kernel.org/r/20240719085756.30598-5-kabel@kernel.org
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
2024-08-07 14:43:54 +02:00
Marek Behún
74a22fced5 platform: cznic: turris-omnia-mcu: Make poweroff and wakeup code optional
Make the system poweroff and RTC wakeup part of the driver optional,
under a boolean config option. Move the dependency to RTC_CLASS to this
new option.

This makes the turris-omnia-mcu driver available for compilation even if
RTC_CLASS is disabled.

Fixes: ed46f1f773 ("platform: cznic: turris-omnia-mcu: fix Kconfig dependencies")
Signed-off-by: Marek Behún <kabel@kernel.org>
Link: https://lore.kernel.org/r/20240719085756.30598-4-kabel@kernel.org
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
2024-08-07 14:43:54 +02:00
Marek Behún
c7da0d4e33 platform: cznic: turris-omnia-mcu: Make TRNG code optional
Make the TRNG part of the driver optional, under a boolean config
option.

This makes the driver turris-omnia-mcu available for compilation even if
HW_RANDOM is disabled.

Fixes: ed46f1f773 ("platform: cznic: turris-omnia-mcu: fix Kconfig dependencies")
Signed-off-by: Marek Behún <kabel@kernel.org>
Link: https://lore.kernel.org/r/20240719085756.30598-3-kabel@kernel.org
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
2024-08-07 14:43:54 +02:00
Marek Behún
019f87f1ef platform: cznic: turris-omnia-mcu: Make watchdog code optional
Make the watchdog part of the driver optional, under a boolean config
option. Move the dependency to WATCHDOG to this new option, and change
the WATCHDOG_CORE dependency to selection, as is done in most watchdog
drivers.

This makes the turris-omnia-mcu driver available for compilation even if
WATCHDOG is disabled.

Fixes: ed46f1f773 ("platform: cznic: turris-omnia-mcu: fix Kconfig dependencies")
Signed-off-by: Marek Behún <kabel@kernel.org>
Link: https://lore.kernel.org/r/20240719085756.30598-2-kabel@kernel.org
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
2024-08-07 14:43:54 +02:00
Linus Torvalds
eb5e56d149 platform-drivers-x86 for v6.11-2
Fixes:
 - intel-vbtn: ACPI notifier racing with itself.
 - intel/ifs: Init local variable to cover a timeout corner case.
 - WMI docs spelling
 
 New HW Support:
 - amd/{pmc,pmf}: AMD 1Ah model 60h series.
 - amd/pmf: SPS quirk support for ASUS ROG Ally X
 
 The following is an automated shortlog grouped by driver:
 
 amd/pmc:
  -  Send OS_HINT command for new AMD platform
 
 amd/pmf:
  -  Add new ACPI ID AMDI0107
 
 amd: pmf:
  -  Add quirk for ROG Ally X
 
 intel/ifs:
  -  Initialize union ifs_status to zero
 
 intel-vbtn:
  -  Protect ACPI notify handler against recursion
 
 msi-wmi-platform:
  -  Fix spelling mistakes
 -----BEGIN PGP SIGNATURE-----
 
 iHUEABYIAB0WIQSCSUwRdwTNL2MhaBlZrE9hU+XOMQUCZrHFkgAKCRBZrE9hU+XO
 Mb3RAP9M0BfrdTBGxgrnR1NNGkzNWUvFPcw1OkWD+ceCpQVhAQEAoPtXnlwvn+6C
 /1pKcHGHy7zjyeQINTrKBoI1KsdoCQM=
 =hL5i
 -----END PGP SIGNATURE-----

Merge tag 'platform-drivers-x86-v6.11-2' of git://git.kernel.org/pub/scm/linux/kernel/git/pdx86/platform-drivers-x86

Pull x86 platform driver fixes from Ilpo Järvinen:
 "Fixes:

   - Fix ACPI notifier racing with itself (intel-vbtn)

   - Initialize local variable to cover a timeout corner case
     (intel/ifs)

   - WMI docs spelling

  New device IDs:

   - amd/{pmc,pmf}: AMD 1Ah model 60h series.

   - amd/pmf: SPS quirk support for ASUS ROG Ally X"

* tag 'platform-drivers-x86-v6.11-2' of git://git.kernel.org/pub/scm/linux/kernel/git/pdx86/platform-drivers-x86:
  platform/x86/intel/ifs: Initialize union ifs_status to zero
  platform/x86: msi-wmi-platform: Fix spelling mistakes
  platform/x86/amd/pmf: Add new ACPI ID AMDI0107
  platform/x86/amd/pmc: Send OS_HINT command for new AMD platform
  platform/x86/amd: pmf: Add quirk for ROG Ally X
  platform/x86: intel-vbtn: Protect ACPI notify handler against recursion
2024-08-06 07:52:10 -07:00
Kuppuswamy Sathyanarayanan
3114f77e94
platform/x86/intel/ifs: Initialize union ifs_status to zero
If the IFS scan test exits prematurely due to a timeout before
completing a single run, the union ifs_status remains uninitialized,
leading to incorrect test status reporting. To prevent this, always
initialize the union ifs_status to zero.

Fixes: 2b40e654b7 ("platform/x86/intel/ifs: Add scan test support")
Suggested-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>
Reviewed-by: Jithu Joseph <jithu.joseph@intel.com>
Reviewed-by: Ashok Raj <ashok.raj@intel.com>
Signed-off-by: Kuppuswamy Sathyanarayanan <sathyanarayanan.kuppuswamy@linux.intel.com>
Link: https://lore.kernel.org/r/20240730155930.1754744-1-sathyanarayanan.kuppuswamy@linux.intel.com
Reviewed-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>
Signed-off-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>
2024-07-31 12:37:34 +03:00
Linus Torvalds
c91a7dee05 chrome-platform fixes for v6.11-rc2
Fix a race condition that sends multiple host commands at a time.
 -----BEGIN PGP SIGNATURE-----
 
 iIkEABYKADEWIQS0yQeDP3cjLyifNRUrxTEGBto89AUCZqjUCxMcdHp1bmdiaUBr
 ZXJuZWwub3JnAAoJECvFMQYG2jz0eEwA/3GWRwO2WHsD5QwpXkUo9KgfYPOuyBUS
 Z7eden+7DLeAAQDGnFKNiD7uzfcYKd48SI4crb5ry0+++zqrj0/XZdXPCw==
 =n4ok
 -----END PGP SIGNATURE-----

Merge tag 'chrome-platform-fixes-for-v6.11-rc2' of git://git.kernel.org/pub/scm/linux/kernel/git/chrome-platform/linux

Pull chrome-platform fix from Tzung-Bi Shih:
 "Fix a race condition that sends multiple host commands at a time"

* tag 'chrome-platform-fixes-for-v6.11-rc2' of git://git.kernel.org/pub/scm/linux/kernel/git/chrome-platform/linux:
  platform/chrome: cros_ec_proto: Lock device when updating MKBP version
2024-07-30 12:53:52 -07:00