init-ld20.c 844 B

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758
  1. /*
  2. * Copyright (C) 2016 Socionext Inc.
  3. * Author: Masahiro Yamada <yamada.masahiro@socionext.com>
  4. *
  5. * SPDX-License-Identifier: GPL-2.0+
  6. */
  7. #include <common.h>
  8. #include <spl.h>
  9. #include "../init.h"
  10. #include "../micro-support-card.h"
  11. int uniphier_ld20_init(const struct uniphier_board_data *bd)
  12. {
  13. uniphier_sbc_init_savepin(bd);
  14. uniphier_pxs2_sbc_init(bd);
  15. uniphier_pin_init("system_bus_grp");
  16. support_card_reset();
  17. support_card_init();
  18. led_puts("L0");
  19. memconf_init(bd);
  20. uniphier_pxs2_memconf_init(bd);
  21. led_puts("L1");
  22. uniphier_ld20_early_clk_init(bd);
  23. led_puts("L2");
  24. led_puts("L3");
  25. #ifdef CONFIG_SPL_SERIAL_SUPPORT
  26. preloader_console_init();
  27. #endif
  28. led_puts("L4");
  29. {
  30. int res;
  31. res = uniphier_ld20_umc_init(bd);
  32. if (res < 0) {
  33. while (1)
  34. ;
  35. }
  36. }
  37. led_puts("L5");
  38. dcache_disable();
  39. return 0;
  40. }