# Temperature monitoring

## Omega21

Hi there,

I have a Toshiba Satellite A70, with a mobile pentium 4 with hyperthreading. It runs at 3.2 GHz.

Has anyone gotten a temperature reading on one of these chips? If so, how do I monitor it?

Im just a little worried because it just shut off while I was compiling something.. 

Thanks!

----------

## ali3nx

Based on experience with a Toshiba Sattelite laptop i installed with 2005.0 gentoo for a friend last year I recall all the temperature sensors worked really well. You'll most likely need to find which smbus chipset your laptop motherboard uses and check your kernel configuration, enable the modules and recompile your kernel. Setting up temperature sensors usually requires both the kernel modules and lm_sensors userland utilities which can be found in portage. The below code example is from one of my 246 opterons. As you can see the SMBus chipset is an AMD-8111 which is available in the I2C hardware bus module list in the 2.6 linux kernel. After i'd selected the module and compiled -all- of the required i2C layer as modules the setup script thats installed with lm_sensors which is names sensors-detect can setup it's scripts to load the i2C layer as required.

```
anvil postfix # lspci

00:06.0 PCI bridge: Advanced Micro Devices [AMD] AMD-8111 PCI (rev 07)

00:07.0 ISA bridge: Advanced Micro Devices [AMD] AMD-8111 LPC (rev 05)

00:07.1 IDE interface: Advanced Micro Devices [AMD] AMD-8111 IDE (rev 03)

00:07.2 SMBus: Advanced Micro Devices [AMD] AMD-8111 SMBus 2.0 (rev 02)

00:07.3 Bridge: Advanced Micro Devices [AMD] AMD-8111 ACPI (rev 05)

00:0a.0 PCI bridge: Advanced Micro Devices [AMD] AMD-8131 PCI-X Bridge (rev 12)

00:0a.1 PIC: Advanced Micro Devices [AMD] AMD-8131 PCI-X IOAPIC (rev 01)

00:0b.0 PCI bridge: Advanced Micro Devices [AMD] AMD-8131 PCI-X Bridge (rev 12)

00:0b.1 PIC: Advanced Micro Devices [AMD] AMD-8131 PCI-X IOAPIC (rev 01)

00:18.0 Host bridge: Advanced Micro Devices [AMD] K8 [Athlon64/Opteron] HyperTransport Technology Configuration

00:18.1 Host bridge: Advanced Micro Devices [AMD] K8 [Athlon64/Opteron] Address Map

00:18.2 Host bridge: Advanced Micro Devices [AMD] K8 [Athlon64/Opteron] DRAM Controller

00:18.3 Host bridge: Advanced Micro Devices [AMD] K8 [Athlon64/Opteron] Miscellaneous Control

00:19.0 Host bridge: Advanced Micro Devices [AMD] K8 [Athlon64/Opteron] HyperTransport Technology Configuration

00:19.1 Host bridge: Advanced Micro Devices [AMD] K8 [Athlon64/Opteron] Address Map

00:19.2 Host bridge: Advanced Micro Devices [AMD] K8 [Athlon64/Opteron] DRAM Controller

00:19.3 Host bridge: Advanced Micro Devices [AMD] K8 [Athlon64/Opteron] Miscellaneous Control

02:09.0 Ethernet controller: Broadcom Corporation NetXtreme BCM5704 Gigabit Ethernet (rev 03)

02:09.1 Ethernet controller: Broadcom Corporation NetXtreme BCM5704 Gigabit Ethernet (rev 03)

03:00.0 USB Controller: Advanced Micro Devices [AMD] AMD-8111 USB (rev 0b)

03:00.1 USB Controller: Advanced Micro Devices [AMD] AMD-8111 USB (rev 0b)

03:05.0 Mass storage controller: Silicon Image, Inc. SiI 3114 [SATALink/SATARaid] Serial ATA Controller (rev 02)

03:06.0 VGA compatible controller: ATI Technologies Inc Rage XL (rev 27)

03:08.0 Ethernet controller: Intel Corporation 82557/8/9 [Ethernet Pro 100] (rev 10)
```

my kernel configuration of I2C is usually all comprised of modules so that userlans scripts used with lm_sensors work correctly

```
  │ │ <M> I2C support                                                                                                                                 │ │

  │ │ <M>   I2C device interface                                                                                                                      │ │

  │ │       I2C Algorithms  --->                                                                                                                      │ │

  │ │       I2C Hardware Bus support  --->                                                                                                            │ │

  │ │       Miscellaneous I2C Chip support  --->                                                                                                      │ │

  │ │ [ ]   I2C Core debugging messages                                                                                                               │ │

  │ │ [ ]   I2C Algorithm debugging messages                                                                                                          │ │

  │ │ [ ]   I2C Bus debugging messages                                                                                                                │ │

  │ │ [ ]   I2C Chip debugging messages                                                                                                               │ │

```

```
  │ │ < > ALI 1535                                                                                                                                    │ │

  │ │ < > ALI 1563                                                                                                                                    │ │

  │ │ < > ALI 15x3                                                                                                                                    │ │

  │ │ <M> AMD 756/766/768/8111 and nVidia nForce                                                                                                      │ │

  │ │ < >   SMBus multiplexing on the Tyan S4882                                                                                                      │ │

  │ │ <M> AMD 8111                                                                                                                                    │ │

  │ │ < > Intel 82801 (ICH)                                                                                                                           │ │

  │ │ < > Intel 810/815                                                                                                                               │ │

  │ │ < > Intel PIIX4                                                                                                                                 │ │

  │ │ < > Nvidia nForce2, nForce3 and nForce4                                                                                                         │ │

  │ │ < > Parallel port adapter (light)                                                                                                               │ │

  │ │ < > S3/VIA (Pro)Savage                                                                                                                          │ │

  │ │ < > S3 Savage 4                                                                                                                                 │ │

  │ │ < > NatSemi SCx200 ACCESS.bus                                                                                                                   │ │

  │ │ < > SiS 5595                                                                                                                                    │ │

  │ │ < > SiS 630/730                                                                                                                                 │ │

  │ │ < > SiS 96x                                                                                                                                     │ │

  │ │ < > I2C/SMBus Test Stub                                                                                                                         │ │

  │ │ < > VIA 82C586B                                                                                                                                 │ │

  │ │ < > VIA 82C596/82C686/823x                                                                                                                      │ │

  │ │ < > Voodoo 3                                                                                                                                    │ │

  │ │ < > PCA9564 on an ISA bus                                                                                                                       │ │
```

If you recieve an error when attempting to run the sensors-detect script

```
midas ~ # sensors-detect

No i2c device files found. Use prog/mkdev/mkdev.sh to create them.
```

Just modprobe the i2c-dev kernel module

```
modprobe i2c-dev
```

Usually takes care of the error and then the script can continue prompting you for input. since my opteron is running hardened gentoo with the grsecurity patches enabled in fort knox mode probing the isa bus and others besides the SMBus fails due to /dev/port being restricted.

```
anvil postfix # sensors-detect

# sensors-detect revision 1.393 (2005/08/30 18:51:18)

This program will help you determine which I2C/SMBus modules you need to

load to use lm_sensors most effectively. You need to have i2c and

lm_sensors installed before running this program.

Also, you need to be `root', or at least have access to the /dev/i2c-*

files, for most things.

If you have patched your kernel and have some drivers built in, you can

safely answer NO if asked to load some modules. In this case, things may

seem a bit confusing, but they will still work.

It is generally safe and recommended to accept the default answers to all

questions, unless you know what you're doing.

 We can start with probing for (PCI) I2C or SMBus adapters.

 You do not need any special privileges for this.

 Do you want to probe now? (YES/no): yes

Probing for PCI bus adapters...

Use driver `i2c-amd8111' for device 00:07.2: AMD-8111 SMBus 2.0

Use driver `i2c-amd756' for device 00:07.3: AMD-8111 ACPI

Probe succesfully concluded.

We will now try to load each adapter module in turn.

Module `i2c-amd8111' already loaded.

Module `i2c-amd756' already loaded.

If you have undetectable or unsupported adapters, you can have them

scanned by manually loading the modules before running this script.

 To continue, we need module `i2c-dev' to be loaded.

 If it is built-in into your kernel, you can safely skip this.

 i2c-dev is not loaded. Do you want to load it now? (YES/no): yes

 Module loaded succesfully.

 We are now going to do the adapter probings. Some adapters may hang halfway

 through; we can't really help that. Also, some chips will be double detected;

 we choose the one with the highest confidence value in that case.

 If you found that the adapter hung after probing a certain address, you can

 specify that address to remain unprobed. That often

 includes address 0x69 (clock chip).

Next adapter: SMBus AMD8111 adapter at 50e0

Do you want to scan it? (YES/no/selectively): yes

Can't open /dev/i2c-1

Next adapter: SMBus2 AMD8111 adapter at cc00

Do you want to scan it? (YES/no/selectively): yes

Client found at address 0x08

Some chips are also accessible through the ISA bus. ISA probes are

typically a bit more dangerous, as we have to write to I/O ports to do

this. This is usually safe though.

Do you want to scan the ISA bus? (YES/no): no

Some Super I/O chips may also contain sensors. Super I/O probes are

typically a bit more dangerous, as we have to write to I/O ports to do

this. This is usually safe though.

Do you want to scan for Super I/O sensors? (YES/no): no

 Sorry, no chips were detected.

 Either your sensors are not supported, or they are

 connected to an I2C bus adapter that we do not support.

 See doc/FAQ, doc/lm_sensors-FAQ.html, or

 http://www2.lm-sensors.nu/~lm78/cvs/lm_sensors2/doc/lm_sensors-FAQ.html

 (FAQ #4.24.3) for further information.

 If you find out what chips are on your board, see

 http://secure.netroedge.com/~lm78/newdrivers.html for driver status.
```

----------

## kamracik

Omega i had same problem, you just need to get acpi work, if it's a first install from a cd type in boot: `gentoo acpi=on' and it sholud do the trick  :Wink:  and if you have already system installed just emerge acpi :]

----------

