Commit Graph
25 Commits
Author SHA1 Message Date
Jean Delvare e369e65d42 Change libsensors license from GPL to LGPL.
git-svn-id: http://lm-sensors.org/svn/lm-sensors/trunk@5844 7894878c-1315-0410-8ee3-d5d059ff63e0
2010-07-01 11:56:42 +00:00
Andre Prendel a03ec09359 Use __func__ in sensors_fatal_error() to get function name.
git-svn-id: http://lm-sensors.org/svn/lm-sensors/trunk@5674 7894878c-1315-0410-8ee3-d5d059ff63e0
2009-03-02 13:07:23 +00:00
Jean Delvare 0efe346b80 Include the configuration file name when reporting parse errors.
git-svn-id: http://lm-sensors.org/svn/lm-sensors/trunk@5649 7894878c-1315-0410-8ee3-d5d059ff63e0
2009-02-15 17:26:57 +00:00
Jean Delvare 6a7286464d Keep track of configuration file names so that we can later generate
better error reports.


git-svn-id: http://lm-sensors.org/svn/lm-sensors/trunk@5648 7894878c-1315-0410-8ee3-d5d059ff63e0
2009-02-15 17:24:31 +00:00
Jean Delvare 9fcfb654af The free_expr() function is no longer static in lib/init.c (it is also
used in lib/conf-parse.y), and therefore must be renamed according to
the libsensors naming conventions.
Based on an original patch from Sergey Vlasov.


git-svn-id: http://lm-sensors.org/svn/lm-sensors/branches/lm-sensors-3.0.0@5302 7894878c-1315-0410-8ee3-d5d059ff63e0
2008-07-14 16:21:48 +00:00
Jean Delvare f2e518511d Patch from Aurelien Jarno:
I have just noticed that the FSF address is the old one in all files
except COPYING. Please find a patch below to fix that.


git-svn-id: http://lm-sensors.org/svn/lm-sensors/branches/lm-sensors-3.0.0@5163 7894878c-1315-0410-8ee3-d5d059ff63e0
2008-03-26 13:37:12 +00:00
Jean Delvare ab0e8eb731 Complete the previous memory leak fix.
git-svn-id: http://lm-sensors.org/svn/lm-sensors/branches/lm-sensors-3.0.0@4793 7894878c-1315-0410-8ee3-d5d059ff63e0
2007-09-09 17:32:59 +00:00
Jean Delvare 5e5a996d83 Delete redundant declarations.
git-svn-id: http://lm-sensors.org/svn/lm-sensors/branches/lm-sensors-3.0.0@4780 7894878c-1315-0410-8ee3-d5d059ff63e0
2007-09-05 20:19:35 +00:00
Jean Delvare 5dec68540f Warning fix.
git-svn-id: http://lm-sensors.org/svn/lm-sensors/branches/lm-sensors-3.0.0@4778 7894878c-1315-0410-8ee3-d5d059ff63e0
2007-09-05 20:10:00 +00:00
Jean Delvare 6b3803c386 Fix memory leaks in the configuration file parser when a label, set,
compute or ignore statement is found before the first chip statement.


git-svn-id: http://lm-sensors.org/svn/lm-sensors/branches/lm-sensors-3.0.0@4768 7894878c-1315-0410-8ee3-d5d059ff63e0
2007-09-05 12:30:39 +00:00
Jean Delvare 079ba26574 Drop sensors_strip_of_spaces. There's no rationale for stripping
trailing spaces of bus names and nothing else.


git-svn-id: http://lm-sensors.org/svn/lm-sensors/branches/lm-sensors-3.0.0@4756 7894878c-1315-0410-8ee3-d5d059ff63e0
2007-09-05 08:07:14 +00:00
Jean Delvare a74addb5d4 Support more bus types (part 2 of 2). Originally libsensors was very
i2c-centric. Make it more neutral so that we can cleanly support
additional bus types such as SPI or One-Wire.

This second part updates sensors_bus to use sensors_bus_id. Thanks
to Mark M. Hoffman for showing me how the configuration file
parser could be modified to support that change.


git-svn-id: http://lm-sensors.org/svn/lm-sensors/branches/lm-sensors-3.0.0@4687 7894878c-1315-0410-8ee3-d5d059ff63e0
2007-08-19 15:04:29 +00:00
Jean Delvare 24f6b62c3f Delete all remnants of algorithm names.
git-svn-id: http://lm-sensors.org/svn/lm-sensors/branches/lm-sensors-3.0.0@4465 7894878c-1315-0410-8ee3-d5d059ff63e0
2007-06-25 14:21:01 +00:00
Jean Delvare 6270cf381a libsensors: Drop support for algorithm names.
I2C algorithms no longer have names in Linux 2.6, and anyway they are
implementation details user-space doesn't care about. No third party
application is known to have ever used this particular feature of
libsensors. "sensord" and "sensors" no longer do.


git-svn-id: http://lm-sensors.org/svn/lm-sensors/trunk@4208 7894878c-1315-0410-8ee3-d5d059ff63e0
2006-10-13 19:55:41 +00:00
Mark M. Hoffman 71a96916d5 Patch by Philipp Thomas <pth@suse.de>:
> Current gcc versions warn when type punning is used, as this breaks the
> strict aliasing analysis gcc 3.3 does by default. When checking the causes
> for these warnings I discovered that sensors_malloc_array,
> sensors_free_array, sensors_add_array_el and sensors_add_array_els in
> lib/general.c all take a 'void **' for the list. This is plain wrong as
> the C standard only allow 'char *' and 'void *' to alias any other type, so
> if these functions should take a generic pointer, it *must* be a 'void *'
> that's internally cast to a 'void **'.
>
> The attached patch does this and adapts all places where these functions are
> called. Note that when done correctly, no cast what-so-ever in the calling
> code is needed.
>
> The patch is against current lm_sensors2 cvs version.


git-svn-id: http://lm-sensors.org/svn/lm-sensors/trunk@2345 7894878c-1315-0410-8ee3-d5d059ff63e0
2004-03-08 04:39:50 +00:00
Mark D. Studebaker 1d0d09cc26 add library support for logarithms and exponents (!) to support
vt1211 / vt8235 thermistor calculations. Add such calculations to
      vt1211/vt8235 section in sensors.conf; bump library version to 1.4.0.


git-svn-id: http://lm-sensors.org/svn/lm-sensors/trunk@1667 7894878c-1315-0410-8ee3-d5d059ff63e0
2002-12-09 02:55:58 +00:00
Mark D. Studebaker 4f7a7db7f6 add missing semicolon which apparently caused
'flex scanner jammed' on redhat 7.3.


git-svn-id: http://lm-sensors.org/svn/lm-sensors/trunk@1386 7894878c-1315-0410-8ee3-d5d059ff63e0
2002-06-08 01:46:22 +00:00
Frodo Looijaard 8199abde46 New sensors.conf keyword 'ignore'
This often-asked for, long-planned and somewhat-forgotten feature
makes it possible to tell libsensors-linked applications (like
the sensors program) that certain features should not be displayed.
This is very nice for things like unconnected temperature sensors
or fans.

Modifications to the library code, to the sensors program and to
the documentation and example sensors.conf file.


git-svn-id: http://lm-sensors.org/svn/lm-sensors/trunk@676 7894878c-1315-0410-8ee3-d5d059ff63e0
1999-12-24 22:44:41 +00:00
Frodo Looijaard 24792039f6 Adrian's copyright patch applied
git-svn-id: http://lm-sensors.org/svn/lm-sensors/trunk@207 7894878c-1315-0410-8ee3-d5d059ff63e0
1999-02-08 22:50:29 +00:00
Frodo Looijaard 33269d5252 Small fixes to make all programs compile cleanly with libc6.
git-svn-id: http://lm-sensors.org/svn/lm-sensors/trunk@168 7894878c-1315-0410-8ee3-d5d059ff63e0
1999-01-14 00:41:44 +00:00
Frodo Looijaard faa996f454 Moved some library functions around, to put them in more logical files.
No external changes.


git-svn-id: http://lm-sensors.org/svn/lm-sensors/trunk@119 7894878c-1315-0410-8ee3-d5d059ff63e0
1998-12-25 21:51:59 +00:00
Frodo Looijaard 1c12665831 Expanded expressions, slightly new syntax
An expression can now refer to the value it has to compute (@), but also to
other values. This is now perfectly valid as an expression:
  vid + in_min - in_max * 2 / @
Not that this is very sensible, but you get the idea. Please install the
new example config file, or replace all old 'val' occurences with '@'.


git-svn-id: http://lm-sensors.org/svn/lm-sensors/trunk@107 7894878c-1315-0410-8ee3-d5d059ff63e0
1998-12-24 01:13:44 +00:00
Frodo Looijaard 849acbe439 More libary stuff
The bus translation functions.


git-svn-id: http://lm-sensors.org/svn/lm-sensors/trunk@101 7894878c-1315-0410-8ee3-d5d059ff63e0
1998-12-22 01:25:25 +00:00
Frodo Looijaard f26b52021b More library extensions
Most notably, config file line numbers are now stored, so we can now generate
better error messages.


git-svn-id: http://lm-sensors.org/svn/lm-sensors/trunk@98 7894878c-1315-0410-8ee3-d5d059ff63e0
1998-12-21 14:14:25 +00:00
Frodo Looijaard c4cb096dd9 The first bunch of library files
These are the relatively well-tested files. They allow you to parse a
configuration file, and to build an internal abstract syntax tree.


git-svn-id: http://lm-sensors.org/svn/lm-sensors/trunk@91 7894878c-1315-0410-8ee3-d5d059ff63e0
1998-12-19 00:10:48 +00:00