From nobody Sat Oct 4 06:35:15 2025 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (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 8BF402798FE; Wed, 20 Aug 2025 09:50:49 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1755683449; cv=none; b=nuctZBJ6IfXFYl1WG90LJT9oojPf2WUgvd+XvZS+w3TcGD0vSqu+d+rXDiSHvWX87B1M4PVPthzkT5vUkxXusu2HX2nGXGuxirQht0YWmR1xmu4vjDIgmpfc34kCKh8jLdW16iYFJb4dzheQcNSx1+DV0PPKzoVp650eUXdyyCA= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1755683449; c=relaxed/simple; bh=/dGQ/KHU4QWB9oKn1Tz6oNVgq/D6ekwIYY7vjkTbeAA=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=iE8XjI5ahjsv7IXpg4gHDALzH9eNCuF63lX9QBgRu4nqdDEzb2p8JjAInhPK0b8zI7dQo2ecBNAY9hUCsimac60OM/fnMwMOFR1sPxrR5BJ0NSVnNFFHEmVlEeKWIxJi57/3jaDYot8v+diXkJ15T6tJHaWO/YaCir8W8VK4TGs= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=JEBzBBtH; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="JEBzBBtH" Received: by smtp.kernel.org (Postfix) with ESMTPS id 248C2C116C6; Wed, 20 Aug 2025 09:50:49 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1755683449; bh=/dGQ/KHU4QWB9oKn1Tz6oNVgq/D6ekwIYY7vjkTbeAA=; h=From:Date:Subject:References:In-Reply-To:To:Cc:Reply-To:From; b=JEBzBBtHkWI+yJiORa5Ux1XW2wpoxQ1cFd8kuxZf7k7RJ0aRIfFqTcvbBlNSgF5g9 eVypj1zdNdq9VYyynGgrp7Qx2isUmLj2ipTyxpSnPW2h+Xf7Q3WvqDUrR7a2pa7a/4 sZeGzIi8DKxDT4adgn9+k6A0+K8MKkz91gbJjMfHwDD9QYZBZknCSIGP9UC4Bwu3TW biUWCveWcrADKlhL39I/F1U1lW0WeHGWgqNNG+GasKBDDz6OzbhHeM/JLNKwO7r3Dv ot+dLWHlAjmphDBW66BEyiNkzMHtb6XsWHNwiG07Rrkrg1QLJzox8g/JhtTYmAM5d8 5StaypxlCphVw== Received: from aws-us-west-2-korg-lkml-1.web.codeaurora.org (localhost.localdomain [127.0.0.1]) by smtp.lore.kernel.org (Postfix) with ESMTP id 1BD58CA0EDC; Wed, 20 Aug 2025 09:50:49 +0000 (UTC) From: Cryolitia PukNgae via B4 Relay Date: Wed, 20 Aug 2025 17:50:39 +0800 Subject: [PATCH RESEND v7 2/2] hwmon: document: add gpd-fan Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Message-Id: <20250820-gpd_fan-v7-2-10c8058f4dba@uniontech.com> References: <20250820-gpd_fan-v7-0-10c8058f4dba@uniontech.com> In-Reply-To: <20250820-gpd_fan-v7-0-10c8058f4dba@uniontech.com> To: Jean Delvare , Guenter Roeck , Jonathan Corbet , Cryolitia PukNgae Cc: linux-kernel@vger.kernel.org, linux-hwmon@vger.kernel.org, linux-doc@vger.kernel.org, Celeste Liu , Yao Zi , Derek John Clark , WangYuli , Jun Zhan , niecheng1@uniontech.com, guanwentao@uniontech.com, =?utf-8?q?Marcin_Str=C4=85gowski?= , someone5678 , Justin Weiss , Antheas Kapenekakis , command_block , derjohn , Crashdummyy X-Mailer: b4 0.14.2 X-Developer-Signature: v=1; a=ed25519-sha256; t=1755683447; l=3233; i=cryolitia@uniontech.com; s=20250730; h=from:subject:message-id; bh=gh/oPM4ovDnsO6Zc31vhvlqN6f1O4IdwmGmblL0tVrM=; b=kVuPITKo4enIBUQCSMFS7B+pfc8vQhyhP7jFEiJ4wpejvwkh7ZMO4f3iNkfgDJ8Jy64QhlLBj 9lxyZEAsDYrAoq3VGIEV/5QI/IELkSh4s1i4tDPt4spbnzJjWTyx6/Q X-Developer-Key: i=cryolitia@uniontech.com; a=ed25519; pk=tZ+U+kQkT45GRGewbMSB4VPmvpD+KkHC/Wv3rMOn/PU= X-Endpoint-Received: by B4 Relay for cryolitia@uniontech.com/20250730 with auth_id=474 X-Original-From: Cryolitia PukNgae Reply-To: cryolitia@uniontech.com From: Cryolitia PukNgae Add GPD fan driver document Signed-off-by: Cryolitia PukNgae --- Documentation/hwmon/gpd-fan.rst | 71 +++++++++++++++++++++++++++++++++++++= ++++ Documentation/hwmon/index.rst | 1 + MAINTAINERS | 1 + 3 files changed, 73 insertions(+) diff --git a/Documentation/hwmon/gpd-fan.rst b/Documentation/hwmon/gpd-fan.= rst new file mode 100644 index 0000000000000000000000000000000000000000..82f064c80aac485348f7c5179a9= c4104fd6a4745 --- /dev/null +++ b/Documentation/hwmon/gpd-fan.rst @@ -0,0 +1,71 @@ +.. SPDX-License-Identifier: GPL-2.0-or-later + +Kernel driver gpd-fan +=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D + +Author: + - Cryolitia PukNgae + +Description +------------ + +Handheld devices from Shenzhen GPD Technology Co., Ltd. provide fan readin= gs and fan control through +their embedded controllers. + +Supported devices +----------------- + +Currently the driver supports the following handhelds: + + - GPD Win Mini (7840U) + - GPD Win Mini (8840U) + - GPD Win Mini (HX370) + - GPD Pocket 4 + - GPD Duo + - GPD Win Max 2 (6800U) + - GPD Win Max 2 2023 (7840U) + - GPD Win Max 2 2024 (8840U) + - GPD Win Max 2 2025 (HX370) + - GPD Win 4 (6800U) + - GPD Win 4 (7840U) + +Module parameters +----------------- + +gpd_fan_board + Force specific which module quirk should be used. + Use it like "gpd_fan_board=3Dwm2". + + - wm2 + - GPD Win 4 (7840U) + - GPD Win Max 2 (6800U) + - GPD Win Max 2 2023 (7840U) + - GPD Win Max 2 2024 (8840U) + - GPD Win Max 2 2025 (HX370) + - win4 + - GPD Win 4 (6800U) + - win_mini + - GPD Win Mini (7840U) + - GPD Win Mini (8840U) + - GPD Win Mini (HX370) + - GPD Pocket 4 + - GPD Duo + +Sysfs entries +------------- + +The following attributes are supported: + +fan1_input + Read Only. Reads current fan RPM. + +pwm1_enable + Read/Write. Enable manual fan control. Write "0" to disable control and = run at + full speed. Write "1" to set to manual, write "2" to let the EC control = decide + fan speed. Read this attribute to see current status. + +pwm1 + Read/Write. Read this attribute to see current duty cycle in the range [= 0-255]. + When pwm1_enable is set to "1" (manual) write any value in the range [0-= 255] + to set fan speed. + diff --git a/Documentation/hwmon/index.rst b/Documentation/hwmon/index.rst index d292a86ac5da902cad02c1965c90f5de530489df..ce4419f064e1368740387af70af= 38a85cadd952d 100644 --- a/Documentation/hwmon/index.rst +++ b/Documentation/hwmon/index.rst @@ -82,6 +82,7 @@ Hardware Monitoring Kernel Drivers gigabyte_waterforce gsc-hwmon gl518sm + gpd-fan gxp-fan-ctrl hih6130 hp-wmi-sensors diff --git a/MAINTAINERS b/MAINTAINERS index 1deb9b817a37998828b6773d3dc8237c982d4bf9..d5af3b7ab7a5fdc778b4032e564= 5fd9551223148 100644 --- a/MAINTAINERS +++ b/MAINTAINERS @@ -10414,6 +10414,7 @@ GPD FAN DRIVER M: Cryolitia PukNgae L: linux-hwmon@vger.kernel.org S: Maintained +F: Documentation/hwmon/gpd-fan.rst F: drivers/hwmon/gpd-fan.c =20 GPD POCKET FAN DRIVER --=20 2.50.1