summaryrefslogtreecommitdiffstats
path: root/arch/arm/cpu/cpu.c
diff options
context:
space:
mode:
Diffstat (limited to 'arch/arm/cpu/cpu.c')
-rw-r--r--arch/arm/cpu/cpu.c27
1 files changed, 8 insertions, 19 deletions
diff --git a/arch/arm/cpu/cpu.c b/arch/arm/cpu/cpu.c
index c5daf6c60e..5f1ffe9a3c 100644
--- a/arch/arm/cpu/cpu.c
+++ b/arch/arm/cpu/cpu.c
@@ -1,20 +1,5 @@
-/*
- * cpu.c - A few helper functions for ARM
- *
- * Copyright (c) 2007 Sascha Hauer <s.hauer@pengutronix.de>, Pengutronix
- *
- * See file CREDITS for list of people who contributed to this
- * project.
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License version 2
- * as published by the Free Software Foundation.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU General Public License for more details.
- */
+// SPDX-License-Identifier: GPL-2.0-only
+// SPDX-FileCopyrightText: 2007 Sascha Hauer <s.hauer@pengutronix.de>, Pengutronix
/**
* @file
@@ -32,8 +17,7 @@
#include <asm/cputype.h>
#include <asm/cache.h>
#include <asm/ptrace.h>
-
-#include "mmu.h"
+#include <efi/efi-mode.h>
/**
* Enable processor's instruction cache
@@ -99,6 +83,8 @@ static void disable_interrupts(void)
*/
static void arch_shutdown(void)
{
+ if (efi_is_payload())
+ return;
#ifdef CONFIG_MMU
mmu_disable();
@@ -113,6 +99,9 @@ extern unsigned long arm_stack_top;
static int arm_request_stack(void)
{
+ if (efi_is_payload())
+ return 0;
+
if (!request_sdram_region("stack", arm_stack_top - STACK_SIZE, STACK_SIZE))
pr_err("Error: Cannot request SDRAM region for stack\n");