pch-uclass.c 600 B

123456789101112131415161718192021222324252627282930
  1. /*
  2. * Copyright (c) 2015 Google, Inc
  3. * Written by Simon Glass <sjg@chromium.org>
  4. *
  5. * SPDX-License-Identifier: GPL-2.0+
  6. */
  7. #include <common.h>
  8. #include <dm.h>
  9. #include <dm/root.h>
  10. DECLARE_GLOBAL_DATA_PTR;
  11. static int pch_uclass_post_bind(struct udevice *bus)
  12. {
  13. /*
  14. * Scan the device tree for devices
  15. *
  16. * Before relocation, only bind devices marked for pre-relocation
  17. * use.
  18. */
  19. return dm_scan_fdt_node(bus, gd->fdt_blob, bus->of_offset,
  20. gd->flags & GD_FLG_RELOC ? false : true);
  21. }
  22. UCLASS_DRIVER(pch) = {
  23. .id = UCLASS_PCH,
  24. .name = "pch",
  25. .post_bind = pch_uclass_post_bind,
  26. };