LoongArch: PE format image loading support

The LoongArch kernel will mainly use the vmlinux.efi image in PE format,
so add it support.

I tested this on LoongArch 3A5000 machine and works as expected,

  $ sudo kexec -l /boot/vmlinux.efi --reuse-cmdline
  $ sudo kexec -e

  $ sudo kexec -p /boot/vmlinux-kdump.efi --reuse-cmdline --append="nr_cpus=1"
  # echo c > /proc/sysrq_trigger

Signed-off-by: Youling Tang <tangyouling@loongson.cn>
Signed-off-by: Simon Horman <horms@kernel.org>
6 files changed