Commit Graph
1925 Commits
Author SHA1 Message Date
Andrew Lunn dcf23676cc sensors: Add support for power min, lcrit, min_alarm, lcrit_alarm
SFP modules measure the transmit power of the lazer. The sensor has
expected minimum values, and alarms when these minimams are reached.
Add support to sensors to print these.

Signed-off-by: Andrew Lunn <andrew@lunn.ch>
2018-06-29 12:29:46 -07:00
Ondřej Lysoněk e0c146763b pwmconfig: Declare TMP1 and TMP2 on a separate line
Declare TMP1 and TMP2 on a separate line to make Coverity Scan happy.

Signed-off-by: Ondřej Lysoněk <olysonek@redhat.com>
2018-05-14 08:49:01 -07:00
Ondřej Lysoněk fb595f55d1 fancontrol: Do command substitution in double quotes
Do command substitution in double quotes to prevent word splitting.
The issue was reported by Coverity Scan.

Signed-off-by: Ondřej Lysoněk <olysonek@redhat.com>
2018-05-14 08:49:01 -07:00
Ondřej Lysoněk 40aa494c02 Remove superfluous call to get_input_value()
It is already called in the line above.
Discovered thanks to a Coverity Scan warning.

Signed-off-by: Ondřej Lysoněk <olysonek@redhat.com>
2018-05-14 08:49:01 -07:00
Ondřej Lysoněk 3b548b74ae Fix a use after free()
The issue was reported by Coverity Scan.

Signed-off-by: Ondřej Lysoněk <olysonek@redhat.com>
2018-05-14 08:49:01 -07:00
Guenter Roeck b4923f19eb sensors-detect: 0x15b3 is a Family 15h chip, not 17h
Signed-off-by: Guenter Roeck <linux@roeck-us.net>
2018-05-10 07:52:25 -07:00
Guenter Roeck e0a0238d90 sensors-detect: Add detection of AMD Ryzen Zen+ series chips
Signed-off-by: Guenter Roeck <linux@roeck-us.net>
2018-05-08 06:40:55 -07:00
Ondřej Lysoněk c874e11639 Add detection of AMD Ryzen w/ Vega graphics
Kernel support was added in commit
https://github.com/torvalds/linux/commit/877d8948d0aa402fb
2018-05-03 06:15:09 -07:00
jschwender 06a57f6d54 Update vt1211_pwm
the script uses bashisms that work only if sh is bash. if not this will fail. Consequently shebang should be bash, not sh.
2018-03-14 21:08:37 -07:00
jschwender 0e255d895f pwmconfig: fix missing "
introduced in #3daae37

Signed-off-by: Guenter Roeck <linux@roeck-us.net>
2018-03-13 09:18:55 -07:00
jschwender 2d236fbb96 Update vt1211_pwm
replaced deprecated sub shell syntax

Signed-off-by: Guenter Roeck <linux@roeck-us.net>
2018-03-11 09:45:03 -07:00
jschwender 3daae37d58 Update pwmconfig
replaced deprecated sub shell syntax

Signed-off-by: Guenter Roeck <linux@roeck-us.net>
2018-03-11 09:45:03 -07:00
jschwender 33463a1c77 Update fancontrol
replaced deprecated sub shell syntax and replaced deprecated egrep by grep -E

Signed-off-by: Guenter Roeck <linux@roeck-us.net>
2018-03-11 09:45:03 -07:00
jschwender 6842a129c8 Update fancontrol.8
fix incorrect alg description

Signed-off-by: Guenter Roeck <linux@roeck-us.net>
2018-03-11 09:45:03 -07:00
Jakub Wilk 8c2a6ebc22 Fix typos in documentation
Signed-off-by: Guenter Roeck <linux@roeck-us.net>
2018-03-02 11:07:26 -08:00
Guenter Roeck df96b0bb4d sensors-detect: Support detection of NCT6796D
Signed-off-by: Guenter Roeck <linux@roeck-us.net>
2018-02-21 13:04:55 -08:00
Roland Ramthun 34627e4666 Update fancontrol to save original pwm values
Update fancontrol script to save the values of pwmN_enable and pwmN
when it starts and restore the values, when it exits.
Closes groeck/lm-sensors#47.

Signed-off-by: Roland Ramthun <bts@roland-ramthun.de>
[groeck: Split description into multiple lines]
Signed-off-by: Guenter Roeck <linux@roeck-us.net>
2018-02-04 08:56:58 -08:00
Guenter Roeck df12836f48 Add detection of AMD Family 15h Model 60+ temperature sensors
Signed-off-by: Guenter Roeck <linux@roeck-us.net>
2017-12-27 09:52:14 -08:00
Guenter Roeck 3613422167 Add detection of various JC42.4 chips
Signed-off-by: Guenter Roeck <linux@roeck-us.net>
2017-12-12 00:31:44 -08:00
Guenter Roeck 915fc2fb78 sensors-detect: Detect various Intel SMBus controllers
Signed-off-by: Guenter Roeck <linux@roeck-us.net>
2017-12-12 00:10:38 -08:00
Guenter Roeck 9d155f3bd9 sensors-detect: Detect AMD Family 17h temperature sensor and other changes
Detect AMD Family 17h temperature sensor
Detect AMD KERNCZ SMBus controller
Fix NCT6795D detection

Signed-off-by: Guenter Roeck <linux@roeck-us.net>
2017-12-11 23:54:10 -08:00
Guenter Roeck 8d510a7d75 sensors-detect: Support detection of IT8987D
IT8987D is an embedded controller from ITE, used on some Intel NUC boards.

Signed-off-by: Guenter Roeck <linux@roeck-us.net>
2017-08-29 06:27:51 -07:00
Guenter Roeck 0d5ccf640d Add detection of DDR4 SPD
DDR4 SPD is quite similar to DDR3 SPD. Key difference for detection is
the DDR type, which is 0x0c or 12 for DDR4.

Signed-off-by: Guenter Roeck <linux@roeck-us.net>
2017-05-01 20:13:34 -07:00
Matthew Tiffany 1b36ea4299 Added feature to sensors to allow json output.
* Added -j option to sensors that outputs json.
* -j option overrides raw option

Signed-off-by: Matthew SL Tiffany <shadethedemon@gmail.com>
Signed-off-by: Guenter Roeck <linux@roeck-us.net>
2017-04-14 08:03:49 -07:00
Guenter Roeck 90f7e3c069 sensors-detect: Add detection of Nuvoton NCT6795D
Signed-off-by: Guenter Roeck <linux@roeck-us.net>
2017-03-25 18:45:52 -07:00
Guenter Roeck 8aa117ffd7 sensors-detect: Add detection of various ITE Super-IO chips
Signed-off-by: Guenter Roeck <linux@roeck-us.net>
2017-03-25 18:41:53 -07:00
Guenter Roeck 45ffa15cf0 sensors-detect: Fix syntax error
elseif should be elsif

Signed-off-by: Guenter Roeck <linux@roeck-us.net>
2016-07-25 13:19:00 -07:00
Guenter Roeck 6a368f70ea sensors-detect: Fix detection of NCT6793D
The Chip ID for NCT6793D is 0xD12x, not 0xD11x.

Signed-off-by: Guenter Roeck <linux@roeck-us.net>
2016-07-16 10:32:13 -07:00
Guenter Roeck ff36ee04b8 sensors-detect: Mark F81866D as supported by the f71882fg driver
Signed-off-by: Guenter Roeck <linux@roeck-us.net>
2016-07-16 10:25:40 -07:00
Guenter Roeck feabab994e sensors-detect: Mark F81768D as supported by the f71882fg driver
Signed-off-by: Guenter Roeck <linux@roeck-us.net>
2016-07-16 10:25:40 -07:00
Guenter Roeck 5a71627a80 sensors-detect: Mark F71868A as supported by the f71882fg driver
Signed-off-by: Guenter Roeck <linux@roeck-us.net>
2016-07-16 10:25:40 -07:00
AlisonSchofield 5ea7fefee4 update sensors-detect for Microchip MCP9808 2016-07-15 14:03:49 -07:00
Guenter Roeck 21e256095c Add detection of Nuvoton NCT6793D 2015-08-31 07:47:39 +00:00
Jean Delvare 8fb3922219 isadump: Fix compilation under musl
From Brendan Heading:

You may be aware of the musl C-library implementation, which tries to
be strictly standards compliant, avoids non-standard extensions, etc.
Some distributions have adopted it as their standard C library, in
others (such as buildroot) it is a configuration alternative.

Vanilla lm-sensors does not compile under musl, due to the following
excerpt which appears in four different places. The code is checking
that the glibc version is greater than 2.0.

#if defined(__GLIBC__) && __GLIBC__ == 2 && __GLIBC_MINOR__ >= 0
#include <sys/io.h>
#else
#include <asm/io.h>
#endif

This fails under musl does not define __GLIBC__ (in fact, by design,
it doesn't provide any way to identify itself at all) - which causes
it to try to include <asm/io.h> rather than <sys/io.h>.

It's a long time since glibc 2.0.1 was released - 1997. Accordingly,
it seems to make little sense at this stage to try to retain
compatibility with very old libcs - so maybe it should be removed
entirely.
2015-08-31 07:34:51 +00:00
Jean Delvare 6507372685 sensors-detect: Only probe I/O ports on x86
Contributed by Aurelien Jarno.
2015-08-10 09:04:53 +00:00
Jean Delvare 991c8d5f9a sensors.1: Add reference to sensors-detect
Contributed by Aurelien Jarno.
2015-08-10 08:23:41 +00:00
Jean Delvare 76e050dc2f sensors-detect: Add detection of Fintek F81768 2015-07-06 12:11:15 +00:00
Jean Delvare b26a85f06c sensors-detect: Fix systemd paths 2015-07-06 11:51:24 +00:00
Jean Delvare 096a5fc953 fancontrol: Reduce memory consumption
Construct "wait $!" causes bash to remember the exit status of the
children. This consumes memory. We don't need the status code and we
are only waiting for a single child, so we can simply use "wait". This
will reduce the memory usage.

This partly fixes ticket #2391.
http://www.lm-sensors.org/ticket/2391

The actual leak is in bash 4.3 and should be fixed there.
2015-06-25 10:34:52 +00:00
Jean Delvare 955a371506 Be more flexible when parsing address list 2015-05-31 12:00:33 +00:00
Jean Delvare b457bc7c63 sensors-detect: Skip addresses 0x37 and 0x4f on DDC channels
We already skip EDID addresses (0x50-0x57) by default on graphics card
I2C/DDC buses. Also skip 0x37 (DDC/CI) and 0x4f which was recently
reported as corrupting a laptop's display when probed.

This closes ticket #2392.
http://www.lm-sensors.org/ticket/2392
2015-05-31 11:58:16 +00:00
Jean Delvare 332c6fe2b9 sensors-detect: Detect graphics card in all cases
On recent kernels, the i2c bus may not be an immediate child of the
graphics device, instead there can be a drm class device in between.
Treat all drm class devices as graphics devices so that probing the
i2c bus is disabled by default as intended.
2015-05-31 11:53:30 +00:00
Jean Delvare 15cafdf597 Don't probe address 0x37 for TMP435, this address is known to be
problematic.
2015-05-28 06:01:18 +00:00
Guenter Roeck aaf34b0de8 Add detection of ITE8790E.
Reflect that IT8620E will soon be supported by the it87 driver.
2015-03-30 06:43:30 +00:00
Guenter Roeck da60f83fa2 sensors-detect: Nuvoton chip updates
Document driver support for NCT7802Y.
Add detection of NCT7904D.
2015-03-03 16:48:20 +00:00
Jean Delvare 64629dc2f2 healthd.sh: Drop PATH manipulations
Altering PATH shouldn't be needed, everything that is required should
be already available.
2015-03-03 09:14:15 +00:00
Jean Delvare f86fd47838 healthd.sh: Revert to regular sleep
The read trick did not work when the daemon is started by systemd.
So we call sleep again, but we try to use the builtin flavor when
available.
2015-03-03 09:02:31 +00:00
Jean Delvare 1f5ef824c8 healthd.sh: Bump version 2015-02-28 10:15:00 +00:00
Jean Delvare 53d852c9b5 healthd.sh: Decrease the resource consumption by replacing the
external commands with the built-in bash commands. Contributed by
vbooh.
2015-02-28 09:11:05 +00:00
Guenter Roeck 266a45579c sensors-detect: Detect additional IDT temperature sensors
Loosen detection rules for TS3000/TSE2002 to detect additional
chip revisions. Add detection of TSE2004 and TS3001.
2015-02-25 16:38:20 +00:00