mbox series

[0/3] pmbus: extend configurability via sysfs

Message ID cover.1554934898.git.krzysztof.adamski@nokia.com (mailing list archive)
Headers show
Series pmbus: extend configurability via sysfs | expand

Message

Krzysztof Adamski April 10, 2019, 10:38 p.m. UTC
Hi,

This patch series extends pmbus core for two specific use cases we have:
- First two patches allows lm25066 driver to export custom sysfs entry
  for controlling manufacturer specific SAMPLES_FOR_AVG register. It is
  useful to be able to set this register when using any of the *_average
  registers, especially since the default value means we are averaging 1
  sample which isn't that useful.
- Third patch exports m, b, R coefficients so that they can be adjusted
  by user space. We can't use default coefficients values and in order
  to achieve high accuracy, we calibrate then per device so using
  device-tree or similar concepts to store them is not an option too.
  Thus, we export it so that the logic of loading proper coeffs can
  be implemented in user space instead.

Krzysztof Adamski (3):
  pmbus: support for custom sysfs attributes
  lm25066: export sysfs attribute for SAMPLES_FOR_AVG
  pmbus: export coefficients via sysfs

 drivers/hwmon/pmbus/lm25066.c    |  45 +++++++++++++
 drivers/hwmon/pmbus/pmbus.h      |   3 +
 drivers/hwmon/pmbus/pmbus_core.c | 109 ++++++++++++++++++++++++++++++-
 3 files changed, 155 insertions(+), 2 deletions(-)