summaryrefslogtreecommitdiff
path: root/arch/x86/lib/zimage.c
diff options
context:
space:
mode:
authorSimon Glass <sjg@chromium.org>2020-09-05 14:50:42 -0600
committerBin Meng <bmeng.cn@gmail.com>2020-09-25 11:27:08 +0800
commite9d31b302d8a4b9c371c73d3385a1efd222ab4c0 (patch)
tree977952a71b54ab48ff304f6bb1a8048d2dcfe701 /arch/x86/lib/zimage.c
parent00630f63cc98d5c98605fb4952b9850d9366ded9 (diff)
x86: zimage: Disable interrupts just before booting
At present if an error occurs while setting up the boot, interrupts are left disabled. Move this call later in the sequence to avoid this problem. Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Wolfgang Wallner <wolfgang.wallner@br-automation.com> Reviewed-by: Bin Meng <bmeng.cn@gmail.com>
Diffstat (limited to 'arch/x86/lib/zimage.c')
-rw-r--r--arch/x86/lib/zimage.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/arch/x86/lib/zimage.c b/arch/x86/lib/zimage.c
index ba9eb50b0ba..8651dea93b3 100644
--- a/arch/x86/lib/zimage.c
+++ b/arch/x86/lib/zimage.c
@@ -333,7 +333,6 @@ int do_zboot(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[])
struct boot_params *base_ptr;
char *s;
- disable_interrupts();
memset(&state, '\0', sizeof(state));
if (argc >= 2) {
/* argv[1] holds the address of the bzImage */
@@ -369,6 +368,7 @@ int do_zboot(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[])
return -1;
}
+ disable_interrupts();
/* we assume that the kernel is in place */
return boot_linux_kernel((ulong)base_ptr, state.load_address, false);
}