Skip to contentSkip to conversation

adt7475 support status update?

lm-sensors Hans de Goede 5 participants 15 messages Feb 13, 2008 – Feb 21, 2008

Subsystems (3)
lore
Share & tools
lore
#0 lore raw

Hi all,

Yesterday the store called me that my defective Asus M2N-SLI Deluxe has been replaced by a new one. So I should be able to start working on the adt7475 driver again soon.

Is there any progress after Jordan Crouse latest patch:
http://lists.lm-sensors.org/pipermail/lm-sensors/2008-January/022338.html

?

Thanks & Regards,

Hans

_______________________________________________
lm-sensors mailing list
[email protected]
http://lists.lm-sensors.org/mailman/listinfo/lm-sensors

#1 lore raw
Quoted 2 lines · Hans de Goede

Is there any progress after Jordan Crouse latest patch:
http://lists.lm-sensors.org/pipermail/lm-sensors/2008-January/022338.html

I've been running that driver for about a month now and it seems to work fine. I have not yet tried hooking up any fans to test the fan speed reporting.

Matt Roberds

_______________________________________________
lm-sensors mailing list
[email protected]
http://lists.lm-sensors.org/mailman/listinfo/lm-sensors

#2 lore raw
In reply to Hans de Goede

Hi Hans,

Quoted 10 lines · Hans de Goede

Hi all,

Yesterday the store called me that my defective Asus M2N-SLI Deluxe has been replaced by a new one. So I should be able to start working on the adt7475 driver again soon.

Is there any progress after Jordan Crouse latest patch:
http://lists.lm-sensors.org/pipermail/lm-sensors/2008-January/022338.html

?

Not that I know of. You might want to update the wiki/Devices page to record the current state so that you (and others) can look it up at a later time.

Signature · 6 lines
Jean Delvare

_______________________________________________
lm-sensors mailing list
[email protected]
http://lists.lm-sensors.org/mailman/listinfo/lm-sensors
#3 lore raw
In reply to Hans de Goede
Quoted 9 lines · Jean Delvare

Hi Hans,

Quoted 6 lines · Hans de Goede

Hi all,

Yesterday the store called me that my defective Asus M2N-SLI Deluxe has been replaced by a new one. So I should be able to start working on the adt7475 driver again soon.

Quoted 8 lines
Quoted 4 lines

Is there any progress after Jordan Crouse latest patch:
http://lists.lm-sensors.org/pipermail/lm-sensors/2008-January/022338.html

?

Not that I know of. You might want to update the wiki/Devices page to record the current state so that you (and others) can look it up at a later time.

There was one little buglet that needed to be fixed (I2C_DRIVERID_ADT74XX should be I2C_DRIVERID_ADT7475)

but by all reports, things were looking good. I was actually getting ready to send the updated patch to Mark to start the trip upstream, but I'll hold off if you want to test some more.

I'll reply with an up-to-date version against HEAD.

Jordan

Signature · 10 lines
Jordan Crouse
Systems Software Development Engineer 
Advanced Micro Devices, Inc.



_______________________________________________
lm-sensors mailing list
[email protected]
http://lists.lm-sensors.org/mailman/listinfo/lm-sensors
#4 lore raw
In reply to Hans de Goede
Quoted 9 lines · Jean Delvare

Hi Hans,

Quoted 6 lines · Hans de Goede

Hi all,

Yesterday the store called me that my defective Asus M2N-SLI Deluxe has been replaced by a new one. So I should be able to start working on the adt7475 driver again soon.

Quoted 8 lines
Quoted 4 lines

Is there any progress after Jordan Crouse latest patch:
http://lists.lm-sensors.org/pipermail/lm-sensors/2008-January/022338.html

?

Not that I know of. You might want to update the wiki/Devices page to record the current state so that you (and others) can look it up at a later time.

Updated patch against HEAD is attached. Thanks.

[PATCH] hwmon: Add a driver for the ADT7475 thermal sensor

From: Jordan Crouse <[email protected]>

HWMON driver for the ADT7475 thermal sensor.

---

 Documentation/hwmon/adt7475 |  110 +++++
 drivers/hwmon/Kconfig       |   10 
 drivers/hwmon/Makefile      |    1 
 drivers/hwmon/adt7475.c     |  965 +++++++++++++++++++++++++++++++++++++++++++
 include/linux/i2c-id.h      |    2 
 5 files changed, 1087 insertions(+), 1 deletions(-)
Documentation/hwmon/adt7475 new file +110 -0
new file mode 100644
index 0000000..491e5e0
@@ -0,0 +1,110 @@
+This describes the interface for the ADT7475 driver:
+
+(there are 4 fans, numbered fan1 to fan4):
+
+fanX_input              Read the current speed of the fan (in RPMs)
+fanX_min                Read/write the minimum speed of the fan.  Dropping
+	   		below this sets an alarm.
+
+(there are three PWMs, numbered pwm1 to pwm3):
+
+pwmX                    Read/write the current duty cycle of the PWM.  Writes
+     			only have effect when auto mode is turned off (see
+			below).
+
+pwmX_enable             Read/write the PWM configuration based on the following
+                        table:
+
+		        0 - Remote1 temp controls PWMx (auto mode)
+		        1 - local temp controls PWMx (auto mode)
+	 	        2 - remote2 temp controls PWMx (auto mode)
+                        3 - PWMx runs at full speed
+                        4 - PWMx is disabled
+                        5 - Use fastest speed calculated by local and remote2
+                        6 - Use fastest speed calculated by all three channels
+                        7 - Manual mode
+
+pwmX_freq               Read/write the PWM frequency.  The value returned is
+	  	        an index into the following table:
+
+		        0x0 - 11.0 Hz
+		        0x1 - 14.7 Hz
+		        0x2 - 22.1 Hz
+		        0x3 - 29.4 Hz
+		        0x4 - 35.3 Hz
+		        0x5 - 44.1 Hz
+		        0x6 - 58.8 Hz
+		        0x7 - 88.2 Hz
+
+pwmX_max                Read/write the maximum PWM duty cycle.  The PWM
+                        duty cycle will never exceed this.
+
+pwmX_min                Read/write the minimum PWM duty cycle in automatic mode
+
+(there are three temperature settings numbered temp1 to temp3):
+
+tempX_input             Read the current temperature.  The value is in milli
+			degrees of Celsius.
+
+tempX_label		Returns the "name" of the sensor as described in the
+			datasheet (remote1, local, or remote2)
+
+tempX_max               Read/write the upper temperature limit - exceeding this
+	                will cause an alarm.
+
+tempX_min               Read/write the lower temperature limit - exceeding this
+                        will cause an alarm.
+
+tempX_offset            Read/write the temperature adjustment offset
+
+tempX_crit_max        Read/write the THERM limit for remote1.  Exceeding this
+                        causes the chip to force the processor off.
+
+tempX_auto_min   	Read/write the minimum temperature where the fans will
+                        turn on in automatic mode.
+
+tempX_auto_range  	Read/write the range over which the automatic fan
+			control will be executed.  The value returned is a
+			index into the following table:
+
+			0x0 - 2 C
+			0x1 - 2.5 C
+			0x2 - 3.33 C
+			0x3 - 4 C
+			0x4 - 5 C
+			0x5 - 6.67 C
+			0x6 - 8 C
+			0x7 - 10 C
+			0x8 - 13.33 C
+			0x9 - 16 C
+			0xA - 20 C
+			0xB - 26.67 C
+			0xC - 32 C
+			0xD - 40 C
+			0xE - 53.33 C
+			0xF - 80 C
+
+tempX_crit_hyst 	set the temperature range below crit_max where the
+                        fans will stay on - this helps drive the temperature
+                        low enough so it doesn't stay near the edge and
+                        cause THERM to keep tripping.
+
+tempX_alarm		Read a 1 if the max/min alarm is set
+tempX_crit_alarm	Read a 1 if the critical limit is exceeded
+tempX_fault		Read a 1 if either temp1 or temp3 diode has a fault
+
+(There are two voltage settings, in1 and in2):
+
+inX_input               Read the current voltage on VCC.  Value is in
+			millivolts.
+
+inX_min                 read/write the minimum voltage limit.
+			Dropping below this causes an alarm.
+
+inX_max   		read/write the maximum voltage limit.
+			Exceeding this causes an alarm.
+
+inX_label		Return the name of the input as specified in the
+			datasheet (vcc or vccp)
+
+inX_alarm		Read a 1 if the max/min alarm is set.
drivers/hwmon/Kconfig +10 -0
index 410ffe4..a028560 100644
@@ -143,6 +143,16 @@ config SENSORS_ADT7470
 	  This driver can also be built as a module. If so, the module
 	  will be called adt7470.
 
+config SENSORS_ADT7475
+	tristate "Analog Devices ADT7475"
+	depends on I2C && EXPERIMENTAL
+	help
+	  If you say yes here you get support for the Analog Devices
+	  ADT7475 sensor chip.
+
+	  This driver can also be build as a module.  If so, the module
+	  will be called adt7475.
+
 config SENSORS_K8TEMP
 	tristate "AMD Athlon64/FX or Opteron temperature sensor"
 	depends on X86 && PCI && EXPERIMENTAL
drivers/hwmon/Makefile +1 -0
index 8241613..a75227c 100644
@@ -24,6 +24,7 @@ obj-$(CONFIG_SENSORS_ADM1031)	+= adm1031.o
 obj-$(CONFIG_SENSORS_ADM9240)	+= adm9240.o
 obj-$(CONFIG_SENSORS_ADS7828)	+= ads7828.o
 obj-$(CONFIG_SENSORS_ADT7470)	+= adt7470.o
+obj-$(CONFIG_SENSORS_ADT7475)   += adt7475.o
 obj-$(CONFIG_SENSORS_APPLESMC)	+= applesmc.o
 obj-$(CONFIG_SENSORS_AMS)	+= ams/
 obj-$(CONFIG_SENSORS_ATXP1)	+= atxp1.o
drivers/hwmon/adt7475.c new file +965 -0

965 lines not on this page · raw message

include/linux/i2c-id.h +1 -1
index b979112..2efb095 100644
@@ -97,7 +97,7 @@
 #define I2C_DRIVERID_I2CDEV	900
 
 #define I2C_DRIVERID_OV7670 1048	/* Omnivision 7670 camera */
-
+#define I2C_DRIVERID_ADT7475 1049
 /*
  * ---- Adapter types ----------------------------------------------------
  */

_______________________________________________
lm-sensors mailing list
[email protected]
http://lists.lm-sensors.org/mailman/listinfo/lm-sensors

#5 lore raw
In reply to Hans de Goede

Hi Jordan,

Quoted 13 lines · Jordan Crouse
Quoted 12 lines · Jean Delvare

Hi Hans,

Quoted 9 lines · Hans de Goede

Hi all,

Yesterday the store called me that my defective Asus M2N-SLI Deluxe has been replaced by a new one. So I should be able to start working on the adt7475 driver again soon.

Is there any progress after Jordan Crouse latest patch:
http://lists.lm-sensors.org/pipermail/lm-sensors/2008-January/022338.html

Quoted 8 lines
Quoted 5 lines
Quoted 1 line

?

Not that I know of. You might want to update the wiki/Devices page to record the current state so that you (and others) can look it up at a later time.

There was one little buglet that needed to be fixed (I2C_DRIVERID_ADT74XX should be I2C_DRIVERID_ADT7475)

Best would be to get rid of it altogether. As you might have noticed, all the hwmon driver IDs have be deleted by now:
http://git.kernel.org/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h{501b1f53605bec17454dd8bbdbbf3f57a7cf32

Quoted 5 lines

but by all reports, things were looking good. I was actually getting ready to send the updated patch to Mark to start the trip upstream, but I'll hold off if you want to test some more.

I'll reply with an up-to-date version against HEAD.

Thanks,

Signature · 6 lines
Jean Delvare

_______________________________________________
lm-sensors mailing list
[email protected]
http://lists.lm-sensors.org/mailman/listinfo/lm-sensors
#6 lore raw
In reply to Hans de Goede
Quoted 7 lines · Jordan Crouse

Updated patch against HEAD is attached.
[...]
+/* 7475 Notes:
+ * Addeded by: Jordan Crouse <[email protected]>
+ * Datasheet: http://www.analog.com/UploadedFiles/Data_Sheets/ADT7475.pdf
+ * TODO: enhanced acoustics
+ */

This doesn't affect the code at all, but this line of chips was apparently sold to On Semiconductor, effective 1 Jan 2008. When I was looking for data on this chip in mid-January, Analog Devices no longer had the data sheet and On hadn't posted it yet, but now it is available from On. Product page is
http://www.onsemi.com/PowerSolutions/product.do?id­T7475 and datasheet is http://www.onsemi.com/pub/Collateral/ADT7475-D.PDF . This seems to have affected several of the ADT74xx series chips.

It might be out of scope for lm-sensors, but I wonder if it would be a good idea to collect the datasheets on the various hardware monitoring chips and possibly make them available on the lm-sensors site. I know the Devices page has links to the manufacturer pages, but these can and do change or go away.

Matt Roberds

_______________________________________________
lm-sensors mailing list
[email protected]
http://lists.lm-sensors.org/mailman/listinfo/lm-sensors

#7 lore raw
In reply to Hans de Goede
Quoted 1 line · Jordan Crouse

Updated patch against HEAD is attached. Thanks.

I finally got around to checking the fan speed reporting and it appears to work fine. At the moment I only have one spare fan, but I swapped it around to the various fan connectors on my Asus M2N-SLI Deluxe motherboard and Jordan's driver read them all. The fan idled at about 3000 rpm (this was with the BIOS set to "Performance" chassis fan speed), and the speed went down when I put my thumb on the hub of the fan. The particular fan I used was the one supplied by Intel on the heat sink of an old Pentium II processor; it says "12 V 0.06 A Sanyo Denki" on it.

For reference, the mapping from motherboard connectors to chip inputs on this particular motherboard seems to be:

Input          Connector
it8716 fan 1   CPU
it8716 fan 2   Chassis 1
it8716 fan 3   Power
adt7475 fan 1  Chassis 4
adt7475 fan 2  Chassis 2
adt7475 fan 3  Chassis 3
adt7475 fan 4  Probably no connection

Matt Roberds

_______________________________________________
lm-sensors mailing list
[email protected]
http://lists.lm-sensors.org/mailman/listinfo/lm-sensors

#8 lore raw
In reply to Hans de Goede

Hey,

Quoted 6 lines · Matt Roberds

It might be out of scope for lm-sensors, but I wonder if it would be a good idea to collect the datasheets on the various hardware monitoring chips and possibly make them available on the lm-sensors site. I know the Devices page has links to the manufacturer pages, but these can and do change or go away.

This has been discussed before, see:
http://lists.lm-sensors.org/pipermail/lm-sensors/2007-July/020393.html

Just to quote Hans-Jürgen Koch

Quoted 5 lines
Quoted 5 lines

Useful, yes. But I guess it's simply a legal problem. Just because a datasheet can be downloaded for free from the manufacturers website doesn't mean that you are entitled to re-publish it on your site. You'd have to obtain permission (in writing) for each datasheet, otherwise you can easily run into legal problems.

And Jean Delvare

Quoted 9 lines
Quoted 9 lines

Hans is unfortunately correct. Ensuring the legality of such a datasheet hosting would be a real pain.

When possible we link to the datasheets on our Device wiki page, this should be sufficient in most cases. For older devices, datasheets are sometimes no longer available from the manufacturer's website, I admit this is a problem, but in that case, an interested developer can always contact the driver author, who hopefully can either share a copy of the datasheet or at least answer questions

Ivo Manca

Quoted 2 lines

Matt Roberds

Ivo Manca

Quoted 6 lines

_______________________________________________
lm-sensors mailing list
[email protected]
http://lists.lm-sensors.org/mailman/listinfo/lm-sensors

_______________________________________________
lm-sensors mailing list
[email protected]
http://lists.lm-sensors.org/mailman/listinfo/lm-sensors

#9 lore raw
In reply to Hans de Goede

Hi Matt,

Quoted 9 lines · Matt Roberds
Quoted 7 lines · Jordan Crouse

Updated patch against HEAD is attached.
[...]
+/* 7475 Notes:
+ * Addeded by: Jordan Crouse <[email protected]>
+ * Datasheet: http://www.analog.com/UploadedFiles/Data_Sheets/ADT7475.pdf
+ * TODO: enhanced acoustics
+ */

Quoted 8 lines

This doesn't affect the code at all, but this line of chips was apparently sold to On Semiconductor, effective 1 Jan 2008. When I was looking for data on this chip in mid-January, Analog Devices no longer had the data sheet and On hadn't posted it yet, but now it is available from On. Product page is
http://www.onsemi.com/PowerSolutions/product.do?id­T7475 and datasheet is http://www.onsemi.com/pub/Collateral/ADT7475-D.PDF . This seems to have affected several of the ADT74xx series chips.

Thanks for the information. I have updated wiki/Devices to reflect this change for the ADT7475.

I fear that this change will affect pretty much all the hardware monitoring chips originally designed and sold by Analog Devices. Even the old ADM1022, ADM1024, ADM1026, ADM1027 etc. have been removed from the Analog Devices website. These 3 pages on the ON Semiconductor website seem to cover pretty much all the hardware monitoring chips of Analog Devices:
http://www.onsemi.com/PowerSolutions/parametrics.do?id!27
http://www.onsemi.com/PowerSolutions/parametrics.do?id!26
http://www.onsemi.com/PowerSolutions/parametrics.do?id!25

We will have to update all the links on the wiki/Devices pages, and ideally we would also update the references in the source code of all related drivers. This is a non-trivial amount of work, volunteers are welcome.

Thanks,

Signature · 6 lines
Jean Delvare

_______________________________________________
lm-sensors mailing list
[email protected]
http://lists.lm-sensors.org/mailman/listinfo/lm-sensors
#10 lore raw
In reply to Hans de Goede
Quoted 9 lines · Jean Delvare

I fear that this change will affect pretty much all the hardware monitoring chips originally designed and sold by Analog Devices. Even the old ADM1022, ADM1024, ADM1026, ADM1027 etc. have been removed from the Analog Devices website. These 3 pages on the ON Semiconductor website seem to cover pretty much all the hardware monitoring chips of Analog Devices:
http://www.onsemi.com/PowerSolutions/parametrics.do?id!27
http://www.onsemi.com/PowerSolutions/parametrics.do?id!26
http://www.onsemi.com/PowerSolutions/parametrics.do?id!25

Note: it seems that the AD7xxx series of thermal sensor chips (in particular the AD7414, AD7416, AD7417 and AD7418 which we support) is still the property of Analog Devices, and "only" the ADM and ADT series have been sold to ON Semiconductor.

Quoted 4 lines

We will have to update all the links on the wiki/Devices pages, and ideally we would also update the references in the source code of all related drivers. This is a non-trivial amount of work, volunteers are welcome.

I have created a task in trac to that effect:
http://www.lm-sensors.org/ticket/2303

Signature · 6 lines
Jean Delvare

_______________________________________________
lm-sensors mailing list
[email protected]
http://lists.lm-sensors.org/mailman/listinfo/lm-sensors
#11 lore raw
In reply to Hans de Goede
Quoted 3 lines · Jean Delvare

We will have to update all the links on the wiki/Devices pages, and ideally we would also update the references in the source code of all related drivers.

One one hand, it sucks to chase pointers when one of the pointers is bad or missing - see the general argument against sites like tinyurl.com. On the other hand, it might avoid some work if it was possible to give URLs like http://www.lm-sensors.org/wiki/Devices#ali-m1533 or
http://www.lm-sensors.org/wiki/Devices#ad-adt7475 in the source code. This way the links on the wiki could be kept up to date, which means they wouldn't *have* to be changed in the source code so often.

Quoted 1 line

This is a non-trivial amount of work, volunteers are welcome.

Maybe I'm missing something, but how does one edit the wiki? I can't find the usual "edit this page" links. Do you have to be a developer or otherwise have an account?

A quick check of the current lm-sensors and i2c-tools code doesn't show
that many links that would need revising. The kernel i2c drivers aren't
too bad but the hwmon drivers have lots of datasheet links. (Quick
check, that removes some of the common non-datasheet links, was done with
grep -i -r -h http * | sed -e 's/^.*http/http/g' | grep -v 'lm-sensors\.org' | grep -v '\.gmane\.org' | grep -v oetiker | sort -u .)

Matt Roberds

_______________________________________________
lm-sensors mailing list
[email protected]
http://lists.lm-sensors.org/mailman/listinfo/lm-sensors

#12 lore raw
In reply to Hans de Goede

Hi Matt,

Quoted 5 lines · Matt Roberds
Quoted 3 lines · Jean Delvare

We will have to update all the links on the wiki/Devices pages, and ideally we would also update the references in the source code of all related drivers.

Quoted 7 lines

One one hand, it sucks to chase pointers when one of the pointers is bad or missing - see the general argument against sites like tinyurl.com. On the other hand, it might avoid some work if it was possible to give URLs like http://www.lm-sensors.org/wiki/Devices#ali-m1533 or
http://www.lm-sensors.org/wiki/Devices#ad-adt7475 in the source code. This way the links on the wiki could be kept up to date, which means they wouldn't *have* to be changed in the source code so often.

I am worried that this adds one more point of failure (on top of requiring additional work, and I'm not even sure if trac supports adding arbitrary anchors like that). For example, when we will move the I2C bus driver information to a different page (or even plain drop it), the links you suggested would no longer be valid. Even worse if we move the whole website (this happened recently.)

Changes like the one we must do for Analog Devices are thankfully rare enough that I don't think it's worth developing an infrastructure to handle them. Also, Google should be able to catch up with the new datasheet locations, so I guess that a developer really in need of the datasheet would find it quickly even if our link is broken.

Quoted 5 lines
Quoted 1 line

This is a non-trivial amount of work, volunteers are welcome.

Maybe I'm missing something, but how does one edit the wiki? I can't find the usual "edit this page" links. Do you have to be a developer or otherwise have an account?

Yes, you need an account, otherwise we were receiving a lot of spam. If you want an account to do some work on the wiki, just provide (in private) the output of "htpasswd" (from the Apache httpd package) for the login you want and I'll create an account for you.

Quoted 6 lines

A quick check of the current lm-sensors and i2c-tools code doesn't show
that many links that would need revising. The kernel i2c drivers aren't
too bad but the hwmon drivers have lots of datasheet links. (Quick
check, that removes some of the common non-datasheet links, was done with
grep -i -r -h http * | sed -e 's/^.*http/http/g' | grep -v 'lm-sensors\.org' | grep -v '\.gmane\.org' | grep -v oetiker | sort -u .)

Signature · 6 lines
Jean Delvare

_______________________________________________
lm-sensors mailing list
[email protected]
http://lists.lm-sensors.org/mailman/listinfo/lm-sensors
#13 lore raw
In reply to Hans de Goede
Quoted 1 line · Jordan Crouse

Updated patch against HEAD is attached. Thanks.

Something I noticed while hacking on sensors.conf: naming it adt7475 would align better with the names of most of the other chips. In other words, change

Quoted 10 lines
static struct adt7475_chip {
	const char *name;
	struct attribute_group group;
} adt7475_chips[ADT7475_MAX_ID] = {
	{ .name = "ADT7475",
	  .group = {
		  .attrs = adt7475_attrs,
	  }
	},
};

to

{ .name = "adt7475",
.

Matt Roberds

_______________________________________________
lm-sensors mailing list
[email protected]
http://lists.lm-sensors.org/mailman/listinfo/lm-sensors

#14 lore raw
In reply to Hans de Goede
Quoted 18 lines · Matt Roberds
Quoted 1 line · Jordan Crouse

Updated patch against HEAD is attached. Thanks.

Something I noticed while hacking on sensors.conf: naming it adt7475 would align better with the names of most of the other chips. In other words, change

Quoted 10 lines
static struct adt7475_chip {
	const char *name;
	struct attribute_group group;
} adt7475_chips[ADT7475_MAX_ID] = {
	{ .name = "ADT7475",
	  .group = {
		  .attrs = adt7475_attrs,
	  }
	},
};
Quoted 3 lines

to

{ .name = "adt7475",

I completely agree.

Signature · 6 lines
Jean Delvare

_______________________________________________
lm-sensors mailing list
[email protected]
http://lists.lm-sensors.org/mailman/listinfo/lm-sensors