longer need to build an array from the chip names passed on the
command line. Instead, we can process them one after the other
directly. This saves some memory and allows for minor code cleanups.
git-svn-id: http://lm-sensors.org/svn/lm-sensors/branches/lm-sensors-3.0.0@4703 7894878c-1315-0410-8ee3-d5d059ff63e0
caller select which subset of chips it wants. This is slightly better
size-wise than letting all applications do the filtering by themselves.
This will change the way the command line parameters of "sensors" are
interpreted. Beforehand, the chips were always returned in the order
in which they were listed by the library. Also, each chip could be listed
only once. From now on, the chips will be listed in the order in which
they are passed on the command line, which I think makes more sense. A
side effect is that chips can be listed more than once, if that's what
the user asks for. Not very useful though.
This change makes it possible to make sensors_match_chip() internal
to the library. Filtering the list of chips returned by
sensors_get_detected_chips() was the last known external use for this
function.
This patch looks much bigger than it really is, but the largest part is
really only code reindentation.
git-svn-id: http://lm-sensors.org/svn/lm-sensors/branches/lm-sensors-3.0.0@4701 7894878c-1315-0410-8ee3-d5d059ff63e0
i2c-centric. Make it more neutral so that we can cleanly support
additional bus types such as SPI or One-Wire.
This first part introduces sensors_bus_id, and updates
sensors_chip_name to use it.
git-svn-id: http://lm-sensors.org/svn/lm-sensors/branches/lm-sensors-3.0.0@4686 7894878c-1315-0410-8ee3-d5d059ff63e0
sensors_parse_chip_name(). sensors_snprintf_chip_name() converts
a chip name from its internal representation to a human readable
string. So far, each user program had to reimplement this function.
git-svn-id: http://lm-sensors.org/svn/lm-sensors/branches/lm-sensors-3.0.0@4676 7894878c-1315-0410-8ee3-d5d059ff63e0
abituguru seems to work well with the new dynamic chip support and generic
chip printroutines. note: the abituguru code should be completly removed in
the future.
-comment k8temp entry in lib/chips.c and prog/sensors/main.c, as the
k8temp seems to work well with the new dynamic chip support and generic
chip printroutines. note: the k8temp code should be completly removed in
the future.
-make the match for the subtype exact instead of a strncmp, otherwise
an alarm_enable flag gets classified as an alarm, leading to all sensors who
have their alarm enabled getting an alarm reported, as the alarm_enabled gets
read as alarm.
-and do the same for the _input match to check if this is a main or subfeature
git-svn-id: http://lm-sensors.org/svn/lm-sensors/branches/lm-sensors-3.0.0@4367 7894878c-1315-0410-8ee3-d5d059ff63e0
The algorithm names are no more available since Linux 2.6, and were not
very useful anyway.
git-svn-id: http://lm-sensors.org/svn/lm-sensors/trunk@4206 7894878c-1315-0410-8ee3-d5d059ff63e0
We don't need to strdup() the file names, we can use them directly.
As a side effect, this fixes a memory leak which was happening if
option -c was specified more than once on the command line.
git-svn-id: http://lm-sensors.org/svn/lm-sensors/trunk@4205 7894878c-1315-0410-8ee3-d5d059ff63e0
sensord: Add pc87247 support (fans only).
sensors: Add pc87247 support (fans only).
sensors-detect: Advertise the upcoming pc87427 driver.
Thanks to Amir Habibi at Candelis for setting up a test system.
git-svn-id: http://lm-sensors.org/svn/lm-sensors/trunk@4196 7894878c-1315-0410-8ee3-d5d059ff63e0
to confuse users a lot, to report the lack of hwmon driver as an error.
prog/sensors: Clearer error messages when no sensors are found. The
most frequent cause is a lack of drivers, not procfs/sysfs problems.
git-svn-id: http://lm-sensors.org/svn/lm-sensors/trunk@4159 7894878c-1315-0410-8ee3-d5d059ff63e0
IT8712F so there's not much to do. The most significant difference is that
fan speeds are now reported as 16-bit values, without fan clock dividers.
For this reason, I made the fan_divs optional in sensors. I also made the
fans themselves optional, as I noticed that a number of motherboards don't
use (and don't enable) fan3.
I've made a separate section (chip "it8716-*") in sensors.conf.eg, because
new motherboards tend to have different wirings (e.g. negative voltage
lines are not monitored) so this will make for saner defaults.
Thanks to Stian Oksavik for testing.
git-svn-id: http://lm-sensors.org/svn/lm-sensors/trunk@4083 7894878c-1315-0410-8ee3-d5d059ff63e0