Fork of the vendor (Boundary Devices) u-boot for Reform 2, with minor tweaks. The goal is to migrate to mainstream u-boot or barebox ASAP. The main impediment so far is the 4GB RAM config.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
This repo is archived. You can view files and clone it, but cannot push or open issues/pull-requests.
 
 
 
 
 
 

37 lines
929 B

  1. // SPDX-License-Identifier: GPL-2.0+
  2. /*
  3. * Cirrus Logic EP93xx CPU-specific support.
  4. *
  5. * Copyright (C) 2009 Matthias Kaehlcke <matthias@kaehlcke.net>
  6. *
  7. * Copyright (C) 2004, 2005
  8. * Cory T. Tusar, Videon Central, Inc., <ctusar@videon-central.com>
  9. */
  10. #include <common.h>
  11. #include <asm/arch/ep93xx.h>
  12. #include <asm/io.h>
  13. /* We reset the CPU by generating a 1-->0 transition on DeviceCfg bit 31. */
  14. extern void reset_cpu(ulong addr)
  15. {
  16. struct syscon_regs *syscon = (struct syscon_regs *)SYSCON_BASE;
  17. uint32_t value;
  18. /* Unlock DeviceCfg and set SWRST */
  19. writel(0xAA, &syscon->sysswlock);
  20. value = readl(&syscon->devicecfg);
  21. value |= SYSCON_DEVICECFG_SWRST;
  22. writel(value, &syscon->devicecfg);
  23. /* Unlock DeviceCfg and clear SWRST */
  24. writel(0xAA, &syscon->sysswlock);
  25. value = readl(&syscon->devicecfg);
  26. value &= ~SYSCON_DEVICECFG_SWRST;
  27. writel(value, &syscon->devicecfg);
  28. /* Dying... */
  29. while (1)
  30. ; /* noop */
  31. }