]> git.dujemihanovic.xyz Git - u-boot.git/commitdiff
cros_ec: Allow use with of-platdata
authorSimon Glass <sjg@chromium.org>
Sat, 16 Jan 2021 21:52:30 +0000 (14:52 -0700)
committerSimon Glass <sjg@chromium.org>
Sat, 30 Jan 2021 21:25:41 +0000 (14:25 -0700)
Avoid reading the device tree when of-platdata is in use.

Signed-off-by: Simon Glass <sjg@chromium.org>
drivers/misc/cros_ec.c

index 0bc28e882c9930f62d8f055e53f6d0c49a9c9db8..c22bb4b5b5058c81639ac3029eecae66c8f00fed 100644 (file)
@@ -1577,6 +1577,8 @@ UCLASS_DRIVER(cros_ec) = {
        .id             = UCLASS_CROS_EC,
        .name           = "cros-ec",
        .per_device_auto        = sizeof(struct cros_ec_dev),
+#if !CONFIG_IS_ENABLED(OF_PLATDATA)
        .post_bind      = dm_scan_fdt_dev,
+#endif
        .flags          = DM_UC_FLAG_ALLOC_PRIV_DMA,
 };