arch/arm/mm/proc-v7m.S

Source file repositories/reference/linux-study-clean/arch/arm/mm/proc-v7m.S

File Facts

System
Linux kernel
Corpus path
arch/arm/mm/proc-v7m.S
Extension
.S
Size
7052 bytes
Lines
257
Domain
Architecture Layer
Bucket
arch/arm
Inferred role
Architecture Layer: arch/arm
Status
atlas-only

Why This File Exists

CPU and platform-specific kernel glue: boot entry, traps, syscall entry, interrupts, page tables, context switch, and low-level barriers.

Dependency Surface

Detected Declarations

Annotated Snippet

#include <linux/linkage.h>
#include <linux/cfi_types.h>
#include <asm/assembler.h>
#include <asm/page.h>
#include <asm/v7m.h>
#include "proc-macros.S"

SYM_TYPED_FUNC_START(cpu_v7m_proc_init)
	ret	lr
SYM_FUNC_END(cpu_v7m_proc_init)

SYM_TYPED_FUNC_START(cpu_v7m_proc_fin)
	ret	lr
SYM_FUNC_END(cpu_v7m_proc_fin)

/*
 *	cpu_v7m_reset(loc)
 *
 *	Perform a soft reset of the system.  Put the CPU into the
 *	same state as it would be if it had been reset, and branch
 *	to what would be the reset vector.
 *
 *	- loc   - location to jump to for soft reset
 */
	.align	5
SYM_TYPED_FUNC_START(cpu_v7m_reset)
	ret	r0
SYM_FUNC_END(cpu_v7m_reset)

/*
 *	cpu_v7m_do_idle()
 *
 *	Idle the processor (eg, wait for interrupt).
 *
 *	IRQs are already disabled.
 */
SYM_TYPED_FUNC_START(cpu_v7m_do_idle)
	wfi
	ret	lr
SYM_FUNC_END(cpu_v7m_do_idle)

SYM_TYPED_FUNC_START(cpu_v7m_dcache_clean_area)
	ret	lr
SYM_FUNC_END(cpu_v7m_dcache_clean_area)

/*
 * There is no MMU, so here is nothing to do.
 */
SYM_TYPED_FUNC_START(cpu_v7m_switch_mm)
	ret	lr
SYM_FUNC_END(cpu_v7m_switch_mm)

.globl	cpu_v7m_suspend_size
.equ	cpu_v7m_suspend_size, 0

#ifdef CONFIG_ARM_CPU_SUSPEND
SYM_TYPED_FUNC_START(cpu_v7m_do_suspend)
	ret	lr
SYM_FUNC_END(cpu_v7m_do_suspend)

SYM_TYPED_FUNC_START(cpu_v7m_do_resume)
	ret	lr
SYM_FUNC_END(cpu_v7m_do_resume)
#endif

SYM_TYPED_FUNC_START(cpu_cm7_dcache_clean_area)
	dcache_line_size r2, r3
	movw	r3, #:lower16:BASEADDR_V7M_SCB + V7M_SCB_DCCMVAC
	movt	r3, #:upper16:BASEADDR_V7M_SCB + V7M_SCB_DCCMVAC

Annotation

Implementation Notes