aboutsummaryrefslogtreecommitdiff
path: root/hw/dts.c
diff options
context:
space:
mode:
authorCédric Le Goater <clg@fr.ibm.com>2015-03-09 21:56:16 +0100
committerStewart Smith <stewart@linux.vnet.ibm.com>2015-03-24 18:22:55 +1100
commit42345ef5c60108fc7d74009d73e8ed880e04072c (patch)
treefa5bb43e62cf54592ec25191871423a233f49b20 /hw/dts.c
parent609646f1a6933ce126804b632a74e59729a72c11 (diff)
downloadskiboot-42345ef5c60108fc7d74009d73e8ed880e04072c.zip
skiboot-42345ef5c60108fc7d74009d73e8ed880e04072c.tar.gz
skiboot-42345ef5c60108fc7d74009d73e8ed880e04072c.tar.bz2
dts: add a type property
The hwmon framework in Linux needs a type for the sensors it exposes in userspace through the sysfs interface. This patch gives Linux a hand on what is dealing with when parsing the sensor device tree. Signed-off-by: Cédric Le Goater <clg@fr.ibm.com> Signed-off-by: Stewart Smith <stewart@linux.vnet.ibm.com>
Diffstat (limited to 'hw/dts.c')
-rw-r--r--hw/dts.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/hw/dts.c b/hw/dts.c
index 4a4259a..0ae6d23 100644
--- a/hw/dts.c
+++ b/hw/dts.c
@@ -203,6 +203,7 @@ bool dts_sensor_create_nodes(struct dt_node *sensors)
handler = sensor_make_handler(sensor_class,
c->pir, SENSOR_DTS_ATTR_TEMP_TRIP);
dt_add_property_cells(node, "sensor-status", handler);
+ dt_add_property_string(node, "sensor-type", "temp");
}
}