[lm-sensors] Platform device driver for PMIC and lm-sensors

Jean Delvare khali at linux-fr.org
Fri Aug 27 16:21:38 CEST 2010

Hi Alex,

On Fri, 27 Aug 2010 16:04:32 +0200, Alex Gonzalez wrote:
> I am using a Freescale power management chip (MC13892) and a platform
> driver provided by them that exposes battery information through the
> sysfs as follows:
> / # ls /sys/class/power_supply/
> mc13892_bat      mc13892_charger
> / # ls /sys/class/power_supply/mc13892_bat/
> charge_now   device       status       type         voltage_now
> current_now  power        subsystem    uevent
> / # ls /sys/class/power_supply/mc13892_charger/
> device     online     power      subsystem  type       uevent
> Is this type of platform device something that lm-sensors supports?

No. lm-sensors supports hwmon class devices, which implement the API
described in Documentation/hwmon/sysfs-interface. You driver apparently
doesn't implement this (unless it _also_ creates an hwmon class device,
check it...)

> Any other user space application that can be configured to use the
> sysfs information?

Not that I know of. If you want to monitor the values, best would be to
simply have an hwmon class device created for the device, either by the
driver itself, or through a generic power_supply -> hwmon bridge driver
if this makes sense.

Jean Delvare

More information about the lm-sensors mailing list