ea-lpc3250devkitv2.c 730 B

1234567891011121314151617181920212223242526272829303132333435363738394041
  1. // SPDX-License-Identifier: GPL-2.0+
  2. /*
  3. * Board init file for Embedded Artists LPC3250 DevKit v2
  4. * Copyright (C) 2021 Trevor Woerner <twoerner@gmail.com>
  5. */
  6. #include <init.h>
  7. #include <common.h>
  8. #include <asm/io.h>
  9. #include <asm/global_data.h>
  10. #include <asm/arch/clk.h>
  11. #include <asm/arch/wdt.h>
  12. #include <asm/arch/sys_proto.h>
  13. DECLARE_GLOBAL_DATA_PTR;
  14. int
  15. board_early_init_f(void)
  16. {
  17. lpc32xx_uart_init(CONFIG_CONS_INDEX);
  18. if (IS_ENABLED(CONFIG_SYS_I2C_LPC32XX)) {
  19. lpc32xx_i2c_init(1);
  20. lpc32xx_i2c_init(2);
  21. }
  22. return 0;
  23. }
  24. int
  25. board_init(void)
  26. {
  27. gd->bd->bi_boot_params = CFG_SYS_SDRAM_BASE + 0x2000;
  28. return 0;
  29. }
  30. int
  31. dram_init(void)
  32. {
  33. gd->ram_size = get_ram_size((void *)CFG_SYS_SDRAM_BASE, SZ_64M);
  34. return 0;
  35. }