Age | Commit message (Collapse) | Author |
|
export access to the 'Local Shared OS and T_Crit Limit'
register.
|
|
In order to allow tighter integration with external thermal throttling
code add local temperature and remote critical shutdown temperature
hooks. Rename the existing hooks for clarity.
|
|
In order to allow integrating with external thermal throttling code add
a probe callback and remote over-temperature shutdown hooks.
|
|
In addition to the critical temperature alarm limit this chip features
a second alarm limit called remote over-temperature shutdown ROS with
a separate pin configurable as trigger output. Implement this feature
and add platform data to allow configuring respective pin as output.
|
|
Rather than using hard-coded register indices and offsets define and
use an enumeration thereof.
|
|
Bug 1024886
Resolved compilation error for unused code.
Signed-off-by: Nagaraja Kolur <nkolur@nvidia.com>
Change-Id: I9167d8129a9cba0fc6cb203180e07192d66db439
Reviewed-on: http://git-master/r/120581
Reviewed-by: Automatic_Commit_Validation_User
Reviewed-by: Nagaraj Kolur <nkolur@nvidia.com>
Tested-by: Nagaraj Kolur <nkolur@nvidia.com>
Reviewed-by: Vijaya Bhaskar <vbhaskar@nvidia.com>
Reviewed-by: Wahed Syed <wsyed@nvidia.com>
Reviewed-by: Dan Willemsen <dwillemsen@nvidia.com>
|
|
- Add compilation flag to treat warning as error
bug 949219
Change-Id: I1106e3d7d13e0c6305a8709ddfdf85e7652f26a1
Signed-off-by: schowdary <schowdary@nvidia.com>
|
|
Simplify the temp to counter conversion in tsensor,
Also it can improve a little bit accuracy of temp to
counter conversion.
Change-Id: I5764334d5d94e317dd9400bc03cb5d7a64096ee0
Signed-off-by: Daniel Fu <danifu@nvidia.com>
Reviewed-on: http://git-master/r/115340
Reviewed-by: Automatic_Commit_Validation_User
GVS: Gerrit_Virtual_Submit
Reviewed-by: Bitan Biswas <bbiswas@nvidia.com>
|
|
When set threshold of tsensor,convert the temp to counter.
The counter convert from temp is with ~1.8C average error.
Improved the accuracy, make it to be ~0.1C.
Bug 1015288
Change-Id: Icab03b559eaeb8846dd1191869afe39c9965f934
Signed-off-by: Daniel Fu <danifu@nvidia.com>
Reviewed-on: http://git-master/r/114904
Reviewed-by: Automatic_Commit_Validation_User
Reviewed-by: Bitan Biswas <bbiswas@nvidia.com>
|
|
Changed the low temp to 0C since 20C is very easy to trigger thermal
alert under -15C to 15C environment temperature. And the thermal alert
will run into endless alert from tsensor_work_func.
Also revised suspend and resume routine to cancel the work when suspending
and disable/enable irq.
Bug 999175
Signed-off-by: Linqiang Pu <dpu@nvidia.com>
(cherry picked from commit 6a909bfa690991438be298d4933946a92e4929c4)
Change-Id: Icafc6d5f0164204cc0cb7bea64bef2fadadbfbfd
Reviewed-on: http://git-master/r/111550
Reviewed-by: Rohan Somvanshi <rsomvanshi@nvidia.com>
Tested-by: Rohan Somvanshi <rsomvanshi@nvidia.com>
|
|
tsensor driver uses fixed point approximations.
Improved accuracy of tsensor temperature reading
- adding support to handle negative temperature to counter
conversions and vice-versa
bug 1001632
bug 999175
Signed-off-by: Bitan Biswas <bbiswas@nvidia.com>
(cherry picked from commit 86ae0bdc3fbd34a5a1d0e08f7721ed527ddf5408)
Change-Id: I5f6df85611d502a6dda1186234078fe973d7ca75
Reviewed-on: http://git-master/r/100576
Tested-by: Bitan Biswas <bbiswas@nvidia.com>
Reviewed-by: Automatic_Commit_Validation_User
Reviewed-by: Bitan Biswas <bbiswas@nvidia.com>
|
|
bug 949219
Change-Id: I5942ba86bd1cbe1f1bd06a7c9f51a10d83e6cabb
Signed-off-by: Sanjay Singh Rawat <srawat@nvidia.com>
Reviewed-on: http://git-master/r/92819
Reviewed-by: Rohan Somvanshi <rsomvanshi@nvidia.com>
Tested-by: Rohan Somvanshi <rsomvanshi@nvidia.com>
|
|
Enabled hw reset in tsensor if temperature exceeds given
temperature limit.
bug 966994
Change-Id: I2444c97c97c45b2d190a224388876d592d983c7f
Signed-off-by: Joshua Primero <jprimero@nvidia.com>
Reviewed-on: http://git-master/r/93030
Reviewed-by: Diwakar Tundlam <dtundlam@nvidia.com>
Reviewed-by: Automatic_Commit_Validation_User
|
|
Added function to retrieve tsensor driver's lowest
temperature support
Signed-off-by: Joshua Primero <jprimero@nvidia.com>
Reviewed-on: http://git-master/r/70931
(cherry picked from commit f81c5b945b2104969fd1a391d0e5df8f0900710d)
Change-Id: I8bf3f7c7fb3ab4730bfb6700b2ae5edec44c7da2
Reviewed-on: http://git-master/r/85960
Reviewed-by: Joshua Primero <jprimero@nvidia.com>
Tested-by: Joshua Primero <jprimero@nvidia.com>
Reviewed-by: Diwakar Tundlam <dtundlam@nvidia.com>
|
|
This API is being removed in v3.2
Change-Id: I3d864dabd2273e737604776aa43c45a64eae90b3
Signed-off-by: Dan Willemsen <dwillemsen@nvidia.com>
Reviewed-on: http://git-master/r/83561
Reviewed-by: Prashant Gaikwad <pgaikwad@nvidia.com>
Reviewed-by: Varun Wadekar <vwadekar@nvidia.com>
|
|
commit 6edf3c30af01854c416f8654d3d5d2652470afd4 upstream.
When no platform data was supplied, returned error code was 0.
Signed-off-by: Vivien Didelot <vivien.didelot@savoirfairelinux.com>
Signed-off-by: Guenter Roeck <guenter.roeck@ericsson.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: Varun Wadekar <vwadekar@nvidia.com>
Change-Id: I8d12ab55a13d5c97df4d4f185a268ef5c973a66a
Reviewed-on: http://git-master/r/79685
Reviewed-by: Automatic_Commit_Validation_User
|
|
commit ad77c3e1808f07fa70f707b1c92a683b7c7d3f85 upstream.
NCT6776F only supports pwm mode for pwm2 and pwm3. Return error if an attempt
is made to set those pwm channels to DC mode.
Signed-off-by: Guenter Roeck <linux@roeck-us.net>
Acked-by: Jean Delvare <khali@linux-fr.org>
Signed-off-by: Guenter Roeck <guenter.roeck@ericsson.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: Varun Wadekar <vwadekar@nvidia.com>
Change-Id: I9e7b7a7eec7c7da5a8102b31c305c2f0061101f3
Reviewed-on: http://git-master/r/79684
Reviewed-by: Automatic_Commit_Validation_User
|
|
commit 86b2bbfdbd1fcc4a3aa62ccd3f245c40c5ad5b85 upstream.
Properly clamp temperature limits set by the user. Without this fix,
attempts to write temperature limits above the maximum supported by
the chip (255 degrees Celsius) would arbitrarily and unexpectedly
result in the limit being set to 0 degree Celsius.
Signed-off-by: Jean Delvare <khali@linux-fr.org>
Signed-off-by: Guenter Roeck <guenter.roeck@ericsson.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: Varun Wadekar <vwadekar@nvidia.com>
Change-Id: I7706baf5766f7597b458a62809e147d0dd2ee164
Reviewed-on: http://git-master/r/79683
Reviewed-by: Automatic_Commit_Validation_User
|
|
Only enable one sensor at a time to save power.
bug 928188
Reviewed-on: http://git-master/r/76025
Change-Id: I1d3c21783cbe579568ff9e9ef3ce2e48220e7edb
Reviewed-by: Bitan Biswas <bbiswas@nvidia.com>
Reviewed-by: Diwakar Tundlam <dtundlam@nvidia.com>
Signed-off-by: Joshua Primero <jprimero@nvidia.com>
Signed-off-by: Varun Wadekar <vwadekar@nvidia.com>
Reviewed-on: http://git-master/r/76823
Reviewed-by: Automatic_Commit_Validation_User
|
|
Change-Id: I99507d7cfdcee064f808856dc2ce99d806fd864f
|
|
commit 0b57d7602b68f7b2786b2f0e22da39cbd4139a95 upstream.
wait_for_completion_interruptible_timeout() may return negative value.
In this case, checking if (t > 0) will return true if t is unsigned.
Signed-off-by: Axel Lin <axel.lin@gmail.com>
Acked-by: Lars-Peter Clausen <lars@metafoo.de>
Signed-off-by: Guenter Roeck <guenter.roeck@ericsson.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
|
|
Enabled probe callback in probe function now
that callback function parameter was added
to tsensor data structure.
Reviewed-on: http://git-master/r/62022
(cherry picked from commit 388f5aa8ac8b84bf247db8ebd3dcd05b2788b3d5)
Reviewed-on: http://git-master/r/64560
(cherry picked from commit c58aad90a5226b1a13c4e5397de800d5d7fdfa84)
Change-Id: I4cd66ebdf33e54048166207ab7012e4b74b5350d
Signed-off-by: Joshua Primero <jprimero@nvidia.com>
Reviewed-on: http://git-master/r/67239
Reviewed-by: Automatic_Commit_Validation_User
Reviewed-by: Diwakar Tundlam <dtundlam@nvidia.com>
|
|
Added support for EDP in tsensor. Since low limit
interrupts are not supported in hardware TH2 was
used for upper limit and TH0/TH1 as lower limit.
Also added generic functions to enable tsensor for
thermal refactoring.
Bug 912597
Change-Id: I8f1e126e1fe11c69aa03dee0a20a26ef2b7dc6a0
Signed-off-by: Joshua Primero <jprimero@nvidia.com>
Reviewed-on: http://git-master/r/66554
Reviewed-by: Automatic_Commit_Validation_User
Reviewed-by: Colin McCabe <cmccabe@nvidia.com>
Reviewed-by: Diwakar Tundlam <dtundlam@nvidia.com>
|
|
Adds support for current monitoring for battery EDP capping
Change-Id: I85fc1770013ab80b986b3b6d77ffd96e1dc4068f
Signed-off-by: Peter Boonstoppel <pboonstoppel@nvidia.com>
Reviewed-on: http://git-master/r/60560
Reviewed-on: http://git-master/r/69111
Reviewed-by: Automatic_Commit_Validation_User
Reviewed-by: Anshul Jain (SW) <anshulj@nvidia.com>
Tested-by: Anshul Jain (SW) <anshulj@nvidia.com>
Reviewed-by: Dan Willemsen <dwillemsen@nvidia.com>
|
|
* when outputting to sysfs, we only have to worry about not overflowing
a single page in memory.
* don't use strcat
* avoid passing data between functions by mutating global strings
Change-Id: I8914a9ee282c63a4259c1bcaf9e550328a5664ec
Signed-off-by: Colin Patrick McCabe <cmccabe@nvidia.com>
Reviewed-on: http://git-master/r/63672
Reviewed-by: Bitan Biswas <bbiswas@nvidia.com>
Rebase-Id: Rd3426d0c534a846624a4d55be851a88c67ba6d67
|
|
m, n and p coefficients updated for fuse revision 21 and beyond.
- code cleanup done. fixed checkpatch warnings.
bug 842208
Reviewed-on: http://git-master/r/53808
(cherry picked from commit 488785f279a5642fffde3d48d62c77f46a20b63a)
Reviewed-on: http://git-master/r/55026
(cherry picked from commit 49a5b4cf51ed43e2a9d25a2603e84ed835446832)
Change-Id: I83db5a746d5960c799fbf09e2334ecc608c44d39
Reviewed-on: http://git-master/r/57367
Reviewed-by: Bitan Biswas <bbiswas@nvidia.com>
Tested-by: Bitan Biswas <bbiswas@nvidia.com>
Reviewed-by: Diwakar Tundlam <dtundlam@nvidia.com>
Reviewed-by: Laxman Dewangan <ldewangan@nvidia.com>
Rebase-Id: R49c36a57132c60260e1ab9d9f2aa68bf3602c962
|
|
Bug 844743
Original-Change-Id: Ib6c40bbce942ad43679a63a7729e932e4525043f
Signed-off-by: Pritesh Raithatha <praithatha@nvidia.com>
Reviewed-on: http://git-master/r/48176
Reviewed-by: Venu Byravarasu <vbyravarasu@nvidia.com>
Reviewed-by: Bharat Nihalani <bnihalani@nvidia.com>
Reviewed-by: Varun Wadekar <vwadekar@nvidia.com>
Rebase-Id: R242da5f1b8475357c7add25595bb27cb8f4f7d9c
|
|
Tsensor driver had support for chip revisions 1 and 2 only.
Updated the driver to support later chip revisions.
- Additionally error handling code corrected
bug 864922
Original-Change-Id: I58230b7aa6c343930739f27bcc26e129092a9b4d
Reviewed-on: http://git-master/r/47728
Reviewed-by: Bitan Biswas <bbiswas@nvidia.com>
Tested-by: Bitan Biswas <bbiswas@nvidia.com>
Reviewed-by: Hanumanth Venkateswa Moganty <vmoganty@nvidia.com>
Rebase-Id: Rc4cd2ebc90e7e6cbfd48bdcade89c02626a2629c
|
|
In case of tsensor probe failure in temperature
calculation sanity test step, added more prints.
bug 865024
Original-Change-Id: Ie74b25cc162fc17c83127d832c14dbd1c603a8e5
Reviewed-on: http://git-master/r/47518
Reviewed-by: Varun Colbert <vcolbert@nvidia.com>
Tested-by: Varun Colbert <vcolbert@nvidia.com>
Rebase-Id: Rec20a2726eae6e0779761beb6510f59ef3aab6f1
|
|
tsensor functionality is enabled based on fuse revision.
The fuse revision is to be interpreted as an unsigned integer
while it is interpreted as a decimal number. Corrected this.
bug 863460
Original-Change-Id: I42dbfe406c3ee5b016664410db1b916997e1fe60
Reviewed-on: http://git-master/r/46899
Reviewed-by: Varun Colbert <vcolbert@nvidia.com>
Tested-by: Varun Colbert <vcolbert@nvidia.com>
Rebase-Id: R52f072ab4fc835ae803f4e44fcca768c751d9e4c
|
|
tsensor resume was taking ~20msec because of msleep call.
Removed the unnecessary delay.
bug 862265
Original-Change-Id: I6138a5cd1f19e947cdbfdc8e8d0d236e7c3c8824
Reviewed-on: http://git-master/r/46683
Reviewed-by: Varun Colbert <vcolbert@nvidia.com>
Tested-by: Varun Colbert <vcolbert@nvidia.com>
Rebase-Id: R047a7044707b35fc4e1743f2272aef7e275e92a1
|
|
tsensor probe was not propagating error from a called function.
Later suspend/resume was getting called causing crash. Fixed the code.
bug 863316
Original-Change-Id: I1851d75aeeee332bc582fe45fd7c1c8f0521b5c7
Reviewed-on: http://git-master/r/46890
Reviewed-by: Bitan Biswas <bbiswas@nvidia.com>
Tested-by: Bitan Biswas <bbiswas@nvidia.com>
Reviewed-by: Laxman Dewangan <ldewangan@nvidia.com>
Reviewed-by: Venu Byravarasu <vbyravarasu@nvidia.com>
Rebase-Id: R77a15193c8ae51746ff477f3d877825dd81ecd34
|
|
Formatted the tsensor driver log message's new line location
to match prints from other drivers.
bug 860513
Original-Change-Id: I4a03ecce246ac9847fb1562159bfd9cbcf95ab14
Reviewed-on: http://git-master/r/45501
Tested-by: Bitan Biswas <bbiswas@nvidia.com>
Reviewed-by: Bitan Biswas <bbiswas@nvidia.com>
Rebase-Id: R1f3169b9a05d51ddb81d5066d78afc342f2199fb
|
|
Hardware reset and clock divide feature of tsensor is disabled as
the temperature readings are not accurate. Incorrect threshold
calculations and temperature readings are seen to show tsensor
reset during boot up.
bug 860513
Original-Change-Id: Ib64259f3e400eddde54056dae495983930b5c107
Reviewed-on: http://git-master/r/45487
Reviewed-by: Bitan Biswas <bbiswas@nvidia.com>
Tested-by: Bitan Biswas <bbiswas@nvidia.com>
Reviewed-by: Venu Byravarasu <vbyravarasu@nvidia.com>
Reviewed-by: Hanumanth Venkateswa Moganty <vmoganty@nvidia.com>
Rebase-Id: R01841af1297ed369ea52e6207358cc13296c93e3
|
|
Though tsensor driver was registered as hwmon driver,
sys nodes were not geting created under /sys/class/hwmon.
Hence fixing it.
bug 858158
Original-Change-Id: I6ca226c2a22385c4d0d9ef747267ab0e3060d905
Reviewed-on: http://git-master/r/44313
Tested-by: Venu Byravarasu <vbyravarasu@nvidia.com>
Reviewed-by: Bitan Biswas <bbiswas@nvidia.com>
Rebase-Id: Ra210ae46da9c4598014ad3dce31fb7472aa304d3
|
|
tsensor setup function error path corrected to return error.
bug 857074
Original-Change-Id: I8c4be4868546d39c6c49de9eee4d20afe75f075a
Reviewed-on: http://git-master/r/43714
Reviewed-by: Bitan Biswas <bbiswas@nvidia.com>
Tested-by: Bitan Biswas <bbiswas@nvidia.com>
Reviewed-by: Laxman Dewangan <ldewangan@nvidia.com>
Rebase-Id: Rac3c6ffe339d05186ea38e07e03c517a5d5319ba
|
|
tsensor driver changed as follows:
1. conversion of temperature reading into tsensor counter was not
working earlier. Fixed this.
2. supported tsensor0 usage for upcoming fuse revision 21
3. tsensor specific fuse data extracted using public fuse APIs
bug 851791
bug 855165
Original-Change-Id: I53247f3e029396d5fde479ea168eb279fcae6135
Reviewed-on: http://git-master/r/41037
Reviewed-by: Bitan Biswas <bbiswas@nvidia.com>
Tested-by: Bitan Biswas <bbiswas@nvidia.com>
Reviewed-by: Diwakar Tundlam <dtundlam@nvidia.com>
Reviewed-by: Scott Williams <scwilliams@nvidia.com>
Reviewed-by: Narendra Damahe <ndamahe@nvidia.com>
Reviewed-by: Laxman Dewangan <ldewangan@nvidia.com>
Rebase-Id: R8261421f7a6fd72b14488ac536b98c48e8329c58
|
|
tsensor configuration needs to be saved before lp0 and restored
after lp0 resume else POR values are seen after lp0 resume.
- Config0, Config1 and Config2 registers are saved and restored
bug 851791
Original-Change-Id: I95532d995af4fa71e169209bb1788fc4152290fe
Reviewed-on: http://git-master/r/41819
Reviewed-by: Bitan Biswas <bbiswas@nvidia.com>
Tested-by: Bitan Biswas <bbiswas@nvidia.com>
Reviewed-by: Narendra Damahe <ndamahe@nvidia.com>
Reviewed-by: Laxman Dewangan <ldewangan@nvidia.com>
Rebase-Id: Raceac7154fc86486f2726cdd13637d7e8d1e6828
|
|
tsensor STOP bit is set before suspend. This disables the
counters and prevents OVERFLOW interrupt in LP1 mode
bug 850683
Original-Change-Id: I01fbc9529ecc25ce96f50a5fbf599c9bce2157b5
Reviewed-on: http://git-master/r/40656
Reviewed-by: Bitan Biswas <bbiswas@nvidia.com>
Tested-by: Bitan Biswas <bbiswas@nvidia.com>
Reviewed-by: Laxman Dewangan <ldewangan@nvidia.com>
Rebase-Id: Rbdf02380a72c8f75449a0a3e52007e5883f62d4b
|
|
Tegra integrated temperature sensor(tsensor) driver added
- TH3 counter < current counter causes hardware reset
- TH2 counter < current counter causes CPU clock to be halved
- sysfs interface provided for select operations
- interrupts TH1 TH2 and TH3 working
- used recommended N,M and clk source settings
- tsensor counter to temperature conversion added
tsensor1 counter being used for temperature computations.
Bug 661228
Original-Change-Id: I0fa405c0f542d1b215162291bd913a9ccd55a0f5
Reviewed-on: http://git-master/r/36083
Tested-by: Bitan Biswas <bbiswas@nvidia.com>
Reviewed-by: Bitan Biswas <bbiswas@nvidia.com>
Rebase-Id: R3c910b4fdc630ffee2135d3d649e25015d2b7206
|
|
checking in hwmon driver for TI power monitor device INA219
bug 808311
Change-Id: Idc7a4d6b4fd867db5dc64dc09d6b1f847f9276f4
Reviewed-on: http://git-master/r/34293
Tested-by: Venu Byravarasu <vbyravarasu@nvidia.com>
Reviewed-by: Sachin Nikam <snikam@nvidia.com>
Reviewed-by: Bitan Biswas <bbiswas@nvidia.com>
Reviewed-by: Narendra Damahe <ndamahe@nvidia.com>
Rebase-Id: R3c8f5eea54a0e3c6d1bc0a9283260f12cf865fc1
|
|
The driver now supports thermal throttling.
When the temperature reaches a certain threshold,
thermal throttling is enabled and when the chip cools
off to a certain threshold, throttling is disabled.
Bug 786378
Original-Change-Id: I7e769bd98e0bfe0d1f2decdba4432f91a0133d54
Reviewed-on: http://git-master/r/20372
Tested-by: Prashant Gaikwad <pgaikwad@nvidia.com>
Reviewed-by: Varun Wadekar <vwadekar@nvidia.com>
Reviewed-by: Bharat Nihalani <bnihalani@nvidia.com>
Rebase-Id: R612bbe5253903c74caa676449cc074d83edff984
|
|
Bug 782954
Original-Change-Id: I142e9b3684830e5a10b506d320dbddb71efa57d3
Reviewed-on: http://git-master/r/18018
Reviewed-by: Varun Colbert <vcolbert@nvidia.com>
Tested-by: Varun Colbert <vcolbert@nvidia.com>
Rebase-Id: R333643df9c31076bc29d356d5835012dd8740862
|
|
commit bfa02b0da66965caf46e441270af87edda4fea14 upstream.
Commit 2265cef2 (hwmon: (w83627ehf) Properly report PECI and AMD-SI
sensor types) results in kernel panic if data->temp_label was not
initialized.
The problem was found with chip W83627DHG-P.
Add check if data->temp->label was set before use.
Based on incomplete patch by Alexander Beregalov.
Reported-by: Alexander Beregalov <a.beregalov@gmail.com>
Tested-by: Alexander Beregalov <a.beregalov@gmail.com>
Signed-off-by: Guenter Roeck <guenter.roeck@ericsson.com>
Signed-off-by: Jean Delvare <khali@linux-fr.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
|
|
commit 2265cef2751b3441df91f85e0107f9f549e5b711 upstream.
When temperature sources are PECI or AMD-SI agents, it makes no sense
to report their type as diode or thermistor. Instead we must report
their digital nature.
Signed-off-by: Jean Delvare <khali@linux-fr.org>
Acked-by: Guenter Roeck <guenter.roeck@ericsson.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
|
|
commit 2aba6cac2a84f3b80e11a680c34d55e7739b474d upstream.
The definition of TO_ATTR_NO in the non-SMP case is wrong. As the SMP
definition resolves to the correct value, just use this for both
cases.
Without this fix the temperature attributes are named temp0_* instead
of temp2_*, so libsensors won't pick them. Broken since kernel 3.0.
Signed-off-by: Jean Delvare <khali@linux-fr.org>
Tested-by: Phil Sutter <phil@nwl.cc>
Acked-by: Durgadoss R <Durgadoss.r@intel.com>
Acked-by: Guenter Roeck <guenter.roeck@ericsson.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
|
|
Since 8-bit temperature values are now handled in 16-bit struct
members, values have to be cast to s8 for negative temperatures to be
properly handled. This is broken since kernel version 2.6.39
(commit bce26c58df86599c9570cee83eac58bdaae760e4.)
Signed-off-by: Jean Delvare <khali@linux-fr.org>
Cc: Guenter Roeck <guenter.roeck@ericsson.com>
Cc: stable@kernel.org # 2.6.39+
Signed-off-by: Guenter Roeck <guenter.roeck@ericsson.com>
|
|
The w83627ehf driver is improperly reporting thermal diode sensors as
type 2, instead of 3. This caused "sensors" and possibly other
monitoring tools to report these sensors as "transistor" instead of
"thermal diode".
Furthermore, diode subtype selection (CPU vs. external) is only
supported by the original W83627EHF/EHG. All later models only support
CPU diode type, and some (NCT6776F) don't even have the register in
question so we should avoid reading from it.
Signed-off-by: Jean Delvare <khali@linux-fr.org>
Cc: stable@kernel.org
Signed-off-by: Guenter Roeck <guenter.roeck@ericsson.com>
|
|
Storing the struct temp_data pointer allocated from create_core_data()
when returning an error has the potential of leaving around a pointer
to freed memory. Reset it to NULL for error returns.
Reported-by: Jan Beulich <jbeulich@suse.com>
Signed-off-by: Guenter Roeck <guenter.roeck@ericsson.com>
Acked-by: Jean Delvare <khali@linux-fr.org>
|
|
With recent change "hwmon: (coretemp) don't use kernel assigned CPU
number as platform device ID", the microcode check is now running on
random CPU. Fix that by checking the microcode before creating the
platform device rather than at probe time.
Also avoid calling TO_PHYS_ID(cpu) twice in the same function, it's
expensive.
Signed-off-by: Jean Delvare <khali@linux-fr.org>
Cc: Jan Beulich <jbeulich@suse.com>
Cc: Guenter Roeck <guenter.roeck@ericsson.com>
Signed-off-by: Guenter Roeck <guenter.roeck@ericsson.com>
|