All of lore.kernel.org
 help / color / mirror / Atom feed
From: Guenter Roeck <guenter.roeck@ericsson.com>
To: lm-sensors@vger.kernel.org
Subject: [lm-sensors] [PATCH] sensors-detect: Add code to detect ADT7461A /
Date: Wed, 06 Apr 2011 07:21:37 +0000	[thread overview]
Message-ID: <20110406072137.GB23562@ericsson.com> (raw)

This patch adds code to detect ADT7461A / NCT1008 to sensors-detect.

---

Index: prog/detect/sensors-detect
=================================--- prog/detect/sensors-detect	(revision 5954)
+++ prog/detect/sensors-detect	(working copy)
@@ -1045,6 +1045,11 @@
 		i2c_addrs => [0x4c..0x4d],
 		i2c_detect => sub { lm90_detect(@_, 5); },
 	}, {
+		name => "Analog Devices ADT7461A, ON Semiconductor NCT1008",
+		driver => "to-be-written",	# lm90
+		i2c_addrs => [0x4c..0x4d],
+		i2c_detect => sub { lm90_detect(@_, 13); },
+	}, {
 		name => "Analog Devices ADT7481",
 		driver => "to-be-written",
 		i2c_addrs => [0x4c, 0x4b],
@@ -4317,7 +4322,8 @@
 #		  4 = MAX6654, 5 = ADT7461,
 #		  6 = MAX6646/MAX6647/MAX6648/MAX6649/MAX6692,
 #		  8 = W83L771W/G, 9 = TMP401, 10 = TMP411,
-#		  11 = W83L771AWG/ASG, 12 = MAX6690
+#		  11 = W83L771AWG/ASG, 12 = MAX6690,
+#		  13 = ADT7461A/NCT1008
 # Registers used:
 #   0x03: Configuration
 #   0x04: Conversion rate
@@ -4416,6 +4422,12 @@
 		return if $mid != 0x4d;		# Maxim
 		return 8 if $cid = 0x09;	# MAX6690
 	}
+	if ($chip = 13) {
+		return if ($conf & 0x1b) != 0;
+		return if $rate > 0x0a;
+		return if $mid != 0x41;		# Analog Devices
+		return 8 if $cid = 0x57;	# ADT7461A, NCT1008
+	}
 	return;
 }
 
Index: CHANGES
=================================--- CHANGES	(revision 5954)
+++ CHANGES	(working copy)
@@ -1,6 +1,9 @@
 lm-sensors CHANGES file
 -----------------------
 
+head
+  sensors-detect: Add detection of ADT7461A / NCT1008
+
 3.3.0 (2011-03-28)
   Makefile: Check for bison and flex
   libsensors: Add support for intrusion detection (#2370)

_______________________________________________
lm-sensors mailing list
lm-sensors@lm-sensors.org
http://lists.lm-sensors.org/mailman/listinfo/lm-sensors

             reply	other threads:[~2011-04-06  7:21 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-04-06  7:21 Guenter Roeck [this message]
2011-04-06  8:08 ` [lm-sensors] [PATCH] sensors-detect: Add code to detect Jean Delvare
2011-07-08 16:25 ` [lm-sensors] [PATCH] sensors-detect: Add code to detect LM95245 Guenter Roeck
2011-07-10 15:46 ` Jean Delvare
2011-07-10 15:57 ` Guenter Roeck
2014-12-04 19:14 ` [lm-sensors] [PATCH] sensors-detect: Add code to detect TMP435 Guenter Roeck
2014-12-04 21:57 ` Guenter Roeck
2014-12-05  9:37 ` Jean Delvare
2014-12-05  9:43 ` Jean Delvare
2014-12-05 14:16 ` Guenter Roeck

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20110406072137.GB23562@ericsson.com \
    --to=guenter.roeck@ericsson.com \
    --cc=lm-sensors@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.