Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/sys/dev/i2c - Add Maxim MAX6604.



details:   https://anonhg.NetBSD.org/src/rev/454d94767125
branches:  trunk
changeset: 359721:454d94767125
user:      msaitoh <msaitoh%NetBSD.org@localhost>
date:      Thu Feb 22 10:09:12 2018 +0000

description:
- Add Maxim MAX6604.
- Microchip EMC1501.
- ADT7408's device ID is not 0x80 but 0x08.

diffstat:

 sys/dev/i2c/sdtemp.c     |   8 ++++++--
 sys/dev/i2c/sdtemp_reg.h |  10 +++++++---
 2 files changed, 13 insertions(+), 5 deletions(-)

diffs (74 lines):

diff -r b1d46fa13442 -r 454d94767125 sys/dev/i2c/sdtemp.c
--- a/sys/dev/i2c/sdtemp.c      Thu Feb 22 10:02:08 2018 +0000
+++ b/sys/dev/i2c/sdtemp.c      Thu Feb 22 10:09:12 2018 +0000
@@ -1,4 +1,4 @@
-/*      $NetBSD: sdtemp.c,v 1.32 2016/08/03 03:35:24 msaitoh Exp $        */
+/*      $NetBSD: sdtemp.c,v 1.33 2018/02/22 10:09:12 msaitoh Exp $        */
 
 /*
  * Copyright (c) 2009 The NetBSD Foundation, Inc.
@@ -30,7 +30,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: sdtemp.c,v 1.32 2016/08/03 03:35:24 msaitoh Exp $");
+__KERNEL_RCSID(0, "$NetBSD: sdtemp.c,v 1.33 2018/02/22 10:09:12 msaitoh Exp $");
 
 #include <sys/param.h>
 #include <sys/systm.h>
@@ -115,6 +115,8 @@
        "Giantec GT34TS02" },
     { MAXIM_MANUFACTURER_ID, MAX_6604_DEVICE_ID,     MAX_6604_MASK,      NULL,
        "Maxim MAX6604" },
+    { MAXIM_MANUFACTURER_ID, MAX_6604_2_DEVICE_ID,   MAX_6604_MASK,      NULL,
+       "Maxim MAX6604" },
     { MCP_MANUFACTURER_ID,  MCP_9804_DEVICE_ID,             MCP_9804_MASK,       CMCP,
        "Microchip Tech MCP9804" },
     { MCP_MANUFACTURER_ID,  MCP_9805_DEVICE_ID,             MCP_9805_MASK,       NULL,
@@ -125,6 +127,8 @@
        "Microchip Tech MCP98243" },
     { MCP_MANUFACTURER_ID,  MCP_98244_DEVICE_ID,     MCP_98244_MASK,     CMCP,
        "Microchip Tech MCP98244" },
+    { MCP2_MANUFACTURER_ID, MCP2_EMC1501_DEVICE_ID,  MCP2_EMC1501_MASK,          NULL,
+       "Microchip Tech EMC1501" },
     { ADT_MANUFACTURER_ID,  ADT_7408_DEVICE_ID,             ADT_7408_MASK,       NULL,
        "Analog Devices ADT7408" },
     { NXP_MANUFACTURER_ID,  NXP_SE98_DEVICE_ID,             NXP_SE98_MASK,       NULL,
diff -r b1d46fa13442 -r 454d94767125 sys/dev/i2c/sdtemp_reg.h
--- a/sys/dev/i2c/sdtemp_reg.h  Thu Feb 22 10:02:08 2018 +0000
+++ b/sys/dev/i2c/sdtemp_reg.h  Thu Feb 22 10:09:12 2018 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: sdtemp_reg.h,v 1.12 2016/12/07 04:58:39 nonaka Exp $   */
+/*     $NetBSD: sdtemp_reg.h,v 1.13 2018/02/22 10:09:12 msaitoh Exp $  */
 
 /*
  * Copyright (c) 2009 The NetBSD Foundation, Inc.
@@ -122,6 +122,7 @@
 /* Maxim */
 #define        MAXIM_MANUFACTURER_ID           0x004D
 #define        MAX_6604_DEVICE_ID              0x3E00
+#define        MAX_6604_2_DEVICE_ID            0x5400
 #define        MAX_6604_MASK                   0xFFFF
 
 /* Microchip */
@@ -136,6 +137,9 @@
 #define        MCP_98243_MASK                  0xFFFC
 #define        MCP_98244_DEVICE_ID             0x2200
 #define        MCP_98244_MASK                  0xFFFC
+#define        MCP2_MANUFACTURER_ID            0x1055  /* PCI-SIG manufacturer ID */
+#define        MCP2_EMC1501_DEVICE_ID          0x0842
+#define        MCP2_EMC1501_MASK               0xFFFF
 
 #define        SDTEMP_REG_MCP_RESOLUTION_9804  0x08 /* 9804, 9824[23] */
 #define        SDTEMP_REG_MCP_RESOLUTION_98244 0x09 /* 98244 */
@@ -150,8 +154,8 @@
 
 /* Analog Devices */
 #define        ADT_MANUFACTURER_ID             0x11D4
-#define        ADT_7408_DEVICE_ID              0x8001
-#define        ADT_7408_MASK                   0xFFFF
+#define        ADT_7408_DEVICE_ID              0x0800  /* e.g. 0x0801 */
+#define        ADT_7408_MASK                   0xFFF0
 
 /* IDT */
 #define        IDT_MANUFACTURER_ID             0x00B3



Home | Main Index | Thread Index | Old Index