summaryrefslogtreecommitdiff
path: root/zephyr/shim/src/fan.c
diff options
context:
space:
mode:
authorFabio Baltieri <fabiobaltieri@google.com>2021-06-24 16:57:17 +0000
committerCommit Bot <commit-bot@chromium.org>2021-06-28 12:56:52 +0000
commit96528ae712a9ebfa3658ba4943b60c7a527cfba4 (patch)
tree0bfa09d133d2b348de97b6f947bd96a0f691da82 /zephyr/shim/src/fan.c
parentf4362c1b541ad3ca10b8cb2f7b72c8063dea6fd8 (diff)
downloadchrome-ec-96528ae712a9ebfa3658ba4943b60c7a527cfba4.tar.gz
zephyr: use DEVICE_DT_GET for phandle references
Convert few device_get_binding based on DT_PROP_BY_PHANDLE to DEVICE_DT_GET. BRANCH=none BUG=none TEST=zmake configure -b -B ~/build-volteer/ zephyr/projects/volteer/volteer TEST=zmake configure -b -B ~/build-it8xxx2_evb/ zephyr/projects/it8xxx2_evb Signed-off-by: Fabio Baltieri <fabiobaltieri@google.com> Change-Id: Ib8feee8de759481b833010be815cdeb8178f3710 Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2985464 Reviewed-by: Yuval Peress <peress@chromium.org>
Diffstat (limited to 'zephyr/shim/src/fan.c')
-rw-r--r--zephyr/shim/src/fan.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/zephyr/shim/src/fan.c b/zephyr/shim/src/fan.c
index 1e38dff050..b6fa7b999a 100644
--- a/zephyr/shim/src/fan.c
+++ b/zephyr/shim/src/fan.c
@@ -60,9 +60,9 @@ const struct fan_t fans[] = {
#endif /* named_fan */
};
-#define TACHO_DEV_INIT(node_id) { \
- fan_control[node_id].tach = \
- device_get_binding(DT_PROP_BY_PHANDLE(node_id, tach, label)); \
+#define TACHO_DEV_INIT(node_id) { \
+ fan_control[node_id].tach = \
+ DEVICE_DT_GET(DT_PHANDLE(node_id, tach)); \
}
/* Rpm deviation (Unit:percent) */