mirror of
https://github.com/u-boot/u-boot.git
synced 2025-05-08 10:39:08 +00:00
common: board_r: move init_addr_map() to init.h
asm/mmu.h include is currently guarded by CONFIG_ADDR_MAP ifdef because the header is only present on arm and powerpc. In order to remove the dependency on this header and the associated ifdef, move init_addr_map() declaration to init.h, since it is only called during the common init sequence. Reviewed-by: Simon Glass <sjg@chromium.org> Signed-off-by: Ovidiu Panait <ovidiu.panait@windriver.com>
This commit is contained in:
parent
1b212bb9f4
commit
2fd81be11c
6 changed files with 12 additions and 19 deletions
|
@ -1,8 +0,0 @@
|
||||||
/* SPDX-License-Identifier: GPL-2.0+ */
|
|
||||||
|
|
||||||
#ifndef __ASM_ARM_MMU_H
|
|
||||||
#define __ASM_ARM_MMU_H
|
|
||||||
|
|
||||||
int init_addr_map(void);
|
|
||||||
|
|
||||||
#endif
|
|
|
@ -7,6 +7,7 @@
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include <common.h>
|
#include <common.h>
|
||||||
|
#include <init.h>
|
||||||
#include <asm/bitops.h>
|
#include <asm/bitops.h>
|
||||||
#include <asm/global_data.h>
|
#include <asm/global_data.h>
|
||||||
#include <asm/processor.h>
|
#include <asm/processor.h>
|
||||||
|
|
|
@ -137,10 +137,6 @@ typedef struct _MMU_context {
|
||||||
extern void _tlbie(unsigned long va); /* invalidate a TLB entry */
|
extern void _tlbie(unsigned long va); /* invalidate a TLB entry */
|
||||||
extern void _tlbia(void); /* invalidate all TLB entries */
|
extern void _tlbia(void); /* invalidate all TLB entries */
|
||||||
|
|
||||||
#ifdef CONFIG_ADDR_MAP
|
|
||||||
extern int init_addr_map(void);
|
|
||||||
#endif
|
|
||||||
|
|
||||||
typedef enum {
|
typedef enum {
|
||||||
IBAT0 = 0, IBAT1, IBAT2, IBAT3,
|
IBAT0 = 0, IBAT1, IBAT2, IBAT3,
|
||||||
DBAT0, DBAT1, DBAT2, DBAT3,
|
DBAT0, DBAT1, DBAT2, DBAT3,
|
||||||
|
|
|
@ -6,6 +6,7 @@
|
||||||
#include <common.h>
|
#include <common.h>
|
||||||
#include <dm.h>
|
#include <dm.h>
|
||||||
#include <env.h>
|
#include <env.h>
|
||||||
|
#include <init.h>
|
||||||
#include <fsl_validate.h>
|
#include <fsl_validate.h>
|
||||||
#include <fsl_secboot_err.h>
|
#include <fsl_secboot_err.h>
|
||||||
#include <fsl_sfp.h>
|
#include <fsl_sfp.h>
|
||||||
|
@ -16,10 +17,6 @@
|
||||||
#include <spl.h>
|
#include <spl.h>
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifdef CONFIG_ADDR_MAP
|
|
||||||
#include <asm/mmu.h>
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#ifdef CONFIG_FSL_CORENET
|
#ifdef CONFIG_FSL_CORENET
|
||||||
#include <asm/fsl_pamu.h>
|
#include <asm/fsl_pamu.h>
|
||||||
#endif
|
#endif
|
||||||
|
|
|
@ -59,9 +59,6 @@
|
||||||
#ifdef CONFIG_XEN
|
#ifdef CONFIG_XEN
|
||||||
#include <xen.h>
|
#include <xen.h>
|
||||||
#endif
|
#endif
|
||||||
#ifdef CONFIG_ADDR_MAP
|
|
||||||
#include <asm/mmu.h>
|
|
||||||
#endif
|
|
||||||
#include <asm/sections.h>
|
#include <asm/sections.h>
|
||||||
#include <dm/root.h>
|
#include <dm/root.h>
|
||||||
#include <dm/ofnode.h>
|
#include <dm/ofnode.h>
|
||||||
|
|
|
@ -310,6 +310,16 @@ int board_early_init_r(void);
|
||||||
*/
|
*/
|
||||||
int arch_initr_trap(void);
|
int arch_initr_trap(void);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* init_addr_map()
|
||||||
|
*
|
||||||
|
* Initialize non-identity virtual-physical memory mappings for 32bit CPUs.
|
||||||
|
* It is called during the generic board init sequence, after relocation.
|
||||||
|
*
|
||||||
|
* Return: 0 if OK
|
||||||
|
*/
|
||||||
|
int init_addr_map(void);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* main_loop() - Enter the main loop of U-Boot
|
* main_loop() - Enter the main loop of U-Boot
|
||||||
*
|
*
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue