Skip to contentSkip to conversation

Preliminary w83627ehf hardware monitoring driver

RFT Jean Delvare 4 participants 8 messages Feb 26, 2005 – May 19, 2005

lore
Share & tools
lore
#0 lore raw

Hi all,

I have been working on a w83627ehf hardware monitoring driver. The W83627EHF is a Super-I/O chip made by Winbond. Like other chips of the family (W83627HF, W83697HF, W83627THF...), it integrates hardware monitoring functions. Of these, my preliminary driver only handles temperature and fan inputs at the moment. I lack time and do not have hardware to test it, so I will not improve it significantly in a near future.

So that my work isn't lost, I am releasing it today in the form of a patch against linux-2.6.11-rc5 (attached). You can also obtain it here for now:
http://jdelvare.net1.nerim.net/sensors/linux-2.6.11-rc5-i2c-w83627ehf-beta1.diff

If it could get some testing, I would possibly get this is the main kernel tree, so that at least what is implemented can be used, and anyone interested in improving it would have a base to start from.

The W83627EHF doesn't seem to be found on many motherboards, but a quick searched listed these ones:
* Asus P5AD2 Premium
* Asus P5GD1-VM
* Asus P5GD2 Premium
* Asus P5GDC-V Deluxe
* Asus P5P800
So if you have any of these motherboards (or any other with a W83627EHF chip, for that matter), I would welcome any feedback about my driver.

Thanks,

Signature · 1 line
Jean Delvare
drivers/i2c/chips/Kconfig renamed from drivers/i2c/chips.orig/Kconfig +14 -0
diff -ruN linux-2.6.11-rc5/drivers/i2c/chips.orig/Kconfig linux-2.6.11-rc5/drivers/i2c/chips/Kconfig
@@ -311,6 +311,20 @@
 	  This driver can also be built as a module.  If so, the module
 	  will be called w83627hf.
 
+config SENSORS_W83627EHF
+	tristate "Winbond W83627EHF"
+	depends on I2C && EXPERIMENTAL
+	select I2C_SENSOR
+	select I2C_ISA
+	help
+	  If you say yes here you get preliminary support for the hardware
+	  monitoring functionality of the Winbond W83627EHF Super-I/O chip.
+	  Only fan and temperature inputs are supported at the moment, while
+	  the chip does much more than that.
+
+	  This driver can also be built as a module.  If so, the module
+	  will be called w83627ehf.
+
 endmenu
 
 menu "Other I2C Chip support"
drivers/i2c/chips/Makefile renamed from drivers/i2c/chips.orig/Makefile +1 -0
diff -ruN linux-2.6.11-rc5/drivers/i2c/chips.orig/Makefile linux-2.6.11-rc5/drivers/i2c/chips/Makefile
@@ -33,6 +33,7 @@
 obj-$(CONFIG_SENSORS_SMSC47B397)+= smsc47b397.o
 obj-$(CONFIG_SENSORS_SMSC47M1)	+= smsc47m1.o
 obj-$(CONFIG_SENSORS_VIA686A)	+= via686a.o
+obj-$(CONFIG_SENSORS_W83627EHF)	+= w83627ehf.o
 obj-$(CONFIG_SENSORS_W83L785TS)	+= w83l785ts.o
 obj-$(CONFIG_ISP1301_OMAP)	+= isp1301_omap.o
 
drivers/i2c/chips/w83627ehf.c renamed from drivers/i2c/chips.orig/w83627ehf.c +793 -0

793 lines not on this page · raw message

#1 lore raw
Quoted 10 lines · Jean Delvare

Hi all,

I have been working on a w83627ehf hardware monitoring driver. The W83627EHF is a Super-I/O chip made by Winbond. Like other chips of the family (W83627HF, W83697HF, W83627THF...), it integrates hardware monitoring functions. Of these, my preliminary driver only handles temperature and fan inputs at the moment. I lack time and do not have hardware to test it, so I will not improve it significantly in a near future.

Hi!

Do you know about driver for W83627THF watchdog? I'm using Supermicro P8SCI motherboard, and I haven't found working driver for it..

Thanks!

-- Pasi Kärkkäinen

                                   ^
                                .     .
                                 Linux
                              /    -    \
                             Choice.of.the
                           .Next.Generation.
#2 lore raw

Hi Pasi,

Quoted 2 lines

Do you know about driver for W83627THF watchdog? I'm using Supermicro P8SCI motherboard, and I haven't found working driver for it..

Have you tried w83627hf_wdt? I took a quick look at the W83627HF and W83627THF datasheets and watchdog timer seems to work identically. Since the driver doesn't seem to identify the chip (it probably should, BTW), I'd expect it to work.

Hope that helps,

Signature · 1 line
Jean Delvare
#3 lore raw
Quoted 10 lines · Jean Delvare

Hi Pasi,

Quoted 2 lines

Do you know about driver for W83627THF watchdog? I'm using Supermicro P8SCI motherboard, and I haven't found working driver for it..

Have you tried w83627hf_wdt? I took a quick look at the W83627HF and W83627THF datasheets and watchdog timer seems to work identically. Since the driver doesn't seem to identify the chip (it probably should, BTW), I'd expect it to work.

Yes, I have tried it. It doesn't work.

The machine reboots always after the watchdog timeout set in the BIOS. I've tried with the example watchdog daemon from the watchdog.txt, and with the Debian "watchdog" package.

When I enable the debug messages and logging in the Debian watchdog package, I can see that the watchdog daemon gets stuck while trying to update the /dev/watchdog.. so the driver hangs..

-- Pasi Kärkkäinen

                                   ^
                                .     .
                                 Linux
                              /    -    \
                             Choice.of.the
                           .Next.Generation.
#4 lore raw

Hi Pasi,

Quoted 7 lines
Quoted 4 lines

Have you tried w83627hf_wdt? I took a quick look at the W83627HF and W83627THF datasheets and watchdog timer seems to work identically. Since the driver doesn't seem to identify the chip (it probably should, BTW), I'd expect it to work.

Yes, I have tried it. It doesn't work.

Quoted 7 lines

The machine reboots always after the watchdog timeout set in the BIOS. I've tried with the example watchdog daemon from the watchdog.txt, and with the Debian "watchdog" package.

When I enable the debug messages and logging in the Debian watchdog package, I can see that the watchdog daemon gets stuck while trying to update the /dev/watchdog.. so the driver hangs..

I am not familiar with watchdogs. I'd invite you to get in touch with the author and/or maintainer of the w83627hf_wdt driver, or possibly try to debug it yourself. Datasheets are freely available from Winbond for both the W83627HF and W83627THF:
http://www.winbond.com/e-winbondhtm/partner/b_2_d_2.htm

I do not own a system with either chip myself, so I can hardly help. (If anyone wants to donate a system with either chip so that I can work on this, just contact me.)

--
Jean Delvare

#5 lore raw
Quoted 5 lines · Jean Delvare

I am not familiar with watchdogs. I'd invite you to get in touch with the author and/or maintainer of the w83627hf_wdt driver, or possibly try to debug it yourself. Datasheets are freely available from Winbond for both the W83627HF and W83627THF:
http://www.winbond.com/e-winbondhtm/partner/b_2_d_2.htm

He already contacted me (indirectly).
A test program I sent showed the timer in the winbond counting down, but the reboot never happened.
I would need to get access to the hardware to debug further.

Signature · 2 lines
Pádraig Brady - http://www.pixelbeat.org
--
#6 lore raw
In reply to Jean Delvare

Hi Leon,

Quoted 10 lines

I have an Asus P5P800 motherboard with the W83627EHF and would like to monitor the CPU temperature. I have used your patchfile
(http://jdelvare.net1.nerim.net/sensors/linux-2.6.11-rc5-i2c-w83627eh
f-beta1.diff) to patch my linux-2.6.10 sources (no obvious problems there) and recompiled and installed (I'm running Fedora Core 3).

I had hoped that this would give me CPU temperature readings but I didn't get any values when running the sensors command (neither as root nor as normal user, and after running sensors -s):
----------------

Quoted 6 lines
# sensors
w83627ehf-isa-0290
Adapter: ISA adapter

#
----------------

This is expected. The driver being preliminary, it has no user-space support yet. Neither libsensors not sensors know about it. Our design makes it necessary to update both whenever we want a new chip to be supported.

Quoted 4 lines

I have no idea how to debug this further or how to get sensor values but I'm willing to put some time in this as a tester. Were my expectations wrong and can't I use your preliminary driver to get temperature readings?

If your expectations were that you could use "sensors" out of the box, you were indeed wrong. You can however read the raw sensors values in /sys/bus/i2c/devices/0-0290 (or something similar), which is already something to start with, and should at least help you make sure that the driver itself work properly for you.

Quoted 2 lines

Are there changes in the 2.6.11-rc5 kernel w.r.t. 2.6.10 that I might need?

Not that I can think of. If you were able to compile the driver, chances are good that it will work properly.

Signature · 1 line
Jean Delvare
#7 lore raw
In reply to Jean Delvare
Quoted 5 lines · Jean Delvare

I have been working on a w83627ehf hardware monitoring driver. The W83627EHF is a Super-I/O chip made by Winbond. Like other chips of the family (W83627HF, W83697HF, W83627THF...), it integrates hardware monitoring functions. Of these, my preliminary driver only handles temperature and fan inputs at the moment.

I have an Asus P5P800 motherboard with the W83627EHF and would like to monitor the CPU temperature. I have used your patchfile
(http://jdelvare.net1.nerim.net/sensors/linux-2.6.11-rc5-i2c-w83627ehf-beta1.diff)
to patch my linux-2.6.10 sources (no obvious problems there) and recompiled and installed (I'm running Fedora Core 3).

I had hoped that this would give me CPU temperature readings but I didn't get any values when running the sensors command (neither as root nor as normal user, and after running sensors -s):
----------------

# sensors
w83627ehf-isa-0290
Adapter: ISA adapter

#
----------------

Since then I've read your discussion with David Hoffman and repeated some of the experiments:

Initially I could not get the version of sensors_detect at
http://www2.lm-sensors.nu/%7Elm78/cvs/lm_sensors2/prog/detect/sensors-detect
to detect the W83627EHF at the ISA bus. Here's some of the output:
-----------
Do you want to scan the ISA bus? (YES/no):
..
Probing for `Winbond W83627EHF'
Trying address 0x0290... Failed!
..
Do you want to scan for Super I/O sensors? (YES/no):
..
Probing for `Winbond W83627EHF Super IO Sensors'
Success... found at address 0x0290

Do you want to scan for secondary Super I/O sensors? (YES/no):
..
Probing for `Winbond W83627EHF Super IO Sensors'
Failed! (skipping family)
-----------

After running 'isaset 0x295 0x296 0x4e 0' the W83627EHF is found as an ISA chip as well:
-----------
Do you want to scan the ISA bus? (YES/no):
..
Probing for `Winbond W83627EHF'
Trying address 0x0290... Success!
(confidence 8, driver `to-be-written')
..
Do you want to scan for Super I/O sensors? (YES/no):
..
Probing for `Winbond W83627EHF Super IO Sensors'
Success... found at address 0x0290

Do you want to scan for secondary Super I/O sensors? (YES/no):
..
Probing for `Winbond W83627EHF Super IO Sensors'
Failed! (skipping family)
-----------

However, both before and after the isaset command I cannot get any values as output from running sensors.

Here is the i2c part of the output from lsmod
------------------------
Module Size Used by
..

w83627ehf              18200  0
i2c_sensor              7680  1 w83627ehf
i2c_isa                 6400  0
i2c_dev                13568  0
i2c_core               24960  4 w83627ehf,i2c_sensor,i2c_isa,i2c_dev

..
------------------------

I've updated modules.conf (actually modprobe.conf on FC3) and lm_sensors as indicated by sensors_detect. Dmesg shows that lm_sensors is loaded without problems (it gave a no sensors found warning before I applied your patches).

I have no idea how to debug this further or how to get sensor values but I'm willing to put some time in this as a tester. Were my expectations wrong and can't I use your preliminary driver to get temperature readings? Should I maybe add something to sensors.conf? Are there changes in the 2.6.11-rc5 kernel w.r.t. 2.6.10 that I might need?

cheers,
-- Leon

------------------------------------------------------------------------
Leon Moonen mailto:[email protected] http://www.cwi.nl/~leon/
------------------------------------------------------------------------

Delft University of Technology  | CWI
Software Evolution Research Lab | Department of Software Engineering
Mekelweg 4, 2628 CD, Delft, NL  | Kruislaan 413, 1098 SJ, Amsterdam, NL

------------------------------------------------------------------------