From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from out-183.mta1.migadu.com (out-183.mta1.migadu.com [95.215.58.183]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 3616D2376F2 for ; Wed, 26 Feb 2025 19:07:43 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=95.215.58.183 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1740596867; cv=none; b=Ys9QIRxmM+mMyAxmLfVvJZ7XBQibnaY9PpE5E9gsse5AveJgqx47fn54QIK1bVp7FOET58xUHoNIx3ZKFWUz0V7ZXWMFCorjdYMRzy+QU3YRlPu1yAsv/EUUYpkfxW92YJ8syZwwDiB4Rm4TnqNQrJanGyOzq6sUlvZtTxDGKv0= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1740596867; c=relaxed/simple; bh=vaZR9Hnj++wdm9p2gOfT46UizyWXUgiuV8N/tsFe4CQ=; h=Message-ID:Date:MIME-Version:Subject:To:Cc:References:From: In-Reply-To:Content-Type; b=kd5nIUtSPDIpUW/adIxeFoe10dJwEzUIG8J8yAekK3BQ+b1VJnMMXDj0lag6rFQKWODEUF8ZcvH9dFPg/j45g+DI4o263xxTOA6zBTXfcydggIIkYUVK5NxlKlUdgtlP9+Zpb24wMwIvEAZHd6m1mPcJGfureVfHPFdlhRLiJtY= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linux.dev; spf=pass smtp.mailfrom=linux.dev; dkim=pass (1024-bit key) header.d=linux.dev header.i=@linux.dev header.b=X3Mi75tV; arc=none smtp.client-ip=95.215.58.183 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linux.dev Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=linux.dev Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linux.dev header.i=@linux.dev header.b="X3Mi75tV" Message-ID: <1d495444-5287-453f-8d20-6d578c4edb36@linux.dev> DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linux.dev; s=key1; t=1740596862; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=j71fEwNAw6vMemf2qgdxvV8cBNKsWsP3YOvG0aBa448=; b=X3Mi75tVIKy5oeu+mDylHxr1bM+aq2YD2tiPCVIof4NAN9q4CO+6jCwl07Czw4D4nC2jdA rVzqHV2LCNnikpVG4DU8Ha2+Obse2084q7JAyhPMPrWJLXjim0LNpmWMqBokF9NAldfs0J wfQrE53G3GT4zBSP13cXqqcmkcRw30c= Date: Wed, 26 Feb 2025 11:07:36 -0800 Precedence: bulk X-Mailing-List: linux-doc@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Subject: Re: [PATCH v3 0/4] platform/x86: Add Lenovo Gaming Series WMI Drivers To: "Derek J. Clark" , Hans de Goede , =?UTF-8?Q?Ilpo_J=C3=A4rvinen?= Cc: Armin Wolf , Jonathan Corbet , Mario Limonciello , Luke Jones , Xino Ni , Zhixin Zhang , Mia Shao , Mark Pearson , "Pierre-Loup A . Griffais" , "Cody T . -H . Chiu" , John Martens , platform-driver-x86@vger.kernel.org, linux-doc@vger.kernel.org, linux-kernel@vger.kernel.org References: <20250225220037.16073-1-derekjohn.clark@gmail.com> Content-Language: en-US X-Report-Abuse: Please report any abuse attempt to abuse@migadu.com and include these headers. From: Matthew Schwartz In-Reply-To: <20250225220037.16073-1-derekjohn.clark@gmail.com> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-Migadu-Flow: FLOW_OUT For the series on both Lenovo Legion Go and Legion Go S, all platform profile selection and power controls have been working consistently over several hours with numerous adjustments and many suspend/resume cycles. Tested on Arch Linux w/ kernel 6.14-rc1 compiled from platform-drivers-x86. Tested-by: Matthew Schwartz On 2/25/25 1:59 PM, Derek J. Clark wrote: > Adds support for the Lenovo "Gaming Series" of laptop hardware that use > WMI interfaces that control various power settings. There are multiple WMI > interfaces that work in concert to provide getting and setting values as > well as validation of input. Currently only the "Gamezone", "Other > Mode", and "LENOVO_CAPABILITY_DATA_01" interfaces are implemented, but > I attempted to structure the driver so that adding the "Custom Mode", > "Lighting", and other data block interfaces would be trivial in a later > patches. > > This driver is distinct from, but should be considered a replacement for > this patch: > https://lore.kernel.org/all/20241118100503.14228-1-jonmail@163.com/ > > This driver attempts to standardize the exposed sysfs by mirroring the > asus-armoury driver currently under review. As such, a lot of > inspiration has been drawn from that driver. > https://lore.kernel.org/all/20240930000046.51388-1-luke@ljones.dev/ > > The drivers have been tested by me on the Lenovo Legion Go and Legion Go > S. > > v3: > - Added notifier chain to Gamezone and Other Mode drivers. > - Added component framework to lenovo-wmi-other driver with > lenovo-wmi-capdata01 acting as a component. > - Completed all suggestions from v2. > - Checkpatch produces CHECK complaints about the Other Mode macros > reusing some variable names. This don't appear to create the condition > it highlights in my testing. > > v2: > https://lore.kernel.org/platform-driver-x86/20250102004854.14874-1-derekjohn.clark@gmail.com/t/#m9682cee65783ff3a9e927f2ad1f55c4cbfc37615 > v1: > https://lore.kernel.org/platform-driver-x86/CAFqHKTna+kJpHLo5s4Fm1TmHcSSqSTr96JHDm0DJ0dxsZMkixA@mail.gmail.com/T/#t > > Suggested-by: Mario Limonciello > Signed-off-by: Derek J. Clark > Derek J. Clark (4): > platform/x86: Add lenovo-wmi drivers Documentation > platform/x86: Add Lenovo Gamezone WMI Driver > platform/x86: Add Lenovo Capability Data 01 WMI Driver > platform/x86: Add Lenovo Other Mode WMI Driver > > .../wmi/devices/lenovo-wmi-gamezone.rst | 355 +++++++++++ > .../wmi/devices/lenovo-wmi-other-method.rst | 142 +++++ > MAINTAINERS | 12 + > drivers/platform/x86/Kconfig | 35 ++ > drivers/platform/x86/Makefile | 4 + > drivers/platform/x86/lenovo-wmi-capdata01.c | 140 +++++ > drivers/platform/x86/lenovo-wmi-gamezone.c | 374 ++++++++++++ > drivers/platform/x86/lenovo-wmi-other.c | 549 ++++++++++++++++++ > drivers/platform/x86/lenovo-wmi.c | 77 +++ > drivers/platform/x86/lenovo-wmi.h | 94 +++ > 10 files changed, 1782 insertions(+) > create mode 100644 Documentation/wmi/devices/lenovo-wmi-gamezone.rst > create mode 100644 Documentation/wmi/devices/lenovo-wmi-other-method.rst > create mode 100644 drivers/platform/x86/lenovo-wmi-capdata01.c > create mode 100644 drivers/platform/x86/lenovo-wmi-gamezone.c > create mode 100644 drivers/platform/x86/lenovo-wmi-other.c > create mode 100644 drivers/platform/x86/lenovo-wmi.c > create mode 100644 drivers/platform/x86/lenovo-wmi.h >