locore.S 439 B

123456789101112131415161718192021222324252627282930
  1. /*
  2. * locore.S
  3. */
  4. #include <asm/asm.h>
  5. #include <asm/regdef.h>
  6. #include <asm/mipsregs.h>
  7. .text
  8. /*
  9. * Simple general exception handling routine. This one is used for the
  10. * Memory sizing routine for pmax machines. HK
  11. */
  12. NESTED(genexcept_early, 0, sp)
  13. .set noat
  14. .set noreorder
  15. mfc0 k0, CP0_STATUS
  16. la k1, mem_err
  17. sw k0, 0(k1)
  18. mfc0 k0, CP0_EPC
  19. nop
  20. addiu k0, 4 # skip the causing instruction
  21. jr k0
  22. rfe
  23. END(genexcept_early)