From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from lithops.sigma-star.at (mailout.nod.at [116.203.167.152]) (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 F1C751397; Fri, 27 Feb 2026 07:46:54 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=116.203.167.152 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1772178417; cv=none; b=T79yb8iPIAwUY9RpEiC04vOkwDTT7AC7gOlS9DgzZLHabiqOu3FlFR/RTxnrAv0Q3Nm9ZZFbG1iFEF2G/yUCXRpxPYmyXlzt+B50hNH4gqFGFRGDTplan9PgtyawvGDGg/hPMqQ5uNqEuhxxR12SvMuRWdGgMn/Lk8yV3EKEvws= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1772178417; c=relaxed/simple; bh=Swi2P6Q/gTmIpsIEdrPw6i8z8fdQ4iYvhdMTsDeq/eo=; h=Date:From:To:Cc:Message-ID:In-Reply-To:References:Subject: MIME-Version:Content-Type; b=Sxo/PCIk98rai6eeebk1v98aKRy92Rt3PhvHzZWQ0BqAzSCGDf3B7ZWZF96yQ6IUFTwcl+ERVSw1cpeoO3Go7Xc1oQv/JRXqUx/dgFvOjAUXMASPWol55Yj774f0eQBtKohaJDq2QmwVpRiH8PFLSNd04lAl0/7+akrI+Qp/jJo= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=nod.at; spf=fail smtp.mailfrom=nod.at; arc=none smtp.client-ip=116.203.167.152 Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=nod.at Authentication-Results: smtp.subspace.kernel.org; spf=fail smtp.mailfrom=nod.at Received: from localhost (localhost [127.0.0.1]) by lithops.sigma-star.at (Postfix) with ESMTP id D2B11298580; Fri, 27 Feb 2026 08:46:52 +0100 (CET) Received: from lithops.sigma-star.at ([127.0.0.1]) by localhost (lithops.sigma-star.at [127.0.0.1]) (amavisd-new, port 10032) with ESMTP id hfUOubwOJEVy; Fri, 27 Feb 2026 08:46:51 +0100 (CET) Received: from localhost (localhost [127.0.0.1]) by lithops.sigma-star.at (Postfix) with ESMTP id C7B78298599; Fri, 27 Feb 2026 08:46:51 +0100 (CET) Received: from lithops.sigma-star.at ([127.0.0.1]) by localhost (lithops.sigma-star.at [127.0.0.1]) (amavisd-new, port 10026) with ESMTP id vzR7oCGiDGlw; Fri, 27 Feb 2026 08:46:51 +0100 (CET) Received: from lithops.sigma-star.at (lithops.sigma-star.at [195.201.40.130]) by lithops.sigma-star.at (Postfix) with ESMTP id 80282298580; Fri, 27 Feb 2026 08:46:51 +0100 (CET) Date: Fri, 27 Feb 2026 08:46:51 +0100 (CET) From: Richard Weinberger To: Guenter Roeck Cc: linux-kernel , linux-pwm , linux-hwmon , Uwe =?utf-8?Q?Kleine-K=C3=B6nig?= , julian friedrich Message-ID: <1892064865.155.1772178411224.JavaMail.zimbra@nod.at> In-Reply-To: <9c733024-8ad6-459d-ae5a-a9825f85c506@roeck-us.net> References: <20260225125159.20822-1-richard@nod.at> <9c733024-8ad6-459d-ae5a-a9825f85c506@roeck-us.net> Subject: Re: [PATCH] [RFC] hwmon: nct6775: Register fan PWMs as PWM chip 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 X-Mailer: Zimbra 8.8.12_GA_3807 (ZimbraWebClient - FF147 (Linux)/8.8.12_GA_3809) Thread-Topic: hwmon: nct6775: Register fan PWMs as PWM chip Thread-Index: umDdz0jqWtvRem2Pc1uXQyHbpW7x4g== Hello Guenter, ----- Urspr=C3=BCngliche Mail ----- > Von: "Guenter Roeck" >> - Exporting a PWM for external use is only allowed when the fan mode >> is set to manual or off. >> - As soon as a PWM is exported, changing its configuration is no >> longer possible through the hwmon sysfs interface, reading is >> still allowed. >> - Changing the PWM period is not supported. IMHO, it is too risky >> since the PWMs usually control system fans and similar components. >> - Reading and decoding the current PWM period is only supported for >> one chip variant so far, for all other chips, a fixed period of >> 100ms is assumed. >>=20 >=20 > This is a good start, but I'll want to see stronger safeguards. > - Creating a pwmchip entry for a pwm channel must be triggered by > device property data, obtained either from devicetree or through > DMI or through device properties embedded in ACPI data. For each > channel, this must be confirmed by checking that the channel is > not associated with a fan control channel. In my case it's a x86 based industrial PC with direct access. What safeguard do you suggest in this case? A module parameter? Also for ACPI data, what exactly do you have in mind? > - If a pwm channel is configured as pwmchip, it must not be used for fan > control, meaning the hwmon properties associated with that channel > must not be created. Ok. =20 > This will retain current functionality while enabling support for using > pwm channels for purposes other than fan control. >=20 > Thanks, > Guenter