summaryrefslogtreecommitdiffstats
path: root/drivers/hwmon/nct6683.c
diff options
context:
space:
mode:
authorJiqi Li <lijq9@lenovo.com>2021-03-04 18:44:21 +0800
committerGuenter Roeck <linux@roeck-us.net>2021-04-20 06:50:14 -0700
commitbfbbbe04d01222aa484400a7257f34a952af2237 (patch)
tree5a96282a67d3e57837b80c7b0a6f42128d2e0d4b /drivers/hwmon/nct6683.c
parente20a7198a20fcd406809ccf25e6331331d352718 (diff)
downloadlinux-bfbbbe04d01222aa484400a7257f34a952af2237.tar.bz2
hwmon: (nct6683) Support NCT6686D
Add support for NCT6686D chip used in the Lenovo P620. Signed-off-by: Jiqi Li <lijq9@lenovo.com> Reviewed-by: Mark Pearson <markpearson@lenovo.com> Link: https://lore.kernel.org/r/20210304104421.1912934-1-lijq9@lenovo.com Signed-off-by: Guenter Roeck <linux@roeck-us.net>
Diffstat (limited to 'drivers/hwmon/nct6683.c')
-rw-r--r--drivers/hwmon/nct6683.c11
1 files changed, 9 insertions, 2 deletions
diff --git a/drivers/hwmon/nct6683.c b/drivers/hwmon/nct6683.c
index a23047a3bfe2..256e8d62f858 100644
--- a/drivers/hwmon/nct6683.c
+++ b/drivers/hwmon/nct6683.c
@@ -1,7 +1,7 @@
// SPDX-License-Identifier: GPL-2.0-or-later
/*
* nct6683 - Driver for the hardware monitoring functionality of
- * Nuvoton NCT6683D/NCT6687D eSIO
+ * Nuvoton NCT6683D/NCT6686D/NCT6687D eSIO
*
* Copyright (C) 2013 Guenter Roeck <linux@roeck-us.net>
*
@@ -12,6 +12,7 @@
*
* Chip #vin #fan #pwm #temp chip ID
* nct6683d 21(1) 16 8 32(1) 0xc730
+ * nct6686d 21(1) 16 8 32(1) 0xd440
* nct6687d 21(1) 16 8 32(1) 0xd590
*
* Notes:
@@ -33,7 +34,7 @@
#include <linux/platform_device.h>
#include <linux/slab.h>
-enum kinds { nct6683, nct6687 };
+enum kinds { nct6683, nct6686, nct6687 };
static bool force;
module_param(force, bool, 0);
@@ -41,11 +42,13 @@ MODULE_PARM_DESC(force, "Set to one to enable support for unknown vendors");
static const char * const nct6683_device_names[] = {
"nct6683",
+ "nct6686",
"nct6687",
};
static const char * const nct6683_chip_names[] = {
"NCT6683D",
+ "NCT6686D",
"NCT6687D",
};
@@ -66,6 +69,7 @@ static const char * const nct6683_chip_names[] = {
#define SIO_NCT6681_ID 0xb270 /* for later */
#define SIO_NCT6683_ID 0xc730
+#define SIO_NCT6686_ID 0xd440
#define SIO_NCT6687_ID 0xd590
#define SIO_ID_MASK 0xFFF0
@@ -1362,6 +1366,9 @@ static int __init nct6683_find(int sioaddr, struct nct6683_sio_data *sio_data)
case SIO_NCT6683_ID:
sio_data->kind = nct6683;
break;
+ case SIO_NCT6686_ID:
+ sio_data->kind = nct6686;
+ break;
case SIO_NCT6687_ID:
sio_data->kind = nct6687;
break;