@@ -79,20 +79,9 @@ static const unsigned short normal_i2c[] = {
#define AT30TS00_DEVID 0x8201
#define AT30TS00_DEVID_MASK 0xffff
-#define AT30TSE004_DEVID 0x2200
-#define AT30TSE004_DEVID_MASK 0xffff
-
-/* Giantec */
-#define GT30TS00_DEVID 0x2200
-#define GT30TS00_DEVID_MASK 0xff00
-
#define GT34TS02_DEVID 0x3300
#define GT34TS02_DEVID_MASK 0xff00
-/* IDT */
-#define TSE2004_DEVID 0x2200
-#define TSE2004_DEVID_MASK 0xff00
-
#define TS3000_DEVID 0x2900 /* Also matches TSE2002 */
#define TS3000_DEVID_MASK 0xff00
@@ -116,9 +105,6 @@ static const unsigned short normal_i2c[] = {
#define MCP98243_DEVID 0x2100
#define MCP98243_DEVID_MASK 0xfffc
-#define MCP98244_DEVID 0x2200
-#define MCP98244_DEVID_MASK 0xfffc
-
#define MCP9843_DEVID 0x0000 /* Also matches mcp9805 */
#define MCP9843_DEVID_MASK 0xfffe
@@ -136,12 +122,6 @@ static const unsigned short normal_i2c[] = {
#define CAT34TS02C_DEVID 0x0a00
#define CAT34TS02C_DEVID_MASK 0xfff0
-#define CAT34TS04_DEVID 0x2200
-#define CAT34TS04_DEVID_MASK 0xfff0
-
-#define N34TS04_DEVID 0x2230
-#define N34TS04_DEVID_MASK 0xfff0
-
/* ST Microelectronics */
#define STTS424_DEVID 0x0101
#define STTS424_DEVID_MASK 0xffff
@@ -152,15 +132,12 @@ static const unsigned short normal_i2c[] = {
#define STTS2002_DEVID 0x0300
#define STTS2002_DEVID_MASK 0xffff
-#define STTS2004_DEVID 0x2201
-#define STTS2004_DEVID_MASK 0xffff
-
#define STTS3000_DEVID 0x0200
#define STTS3000_DEVID_MASK 0xffff
-/* Seiko Instruments */
-#define S34TS04A_DEVID 0x2221
-#define S34TS04A_DEVID_MASK 0xffff
+/* TSE2004 compliant sensors */
+#define TSE2004_DEVID 0x2200
+#define TSE2004_DEVID_MASK 0xff00
static u16 jc42_hysteresis[] = { 0, 1500, 3000, 6000 };
@@ -173,8 +150,8 @@ struct jc42_chips {
static struct jc42_chips jc42_chips[] = {
{ ADT_MANID, ADT7408_DEVID, ADT7408_DEVID_MASK },
{ ATMEL_MANID, AT30TS00_DEVID, AT30TS00_DEVID_MASK },
- { ATMEL_MANID2, AT30TSE004_DEVID, AT30TSE004_DEVID_MASK },
- { GT_MANID, GT30TS00_DEVID, GT30TS00_DEVID_MASK },
+ { ATMEL_MANID2, TSE2004_DEVID, TSE2004_DEVID_MASK },
+ { GT_MANID, TSE2004_DEVID, TSE2004_DEVID_MASK },
{ GT_MANID2, GT34TS02_DEVID, GT34TS02_DEVID_MASK },
{ IDT_MANID, TSE2004_DEVID, TSE2004_DEVID_MASK },
{ IDT_MANID, TS3000_DEVID, TS3000_DEVID_MASK },
@@ -184,19 +161,19 @@ static struct jc42_chips jc42_chips[] = {
{ MCP_MANID, MCP9808_DEVID, MCP9808_DEVID_MASK },
{ MCP_MANID, MCP98242_DEVID, MCP98242_DEVID_MASK },
{ MCP_MANID, MCP98243_DEVID, MCP98243_DEVID_MASK },
- { MCP_MANID, MCP98244_DEVID, MCP98244_DEVID_MASK },
+ { MCP_MANID, TSE2004_DEVID, TSE2004_DEVID_MASK },
{ MCP_MANID, MCP9843_DEVID, MCP9843_DEVID_MASK },
{ NXP_MANID, SE97_DEVID, SE97_DEVID_MASK },
{ ONS_MANID, CAT6095_DEVID, CAT6095_DEVID_MASK },
{ ONS_MANID, CAT34TS02C_DEVID, CAT34TS02C_DEVID_MASK },
- { ONS_MANID, CAT34TS04_DEVID, CAT34TS04_DEVID_MASK },
- { ONS_MANID, N34TS04_DEVID, N34TS04_DEVID_MASK },
+ { ONS_MANID, TSE2004_DEVID, TSE2004_DEVID_MASK },
+ { ONS_MANID, TSE2004_DEVID, TSE2004_DEVID_MASK },
{ NXP_MANID, SE98_DEVID, SE98_DEVID_MASK },
- { SI_MANID, S34TS04A_DEVID, S34TS04A_DEVID_MASK },
+ { SI_MANID, TSE2004_DEVID, TSE2004_DEVID_MASK },
{ STM_MANID, STTS424_DEVID, STTS424_DEVID_MASK },
{ STM_MANID, STTS424E_DEVID, STTS424E_DEVID_MASK },
{ STM_MANID, STTS2002_DEVID, STTS2002_DEVID_MASK },
- { STM_MANID, STTS2004_DEVID, STTS2004_DEVID_MASK },
+ { STM_MANID, TSE2004_DEVID, TSE2004_DEVID_MASK },
{ STM_MANID, STTS3000_DEVID, STTS3000_DEVID_MASK },
};
TSE2004 standardizes the device ID of compliant temperature sensors to be 0x22xx, where xx is the device revision. Use a single define for all TSE2004 compliant temperature sensors, and relax the device id mask to match the upper 8 bit of the device id register. Signed-off-by: Guenter Roeck <linux@roeck-us.net> --- drivers/hwmon/jc42.c | 43 ++++++++++--------------------------------- 1 file changed, 10 insertions(+), 33 deletions(-)