Commit Graph

74 Commits

Author SHA1 Message Date
Jingoo Han a8b3a3a53f hwmon: use dev_get_platdata()
Use the wrapper function for retrieving the platform data instead of
accessing dev->platform_data directly.

Signed-off-by: Jingoo Han <jg1.han@samsung.com>
Signed-off-by: Guenter Roeck <linux@roeck-us.net>
2013-08-11 22:10:39 -07:00
Guenter Roeck 2a844c148e hwmon: Replace SENSORS_LIMIT with clamp_val
SENSORS_LIMIT and the generic clamp_val have the same functionality,
and clamp_val is more efficient.

This patch reduces text size by 9052 bytes and bss size by 11624 bytes
for x86_64 builds.

Signed-off-by: Guenter Roeck <linux@roeck-us.net>
Acked-by: George Joseph <george.joseph@fairview5.com>
Acked-by: Jean Delvare <khali@linux-fr.org>
2013-01-25 21:03:54 -08:00
Bill Pemberton 6c931ae1c0 hwmon: remove use of __devinit
CONFIG_HOTPLUG is going away as an option so __devinit is no longer
needed.

Signed-off-by: Bill Pemberton <wfp5p@virginia.edu>
Cc: Hans de Goede <hdegoede@redhat.com>
Cc: Jean Delvare <khali@linux-fr.org>
Cc: Alistair John Strachan <alistair@devzero.co.uk>
Cc: Fenghua Yu <fenghua.yu@intel.com>
Cc: Juerg Haefliger <juergh@gmail.com>
Cc: Andreas Herrmann <herrmann.der.user@googlemail.com>
Cc: Clemens Ladisch <clemens@ladisch.de>
Cc: Rudolf Marek <r.marek@assembler.cz>
Cc: Jim Cromie <jim.cromie@gmail.com>
Cc: "Mark M. Hoffman" <mhoffman@lightlink.com>
Cc: Roger Lucas <vt8231@hiddenengine.co.uk>
Acked-by: Guenter Roeck <linux@roeck-us.net>
Acked-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-11-28 11:49:40 -08:00
Guenter Roeck 33cd66e3c8 hwmon: (f71882fg) Convert to use devm_ functions
Convert to use devm_ functions to reduce code size and simplify the code.

Signed-off-by: Guenter Roeck <linux@roeck-us.net>
2012-09-23 21:08:31 -07:00
Guenter Roeck 0038389add hwmon: (f71882fg) Fix build warning
Fix:

warning: 'address' may be used uninitialized in this function [-Wuninitialized]

While this is a false warning, the patch reduces module size on x86_64 by
approximately 175 bytes, so it is still worth the effort.

Signed-off-by: Guenter Roeck <linux@roeck-us.net>
Acked-by: Hans de Goede <hdegoede@redhat.com>
2012-09-23 21:08:29 -07:00
Guenter Roeck 20eaf7247e hwmon: (f71882fg) Fix multi-line comments
Cc: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Guenter Roeck <linux@roeck-us.net>
2012-03-18 18:27:15 -07:00
Frans Meulenbroeks 1dc370899f hwmon: (f71882fg) fix checkpatch issues
fixed:
WARNING: static const char * array should probably be static const char * const
+static const char *f71882fg_names[] = {

Signed-off-by: Frans Meulenbroeks <fransmeulenbroeks@gmail.com>
Signed-off-by: Guenter Roeck <guenter.roeck@ericsson.com>
2012-03-18 18:26:38 -07:00
Frans Meulenbroeks 179c4fdb56 hwmon: replaced strict_str* with kstr*
replaced strict_strtol with kstrtol and
replaced strict_strtuol with kstrtuol

This satisfies checkpatch -f
Compile tested only: no warnings or errors given

Signed-off-by: Frans Meulenbroeks <fransmeulenbroeks@gmail.com>
Signed-off-by: Guenter Roeck <guenter.roeck@ericsson.com>
2012-01-05 08:19:34 -08:00
Hans de Goede 6543439f19 hwmon/f71882fg: Make the decision wether to register fan attr. per fan
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 <hdegoede@redhat.com>
Signed-off-by: Guenter Roeck <guenter.roeck@ericsson.com>
2011-10-24 11:09:38 -07:00
Hans de Goede 9af0794c63 hwmon/f71882fg: Add a f71882fg_create_fan_sysfs_files helper function
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 <hdegoede@redhat.com>
Signed-off-by: Guenter Roeck <guenter.roeck@ericsson.com>
2011-10-24 11:09:37 -07:00
Hans de Goede 5584014256 hwmon/f71882fg: Make all fan/pwm attr tables 2 dimensional
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 <hdegoede@redhat.com>
Signed-off-by: Guenter Roeck <guenter.roeck@ericsson.com>
2011-10-24 11:09:37 -07:00
Hans de Goede 5da556e33f hwmon: (f71882fg) Add support for the F71869A
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 <hdegoede@redhat.com>
Tested-by: Max Baldwin <archerseven@gmail.com>
Acked-by: Guenter Roeck <guenter.roeck@ericsson.com>
Signed-off-by: Jean Delvare <khali@linux-fr.org>
2011-07-03 13:32:53 +02:00
Hans de Goede 7958e3b45d hwmon: Use <> rather than () around my e-mail address
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Jean Delvare <khali@linux-fr.org>
2011-07-03 13:32:53 +02:00
Hans de Goede 629c58bac0 hwmon: (f71882fg) Add support for F71808A
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Jean Delvare <khali@linux-fr.org>
2011-05-25 20:43:32 +02:00
Hans de Goede 4d53811a28 hwmon: (f71882fg) Split has_beep in fan_has_beep and temp_has_beep
Needed for upcoming support of the F71808A.

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Jean Delvare <khali@linux-fr.org>
2011-05-25 20:43:32 +02:00
Hans de Goede a66c10887a hwmon: (f71882fg) Add support for the F71889A
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Acked-by: Guenter Roeck <guenter.roeck@ericsson.com>
Signed-off-by: Jean Delvare <khali@linux-fr.org>
2011-03-26 10:45:02 +01:00
Jean Delvare 383586b12d hwmon: (f71882fg) Add support for the F81865F
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 <khali@linux-fr.org>
Acked-by: Hans de Goede <hdegoede@redhat.com>
Acked-by: Guenter Roeck <guenter.roeck@ericsson.com>
2011-03-26 10:45:02 +01:00
Jean Delvare 5d7f77bf66 hwmon: (f71882fg) Document all supported devices
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 <khali@linux-fr.org>
Acked-by: Hans de Goede <hdegoede@redhat.com>
Acked-by: Guenter Roeck <guenter.roeck@ericsson.com>
2011-03-26 10:45:02 +01:00
Jean Delvare f27def07bf hwmon: (f71882fg) Per-chip fan/temperature input count tables
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 <khali@linux-fr.org>
Acked-by: Hans de Goede <hdegoede@redhat.com>
Acked-by: Guenter Roeck <guenter.roeck@ericsson.com>
2011-03-26 10:45:01 +01:00
Jean Delvare 2740c60c4a hwmon: (f71882fg) Secure chip property definition arrays
Using C99-style array initialization will ensure definitions won't
drift if the chips enum gets new values added.

Signed-off-by: Jean Delvare <khali@linux-fr.org>
Acked-by: Hans de Goede <hdegoede@redhat.com>
Acked-by: Guenter Roeck <guenter.roeck@ericsson.com>
2011-03-26 10:45:01 +01:00
Hans de Goede e5e713cbe8 hwmon/f71882fg: Add support for f71808e
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Tested-by: Jonathan Michalon <johndescs@gmail.com>
Signed-off-by: Guenter Roeck <guenter.roeck@ericsson.com>
2011-03-14 22:39:26 -07:00
Hans de Goede c11bb99362 hwmon/f71882fg: Add support for f71869f and f71869e
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 <hdegoede@redhat.com>
Tested-by: Thomas Faber <thfabba@gmx.de>
Tested-by: Alexey Sychev <owl@umail.ru>
Tested-by: Dieter Bloms <dieter@bloms.de>
Signed-off-by: Guenter Roeck <guenter.roeck@ericsson.com>
2011-03-14 22:39:26 -07:00
Hans de Goede 3cad402281 hwmon/f71882fg: Add support for f71889ed
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 <hdegoede@redhat.com>
Tested-by: Thomas Greve <tg42@gmx.net>
Tested-by: Sander Eikelenboom <linux@eikelenboom.it>
Signed-off-by: Guenter Roeck <guenter.roeck@ericsson.com>
2011-03-14 22:39:25 -07:00
Hans de Goede e48a7f1a71 hwmon/f71882fg: Break out test for auto pwm's controlled by digital readings
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 <hdegoede@redhat.com>
Signed-off-by: Guenter Roeck <guenter.roeck@ericsson.com>
2011-03-14 22:39:24 -07:00
Hans de Goede 78aa4f72b3 hwmon/f71882fg: Separate temp beep sysfs attr from the other temp sysfs attr
This is a preparation patch for adding support for more different models.

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Guenter Roeck <guenter.roeck@ericsson.com>
2011-03-14 22:39:24 -07:00
Hans de Goede 2a91946ac9 hwmon/f71882fg: Remove bogus temp2_type for certain models
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 <hdegoede@redhat.com>
Signed-off-by: Guenter Roeck <guenter.roeck@ericsson.com>
2011-03-14 22:39:23 -07:00
Hans de Goede 60d2b378bb hwmon/f71882fg: Make number of temps configurable
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 <hdegoede@redhat.com>
Signed-off-by: Guenter Roeck <guenter.roeck@ericsson.com>
2011-03-14 22:39:22 -07:00
Hans de Goede 0bae640088 hwmon/f71882fg: Make creation of in sysfs attributes more generic
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 <hdegoede@redhat.com>
Signed-off-by: Guenter Roeck <guenter.roeck@ericsson.com>
2011-03-14 22:39:22 -07:00
Hans de Goede 98f7ba197f hwmon/f71882fg: Only allow negative auto point temps if fan_neg_temp is enabled
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Guenter Roeck <guenter.roeck@ericsson.com>
2011-03-14 22:39:21 -07:00
Hans de Goede 44c4dc521e hwmon/f71882fg: Fix temp1 sensor type reporting
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 <hdegoede@redhat.com>
Signed-off-by: Guenter Roeck <guenter.roeck@ericsson.com>
2011-03-14 22:39:21 -07:00
Hans de Goede d9ebaa4547 hwmon/f71882fg: Set platform drvdata to NULL later
This avoids a possible race leading to trying to dereference NULL.

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Acked-by: Jean Delvare <khali@linux-fr.org>
Cc: stable@kernel.org
Signed-off-by: Guenter Roeck <guenter.roeck@ericsson.com>
2011-03-13 07:42:52 -07:00
Hans de Goede 14a4019de8 hwmon/f71882fg: Fix a typo in a comment
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Acked-by: Jean Delvare <khali@linux-fr.org>
Signed-off-by: Guenter Roeck <guenter.roeck@ericsson.com>
2011-03-13 07:40:41 -07:00
Joe Perches 22d3b41281 hwmon: (f71882fg) Use pr_fmt and pr_<level>
Added #define pr_fmt KBUILD_MODNAME ": " fmt
Converted printks to pr_<level>
Coalesced any long formats
Removed prefixes from formats

Signed-off-by: Joe Perches <joe@perches.com>
Signed-off-by: Guenter Roeck <guenter.roeck@ericsson.com>
2011-01-08 10:55:08 -08:00
Giel van Schijndel cadb86570c hwmon: f71882fg: use a muxed resource lock for the Super I/O port
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 <me@mortis.eu>
Acked-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Guenter Roeck <guenter.roeck@ericsson.com>
2010-10-03 05:57:04 -07:00
Andrew Morton f2e41e9103 revert "hwmon: f71882fg: add support for the Fintek F71808E"
Revert commit 7721fea3d0 ("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 <me@mortis.eu>
Cc: Jean Delvare <khali@linux-fr.org>
Cc: Hans de Goede <hdegoede@redhat.com>
Cc: Jonathan Cameron <jic23@cam.ac.uk>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2010-08-20 09:34:55 -07:00
Giel van Schijndel 7721fea3d0 hwmon: f71882fg: add support for the Fintek F71808E
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 <me@mortis.eu>
Cc: Jean Delvare <khali@linux-fr.org>
Cc: Hans de Goede <hdegoede@redhat.com>
Cc: Jonathan Cameron <jic23@cam.ac.uk>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2010-08-09 20:45:10 -07:00
Giel van Schijndel 729d273aa7 hwmon: (f71882fg) Acquire I/O regions while we're working with them
Acquire the I/O region for the Super I/O chip while we're working on it.

Signed-off-by: Giel van Schijndel <me@mortis.eu>
Cc: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Jean Delvare <khali@linux-fr.org>
2010-05-27 19:58:43 +02:00
Giel van Schijndel bd328acdc6 hwmon: (f71882fg) Code cleanup
Some code cleanup: properly use previously defined functions, rather
than duplicating their code.

Signed-off-by: Giel van Schijndel <me@mortis.eu>
Cc: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Jean Delvare <khali@linux-fr.org>
2010-05-27 19:58:42 +02:00
Giel van Schijndel e8a4eacaa9 hwmon: (f71882fg) Use strict_stro(l|ul) instead of simple_strto$1
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 <me@mortis.eu>
Acked-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Jean Delvare <khali@linux-fr.org>
2010-05-27 19:58:41 +02:00
Giel van Schijndel 162bb59e49 hwmon: (f71882fg) Fixed braces coding style issues
Fixed several coding style issues.

Signed-off-by: Giel van Schijndel <me@mortis.eu>
Acked-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Jean Delvare <khali@linux-fr.org>
2010-05-27 19:58:40 +02:00
Hans de Goede 7669896f49 hwmon: (f71882fg) Add support for the f71889fg (version 2)
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 <hdegoede@redhat.com>
Signed-off-by: Jean Delvare <khali@linux-fr.org>
2009-12-09 20:36:01 +01:00
Hans de Goede fc16c56e69 hwmon: (f71882fg) Fix sysfs file removal
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 <hdegoede@redhat.com>
Signed-off-by: Jean Delvare <khali@linux-fr.org>
2009-12-09 20:36:01 +01:00
Hans de Goede b69b039922 hwmon: (f71882fg) Cleanup sysfs attr creation 2/2
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 <hdegoede@redhat.com>
Signed-off-by: Jean Delvare <khali@linux-fr.org>
2009-12-09 20:36:00 +01:00
Hans de Goede 66344aa6ad hwmon: (f71882fg) Cleanup sysfs attr creation 1/2
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 <hdegoede@redhat.com>
Signed-off-by: Jean Delvare <khali@linux-fr.org>
2009-12-09 20:35:59 +01:00
Hans de Goede 09475d32e6 hwmon: (f71882fg) Add support for the F71858F
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 <hdegoede@redhat.com>
Signed-off-by: Jean Delvare <khali@linux-fr.org>
2009-06-15 18:39:52 +02:00
Hans de Goede b6858bca8d hwmon: (f71882fg) Add temp#_fault sysfs attr for f8000
While working on f71852fg support I noticed that the f8000 sysfs attr
table was missing entries for temp#_fault, which the f8000 does have and
which we were already reading.

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Jean Delvare <khali@linux-fr.org>
2009-06-15 18:39:51 +02:00
Hans de Goede 996cadb2bf hwmon: (f71882fg) Sanity check f8000 pwm settings
We depend up on the pwm_enable register (0x96) not containing any reserved
settings in various places. We were already checking to make sure there
were no reserved settings in the register for the f71862fg, this patch adds
the same checking for the f8000, while at it it also moves the code to
a more apropriate place so we don't need to check if the fan/pwm part
of the IC is enabled twice.

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Jean Delvare <khali@linux-fr.org>
2009-06-15 18:39:51 +02:00
Hans de Goede 3fc7838a20 hwmon: (f71882fg) Cleanup f8000 pwm handling
Currently we are using separate per model sysfs attr for the 3th pwm, because
the 3th pwm of the f8000 only has automatic mode and not manual mode. Doing
things this way was getting in the way for adding f71858fg support, so this
patch makes the pwm attr identical for all models, and instead adds a check
to store_pwm_enable() disallowing setting the 3th pwm to manual mode
on a f8000 IC.

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Jean Delvare <khali@linux-fr.org>
2009-06-15 18:39:50 +02:00
Jean Delvare cd659fd0d7 hwmon: Fix more __devexit_p glitches
Make sure __devexit and devexit_p() match in all hwmon drivers.
Suggested by a similar fix from Mike Frysinger.

Signed-off-by: Jean Delvare <khali@linux-fr.org>
Acked-by: Hans de Goede <hdegoede@redhat.com>
Acked-by: Jonathan Cameron <jic23@cam.ac.uk>
2009-06-15 18:39:45 +02:00
Hans de Goede 18632f84fa hwmon: Fix ACPI resource check error handling
This patch fixes a number of cases where things were not properly
cleaned up when acpi_check_resource_conflict() returned an error,
causing oopses such as the one reported here:
https://bugzilla.redhat.com/show_bug.cgi?id=483208

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Jean Delvare <khali@linux-fr.org>
2009-02-17 19:59:54 +01:00