public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH v2 0/4] platform/x86: ideapad-laptop: synchronize VPC commands
@ 2024-07-18  7:27 Gergo Koteles
  2024-07-18  7:27 ` [PATCH v2 1/4] platform/x86: ideapad-laptop: introduce a generic notification chain Gergo Koteles
                   ` (3 more replies)
  0 siblings, 4 replies; 10+ messages in thread
From: Gergo Koteles @ 2024-07-18  7:27 UTC (permalink / raw)
  To: Hans de Goede, Ilpo Järvinen, Ike Panhc
  Cc: platform-driver-x86, linux-kernel, Gergo Koteles

Hi,

Sometimes the Yoga mode control switch did not work properly on my 
laptop, and sometimes even caused a platform profile switch. It turned 
out that it was caused by a race situation, the lenovo-ymc wmi notify 
handler was running at the same time as the ideapad-laptop acpi notify 
handler, and the partial results of the VPC calls in the two were mixed 
up.

This series introduces a notification chain to receive YMC or other 
events, moves the EC triggering into ideapad-laptop, and then introduces 
a mutex to eliminate the problem.

Best regards,
Gergo Koteles

---
Changes in v2:
- Skip the already merged "platform/x86: ideapad-laptop: use cleanup.h" commit
- Based on the WMI driver development guide and the dell drivers,
  introduce a generic notification chain
- Use the notification chain to send the YMC event from lenovo-ymc to
  the ideapad-laptop module
- Move the ec_trigger module parameter to the ideapad-laptop as well
- Mutex changes go into one patch
- Link to v1: https://lore.kernel.org/all/cover.1720515666.git.soyer@irl.hu/
---

Gergo Koteles (4):
  platform/x86: ideapad-laptop: introduce a generic notification chain
  platform/x86: ideapad-laptop: move ymc_trigger_ec from lenovo-ymc
  platform/x86: ideapad-laptop: move ACPI helpers from header to source
    file
  platform/x86: ideapad-laptop: add a mutex to synchronize VPC commands

 drivers/platform/x86/Kconfig          |   1 +
 drivers/platform/x86/ideapad-laptop.c | 282 ++++++++++++++++++++++++--
 drivers/platform/x86/ideapad-laptop.h | 142 +------------
 drivers/platform/x86/lenovo-ymc.c     |  60 +-----
 4 files changed, 275 insertions(+), 210 deletions(-)

-- 
2.45.2


^ permalink raw reply	[flat|nested] 10+ messages in thread

end of thread, other threads:[~2024-07-18  8:17 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-07-18  7:27 [PATCH v2 0/4] platform/x86: ideapad-laptop: synchronize VPC commands Gergo Koteles
2024-07-18  7:27 ` [PATCH v2 1/4] platform/x86: ideapad-laptop: introduce a generic notification chain Gergo Koteles
2024-07-18  7:27 ` [PATCH v2 2/4] platform/x86: ideapad-laptop: move ymc_trigger_ec from lenovo-ymc Gergo Koteles
2024-07-18  8:10   ` Ilpo Järvinen
2024-07-18  7:27 ` [PATCH v2 3/4] platform/x86: ideapad-laptop: move ACPI helpers from header to source file Gergo Koteles
2024-07-18  8:12   ` Ilpo Järvinen
2024-07-18  7:27 ` [PATCH v2 4/4] platform/x86: ideapad-laptop: add a mutex to synchronize VPC commands Gergo Koteles
2024-07-18  8:06   ` Ilpo Järvinen
2024-07-18  8:12     ` Hans de Goede
2024-07-18  8:17       ` Ilpo Järvinen

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox