The chip's programming interface is quite similar to LTC3880
and supports the same set of sensors.
Reviewed-by: Robert Coulson <rob.coulson@gmail.com>
Signed-off-by: Guenter Roeck <linux@roeck-us.net>
The hysteresis register is shared among both temperature sensors.
This means changing one also affects the other. To avoid confusion,
established way to express this is to make only the first instance writable
and keep all other instances as read-only. Otherwise users may be
confused that changing the second writable value also affects the first,
while it is more obvious that a writable value may affect a different
read-only value.
Signed-off-by: Guenter Roeck <linux@roeck-us.net>
Reviewed-by: Jean Delvare <jdelvare@suse.de>
ADC128D818 is a System Monitor with Temperature Sensor. It is similar to LM80
and LM96080, but has 16 bit wide sensor registers and no fan speed monitoring.
Signed-off-by: Guenter Roeck <linux@roeck-us.net>
LTC4260 is a Positive Voltage Hot Swap Controller.
The driver currently only supports voltage monitoring, not voltage control.
Signed-off-by: Guenter Roeck <linux@roeck-us.net>
Add support for IT8603E.
This closes bug #57861:
https://bugzilla.kernel.org/show_bug.cgi?id=57861
[JD: Fixes and clean-ups.]
Signed-off-by: Rudolf Marek <r.marek@assembler.cz>
Signed-off-by: Jean Delvare <khali@linux-fr.org>
Pull hwmon fixes and updates from Jean Delvare:
"All lm90 driver fixes and improvements"
* 'hwmon-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jdelvare/staging:
Documentation: dt: hwmon: Add OF document for LM90
hwmon: (lm90) Add power control
hwmon: (lm90) Add support for TI TMP451
hwmon: (lm90) Use enums for the indexes of temp8 and temp11
hwmon: (lm90) Add support to handle IRQ
hwmon: (lm90) Define status bits
hwmon: (lm90) Fix max6696 alarm handling
TI TMP451 is mostly compatible with ADT7461, except for
local temperature low byte and max conversion rate.
Add support to the LM90 driver.
Signed-off-by: Wei Ni <wni@nvidia.com>
Reviewed-by: Guenter Roeck <linux@roeck-us.net>
Signed-off-by: Jean Delvare <khali@linux-fr.org>
Pull hwmon fixes from Jean Delvare.
* 'hwmon-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jdelvare/staging:
hwmon: (emc6w201) Do not declare enum variable
hwmon: (w83792d) Update module author
Pull trivial tree from Jiri Kosina:
"The usual trivial updates all over the tree -- mostly typo fixes and
documentation updates"
* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jikos/trivial: (52 commits)
doc: Documentation/cputopology.txt fix typo
treewide: Convert retrun typos to return
Fix comment typo for init_cma_reserved_pageblock
Documentation/trace: Correcting and extending tracepoint documentation
mm/hotplug: fix a typo in Documentation/memory-hotplug.txt
power: Documentation: Update s2ram link
doc: fix a typo in Documentation/00-INDEX
Documentation/printk-formats.txt: No casts needed for u64/s64
doc: Fix typo "is is" in Documentations
treewide: Fix printks with 0x%#
zram: doc fixes
Documentation/kmemcheck: update kmemcheck documentation
doc: documentation/hwspinlock.txt fix typo
PM / Hibernate: add section for resume options
doc: filesystems : Fix typo in Documentations/filesystems
scsi/megaraid fixed several typos in comments
ppc: init_32: Fix error typo "CONFIG_START_KERNEL"
treewide: Add __GFP_NOWARN to k.alloc calls with v.alloc fallbacks
page_isolation: Fix a comment typo in test_pages_isolated()
doc: fix a typo about irq affinity
...
w83792d was written by me in 2004, I'd like to update my first name
into my current one to keep consistent, and delete invalid address.
Signed-off-by: Shane Huang <shane.huang@amd.com>
Signed-off-by: Jean Delvare <khali@linux-fr.org>
The temperature reporting interface stays the same, so we just
add the PCI-ID to the list.
Verified on AMD Olive Hill.
Signed-off-by: Wei Hu <wei@aristanetworks.com>
Acked-by: Clemens Ladisch <clemens@ladisch.de>
Cc: stable@vger.kernel.org # 3.10+
Signed-off-by: Guenter Roeck <linux@roeck-us.net>
Corrected the word adventerous to adventurous.
Signed-off-by: Stefan Huber <steffhip@gmail.com>
Signed-off-by: Matthias Schid <aircrach115@gmail.com>
Signed-off-by: Simon Puels <simon.puels@gmail.com>
Signed-off-by: Jiri Kosina <jkosina@suse.cz>
This patch adds support for ads1115 device to ads1015 driver.
Based on work of Emiliano Carnati <carnatiatebneuro.com>.
Tested on ARM CPU based board.
Signed-off-by: Evgeniy A. Dushistov <dushistov@mail.ru>
Signed-off-by: Guenter Roeck <linux@roeck-us.net>
Add support for DS1631, DS1721, and DS1731 to ds1621 driver
Remove detect function from ds1621 driver as unreliable
Bug fixes in nct6775, iio_hwmon, and adm1021 drivers
Remove redundant platform_set_drvdata in various drivers
Add device tree support to ina2xx driver
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.12 (GNU/Linux)
iQIcBAABAgAGBQJR0I8LAAoJEMsfJm/On5mBPp8P+wedtxZpljmca+YnuBnZnnZN
7HLFdGvbwOA+ThfYx7UhpyRgJ+D4ggB0jTiVCPHGUJzmwYjEVk5e9qZkIX/1fBIB
Iun9TZdJPG+fYFkr8H91dnJcaeELog76yOvx3VRU1QYO11L1wx56oJ2b3a+lnIb5
UNyovFhvJuZ4jDpzQNUGY5/CMScj2rtPiRPT5NC/3HoSmkXFuV1uw4nhn3C79ycR
NoZFyjFi7J1hCTB7ExoHHSQBGdLFDXQiEZqNaQS4WXnW1jmiTsQl0rRLoP5KqUDU
3NovVA557nOfOHAjB98nQrBM7Syn2jKYeZP+M5OR1iKIXxv5uUs/Ajmpnk5x2t1d
Wf5uHW99SEDTn19U8icgOO4zLvNX0lSXHs+FC6hzKTpLp/FLVjP2uOYj9TcxtPzn
pLAYsE5UIySH4ybJ0Jdf2pKA+8D2eAOVo1joFhaoz8qFjMNdSxBlf8/xOUsBaJoi
dAQ/SmWc9z0Tk03Hxn1b/XVKHLbb3AIpPTe1PCK9bUBzLQyZp2UmBmSPHIVxdjO/
zyRABp64pkoVMqomJPzujEgT2NaqSfr+wwLyUOPBtmaMM8N6aOUlRjrJyOHrSrmB
3CTT23h8xp8lEgjezQ0jYlhNQPgpGmlu/yuFfL2GyqRw00clAkUem0BrstZg0EOD
lepSJCaSpyqr3jfhIBwN
=OdGw
-----END PGP SIGNATURE-----
Merge tag 'hwmon-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/groeck/linux-staging
Pull hwmon updates from Guenter Roeck:
- new driver to support GMT G762/G763 pwm fan controllers
- add support for DS1631, DS1721, and DS1731 to ds1621 driver
- remove detect function from ds1621 driver as unreliable
- bug fixes in nct6775, iio_hwmon, and adm1021 drivers
- remove redundant platform_set_drvdata in various drivers
- add device tree support to ina2xx driver
* tag 'hwmon-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/groeck/linux-staging:
hwmon: (ds1621) Fix temperature rounding operations
hwmon: (nct6775) Drop unsupported fan alarm attributes for NCT6775
hwmon: (nct6775) Fix temperature alarm attributes
Add support for GMT G762/G763 PWM fan controllers
hwmon: (ina2xx) Add device tree support to pass the shunt resistor
hwmon: (ds1621) Update documentation
hwmon: (ds1621) Add DS1731 chip support to ds1621 driver
hwmon: (iio_hwmon) add alias table
hwmon: (adm1021) Do not create min sysfs attributes for LM84
hwmon: (ds1621) Remove detect function
hwmon: (ds1621) Add ds1631 chip support to ds1621 driver and documentation
hwmon: (ds1621) Add ds1721 update interval sysfs attribute
hwmon: (ds1621) Add ds1721 chip support
hwmon: (w83627ehf) Remove redundant platform_set_drvdata()
hwmon: (ntc_thermistor) Remove redundant platform_set_drvdata()
hwmon: (i5k_amb) Remove redundant platform_set_drvdata()
hwmon: (coretemp) Remove redundant platform_set_drvdata()
hwmon: (abituguru3) Remove redundant platform_set_drvdata()
GMT G762/763 fan speed PWM controller is connected directly to a fan
and performs closed-loop or open-loop control of the fan speed. Two
modes - PWM or DC - are supported by the chip. Introduced driver
provides various knobs to control the operations of the chip (via
sysfs interface). Specific characteristics of the system can be passed
either using board init code or via DT. Documentation for both the
driver and DT bindings are also provided.
Signed-off-by: Arnaud Ebalard <arno@natisbad.org>
Tested-by: Simon Guinot <simon.guinot@sequanux.org>
Signed-off-by: Guenter Roeck <linux@roeck-us.net>
Adding another way that is device tree to pass the shunt resistor
value to driver except for platform data.
Signed-off-by: Tang Yuantian <Yuantian.Tang@freescale.com>
[Guenter Roeck: Added missing of.h include]
Signed-off-by: Guenter Roeck <linux@roeck-us.net>
Replace some written information with tables to improve readability
and to simplify adding newer devices in the future.
Signed-off-by: Robert Coulson <rob.coulson@gmail.com>
Signed-off-by: Guenter Roeck <linux@roeck-us.net>
These changes add DS1731 chip support to the ds1621 driver,
Kconfig, and documentation.
Signed-off-by: Robert Coulson <rob.coulson@gmail.com>
Signed-off-by: Guenter Roeck <linux@roeck-us.net>
Due to a lack of device and vendor identification registers, the
Dallas/Maxim DS16xx devices cannot be uniquely detected, sometimes
resulting in false positives. Therefore, the detect function is
being removed in favor of explicit device instantiation.
Signed-off-by: Robert Coulson <rob.coulson@gmail.com>
Acked-by: Jean Delvare <khali@linux-fr.org>
Signed-off-by: Guenter Roeck <linux@roeck-us.net>
Add definitions, information, and code for ds1631 chip support
to the ds1621 driver.
Signed-off-by: Robert Coulson <rob.coulson@gmail.com>
Signed-off-by: Guenter Roeck <linux@roeck-us.net>
The ds1721 device can be configured for 9..12 bit resolutions;
add a sysfs attribute for userspace to configure this attribute.
The definition, description, details, and usage are shown in the
documentation and were crafted from an LM73 driver patch done by
Chris Verges & Guenter Roeck).
Signed-off-by: Robert Coulson <rob.coulson@gmail.com>
Signed-off-by: Guenter Roeck <linux@roeck-us.net>
Update the ds1621 documentation, driver, and Kconfig with
ds1721 chip support.
Signed-off-by: Robert Coulson <rob.coulson@gmail.com>
Signed-off-by: Guenter Roeck <linux@roeck-us.net>
Ever since commit 45f035ab9b ("CONFIG_HOTPLUG should be always on"),
it has been basically impossible to build a kernel with CONFIG_HOTPLUG
turned off. Remove all the remaining references to it.
Cc: Russell King <linux@arm.linux.org.uk>
Cc: Doug Thompson <dougthompson@xmission.com>
Cc: Bjorn Helgaas <bhelgaas@google.com>
Cc: Steven Whitehouse <swhiteho@redhat.com>
Cc: Arnd Bergmann <arnd@arndb.de>
Cc: Pavel Machek <pavel@ucw.cz>
Cc: "Rafael J. Wysocki" <rjw@sisk.pl>
Cc: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
Acked-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Acked-by: Hans Verkuil <hans.verkuil@cisco.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Basically it's the same as the original DS75 but much faster.
Signed-off-by: Jean Delvare <khali@linux-fr.org>
Acked-by: Guenter Roeck <linux@roeck-us.net>
Most LM75-compatible chips can either sample much faster or with a
much better resolution than the original LM75 chip. So far the lm75
driver did not let the user take benefit of these improvements. Do it
now.
I decided to almost always configure the chip to use the best
resolution possible, which also means the longest sample time. The
only chips for which I didn't are the DS75, DS1775 and STDS75, because
they are really too slow in 12-bit mode (1.2 to 1.5 second worst case)
so I went for 11-bit mode as a more reasonable tradeoff. This choice is
dictated by the fact that the hwmon subsystem is meant for system
monitoring, it has never been supposed to be ultra-fast, and as a
matter of fact we do cache the sampled values in almost all drivers.
If anyone isn't pleased with these default settings, they can always
introduce a platform data structure or DT support for the lm75. That
being said, it seems nobody ever complained that the driver wouldn't
refresh the value faster than every 1.5 second, and the change made
it faster for all chips even in 12-bit mode, so I don't expect any
complaint.
Signed-off-by: Jean Delvare <khali@linux-fr.org>
Acked-by: Guenter Roeck <linux@roeck-us.net>
- OpenFirmware/DeviceTree support for the Power Supply core: the core now
automatically populates supplied_from hierarchy from the device tree.
With these patches chargers and batteries can now lookup each other
without the board files support shim. Rhyland Klein at NVIDIA did the
work;
- New ST-Ericsson ABX500 hwmon driver. The driver is heavily using the
AB85xx core and depends on some recent changes to it, so that is why the
driver comes through the battery tree. It has an appropriate ack from
the hwmon maintainer (i.e. Guenter Roeck). Martin Persson at ST-Ericsson
and Hongbo Zhang at Linaro authored the driver;
- Final bits to sync AB85xx ST-Ericsson changes into mainline. The changes
touch mfd parts, but these were acked by the appropriate MFD maintainer
(i.e. Samuel Ortiz). Lee Jones at Linaro did most of the work and lead
the submission process.
Minor changes, but still worth mentioning:
- Battery temperature reporting fix for Nokia N900 phones;
- Versatile Express poweroff driver moved into drivers/power/reset/.
- Tree-wise: use devm_kzalloc() where appropriate;
- Tree-wise: dev_pm_ops cleanups/fixes.
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.19 (GNU/Linux)
iQIcBAABAgAGBQJRf1BPAAoJEGgI9fZJve1bwyoP/3Gv+qStzbN7mUtIVEvH3EAe
aVJwlODFzEZjk5xoiw7Dc8PuBE8O948hWOnQyCuUQ8+OfK6SyNIjexPYy3Z25a0F
cX9JMj7rtPWHvxo2q/YuKwBPZoxj/JIPyxwUT7akwXoHAV059fvcy9R1DfFX2Qur
hSP0NXTg+guvEpxGV4bC2l+LWZPmDFK9n0RsorttYaBvsiRDWl0c2TY2byofYlBw
++m/rI8Qgl8db8pKq/WDue62HtMt3kmZj6ZIgej3Wb0+GIRmYHMyPIyAkf82Wlw2
g2sGNPT7cstrSNOozegzJ7UghJObcYDFf10NCgvFMNjmAT1dAwdneQHEWy6Ek7pT
9X3e0LmaFqVbufFp4xFiLkMutsCLLTnGyXIbzs7RkTm3XBVIUqiDWtI6I6X44ohG
6PJn8vUlufu7owXrqFpgSBar2U1vfoQdhInmz4hbQeff0qn2nX/BGNwhxYptZ549
TudsI9WGzJ6fvYQ56zh6+BfiA0FmjhUiSKOtrXImrhxE6gUf3IOJyMQlkxLx5t8D
uuhBmO0J6kDi2lqF6alOEo+UDefJj4mUJn2tnIdis90+lNQlSV02GEtiwFT1zt1z
LFW0xshQkxZ4lMa28h35FB1/Z11ApUOe4Es+OKADDJhAnxdZzXcAwIRyPRRPgdsy
jTnJno+Kxk9wXLcekxVE
=5BdE
-----END PGP SIGNATURE-----
Merge tag 'for-v3.10' of git://git.infradead.org/battery-2.6
Pull battery updates from Anton Vorontsov:
"Highlights:
- OpenFirmware/DeviceTree support for the Power Supply core: the core
now automatically populates supplied_from hierarchy from the device
tree. With these patches chargers and batteries can now lookup
each other without the board files support shim. Rhyland Klein at
NVIDIA did the work
- New ST-Ericsson ABX500 hwmon driver. The driver is heavily using
the AB85xx core and depends on some recent changes to it, so that
is why the driver comes through the battery tree. It has an
appropriate ack from the hwmon maintainer (i.e. Guenter Roeck).
Martin Persson at ST-Ericsson and Hongbo Zhang at Linaro authored
the driver
- Final bits to sync AB85xx ST-Ericsson changes into mainline. The
changes touch mfd parts, but these were acked by the appropriate
MFD maintainer (ie Samuel Ortiz). Lee Jones at Linaro did most of
the work and lead the submission process.
Minor changes, but still worth mentioning:
- Battery temperature reporting fix for Nokia N900 phones
- Versatile Express poweroff driver moved into drivers/power/reset/
- Tree-wide: use devm_kzalloc() where appropriate
- Tree-wide: dev_pm_ops cleanups/fixes"
* tag 'for-v3.10' of git://git.infradead.org/battery-2.6: (112 commits)
pm2301-charger: Fix suspend/resume
charger-manager: Use kmemdup instead of kzalloc + memcpy
power_supply: Populate supplied_from hierarchy from the device tree
power_supply: Add core support for supplied_from
power_supply: Define Binding for power-supplies
rx51_battery: Fix reporting temperature
hwmon: Add ST-Ericsson ABX500 hwmon driver
ab8500_bmdata: Export abx500_res_to_temp tables for hwmon
ab8500_{bmdata,fg}: Add const attributes to some data arrays
ab8500_bmdata: Eliminate CamelCase warning of some variables
ab8500_btemp: Make ab8500_btemp_get* interfaces public
goldfish_battery: Use resource_size()
lp8788-charger: Use PAGE_SIZE for the sysfs read operation
max8925_power: Use devm_kzalloc()
da9030_battery: Use devm_kzalloc()
da9052-battery: Use devm_kzalloc()
ds2760_battery: Use devm_kzalloc()
ds2780_battery: Use devm_kzalloc()
gpio-charger: Use devm_kzalloc()
isp1704_charger: Use devm_kzalloc()
...
TMP432 is similar to TMP431 with a second external temperature sensor.
Signed-off-by: Guenter Roeck <linux@roeck-us.net>
Acked-by: Jean Delvare <khali@linux-fr.org>
Each of ST-Ericsson X500 chip set series consists of both ABX500 and DBX500
chips. This is ABX500 hwmon driver, where the abx500.c is a common layer for
all ABX500s, and the ab8500.c is specific for AB8500 chip. Under this designed
structure, other chip specific files can be added simply using the same common
layer abx500.c.
Signed-off-by: Hongbo Zhang <hongbo.zhang@linaro.org>
Reviewed-by: Guenter Roeck <linux@roeck-us.net>
Acked-by: Guenter Roeck <linux@roeck-us.net>
Signed-off-by: Anton Vorontsov <anton@enomsg.org>
NCT6775, NCT6776, and NCT6779 have a number of variants with the same
chip ID but different chip labels. Add text "or compatible" to the
message displayed when the driver is loaded and rephrase the Kconfig
entry to reflect that it also supports compatible chips.
Signed-off-by: Guenter Roeck <linux@roeck-us.net>
TMP431 is compatible to TMP401.
Also add support for additional I2C addresses supported by TMP411B
and TMP411C.
Signed-off-by: Guenter Roeck <linux@roeck-us.net>
Acked-by: Jean Delvare <khali@linux-fr.org>
So far the driver reported the voltage on VAUX as "vout2". This was not
entirely appropriate as it is not an output voltage, and complicates
the code. Use the new virtual "VMON" register set and report the voltage
as "vmon" instead.
Signed-off-by: Guenter Roeck <linux@roeck-us.net>
Some sysfs attributes are only supported on LTC2978 and not on LTC3880.
Update documentation to reflect which attributes are supported for which chips.
Output current attributes supported on LTC3880 were described as providing
input current values. Fix text to reflect that the attributes provide output
current values.
"reset history" attribute descriptions were misleading and seemed to imply
that all history was reset when writing a single attribute. Replace with more
accurate text.
Replace 'internal temperature" with "chip temperature". Temperature limits
not only apply to the chip temperature, but also to external temperatures
on LTC3880, so remove the word "chip" from the attribute description.
Signed-off-by: Guenter Roeck <linux@roeck-us.net>
The NCT677X series support weighted fan control. In this mode, a secondary
temperature source is used in addition to the primary temperature source to
control fan speed. Add support for this feature.
Signed-off-by: Guenter Roeck <linux@roeck-us.net>
This driver will replace the w83627ehf driver for NCT6775F and NCT6776F,
and provides support for NCT6779D.
This patch provides support for voltage monitor attributes.
Signed-off-by: Guenter Roeck <linux@roeck-us.net>
The adt7310/adt7320 is the SPI version of the adt7410/adt7420. The register map
layout is a bit different, i.e. the register addresses differ between the two
variants, but the bit layouts of the individual registers are identical. So both
chip variants can easily be supported by the same driver. The issue of non
matching register address layouts is solved by a simple look-up table which
translates the I2C addresses to the SPI addresses.
The patch moves the bulk of the adt7410 driver to a common module that will be
shared by the adt7410 and adt7310 drivers. This common module implements the
driver logic and uses a set of virtual functions to perform IO access. The
adt7410 and adt7310 driver modules provide proper implementations of these IO
accessor functions for I2C respective SPI.
Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
Reviewed-by: Hartmut Knaack <knaack.h@gmx.de>
Signed-off-by: Guenter Roeck <linux@roeck-us.net>