/* linux/arch/arm/mach-exynos4/sleep.S1*2* Copyright (c) 2011 Samsung Electronics Co., Ltd.3* http://www.samsung.com4*5* EXYNOS4210 power Manager (Suspend-To-RAM) support6* Based on S3C2410 sleep code by:7* Ben Dooks, (c) 2004 Simtec Electronics8*9* Based on PXA/SA1100 sleep code by:10* Nicolas Pitre, (c) 2002 Monta Vista Software Inc11* Cliff Brake, (c) 200112*13* This program is free software; you can redistribute it and/or modify14* it under the terms of the GNU General Public License as published by15* the Free Software Foundation; either version 2 of the License, or16* (at your option) any later version.17*18* This program is distributed in the hope that it will be useful,19* but WITHOUT ANY WARRANTY; without even the implied warranty of20* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the21* GNU General Public License for more details.22*23* You should have received a copy of the GNU General Public License24* along with this program; if not, write to the Free Software25* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA26*/2728#include <linux/linkage.h>29#include <asm/assembler.h>30#include <asm/memory.h>3132.text3334/*35* s3c_cpu_save36*37* entry:38* r1 = v:p offset39*/4041ENTRY(s3c_cpu_save)4243stmfd sp!, { r3 - r12, lr }44ldr r3, =resume_with_mmu45bl cpu_suspend4647ldr r0, =pm_cpu_sleep48ldr r0, [ r0 ]49mov pc, r05051resume_with_mmu:52ldmfd sp!, { r3 - r12, pc }5354.ltorg5556/*57* sleep magic, to allow the bootloader to check for an valid58* image to resume to. Must be the first word before the59* s3c_cpu_resume entry.60*/6162.word 0x2bedf00d6364/*65* s3c_cpu_resume66*67* resume code entry for bootloader to call68*69* we must put this code here in the data segment as we have no70* other way of restoring the stack pointer after sleep, and we71* must not write to the code segment (code is read-only)72*/7374ENTRY(s3c_cpu_resume)75b cpu_resume767778