124 Commits

Author SHA1 Message Date
Frederic BOLTZ
66ddfee6fb Merge pull request #132 from xaizek/fix-for-loop-typo
Fix a typo in start_fan_cfg_update()
2025-06-30 11:54:56 +02:00
xaizek
8d7e74db1b Fix a typo in start_fan_cfg_update()
This fixes commit 563bade4b0 ("Proper management of
configuration mode") from #121 which has invalid condition in one of the
for loops.

Fixes #131
2025-06-29 21:34:35 +03:00
Frederic BOLTZ
cd6a28196c Merge pull request #130 from xaizek/makefile-revert
Bring back copying of Makefile as is
2025-06-19 09:43:14 +02:00
xaizek
5ec66315eb Makefile: silence errors from git
git commands are run during build of the module by DKMS when there is no
git repository, that error output look confusing.
2025-06-18 20:45:44 +03:00
xaizek
e315b9db4a Revert "Makefile: don't install the file as is for DKMS"
This reverts commit ebbe59b205.

It caused difficulties with packaging the module which require relevant
knowledge to resolve.  So far it seems simpler to revert this
modification.
2025-06-18 20:43:11 +03:00
Frederic BOLTZ
7df2680746 Merge pull request #127 from xaizek/makefile-improvements
Makefile improvements
2025-06-15 10:30:45 -07:00
xaizek
46fecbf216 Makefile: drop unconditional installation of dh-dkms
The check for a package was added along with its unconditional
installation.
2025-06-15 16:20:51 +03:00
xaizek
ebbe59b205 Makefile: don't install the file as is for DKMS
Using the whole Makefile results in DKMS running commands unrelated to
the build process (like git commands) which only produce confusing error
output.

Just write `obj-m += nct6687.o` to the Makefile for DKMS as that's the
only thing necessary for it to work.

This also gets rid of `MAKE[0]` in `dkms.conf`.
2025-06-15 11:54:46 +03:00
xaizek
2dccefc54d Makefile: silence unuseful sed's warning
`/etc/fedora-release` doesn't exist on non-Fedora systems, but `sed` is
used on it unconditionally.  Redirect error to `/dev/null` and give the
variable a reasonable value for systems without the file.
2025-06-15 11:54:41 +03:00
Frederic BOLTZ
e2730ffad9 Merge pull request #126 from colluca/patch-1
Fix missing dh-dkms on newer Ubuntu distros
2025-05-17 18:21:07 +02:00
Luca Colagrande
80bd1936a8 Fix missing dh-dkms on newer Ubuntu distros 2025-05-17 13:59:40 +02:00
Frederic BOLTZ
19f66d618f Merge pull request #121 from xaizek/register-update
Proper management of configuration mode
2025-04-27 10:14:22 +02:00
xaizek
563bade4b0 Proper management of configuration mode
Instead of sleeping for 50 milliseconds and hoping that the EC is in
expected state, poll EC's status register to know whether it has entered
or left configuration mode.
2025-04-25 21:08:46 +03:00
Frederic BOLTZ
5ea2a02307 Merge pull request #118 from philipl/dkms-fix
dkms: support building for non-running kernels
2025-04-25 08:40:12 +02:00
Philip Langdale
c053463605 dkms: support building for non-running kernels
This small tweak allows the dkms build to override the target kernel version
to build for a kernel that isn't the current running one.
2025-03-24 09:08:59 -07:00
Frederic BOLTZ
2f1a27a29f Merge pull request #109 from gokomer/dnf5-support
add support for dnf5
2024-11-05 08:46:24 +00:00
Ömer GÖK
5913ac09d1 add support for dnf5 2024-11-05 03:31:59 +03:00
Frederic BOLTZ
f45b72a6ca Merge pull request #101 from gwenhael-le-moine/main
fix compilation with kernel 6.11 (.0-rc6)
2024-09-02 14:45:52 +00:00
Frederic BOLTZ
ec431bf2ce Update nct6687.c
Keep backward compatibility with prévious kernet.

Could you try on 6.11?
2024-09-02 16:02:07 +02:00
Gwenhael Le Moine
66c35797a5 fix compilation with kernel 6.11.0-rc6 2024-09-02 13:35:20 +02:00
Frederic BOLTZ
0ee35ed954 Merge pull request #91 from desowin/pwm-readback-fan2go-workaround
[RFC] Update cached pwm values on pwm store
2024-02-23 09:55:00 +01:00
Tomasz Moń
3e7e79c3f3 [RFC] Update cached pwm values on pwm store
Userspace application fan2go expects written pwm value to be returned on
read after 5 ms. If the value read back then fan2go assumes that the pwm
is resolution limited and was clamped by the driver.

The nct6687d driver returns cached pwm values on reads. The cache is
updated at most once per second (unless resumed from suspend) and
therefore it leads for fan2go to falsely analyzing the pwm output as
resolution limited.

Avoid the issue by waiting for pwm value to be reported back on each
write and updating the cache immediately. On MSI PRO Z790-P WIFI
(MS-7E06) it takes around 500 ms for the pwm value (with DC mode fan
connected, so it is not a real PWM but a voltage) to be read back after
write.

Signed-off-by: Tomasz Moń <desowin@gmail.com>
2024-02-22 18:51:51 +01:00
Frederic BOLTZ
ba813f1ea3 Merge pull request #88 from SergeyMy/patch-5
fixed "mode" to "enable"
2024-02-04 10:00:05 +01:00
SergeyMy
1c0b17a90f Update nct6687.c
:)
2024-02-04 02:46:18 +05:00
SergeyMy
07c1b5a166 fixed mode to enable
fixed
https://github.com/Fred78290/nct6687d/pull/87
2024-02-03 08:43:50 +05:00
Frederic BOLTZ
5295dfac74 Merge pull request #87 from xaizek/add-pwm-enable
Add `pwm[1-8]_enable`
2024-01-28 14:14:38 +01:00
xaizek
76b5717ced Explain how to find module's directory in sysfs 2024-01-28 13:33:40 +02:00
xaizek
f04739ef6c Improve "VERIFIED" section in the README 2024-01-28 00:47:46 +02:00
xaizek
735c472f76 Add pwm[1-8]_enable to sysfs
They can be used to switch manual vs. firmware-configured fan mode.
2024-01-28 00:47:45 +02:00
xaizek
8495d82062 Add configuration section to the README 2024-01-28 00:45:14 +02:00
xaizek
a16f14993f Document available parameters 2024-01-28 00:23:05 +02:00
xaizek
3937b12170 Fix restoring automatic fan mode on module unload
nct6687_restore_fan_control() could only restore manual fan control, but
not the automatic one due to the way it applied previous state of the
bit.
2024-01-28 00:23:05 +02:00
Frederic BOLTZ
aba6f2b9ed Merge pull request #86 from Stefanqn/main
doc: add issues + solutions
2024-01-27 22:55:41 +01:00
Stefan Kuhn
f7ab53ab42 doc: add issues + solutions 2024-01-26 13:07:05 +01:00
Frederic BOLTZ
42e7434df3 Merge pull request #84 from SergeyMy/patch-4
it works on nct6683 too
2023-11-28 21:25:56 +01:00
SergeyMy
b1d0fe89df Update nct6687.c 2023-11-28 20:45:02 +05:00
SergeyMy
20574d2335 it works on nct6683 too
https://github.com/Fred78290/nct6687d/issues/82
2023-11-28 20:27:08 +05:00
Frederic BOLTZ
390bc92839 Merge pull request #83 from SergeyMy/patch-3
add mutex io
2023-11-23 20:05:28 +01:00
SergeyMy
95d5c7b318 add mutex io
must be atomic, otherwise unintended consequences
2023-11-23 20:55:14 +05:00
Frederic BOLTZ
06b88a04ac Merge pull request #81 from SergeyMy/patch-2
Update README.md
2023-11-03 11:56:50 +01:00
SergeyMy
5b26ebe720 Update README.md 2023-11-02 20:57:35 +05:00
Frederic BOLTZ
6761c42cfe Merge pull request #80 from SergeyMy/main
backport kernel-6.6-rc7
2023-10-30 09:47:58 +01:00
SergeyMy
44037baa94 Update nct6687.c 2023-10-29 09:13:21 +05:00
SergeyMy
be4509e2db backport kernel-6.6-rc7
Signed-off-by: SergeyMy <virtual@ufasp.ru>
2023-10-27 20:07:49 +05:00
Frederic BOLTZ
cdfe855342 Merge pull request #77 from josefwells/main
Update README.md
2023-09-22 09:40:15 +02:00
Josef Wells
a0469b8a12 Update README.md
Debian bookworm, trixie... look like they need dh-dkms package as well.
2023-09-21 20:51:34 -05:00
Frederic BOLTZ
df1565ad8e Merge pull request #65 from Sir-Photch/patch-1 2023-03-10 18:38:50 +01:00
Christoph
daf42ec9f4 Update README.md
https://wiki.archlinux.org/title/Kernel_module#systemd
2023-03-10 18:28:03 +01:00
Frederic BOLTZ
f065053226 Merge pull request #64 from llyyr/fix-deprecated-dkms
Remove dkms' deprecated REMAKE_INITRD option
2023-02-23 11:56:05 +01:00
llyyr
5c564bb92b Remove dkms' deprecated REMAKE_INITRD option
Fixes #57
2023-02-22 08:31:41 +05:30