beagleboard / kernel

Kernel for the beagleboard.org boards
172 stars 159 forks source link

Temperature sensor not working on 3.12 and later #91

Closed danieletorelli closed 10 years ago

danieletorelli commented 10 years ago

Hi, from kernel v. 3.12 (but also on the latest 3.13 version) the temperature sensor of my BeagleBone Black is no longer detected by sensors-detect.

This below is the output of sensors-detect with kernel 3.8.13 (with patch set 41):

# sensors-detect revision 6209 (2014-01-14 22:51:58 +0100)
[...]

Next adapter: OMAP I2C adapter (i2c-0)
Do you want to scan it? (YES/no/selectively): 
Adapter doesn't support all probing functions.
Some addresses won't be probed.
Client found at address 0x50
Handled by driver `at24' (built-in), chip type `24c256'
    (note: this is probably NOT a sensor chip!)

Next adapter: OMAP I2C adapter (i2c-1)
Do you want to scan it? (YES/no/selectively): 
Adapter doesn't support all probing functions.
Some addresses won't be probed.

[...]

Instead, what follows is the output of sensors-detect with kernel 3.13.6 (with patch set 7):

# sensors-detect revision 6209 (2014-01-14 22:51:58 +0100)
[...]

Next adapter: OMAP I2C adapter (i2c-0)
Do you want to scan it? (YES/no/selectively): 
Adapter doesn't support all probing functions.
Some addresses won't be probed.
Client found at address 0x50
Handled by driver `at24' (built-in), chip type `24c256'
    (note: this is probably NOT a sensor chip!)

Next adapter: OMAP I2C adapter (i2c-2)
Do you want to scan it? (YES/no/selectively): 
Adapter doesn't support all probing functions.
Some addresses won't be probed.

[...]
RobertCNelson commented 10 years ago

See http://permalink.gmane.org/gmane.linux.linaro.devel/16501

The TI Bandgap IP driver is located under drivers/thermal/ti-soc-thermal/. There we have support for the Bandgap IPs present on OMAP4430/OMAP4460/OMAP4470/OMAP543[0|2] and DRA7 devices.

On the other hand, TI HW engineers discourage the usage of AM335x bandgap IP, due to variability of sensor accuracy, they are copied here. This is the main reason why I didn't upstream any code.