cpu.c 378 B

12345678910111213141516171819202122
  1. // SPDX-License-Identifier: GPL-2.0+
  2. /*
  3. * Copyright (C) 2018, Bin Meng <bmeng.cn@gmail.com>
  4. */
  5. #include <irq_func.h>
  6. #include <asm/cache.h>
  7. /*
  8. * cleanup_before_linux() is called just before we call linux
  9. * it prepares the processor for linux
  10. *
  11. * we disable interrupt and caches.
  12. */
  13. int cleanup_before_linux(void)
  14. {
  15. disable_interrupts();
  16. cache_flush();
  17. return 0;
  18. }