setup.c 586 B

123456789101112131415161718192021222324252627282930
  1. // SPDX-License-Identifier: GPL-2.0-or-later
  2. /*
  3. * Copyright (C) 2007 Lemote Inc. & Institute of Computing Technology
  4. * Author: Fuxin Zhang, [email protected]
  5. */
  6. #include <linux/export.h>
  7. #include <linux/init.h>
  8. #include <asm/wbflush.h>
  9. #include <asm/bootinfo.h>
  10. #include <loongson.h>
  11. static void wbflush_loongson(void)
  12. {
  13. asm(".set\tpush\n\t"
  14. ".set\tnoreorder\n\t"
  15. ".set mips3\n\t"
  16. "sync\n\t"
  17. "nop\n\t"
  18. ".set\tpop\n\t"
  19. ".set mips0\n\t");
  20. }
  21. void (*__wbflush)(void) = wbflush_loongson;
  22. EXPORT_SYMBOL(__wbflush);
  23. void __init plat_mem_setup(void)
  24. {
  25. }