clock_legacy.h 904 B

123456789101112131415161718192021222324252627282930313233343536
  1. /* SPDX-License-Identifier: GPL-2.0+ */
  2. /*
  3. * (C) Copyright 2000-2009
  4. * Wolfgang Denk, DENX Software Engineering, wd@denx.de.
  5. */
  6. #ifndef __CLOCK_LEGACY_H
  7. #define __CLOCK_LEGACY_H
  8. int get_clocks(void);
  9. unsigned long get_bus_freq(unsigned long dummy);
  10. int get_serial_clock(void);
  11. /*
  12. * If we have CONFIG_DYNAMIC_DDR_CLK_FREQ then there will be an
  13. * implentation of get_board_ddr_clk() somewhere. Otherwise we have
  14. * a static value to use now.
  15. */
  16. #ifdef CONFIG_DYNAMIC_DDR_CLK_FREQ
  17. unsigned long get_board_ddr_clk(void);
  18. #else
  19. #define get_board_ddr_clk() CONFIG_DDR_CLK_FREQ
  20. #endif
  21. /*
  22. * If we have CONFIG_DYNAMIC_SYS_CLK_FREQ then there will be an
  23. * implentation of get_board_sys_clk() somewhere. Otherwise we have
  24. * a static value to use now.
  25. */
  26. #ifdef CONFIG_DYNAMIC_SYS_CLK_FREQ
  27. unsigned long get_board_sys_clk(void);
  28. #else
  29. #define get_board_sys_clk() CONFIG_SYS_CLK_FREQ
  30. #endif
  31. #endif