elf.c 699 B

123456789101112131415161718192021222324252627282930
  1. // SPDX-License-Identifier: GPL-2.0
  2. /*
  3. * Author: Huacai Chen <[email protected]>
  4. * Copyright (C) 2020-2022 Loongson Technology Corporation Limited
  5. */
  6. #include <linux/binfmts.h>
  7. #include <linux/elf.h>
  8. #include <linux/export.h>
  9. #include <linux/sched.h>
  10. #include <asm/cpu-features.h>
  11. #include <asm/cpu-info.h>
  12. int arch_elf_pt_proc(void *_ehdr, void *_phdr, struct file *elf,
  13. bool is_interp, struct arch_elf_state *state)
  14. {
  15. return 0;
  16. }
  17. int arch_check_elf(void *_ehdr, bool has_interpreter, void *_interp_ehdr,
  18. struct arch_elf_state *state)
  19. {
  20. return 0;
  21. }
  22. void loongarch_set_personality_fcsr(struct arch_elf_state *state)
  23. {
  24. current->thread.fpu.fcsr = boot_cpu_data.fpu_csr0;
  25. }