summaryrefslogtreecommitdiff
AgeCommit message (Collapse)AuthorFilesLines
2026-07-27ASoC: Use named initializers for platform_device_id arraysUwe Kleine-König (The Capable Hub)3-6/+6
Named initializers are better readable and more robust to changes of the struct definition. This robustness is relevant for a planned change to struct platform_device_id replacing .driver_data by an anonymous union. While touching these arrays unify spacing and usage of commas. Signed-off-by: Uwe Kleine-König (The Capable Hub) <u.kleine-koenig@baylibre.com> Reviewed-by: Charles Keepax <ckeepax@opensource.cirrus.com> Link: https://patch.msgid.link/a76e26aa4edb901b4bea684919463b2243dd8d9d.1784528081.git.u.kleine-koenig@baylibre.com Signed-off-by: Mark Brown <broonie@kernel.org>
2026-07-27ASoC: amd: acp: Unify code style for platform_device_id arrayUwe Kleine-König (The Capable Hub)1-7/+7
- Add a trailing comma for initializers unless the closing brace is on the same line and for the list terminator; - Use a single space in the list terminator; Acked-by: Cezary Rojewski <cezary.rojewski@intel.com> Signed-off-by: Uwe Kleine-König (The Capable Hub) <u.kleine-koenig@baylibre.com> Reviewed-by: Vijendar Mukunda <Vijendar.Mukunda@amd.com> Link: https://patch.msgid.link/08137cf5b3cdd0cc2e00da32256664f3cb9b1e4e.1784528081.git.u.kleine-koenig@baylibre.com Signed-off-by: Mark Brown <broonie@kernel.org>
2026-07-27ASoC: amd: acp: Use named initializers for platform_device_id arraysUwe Kleine-König (The Capable Hub)2-4/+4
Named initializers are better readable and more robust to changes of the struct definition. This robustness is relevant for a planned change to struct platform_device_id replacing .driver_data by an anonymous union. While touching these arrays unify spacing and usage of commas. Signed-off-by: Uwe Kleine-König (The Capable Hub) <u.kleine-koenig@baylibre.com> Reviewed-by: Vijendar Mukunda <Vijendar.Mukunda@amd.com> Link: https://patch.msgid.link/a23fa9f649eaab706c704b671527c238f211ee26.1784528081.git.u.kleine-koenig@baylibre.com Signed-off-by: Mark Brown <broonie@kernel.org>
2026-07-27ASoC: renesas: fsi: Drop platform probing metadataUwe Kleine-König (The Capable Hub)1-2/+2
Since commit 38d3273075d6 ("ASoC: renesas: fsi: remove platform data style support") probing using the traditional platform bus matching isn't supported any more. Drop the platform_device_id entries that should have been removed in the above commit. Note that keeping the empty array results in the driver not matching on "fsi-pcm-audio" (i.e. the driver name). While touching that array, use a single space and no trailing comma for the list terminator, which is the most used style for this. Signed-off-by: Uwe Kleine-König (The Capable Hub) <u.kleine-koenig@baylibre.com> Link: https://patch.msgid.link/c79fa0d31abc0c80fbd7b4ec94d95b197ddb9f94.1784528081.git.u.kleine-koenig@baylibre.com Signed-off-by: Mark Brown <broonie@kernel.org>
2026-07-27ASoC: codecs: mt6357: Drop unused assignment of platform_device_id driver dataUwe Kleine-König (The Capable Hub)1-2/+2
The driver explicitly sets the .driver_data member of struct platform_device_id to zero without relying on that value. Drop this unused assignment. While touching this array unify spacing, use a named initializer for .name and drop a trailing comma after the list terminator. Signed-off-by: Uwe Kleine-König (The Capable Hub) <u.kleine-koenig@baylibre.com> Link: https://patch.msgid.link/724af6f60ed9420d5513724d126d70f22e319c91.1784528081.git.u.kleine-koenig@baylibre.com Signed-off-by: Mark Brown <broonie@kernel.org>
2026-07-27thermal/drivers/airoha: Add support for AN7583 Thermal SensorChristian Marangi1-4/+157
Add support for Airoha AN7583 Thermal driver. This apply similar logic on how to read the temperature but totally drop support for the PTP_THERMAL subsystem. PTP_THERMAL subsystem was a way to trigger trip point from hardware by configuring how to read the temperature internally. This subsystem has been totally removed from Airoha AN7583 permitting only to read the temperature. The SoC support up to 3 sensor but the original driver always read the BGA sensor hence it's currently implemented reading only this specific sensor. Reference and values for the other 2 sensor are defined for further implementation if confirmed working. set_thermal_mux() is extended to also address muxing the sensor as AN7583 use a different way to read the temperature from 3 different diode. The EN7581 code is updated to account for these changes. Signed-off-by: Christian Marangi <ansuelsmth@gmail.com> Signed-off-by: Daniel Lezcano <daniel.lezcano@kernel.org> Link: https://patch.msgid.link/20260702094846.17325-8-ansuelsmth@gmail.com
2026-07-27dt-bindings: arm: airoha: Add the chip-scu node for AN7583 SoCChristian Marangi1-0/+14
Document support for Airoha AN7583 chip-scu node. This is similar to Airoha EN7581 with the addition of the presence of thermal sensor in addition to controlling HW PIN and other miscellaneous pheriperals. Signed-off-by: Christian Marangi <ansuelsmth@gmail.com> Signed-off-by: Daniel Lezcano <daniel.lezcano@kernel.org> Reviewed-by: Krzysztof Kozlowski <krzysztof.kozlowski@oss.qualcomm.com> Link: https://patch.msgid.link/20260702094846.17325-7-ansuelsmth@gmail.com
2026-07-27thermal/drivers/airoha: Generalize get_thermal_ADC and set_mux functionChristian Marangi1-12/+44
In preparation for support of Airoha AN7583, generalize get_thermal_ADC() and set_thermal_mux() with the use of reg_field API. This is to take into account the same logic between the current supported SoC and the new one but with different register address. While at it also further improve some comments and move sleep inside the set_thermal_mux function. Signed-off-by: Christian Marangi <ansuelsmth@gmail.com> Signed-off-by: Daniel Lezcano <daniel.lezcano@kernel.org> Link: https://patch.msgid.link/20260702094846.17325-6-ansuelsmth@gmail.com
2026-07-27thermal/drivers/airoha: Generalize probe functionChristian Marangi1-27/+75
In preparation for support of Airoha AN7583, generalize the probe function to address for the 2 SoC difference. Implement a match_data struct where it's possible to define a more specific probe and post_probe function and specific thermal ops and pllrg protect value. Signed-off-by: Christian Marangi <ansuelsmth@gmail.com> Signed-off-by: Daniel Lezcano <daniel.lezcano@kernel.org> Link: https://patch.msgid.link/20260702094846.17325-5-ansuelsmth@gmail.com
2026-07-27thermal/drivers/airoha: Convert to regmap APIChristian Marangi1-32/+45
In preparation for support of Airoha AN7583, convert the driver to regmap API. This is needed as Airoha AN7583 will be based on syscon regmap. Signed-off-by: Christian Marangi <ansuelsmth@gmail.com> Signed-off-by: Daniel Lezcano <daniel.lezcano@kernel.org> Link: https://patch.msgid.link/20260702094846.17325-4-ansuelsmth@gmail.com
2026-07-27thermal/drivers/airoha: Fix copy paste error for sen internalChristian Marangi1-1/+1
In airoha_thermal_setup_monitor there is a copy paste error on configuring the internval for temp monitor. Fix the error and use the correct mask for the sen interval for the EN7581_TEMPMONCTL2 register. Fixes: 42de37f40e1b ("thermal/drivers: Add support for Airoha EN7581 thermal sensor") Signed-off-by: Christian Marangi <ansuelsmth@gmail.com> Signed-off-by: Daniel Lezcano <daniel.lezcano@kernel.org> Reviewed-by: Wayen Yan <win847@gmail.com> Link: https://patch.msgid.link/20260702094846.17325-3-ansuelsmth@gmail.com
2026-07-27thermal/drivers/airoha: Fix copy paste error on clamp_t low tempChristian Marangi1-1/+1
In airoha_thermal_set_trips, there is a copy paste error on clamping the value for the low trip temp point. Fix it to the correct value and actually clamp for the low variable. Fixes: 42de37f40e1b ("thermal/drivers: Add support for Airoha EN7581 thermal sensor") Signed-off-by: Christian Marangi <ansuelsmth@gmail.com> Signed-off-by: Daniel Lezcano <daniel.lezcano@kernel.org> Reviewed-by: Wayen Yan <win847@gmail.com> Link: https://patch.msgid.link/20260702094846.17325-2-ansuelsmth@gmail.com
2026-07-27ALSA: hda/realtek: Add quirk for HP Dragonfly Folio G3 2-in-1 (103c:8a05)Michael Diesen1-0/+1
The HP Dragonfly Folio G3 2-in-1 also ships with PCI SSID 103c:8a05. On this unit the ALC245 codec reports subsystem id 103c:8a06 - the SSID that is already covered by commit 0a10faad5ca5 ("ALSA: hda/realtek: add quirk for HP Dragonfly Folio G3 2-in-1") - while the PCI SSID that SND_PCI_QUIRK matches against is 103c:8a05: snd_hda_codec_alc269 ehdaudio0D0: ALC245: picked fixup for PCI SSID 103c:8a05 cs35l41-hda spi1-CSC3551:00-cs35l41-hda.0: CS35L41 Bound - SSID: 103C8A06 The existing entry therefore never applies here, the four CS35L41 amplifiers on SPI are not registered and the internal speakers stay silent. Add the same fixup that the 8a06 entry uses: the four amplifiers bind and the speaker mute LED (codec GPIO 0x04) works. Signed-off-by: Michael Diesen <michael.diesen@posteo.de> Link: https://patch.msgid.link/20260727091920.4634-1-michael.diesen@posteo.de Signed-off-by: Takashi Iwai <tiwai@suse.de>
2026-07-27ALSA:hda/realtek:ALC269 fixup for Legion 7 15ASH11 Mic Mute LEDJackie Dong1-0/+4
Lenovo Legion 7 15ASH11 with AMD RYZEN AI MAX+ 392 (Strix Halo, ACP 7.0) uses Realtek ALC287 series codec. Its audio subsystem adopts a hardware design similar to that of the Yoga Pro 7 15ASH11. It shares PCI SSID 17aa:38f9 with Thinkbook 16P Gen5. Therefore, use HDA_CODEC_QUIRK to apply ALC287_FIXUP_LENOVO_YOGA_PRO7 for identification. After added the HDA_CODEC_QUIRK quirk special for Lenovo Legion 7 15ASH11, the mic mute LED works well. Signed-off-by: Jackie Dong <xy-jackie@139.com> Link: https://patch.msgid.link/20260727080048.13254-1-xy-jackie@139.com Signed-off-by: Takashi Iwai <tiwai@suse.de>
2026-07-27Merge tag 'asoc-aw88339-lib' of ↵Takashi Iwai834-6641/+13524
https://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound into for-next ASoC: Add AW88399 HDA side codec driver for Lenovo Legion In order to support AW88399 HDA side codec used on the Lenovo Legion we need updates to it's ASoC driver.
2026-07-27ASoC: meson: aiu-encoder-i2s: improve hw constraints checksMark Brown3-48/+113
Valerio Setti <vsetti@baylibre.com> says: This is a follow-up to the recently merged series reshaping the AIU driver following the same design as AXG [1]. During the review, Jerome pointed out that failing in hw_params() when two streams have incompatible requirements is too late from userspace's point of view [2]. This series addresses that comment: - Patch 1 fixes the existing bclk quirk check first: it only rejected one direction of the mismatch, and its interface-wide flag was cleared too late, making a legal reconfiguration of a single stream fail. This is a standalone fix and it's preparing for patch 2. - Patch 2 is the actual answer to the review comment: the quirk incompatibility is expressed as hw rules on channels and sample bits, refined against the committed configuration of the opposite stream, so it becomes visible during parameter refinement. The hw_params() check is kept as the last backstop in case of concurrent refinement. - Patch 3 applies the same philosophy to the interface-wide rate symmetry. Instead of manually reimplementing the check, take advantage of the core's 'symmetric_rate' handling. Jerome's comment also mentioned the error returned when 'bs' is not a multiple of 2. That one intentionally remains a hw_params() time error: bs depends on the mclk rate, which the DAI only learns via set_sysclk() from the machine driver's hw_params(), after parameter refinement has already run. I don't think that can easily be expressed as a constraint. Final note. [1] has not been mainlined yet and it's only present in 'broonie/sound.git#for-7.3'. Therefore this series depends on commit c7852d2dcf66 ("ASoC: meson: aiu: align I2S design to the AXG one"). [1] https://lore.kernel.org/linux-sound/20260610-reshape-aiu-as-axg-v2-0-cac3663a8b51@baylibre.com/ [2] https://lore.kernel.org/linux-sound/1jik7pebk7.fsf@starbuckisacylon.baylibre.com/ Link: https://patch.msgid.link/20260710-aiu-improve-quirk-check-v1-0-2fdd1b6f8896@baylibre.com
2026-07-27ASoC: meson: aiu-encoder-i2s: use the core symmetric_rate handlingValerio Setti3-22/+3
The driver manually implement the interface-wide rate symmetry enforcement in hw_params(), which suffers from the same problem addressed in the previous patch: the restriction is not visible in the hw parameter constraints, so a stream with a mismatching rate only finds out via -EINVAL late in the stream setup. The ASoC core already provides this feature through the DAI's 'symmetric_rate' flag: when another stream of the DAI is active, soc_pcm_apply_symmetry() constrains the rate at open time so the restriction shows up during parameter refinement, and soc_pcm_params_symmetry() still rejects a mismatch at hw_params() time as a backstop. Set 'symmetric_rate' on the I2S encoder DAI and drop the open-coded check along with the now unused 'rate' member of struct gx_iface. Signed-off-by: Valerio Setti <vsetti@baylibre.com> Link: https://patch.msgid.link/20260710-aiu-improve-quirk-check-v1-3-2fdd1b6f8896@baylibre.com Signed-off-by: Mark Brown <broonie@kernel.org>
2026-07-27ASoC: meson: aiu-encoder-i2s: reflect bs quirk in hw constraintsValerio Setti1-0/+67
Currently the only check for bs-quirk is implemented in hw_params(), but this is too late: nothing in the refined hw parameters hints at the restriction, so userspace has no way to know the configuration is invalid until the setup fails, as Jerome pointed out during review [1]. Add hw rules on CHANNELS and SAMPLE_BITS at startup() so that the restriction shows up during parameter refinement instead. The rules are refined against the committed configuration of the opposite stream: - if it uses the quirk, the current stream is narrowed to the same 8ch/16-bit configuration; - otherwise, selecting a 16-bit physical width limits the stream to 2 channels, and selecting 8 channels requires a physical width larger than 16 bits. The rules key on the physical width while the quirk is defined on the significant bits. This is safe because S16_LE is the only format supported by the encoder where both are 16 bits. The check in aiu_encoder_i2s_set_clocks() is kept as the last backstop: both streams may be refined concurrently before either commits its configuration. The rules are only registered on GX platforms where the bs-quirk exists and only when the DAI has a stream in the opposite direction. [1] https://lore.kernel.org/r/1jik7pebk7.fsf@starbuckisacylon.baylibre.com/ Suggested-by: Jerome Brunet <jbrunet@baylibre.com> Signed-off-by: Valerio Setti <vsetti@baylibre.com> Link: https://lore.kernel.org/r/1jik7pebk7.fsf@starbuckisacylon.baylibre.com/ Link: https://patch.msgid.link/20260710-aiu-improve-quirk-check-v1-2-2fdd1b6f8896@baylibre.com Signed-off-by: Mark Brown <broonie@kernel.org>
2026-07-27ASoC: meson: aiu-encoder-i2s: fix bs quirk incompatibility checkValerio Setti2-26/+43
The bs-quirk incompatibility check has two flaws: - It only rejects one direction of the mismatch. A stream that does not require the quirk is rejected while a quirked stream is active, but the opposite is not true: a stream requiring the quirk passes the check while a non-quirked stream is active, silently reprogramming the shared mclk/bclk divider with the 50% increase and corrupting the output of the running stream. - 'bs_quirk' is only cleared in hw_free() when the last substream closes, but userspace may legally stop/reconfigure/start the stream without an intervening hw_free. Reconfiguring a single stream from the quirked configuration (8ch/16-bit) to one that does not need the quirk therefore fails with -EINVAL due to the stale flag. Drop the interface-wide flag and instead compare the quirk requirement of the incoming parameters against the committed configuration of the opposite stream at hw_params() time. The committed channels/width are cleared in hw_free() so that a released stream no longer constrains the other one. Signed-off-by: Valerio Setti <vsetti@baylibre.com> Link: https://patch.msgid.link/20260710-aiu-improve-quirk-check-v1-1-2fdd1b6f8896@baylibre.com Signed-off-by: Mark Brown <broonie@kernel.org>
2026-07-27drm/bridge: Use named initializers for arrays of i2c_device_dataUwe Kleine-König (The Capable Hub)26-47/+47
While being less compact, using named initializers allows to more easily see which members of the structs are assigned which value without having to lookup the declaration of the struct. And it's also more robust against changes to the struct definition. The mentioned robustness is relevant for a planned change to struct i2c_device_id that replaces .driver_data by an anonymous union. While touching all these arrays, unify usage of whitespace in the list terminator and drop trailing commas there. This patch doesn't modify the compiled arrays, only their representation in source form benefits. The former was confirmed with x86 and arm64 builds. Reviewed-by: Luca Ceresoli <luca.ceresoli@bootlin.com> Signed-off-by: Uwe Kleine-König (The Capable Hub) <u.kleine-koenig@baylibre.com> Acked-by: Douglas Anderson <dianders@chromium.org> # ti-sn65dsi86.c Link: https://patch.msgid.link/9fa3a8e372b7211c06ec885617051f5006227e3a.1784545092.git.u.kleine-koenig@baylibre.com Signed-off-by: Luca Ceresoli <luca.ceresoli@bootlin.com>
2026-07-27ACPI: CPPC: Skip writes to unsupported performance controlsChristian Loehle1-3/+4
MIN_PERF and MAX_PERF are optional CPPC controls. DESIRED_PERF is also optional with CPPC2 when autonomous selection is supported. The cppc-cpufreq target callbacks populate both limits for every request without checking whether the controls are implemented. cppc_set_perf() consequently passes NULL register descriptors to cpc_write(). The writes fail width validation and their return values are ignored, so the failed access paths are repeated on every target request. An autonomous-only platform can take the same path for DESIRED_PERF. Check that each performance control is supported before calling cpc_write(). Fixes: ea3db45ae476 ("cpufreq: cppc: Update MIN_PERF/MAX_PERF in target callbacks") Reviewed-by: Sumit Gupta <sumitg@nvidia.com> Signed-off-by: Christian Loehle <christian.loehle@arm.com> Reviewed-by: Lifeng Zheng <zhenglifeng1@huawei.com> Link: https://patch.msgid.link/20260724104042.1481804-1-christian.loehle@arm.com Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
2026-07-27ACPI: bus: Avoid confusing complaints regarding missing _OSC featuresRafael J. Wysocki1-3/+11
The platform firmware on some platforms sets OSC_CAPABILITIES_MASK_ERROR in _OSC error bits even though it actually acknowledges all of the requested features which after commit e5322888e6bf ("ACPI: bus: Rework the handling of \_SB._OSC platform features") causes the kernel to complain unnecessarily. Avoid the confusing complaints by explicitly checking for that case in acpi_osc_handshake(). Fixes: e5322888e6bf ("ACPI: bus: Rework the handling of \_SB._OSC platform features") Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Tested-by: Saverio Miroddi <saverio.pub2@gmail.com> [ rjw: Fixed a typo in the new comment ] Link: https://patch.msgid.link/6315683.lOV4Wx5bFT@rafael.j.wysocki Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
2026-07-27ASoC: remove conditional returns with no effectMark Brown0-0/+0
Sang-Heon Jeon <ekffu200098@gmail.com> says: This series removes conditional returns where both branches return the same value, so the check has no effect. As suggested by Vijendar, the ASoC patch of the treewide v1 series [1] is split per vendor and posted separately. All patches are generated by the Coccinelle script, which you can find in v1. If you would rather drop any of the patches, just let me know and I will address it in the next version. Link: https://patch.msgid.link/20260725160344.916838-1-ekffu200098@gmail.com
2026-07-27ASoC: SOF: Intel: remove conditional return with no effectSang-Heon Jeon1-5/+1
Both branches of the check return the same value, so the check has no effect. Remove it and return the value directly. This is the result of running the Coccinelle script from scripts/coccinelle/misc/cond_return_no_effect.cocci. Signed-off-by: Sang-Heon Jeon <ekffu200098@gmail.com> Link: https://patch.msgid.link/20260725160344.916838-5-ekffu200098@gmail.com Signed-off-by: Mark Brown <broonie@kernel.org>
2026-07-27ASoC: samsung: smdk_spdif: remove conditional return with no effectSang-Heon Jeon1-6/+2
Both branches of the check return the same value, so the check has no effect. Remove it and return the value directly. This is the result of running the Coccinelle script from scripts/coccinelle/misc/cond_return_no_effect.cocci. Signed-off-by: Sang-Heon Jeon <ekffu200098@gmail.com> Link: https://patch.msgid.link/20260725160344.916838-4-ekffu200098@gmail.com Signed-off-by: Mark Brown <broonie@kernel.org>
2026-07-27ASoC: Intel: atom: remove conditional return with no effectSang-Heon Jeon1-6/+1
Both branches of the check return the same value, so the check has no effect. Remove it and return the value directly. This is the result of running the Coccinelle script from scripts/coccinelle/misc/cond_return_no_effect.cocci. Signed-off-by: Sang-Heon Jeon <ekffu200098@gmail.com> Reviewed-by: Cezary Rojewski <cezary.rojewski@intel.com> Link: https://patch.msgid.link/20260725160344.916838-3-ekffu200098@gmail.com Signed-off-by: Mark Brown <broonie@kernel.org>
2026-07-27ASoC: amd: acp: remove conditional return with no effectSang-Heon Jeon1-8/+3
Both branches of the check return the same value, so the check has no effect. Remove it and return the value directly. This is the result of running the Coccinelle script from scripts/coccinelle/misc/cond_return_no_effect.cocci. Signed-off-by: Sang-Heon Jeon <ekffu200098@gmail.com> Reviewed-by: Vijendar Mukunda <Vijendar.Mukunda@amd.com> Link: https://patch.msgid.link/20260725160344.916838-2-ekffu200098@gmail.com Signed-off-by: Mark Brown <broonie@kernel.org>
2026-07-27gpio: pch: use raw_spinlock_t for the register lockJunjie Cao1-14/+14
pch_irq_type() is registered as the irq_chip .irq_set_type callback and takes chip->spinlock with spin_lock_irqsave(). This callback is reached from __setup_irq() -> __irq_set_trigger() -> chip->irq_set_type() while the caller holds desc->lock, a raw_spinlock_t, with hardirqs disabled. That context is not sleepable, but on PREEMPT_RT a regular spinlock_t is an rtmutex-backed sleeping lock, so acquiring it there is invalid. This was confirmed on a PREEMPT_RT kernel with lockdep (PROVE_RAW_LOCK_NESTING and DEBUG_ATOMIC_SLEEP). A grounded PoC mirrored pch_irq_type()'s locking and drove it through the real genirq carrier irq_set_irq_type() -> __irq_set_trigger() -> chip->irq_set_type(), i.e. the same __irq_set_trigger() edge that __setup_irq() takes for a requested IRQ. With the original spin_lock_irqsave() edge lockdep reported an invalid wait context, immediately followed by: BUG: sleeping function called from invalid context at kernel/locking/spinlock_rt.c:48 in_atomic(): 1, irqs_disabled(): 1, non_block: 0, pid: 95, name: insmod hardirqs last disabled at (3784): _raw_spin_lock_irqsave+0x4f/0x60 rt_spin_lock+0x3a/0x1c0 repro_irq_set_type+0x64/0xa0 [pch_repro] __irq_set_trigger+0x69/0x140 irq_set_irq_type+0x78/0xd0 Switching the mirrored lock to raw_spinlock_t made both splats go away. Convert the register lock to raw_spinlock_t. The same lock also serializes the GPIO direction/value callbacks and the suspend/resume register save/restore, but all of those critical sections only perform MMIO register accesses (ioread32()/iowrite32()) and irq_set_handler_locked(); none of them contain sleepable operations. Keeping this register lock non-sleeping is therefore appropriate for the irqchip callbacks and does not change the GPIO-side locking contract. This is the same class of issue and fix as recently addressed for other GPIO controllers, e.g. commit 286533cb14a3 ("gpio: sch: use raw_spinlock_t in the irq startup path") and commit 90f0109019e6 ("gpio: eic-sprd: use raw_spinlock_t in the irq startup path"). Fixes: 38eb18a6f92d ("gpio-pch: Support interrupt function") Cc: stable@vger.kernel.org Signed-off-by: Junjie Cao <junjie.cao@intel.com> Reviewed-by: Linus Walleij <linusw@kernel.org> Link: https://patch.msgid.link/20260723014129.1129730-1-junjie.cao@intel.com Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@oss.qualcomm.com>
2026-07-27power: supply: qcom_battmgr: terminate the strings from firmwareHyeongJun An1-1/+1
The qcom_battmgr_sc8280xp_strcpy() takes a Pascal-style string when the firmware sends one. Otherwise it copies all BATTMGR_STRING_LEN bytes and leaves the destination without a terminator. Those destinations are model_number, serial_number and oem_info, each BATTMGR_STRING_LEN and declared next to each other. They go out to user space as val->strval, which power_supply_format_property() prints with "%s", so a firmware string that fills the whole field makes that read run into the following members. Use strscpy() so the copy always terminates, the way the SM8350 path already does for the same field. Fixes: 29e8142b5623 ("power: supply: Introduce Qualcomm PMIC GLINK power supply") Cc: stable@vger.kernel.org Assisted-by: Claude:claude-opus-4-8 Signed-off-by: HyeongJun An <sammiee5311@gmail.com> Link: https://patch.msgid.link/20260727074119.2585463-1-sammiee5311@gmail.com Signed-off-by: Sebastian Reichel <sebastian.reichel@collabora.com>
2026-07-27gpio: pca953x: fix cache_only and IRQ state on restore_context() failurebui duc phuc1-2/+13
When pca953x_restore_context() fails, cache_only is left disabled and the IRQ left enabled, even though register synchronization may not have completed successfully. Restore cache_only and disable the IRQ again on failure, matching the state set by pca953x_save_context(). Fixes: ec5bde62019b ("gpio: pca953x: Split pca953x_restore_context() and pca953x_save_context()") Fixes: 3e38f946062b ("gpio: pca953x: fix IRQ storm on system wake up") Cc: stable@vger.kernel.org Reviewed-by: Linus Walleij <linusw@kernel.org> Signed-off-by: bui duc phuc <phucduc.bui@gmail.com> Link: https://patch.msgid.link/20260727080205.16353-1-phucduc.bui@gmail.com Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@oss.qualcomm.com>
2026-07-27drm/bridge: display-connector: Fix I2C adapter resource leakLaurent Pinchart1-3/+8
If the probe function returns an error after getting the I2C adapter for DDC, the reference to the adapter is never released. Fix it by releasing it in the bridge .destroy() handler. There is no need to test the ddc pointer with !IS_ERR(), as of_get_i2c_adapter_by_node() returns NULL on error. Fixes: 2e2bf3a5584d ("drm/bridge: display-connector: add DP support") Cc: stable@vger.kernel.org Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Reviewed-by: Johan Hovold <johan@kernel.org> Reviewed-by: Luca Ceresoli <luca.ceresoli@bootlin.com> Link: https://patch.msgid.link/20260717184836.2017386-1-laurent.pinchart+renesas@ideasonboard.com Signed-off-by: Luca Ceresoli <luca.ceresoli@bootlin.com>
2026-07-27power: supply: max17040: propagate register read errorsJianing Li1-5/+21
max17040_get_vcell() and max17040_get_soc() ignore errors returned by regmap_read(). When an I2C transfer fails, the uninitialized register value is converted and reported to userspace as a valid voltage or state of charge. The polling worker can also replace the cached state of charge with the bogus value and emit a spurious change event. Propagate read errors through the power supply get_property callback and keep the last valid cached state of charge when polling fails. Fixes: c6f4a42de60b ("Add MAX17040 Fuel Gauge driver") Cc: stable@vger.kernel.org Signed-off-by: Jianing Li <m13940358460@163.com> Link: https://patch.msgid.link/20260727064825.948-1-m13940358460@163.com Signed-off-by: Sebastian Reichel <sebastian.reichel@collabora.com>
2026-07-27regulator: wm831x-isink: remove conditional return with no effectSang-Heon Jeon1-5/+1
Both branches of the check return the same value, so the check has no effect. Remove it and return the value directly. This is the result of running the Coccinelle script from scripts/coccinelle/misc/cond_return_no_effect.cocci. Signed-off-by: Sang-Heon Jeon <ekffu200098@gmail.com> Reviewed-by: Charles Keepax <ckeepax@opensource.cirrus.com> Link: https://patch.msgid.link/20260723184538.3888637-29-ekffu200098@gmail.com Signed-off-by: Mark Brown <broonie@kernel.org>
2026-07-27ASoC: remove conditional return with no effectSang-Heon Jeon4-25/+7
Both branches of the check return the same value, so the check has no effect. Remove it and return the value directly. This is the result of running the Coccinelle script from scripts/coccinelle/misc/cond_return_no_effect.cocci. Signed-off-by: Sang-Heon Jeon <ekffu200098@gmail.com> Link: https://patch.msgid.link/20260723184538.3888637-15-ekffu200098@gmail.com Signed-off-by: Mark Brown <broonie@kernel.org>
2026-07-27Merge 7.2-rc5 into char-misc-nextGreg Kroah-Hartman1004-4841/+13408
We need the char/misc fixes AND this resolves two merge conflicts in: drivers/android/binder/thread.rs drivers/misc/nsm.c Reported-by: Mark Brown <broonie@kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2026-07-27ASoC: dt-bindings: Convert eukrea-tlv320.txt to yamlFrank Li2-26/+61
Convert eukrea-tlv320.txt to yaml format. Signed-off-by: Frank Li <Frank.Li@nxp.com> Reviewed-by: Rob Herring (Arm) <robh@kernel.org> Link: https://patch.msgid.link/20260515145205.1696584-1-Frank.Li@oss.nxp.com Signed-off-by: Mark Brown <broonie@kernel.org>
2026-07-27exfat: write moved entry before removing sourceYichong Chen1-5/+5
exfat_move_file() removes the old directory entry before the new entry has been written. If writing the new entry fails, rename returns an error after the source entry has already been marked deleted. Write the new entry first, then remove the old entry and update the cached inode location. This keeps the source entry intact if creating the destination entry fails. Signed-off-by: Yichong Chen <chenyichong@uniontech.com> Signed-off-by: Namjae Jeon <linkinjeon@kernel.org>
2026-07-27drm/bridge: dw-hdmi: fix i2c adapter leak on probe failureJohan Hovold1-1/+2
Make sure to drop the i2c adapter device and module references before returning when detecting a malformed devicetree during probe. Fixes: 80e2f97968b5 ("drm: bridge: dw-hdmi: Switch to regmap for register access") Cc: stable@vger.kernel.org # 4.12 Cc: Neil Armstrong <neil.armstrong@linaro.org> Signed-off-by: Johan Hovold <johan@kernel.org> Reviewed-by: Luca Ceresoli <luca.ceresoli@bootlin.com> Reviewed-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Link: https://patch.msgid.link/20260717090819.1630965-1-johan@kernel.org Signed-off-by: Luca Ceresoli <luca.ceresoli@bootlin.com>
2026-07-27thermal: Remove unneeded 'fast_io' parameter in regmap_configWolfram Sang2-2/+0
When using MMIO with regmap, fast_io is implied. No need to set it again. Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com> Signed-off-by: Daniel Lezcano <daniel.lezcano@kernel.org> Reviewed-by: Miquel Raynal <miquel.raynal@bootlin.com> Link: https://patch.msgid.link/20260705164311.2273-2-wsa+renesas@sang-engineering.com
2026-07-27platform/x86: hp-wmi: Add OMEN board 8BA9 thermal profile supportSuryansh Singh1-0/+4
The HP OMEN 16-wd0xxx (board ID: 8BA9) has the same WMI interface as other Victus S boards, but requires quirks for correctly switching thermal profile. Add the DMI board name to hp_wmi_feature_boards[] table and map it to omen_v1_board_params. Without this entry, platform profile switching is unavailable, preventing fan RPM reporting and controlling. Tested on: HP OMEN 16-wd0012TX DMI Board Name: 8BA9 It has been confirmed that the platform profile is registered successfully, and the fan RPMs are readable and controllable. Signed-off-by: Suryansh Singh <technosfan14@gmail.com> Link: https://patch.msgid.link/20260724120255.49649-1-technosfan14@gmail.com Reviewed-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com> Signed-off-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>
2026-07-27drm/bridge: lontium-lt8912b: make read-only const array supply_names staticColin Ian King1-1/+1
Don't populate the read-only const array supply_names on the stack at run time, instead make it static Signed-off-by: Colin Ian King <colin.i.king@gmail.com> Reviewed-by: Luca Ceresoli <luca.ceresoli@bootlin.com> Acked-by: Francesco Dolcini <francesco.dolcini@toradex.com> Link: https://patch.msgid.link/20260714190400.194605-1-colin.i.king@gmail.com Signed-off-by: Luca Ceresoli <luca.ceresoli@bootlin.com>
2026-07-27platform/x86: dell-smbios-wmi: Replace global list with single itemArmin Wolf1-37/+31
There can only exist a single instance of the dell-smbios-wmi driver at the same time because of naming conflicts with the character device ("wmi/dell-smbios"). Having a global list for all instances thus makes no sense. Replace the global list with a single item used by the character device. This simplifies the driver and allows us to mark it as being multi-instance safe. Signed-off-by: Armin Wolf <W_Armin@gmx.de> Link: https://patch.msgid.link/20260720131921.368000-4-W_Armin@gmx.de Reviewed-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com> Signed-off-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>
2026-07-27platform/x86: dell-smbios: Pass device to callbacksArmin Wolf4-16/+12
The WMI SMBIOS backend needs to access the its driver state container when performing SMBIOS calls. Pass the device associated with a given backend to the callback function to allow the WMI backend to retrieve said state container in a more straightforward manner. Signed-off-by: Armin Wolf <W_Armin@gmx.de> Link: https://patch.msgid.link/20260720131921.368000-3-W_Armin@gmx.de Reviewed-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com> Signed-off-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>
2026-07-27platform/x86: dell-smbios-wmi: Fix chardev resource managementArmin Wolf1-33/+34
When unbinding the WMI driver while a userspace application has an open file descriptor for the character device, a UAF occurs: KASAN: slab-use-after-free in _copy_to_user from platform/x86/dell-smbios-wmi The reason for this is that even after calling misc_deregister(), userspace appications can still call read() and/or ioctl() on open file descriptors associated with the already unregistered character device. This causes a UAF by attempting to access the already freed state container of the WMI driver. Fix this by no longer storing the state container inside filp->private_data. Instead retrieve the state container using get_first_smbios_priv() and return -ENODEV if the state container does not exist anymore. Reported-by: Shuangpeng Bai <shuangpeng.kernel@gmail.com> Closes: https://lore.kernel.org/platform-driver-x86/178144969601.60470.13396800403157907003@gmail.com/ Signed-off-by: Armin Wolf <W_Armin@gmx.de> Link: https://patch.msgid.link/20260720131921.368000-2-W_Armin@gmx.de Reviewed-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com> Signed-off-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>
2026-07-27platform/x86/amd/pmc: Do not fail probe when STB init failsMario Limonciello1-5/+8
STB (Spill to DRAM) is an optional debugging facility that is only enabled through the enable_stb module parameter. On some platforms the SMU refuses the S2D setup outright, and on long-running systems the large telemetry region can fail to ioremap. In either case amd_stb_s2d_init() returns an error and, because probe treated that as fatal, the entire PMC driver failed to load - silently disabling s0i3 support even though STB is only a debug aid. Downgrade the failure to a warning and continue probing so that s0i3 support via the LPS0 handler no longer depends on an optional debug feature. Since probe no longer aborts on this path, the LPS0 and debugfs unwinding added by the earlier fix in this series becomes unreachable and is removed. Reported-by: Francis De Brabandere <francisdb@gmail.com> Closes: https://bugzilla.kernel.org/show_bug.cgi?id=221759 Tested-by: Francis De Brabandere <francisdb@gmail.com> Signed-off-by: Mario Limonciello <mario.limonciello@amd.com> Link: https://patch.msgid.link/20260721181756.143084-7-mario.limonciello@amd.com Reviewed-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com> Signed-off-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>
2026-07-27platform/x86/amd/pmc: Fix LPS0 and debugfs leaks when STB init failsMario Limonciello1-1/+5
amd_pmc_probe() registers the LPS0 s2idle handler with acpi_register_lps0_dev() and creates the driver's debugfs directory before calling amd_stb_s2d_init(), which is the last step in probe that can fail. When amd_stb_s2d_init() fails (for example the S2D telemetry region cannot be ioremapped on a long-running system, or the SMU rejects the S2D setup) the error path only calls pci_dev_put() and returns. This leaves amd_pmc_s2idle_dev_ops on the global lps0_s2idle_devops_head list and leaks the debugfs directory, while the devm-managed resources backing the handler are torn down. Reloading the module then walks the corrupted list in acpi_register_lps0_dev() and hits: list_add corruption. next->prev should be prev, but was NULL. kernel BUG at lib/list_debug.c:29! acpi_register_lps0_dev+0x44/0x80 amd_pmc_probe+0x224/0x380 [amd_pmc] platform_probe+0x67/0x90 Even without a reload, the stale registration means the next s2idle transition calls into torn-down driver state. Unwind the debugfs directory and the LPS0 registration on the amd_stb_s2d_init() error path. acpi_unregister_lps0_dev() is safe to call unconditionally here: it is guarded on the same conditions as acpi_register_lps0_dev(), which is exactly what amd_pmc_remove() already relies on. Reported-by: Francis De Brabandere <francisdb@gmail.com> Closes: https://bugzilla.kernel.org/show_bug.cgi?id=221759 Tested-by: Francis De Brabandere <francisdb@gmail.com> Fixes: 83ad6974dd3b ("platform/x86/amd/pmc: Move STB block into amd_pmc_s2d_init()") Cc: stable@vger.kernel.org Signed-off-by: Mario Limonciello <mario.limonciello@amd.com> Link: https://patch.msgid.link/20260721181756.143084-6-mario.limonciello@amd.com Reviewed-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com> Signed-off-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>
2026-07-27platform/x86/amd/pmc: Only expose stb_read after telemetry buffer is mappedMario Limonciello1-5/+12
amd_stb_s2d_init() creates the v2 "stb_read" debugfs node before mapping the telemetry buffer into dev->stb_virt_addr, leaving a window during probe where a read faults on a NULL dev->stb_virt_addr in amd_stb_debugfs_open_v2()/amd_stb_handle_efr(). This becomes trivial to hit once a failed STB init no longer aborts probe (next patch), which leaves the node registered with a NULL buffer. Create it only after dev->stb_virt_addr is mapped. Signed-off-by: Mario Limonciello <mario.limonciello@amd.com> Link: https://patch.msgid.link/20260721181756.143084-5-mario.limonciello@amd.com Reviewed-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com> Signed-off-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>
2026-07-27platform/x86/amd/pmc: Propagate SMU errors and validate S2D addressMario Limonciello1-11/+20
amd_stb_s2d_init() discards the return value of several S2D SMU commands. When the SMU refuses a command (e.g. "SMU cmd failed. err: 0xff") the failure is only noticed indirectly - if at all - and reported as -EIO, masking the real error. More seriously, the S2D_PHYS_ADDR_LOW/HIGH return values are ignored, so on failure phys_addr_low/hi are left uninitialised and the assembled address is passed straight to devm_ioremap(). When the SMU leaves them at zero this maps physical address 0 and trips the ioremap-on-RAM warning: amd_pmc AMDI000B:00: SMU cmd failed. err: 0xff ioremap on RAM at 0x0000000000000000 - 0x0000000000ffffff WARNING: CPU: 13 PID: 4592 at arch/x86/mm/ioremap.c:... Check the return value of each SMU command and propagate it, and reject a zero physical address before calling devm_ioremap(). Reported-by: Francis De Brabandere <francisdb@gmail.com> Closes: https://bugzilla.kernel.org/show_bug.cgi?id=221759 Tested-by: Francis De Brabandere <francisdb@gmail.com> Fixes: 3d7d407dfb05 ("platform/x86: amd-pmc: Add support for AMD Spill to DRAM STB feature") Cc: stable@vger.kernel.org Signed-off-by: Mario Limonciello <mario.limonciello@amd.com> Link: https://patch.msgid.link/20260721181756.143084-4-mario.limonciello@amd.com Reviewed-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com> Signed-off-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>
2026-07-27platform/x86/amd/pmc: Fix msg_port restoration in amd_stb_debugfs_open_v2()Mario Limonciello1-9/+14
amd_stb_debugfs_open_v2() switches dev->msg_port to MSG_PORT_S2D to query S2D telemetry but only restores it to MSG_PORT_PMC on one path. The early return on the dump_custom_stb path (and the error/allocation returns) leave the port stuck on MSG_PORT_S2D, so subsequent SMU communication - including the s2idle prepare/restore handlers - is directed at the wrong mailbox. Consolidate the exit path through a single label so the message port is always restored, mirroring the fix in amd_stb_s2d_init(). Reported-by: sashiko.dev Link: https://sashiko.dev/#/patchset/20260717162023.956346-1-mario.limonciello%40amd.com Fixes: 2851f4f8ed4e ("platform/x86/amd/pmc: Define enum for S2D/PMC msg_port and add helper function") Cc: stable@vger.kernel.org Signed-off-by: Mario Limonciello <mario.limonciello@amd.com> Link: https://patch.msgid.link/20260721181756.143084-3-mario.limonciello@amd.com Reviewed-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com> Signed-off-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>
2026-07-27platform/x86/amd/pmc: Restore msg_port on amd_stb_s2d_init() error pathsMario Limonciello1-9/+15
dev->msg_port is switched to MSG_PORT_S2D before issuing the S2D SMU commands but is only restored to MSG_PORT_PMC on the success path. The early "return -EIO" and "return -ENOMEM" leave the port stuck on MSG_PORT_S2D, so all subsequent SMU communication - including the s2idle prepare/restore handlers - is directed at the wrong mailbox. Consolidate the exit path through a single label so the message port is always restored. Fixes: 3d7d407dfb05 ("platform/x86: amd-pmc: Add support for AMD Spill to DRAM STB feature") Cc: stable@vger.kernel.org Signed-off-by: Mario Limonciello <mario.limonciello@amd.com> Link: https://patch.msgid.link/20260721181756.143084-2-mario.limonciello@amd.com Reviewed-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com> Signed-off-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>