19 Mar, 2012
2 commits
-
Cc: Hans de Goede
Signed-off-by: Guenter Roeck -
fixed:
WARNING: static const char * array should probably be static const char * const
+static const char *f71882fg_names[] = {Signed-off-by: Frans Meulenbroeks
Signed-off-by: Guenter Roeck
06 Jan, 2012
1 commit
-
replaced strict_strtol with kstrtol and
replaced strict_strtuol with kstrtuolThis satisfies checkpatch -f
Compile tested only: no warnings or errors givenSigned-off-by: Frans Meulenbroeks
Signed-off-by: Guenter Roeck
25 Oct, 2011
3 commits
-
Before this patch the f71882fg driver completely fails to initialize
on systems which have reserved settings in the pwm enable register, and
it disables all auto pwm sysfs attributes if any fan is controlled by
a digital sensor reading.This patch changes the fail to initialize into don't register any attributes
for the fan for which there are reserved settings in the pwm enable register
and also makes the not registering of auto pwm sysfs attributes a per fan
thing.Signed-off-by: Hans de Goede
Signed-off-by: Guenter Roeck -
This is a preparation patch for not registering fan/pwm attributes for
some fans (rather then register them for all or for none).Signed-off-by: Hans de Goede
Signed-off-by: Guenter Roeck -
This is a preparation patch for not registering fan/pwm attributes for
some fans (rather then register them for all or for none).Signed-off-by: Hans de Goede
Signed-off-by: Guenter Roeck
03 Jul, 2011
2 commits
-
The F71869A is almost the same as the F71869F/E, except that it has
the normal number of temp and pwm zones for a F71882FG derived chip,
rather then the limited number of the F71869F/E.Signed-off-by: Hans de Goede
Tested-by: Max Baldwin
Acked-by: Guenter Roeck
Signed-off-by: Jean Delvare -
Signed-off-by: Hans de Goede
Signed-off-by: Jean Delvare
26 May, 2011
2 commits
-
Signed-off-by: Hans de Goede
Signed-off-by: Jean Delvare -
Needed for upcoming support of the F71808A.
Signed-off-by: Hans de Goede
Signed-off-by: Jean Delvare
26 Mar, 2011
5 commits
-
Signed-off-by: Hans de Goede
Acked-by: Guenter Roeck
Signed-off-by: Jean Delvare -
Add support for the Fintek F81865F. It's essentially compatible with
the F71882FG, but has fewer inputs: 7 voltage, 2 temperature and 2 fan
inputs only.Signed-off-by: Jean Delvare
Acked-by: Hans de Goede
Acked-by: Guenter Roeck -
The list of supported devices was not always well documented in all
places. Clarify and list all devices in documentation, Kconfig and
the driver itself.Signed-off-by: Jean Delvare
Acked-by: Hans de Goede
Acked-by: Guenter Roeck -
Use tables to list the count of fan and temperature inputs for all
supported chips, almost similar to (but more simple than) what is
already done for voltage inputs. This avoids repeating the same tests
in different functions, and will make it easier to add support for
chips with a different count of fan or temperature inputs.Signed-off-by: Jean Delvare
Acked-by: Hans de Goede
Acked-by: Guenter Roeck -
Using C99-style array initialization will ensure definitions won't
drift if the chips enum gets new values added.Signed-off-by: Jean Delvare
Acked-by: Hans de Goede
Acked-by: Guenter Roeck
15 Mar, 2011
10 commits
-
Signed-off-by: Hans de Goede
Tested-by: Jonathan Michalon
Signed-off-by: Guenter Roeck -
Note that these 2 are register compatible and report the same superio id,
but they are 2 distinct chips / models!Signed-off-by: Hans de Goede
Tested-by: Thomas Faber
Tested-by: Alexey Sychev
Tested-by: Dieter Bloms
Signed-off-by: Guenter Roeck -
Note that this patch also makes 2 changes to the code paths for the f71889fg
to keep the code unified between the 2 (for simplicities sake). Both of these
are harmless for then f71889fg:1) The first change is to always set the FAN_PROG_SEL bit to 0. This influences
accesses to some banked fan / pwm registers. On the f71889fg no registers
which we use are banked. On the f71889ed however some more fan registers
have been banked including one which we use, by making the FAN_PROG_SEL bit
0, address 0x96 will point to the right register.
2) The second change is to see a FANx_TEMP_SEL value of 0 as pointing to
a PECI / AMDSI value, and thus disable our pwm related sysfs attr.
This is correct for the f71889ed and on the f71889fg 0 is a reserved
value, so we should never see it and if we do, disabling the pwm related
sysfs attr is a sane thing to do.Signed-off-by: Hans de Goede
Tested-by: Thomas Greve
Tested-by: Sander Eikelenboom
Signed-off-by: Guenter Roeck -
Putting this check in its own switch case rather then in the switch case
for adding pwm auto point sysfs attr is cleaner. This is a preparation patch
for adding support for more different models.Signed-off-by: Hans de Goede
Signed-off-by: Guenter Roeck -
This is a preparation patch for adding support for more different models.
Signed-off-by: Hans de Goede
Signed-off-by: Guenter Roeck -
Remove the temp2_type sysfs files for f8000 / f71858fg models,
this got in accidentally and is wrong as these models don't have a
Temperature Sensor Type Register at all.Signed-off-by: Hans de Goede
Signed-off-by: Guenter Roeck -
Make the temp sysattr array for the standard models a 2d array, which allows
to use it for models with less temperatures too. This is a preparation
patch for adding support for more different models.Signed-off-by: Hans de Goede
Signed-off-by: Guenter Roeck -
This is a preparation patch for adding support for more different models,
some of which have a sparse list of used voltage pins.Signed-off-by: Hans de Goede
Signed-off-by: Guenter Roeck -
Signed-off-by: Hans de Goede
Signed-off-by: Guenter Roeck -
The code for determining a sensort type for temp1 was based on me misreading
the datasheet, the tested registers do not determine what kind of sensor
is actually reported as temp1. Instead the enable / disable certain additional
digital sensor readouts throug PECI / AMDSI, etc. Independent of these settings
temp1 is still reading an external BJT or thermistor as configured by the
Temperature Sensor Type Register (0x6b).Signed-off-by: Hans de Goede
Signed-off-by: Guenter Roeck
13 Mar, 2011
2 commits
-
This avoids a possible race leading to trying to dereference NULL.
Signed-off-by: Hans de Goede
Acked-by: Jean Delvare
Cc: stable@kernel.org
Signed-off-by: Guenter Roeck -
Signed-off-by: Hans de Goede
Acked-by: Jean Delvare
Signed-off-by: Guenter Roeck
09 Jan, 2011
1 commit
-
Added #define pr_fmt KBUILD_MODNAME ": " fmt
Converted printks to pr_
Coalesced any long formats
Removed prefixes from formatsSigned-off-by: Joe Perches
Signed-off-by: Guenter Roeck
03 Oct, 2010
1 commit
-
Sleep while acquiring a resource lock on the Super I/O port. This should
prevent collisions from causing the hardware probe to fail with -EBUSY.Signed-off-by: Giel van Schijndel
Acked-by: Hans de Goede
Signed-off-by: Guenter Roeck
21 Aug, 2010
1 commit
-
Revert commit 7721fea3d0fd93fb4d000eb737b444369358d6d3 ("hwmon:
f71882fg: add support for the Fintek F71808E").Hans said:
: A second review after I've received a data sheet for this device from
: Fintek has turned up a few bugs.
:
: Unfortunately Giel (nor I) have time to fix this in time for the 2.6.36
: cycle. Therefor I would like to see this patch reverted as not having any
: support for the hwmon function of this superio chip is better then having
: unreliable support.Cc: Giel van Schijndel
Cc: Jean Delvare
Cc: Hans de Goede
Cc: Jonathan Cameron
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds
10 Aug, 2010
1 commit
-
Allow device probing to recognise the Fintek F71808E.
Sysfs interface:
* Fan/pwm control is the same as for F71889FG
* Temperature and voltage sensor handling is largely the same as for
the F71889FG
- Has one temperature sensor less (doesn't have temp3)
- Misses one voltage sensor (doesn't have V6, thus in6_input refers to
what in7_input refers for F71889FG)For the purpose of the sysfs interface fxxxx_in_temp_attr[] is split up
such that it can largely be reused.Signed-off-by: Giel van Schijndel
Cc: Jean Delvare
Cc: Hans de Goede
Cc: Jonathan Cameron
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds
28 May, 2010
4 commits
-
Acquire the I/O region for the Super I/O chip while we're working on it.
Signed-off-by: Giel van Schijndel
Cc: Hans de Goede
Signed-off-by: Jean Delvare -
Some code cleanup: properly use previously defined functions, rather
than duplicating their code.Signed-off-by: Giel van Schijndel
Cc: Hans de Goede
Signed-off-by: Jean Delvare -
Use the strict_strol and strict_stroul functions instead of simple_strol
and simple_stroul respectively in sysfs functions.Signed-off-by: Giel van Schijndel
Acked-by: Hans de Goede
Signed-off-by: Jean Delvare -
Fixed several coding style issues.
Signed-off-by: Giel van Schijndel
Acked-by: Hans de Goede
Signed-off-by: Jean Delvare
10 Dec, 2009
4 commits
-
This adds support for the Fintek f71889fg to the f71882fg driver,
many thanks to Gerd v. Egidy for providing (remote) access to a
machine which such an ic.Note that this bit of the patch:
- val = SENSORS_LIMIT(val, 0, 255);
+
+ if (data->type == f71889fg)
+ val = SENSORS_LIMIT(val, -128, 127);
+ else
+ val = SENSORS_LIMIT(val, 0, 127);Changes behaviour for already supported models, the new behaviour is correct
as the already supported models have bit 7 of the involved registers fixed at
0, so the previous behaviour which allowed setting temp zone limits > 127
was not correct.Signed-off-by: Hans de Goede
Signed-off-by: Jean Delvare -
There is a bug in the old sysfs file removal, as it uses fxxxx_in_temp_attr
to remove the in and temp sysfs attributes, but fxxxx_in_temp_attr has
temp#_alarm, where as f71858fg_in_temp_attr has temp#_max_alarm, so
the temp#_max_alarm attributes for the f71858fg never get removed.This patch fixes this by doing the sysfs removal exactly the same way as
the creation instead of being (too) clever, this will also avoid similar
bugs in the future.Signed-off-by: Hans de Goede
Signed-off-by: Jean Delvare -
This patch merges the f71882fg_auto_pwm_attr array into the
fxxxx_fan_attr resp. fxxxx_auto_pwm_attr array, as the f71882fg_auto_pwm_attr
array was merely extending these 2 with entries for a 4th fan, it also makes
these 2 arrays 2 dimensional so that the rest of the code can choose to
add attr for 3 or 4 fans without needing to know the nr of attr per fan.Signed-off-by: Hans de Goede
Signed-off-by: Jean Delvare -
This patch makes a number of cleanups to the sysfs attr creation
in the f71882fg driver, this is a preparation patch for adding f71889fg
support:* Add some comments to explain why some models need separate sysfs attr
arrays for in / temp / fan / pwm
* Rename a number of sysfs attr arrays to make their function clearer
* Move the pwm#_auto_channels_temp attribute from the common to all
models fan attr array to the per model auto mode pwm attr arrays, so
that all the auto mode pwm attr are grouped together, and thus can be
left out on models where we don't support auto pwm mode
* Put fan_beep attr in their own array, so that only auto mode pwm attr
remain in the per model pwm sysfs attr arrays.
* Put the 4th special fan input for the f8000 in its own array, so that only
auto mode pwm attr remain in the per model pwm sysfs attr arrays.Signed-off-by: Hans de Goede
Signed-off-by: Jean Delvare
16 Jun, 2009
1 commit
-
Add support for the hwmon part of the Fintek F71858FG superio IC to the
f71882fg driver. Many thanks to Jelle de Jong for lending me a motherboard
with this superio on it.Signed-off-by: Hans de Goede
Signed-off-by: Jean Delvare