handoff.h 705 B

123456789101112131415161718192021222324252627282930313233343536
  1. /* SPDX-License-Identifier: GPL-2.0+ */
  2. /*
  3. * Passing basic information from SPL to U-Boot proper
  4. *
  5. * Copyright 2018 Google, Inc
  6. */
  7. #ifndef __HANDOFF_H
  8. #define __HANDOFF_H
  9. #if CONFIG_IS_ENABLED(HANDOFF)
  10. #include <asm/handoff.h>
  11. /**
  12. * struct spl_handoff - information passed from SPL to U-Boot proper
  13. *
  14. * @ram_size: Value to use for gd->ram_size
  15. */
  16. struct spl_handoff {
  17. struct arch_spl_handoff arch;
  18. u64 ram_size;
  19. #ifdef CONFIG_NR_DRAM_BANKS
  20. struct {
  21. u64 start;
  22. u64 size;
  23. } ram_bank[CONFIG_NR_DRAM_BANKS];
  24. #endif
  25. };
  26. void handoff_save_dram(struct spl_handoff *ho);
  27. void handoff_load_dram_size(struct spl_handoff *ho);
  28. void handoff_load_dram_banks(struct spl_handoff *ho);
  29. #endif
  30. #endif