linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 0/2]  Add a generic virtual thermal sensor
@ 2021-09-06 19:04 Alexandre Bailon
  2021-09-06 19:04 ` [PATCH 1/2] dt-bindings: Add bindings for the " Alexandre Bailon
  2021-09-06 19:04 ` [PATCH 2/2] thermal: add a virtual sensor to aggregate temperatures Alexandre Bailon
  0 siblings, 2 replies; 7+ messages in thread
From: Alexandre Bailon @ 2021-09-06 19:04 UTC (permalink / raw)
  To: rui.zhang, daniel.lezcano, amitk
  Cc: linux-pm, linux-kernel, ben.tseng, khilman, gpain, Alexandre Bailon

This series add a virtual thermal sensor.
It could be used to get a temperature using some thermal sensors.
Currently, the supported operations are max, min and avg.
The virtual sensor could be easily extended to support others operations.

Note:
Currently, thermal drivers must explicitly register their sensors to make them
available to the virtual sensor.
This doesn't seem a good solution to me and I think it would be preferable to
update the framework to register the list of each available sensors.

Alexandre Bailon (2):
  dt-bindings: Add bindings for the virtual thermal sensor
  thermal: add a virtual sensor to aggregate temperatures

 .../thermal/virtual,thermal-sensor.yaml       |  67 +++
 drivers/thermal/Kconfig                       |   8 +
 drivers/thermal/Makefile                      |   1 +
 drivers/thermal/virtual-sensor.h              |  51 +++
 drivers/thermal/virtual_sensor.c              | 400 ++++++++++++++++++
 include/dt-bindings/thermal/virtual-sensor.h  |  15 +
 6 files changed, 542 insertions(+)
 create mode 100644 Documentation/devicetree/bindings/thermal/virtual,thermal-sensor.yaml
 create mode 100644 drivers/thermal/virtual-sensor.h
 create mode 100644 drivers/thermal/virtual_sensor.c
 create mode 100644 include/dt-bindings/thermal/virtual-sensor.h

-- 
2.31.1


^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2021-10-07 15:56 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-09-06 19:04 [PATCH 0/2] Add a generic virtual thermal sensor Alexandre Bailon
2021-09-06 19:04 ` [PATCH 1/2] dt-bindings: Add bindings for the " Alexandre Bailon
2021-10-07 15:56   ` Rafael J. Wysocki
2021-09-06 19:04 ` [PATCH 2/2] thermal: add a virtual sensor to aggregate temperatures Alexandre Bailon
2021-09-07  5:14   ` kernel test robot
2021-09-09 22:29   ` Matthias Kaehlcke
2021-09-15 13:32     ` Alexandre Bailon

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).