summaryrefslogtreecommitdiffstats
path: root/drivers/hwmon/pmbus/ltc2978.c
Commit message (Collapse)AuthorAgeFilesLines
* hwmon: (pmbus/ltc2978) Add support for LTC2974 and LTC3883Guenter Roeck2013-04-071-19/+130
| | | | Signed-off-by: Guenter Roeck <linux@roeck-us.net>
* hwmon: (pmbus/ltc2978) Code cleanupGuenter Roeck2013-04-071-11/+14
| | | | | | | | | | Use u16 instead of int to store cached limit attributes. This reduces allocated data size per driver instance by 48 bytes. Use defines for the number of pages supported by individual chips. Use ARRAY_SIZE for loops to initialize array variables, and initialize all variables in the same code block. Signed-off-by: Guenter Roeck <linux@roeck-us.net>
* hwmon: (pmbus/ltc2978) Fix temperature reportingGuenter Roeck2013-03-141-6/+8
| | | | | | | | | | | | | | On LTC2978, only READ_TEMPERATURE is supported. It reports the internal junction temperature. This register is unpaged. On LTC3880, READ_TEMPERATURE and READ_TEMPERATURE2 are supported. READ_TEMPERATURE is paged and reports external temperatures. READ_TEMPERATURE2 is unpaged and reports the internal junction temperature. Signed-off-by: Guenter Roeck <linux@roeck-us.net> Cc: stable@vger.kernel.org # 3.2+ Acked-by: Jean Delvare <khali@linux-fr.org>
* hwmon: (pmbus/ltc2978) Use detected chip ID to select supported functionalityGuenter Roeck2013-03-031-1/+1
| | | | | | | | | | We read the chip ID from the chip, use it to determine if the chip ID provided to the driver is correct, and report it if wrong. We should also use the correct chip ID to select supported functionality. Signed-off-by: Guenter Roeck <linux@roeck-us.net> Cc: stable@vger.kernel.org # 3.2+ Acked-by: Jean Delvare <khali@linux-fr.org>
* hwmon: (pmbus/ltc2978) Fix peak attribute handlingGuenter Roeck2013-03-031-13/+15
| | | | | | | | | | Peak attributes were not initialized and cleared correctly. Also, temp2_max is only supported on page 0 and thus does not need to be an array. Signed-off-by: Guenter Roeck <linux@roeck-us.net> Cc: stable@vger.kernel.org # 3.2+ Acked-by: Jean Delvare <khali@linux-fr.org>
* hwmon: (pmbus) Simplify remove functionsGuenter Roeck2012-03-181-7/+1
| | | | | | | | | Since devm_kzalloc() is now used to allocate driver memory, the client driver remove function has no purpose other than to call pmbus_do_remove(). This means we can get rid of it by redefining pmbus_do_remove() to use the same prototype, and pointing to it directly. Signed-off-by: Guenter Roeck <linux@roeck-us.net>
* hwmon: (pmbus) Convert pmbus drivers to use devm_kzallocGuenter Roeck2012-03-181-22/+8
| | | | | | Marginally less code and eliminate the possibility of memory leaks. Signed-off-by: Guenter Roeck <linux@roeck-us.net>
* hwmon: convert drivers/hwmon/* to use module_i2c_driver()Axel Lin2012-03-181-11/+1
| | | | | | | | | | | | | | | | | | This patch converts the drivers in drivers/hwmon/* to use the module_i2c_driver() macro which makes the code smaller and a bit simpler. Signed-off-by: Axel Lin <axel.lin@gmail.com> Cc: Corentin Labbe <corentin.labbe@geomatys.fr> Cc: Dirk Eibach <eibach@gdsys.de> Cc: "Mark M. Hoffman" <mhoffman@lightlink.com> Cc: Steve Glendinning <steve.glendinning@smsc.com> Cc: Riku Voipio <riku.voipio@iki.fi> Cc: Guillaume Ligneul <guillaume.ligneul@gmail.com> Cc: David George <david.george@ska.ac.za> Cc: "Hans J. Koch" <hjk@hansjkoch.de> Cc: Marc Hulsman <m.hulsman@tudelft.nl> Cc: Rudolf Marek <r.marek@assembler.cz> Signed-off-by: Guenter Roeck <guenter.roeck@ericsson.com>
* hwmon: (pmbus/ltc2978) Add support for LTC3880 to LTC2978 driverGuenter Roeck2011-10-241-12/+125
| | | | | | | | The LTC3880 PMBus command set is comparable to LTC2978. Add support for it to the LTC2978 driver. Signed-off-by: Guenter Roeck <guenter.roeck@ericsson.com> Reviewed-by: Robert Coulson <robert.coulson@ericsson.com>
* hwmon: (pmbus/ltc2978) Explicit driver for LTC2978Guenter Roeck2011-10-241-0/+295
Provide explicit driver for LTC2978 to enable support for minimum and peak attributes. Remove ltc2978 chip id from generic pmbus driver. Signed-off-by: Guenter Roeck <guenter.roeck@ericsson.com> Reviewed-by: Robert Coulson <robert.coulson@ericsson.com>
OpenPOWER on IntegriCloud