00. 目录


文章目录


01. 设置Uboot的提示符

Uboot的默认提示信息是​​TINY4412 #​​。现在修改提示符为DengJin,具体方法如下:

# 修改115行内容
[root@itcast uboot_tiny4412-master]# vim include/configs/tiny4412.h +115
//修改板子的名字
#define CONFIG_BOARD_NAME "UPLOOKING4412"

//修改255行内容如下,修改提示符信息
#define CONFIG_SYS_PROMPT "DengJin # "

重新编译Uboot

[root@itcast uboot_tiny4412-master]# make -j4

重新烧写Uboot到SD卡

[root@itcast tiny4412]# ./sd_fusing.sh  /dev/sdb
/dev/sdb reader is identified.
---------------------------------------
BL1 fusing
记录了16+0 的读入
记录了16+0 的写出
8192字节(8.2 kB)已复制,0.104866 秒,78.1 kB/秒
---------------------------------------
BL2 fusing
记录了28+0 的读入
记录了28+0 的写出
14336字节(14 kB)已复制,0.256877 秒,55.8 kB/秒
---------------------------------------
u-boot fusing
记录了540+1 的读入
记录了540+1 的写出
276932字节(277 kB)已复制,2.68888 秒,103 kB/秒
---------------------------------------
TrustZone S/W fusing
记录了184+0 的读入
记录了184+0 的写出
94208字节(94 kB)已复制,1.14792 秒,82.1 kB/秒
---------------------------------------
U-boot image is fused successfully.
Eject SD card and insert it again.
[root@itcast tiny4412]#

启动Uboot进行测试

【Tiny4412】设置Uboot提示符和关闭MMU_uboot关闭MMU

02. 关闭MMU

MMU是​Memory Management Unit​的缩写,中文名是内存管理单元,它是中央处理器(CPU)中用来管理虚拟存储器、物理存储器的控制线路,同时也负责虚拟地址映射为物理地址,以及提供硬件机制的内存访问授权,多用户多进程操作系统。

2.1 关闭宏

[root@itcast uboot_tiny4412-master]# vim include/configs/tiny4412.h +311
//修改311行内容如下
//#define CONFIG_ENABLE_MMU
#undef CONFIG_ENABLE_MMU

2.2 修改起始地址

[root@itcast uboot_tiny4412-master]# vim board/samsung/tiny4412/config.mk +13
#
# (C) Copyright 2011 Samsung Electronics Co. Ltd
#
# 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.
#
#

#CONFIG_SYS_TEXT_BASE = 0xc3e00000
# 修改之后的起始地址
CONFIG_SYS_TEXT_BASE = 0x43e00000

2.3 重新编译Uboot

[root@itcast uboot_tiny4412-master]# make -j4

2.4 重新烧写Uboot到SD卡

[root@itcast tiny4412]# ./sd_fusing.sh  /dev/sdb
/dev/sdb reader is identified.
---------------------------------------
BL1 fusing
记录了16+0 的读入
记录了16+0 的写出
8192字节(8.2 kB)已复制,0.0847743 秒,96.6 kB/秒
---------------------------------------
BL2 fusing
记录了28+0 的读入
记录了28+0 的写出
14336字节(14 kB)已复制,0.252366 秒,56.8 kB/秒
---------------------------------------
u-boot fusing
记录了504+1 的读入
记录了504+1 的写出
258148字节(258 kB)已复制,2.47621 秒,104 kB/秒
---------------------------------------
TrustZone S/W fusing
记录了184+0 的读入
记录了184+0 的写出
94208字节(94 kB)已复制,1.14885 秒,82.0 kB/秒
---------------------------------------
U-boot image is fused successfully.
Eject SD card and insert it again.
[root@itcast tiny4412]#

2.4 测试Uboot

U-Boot 2010.12 (Jun 04 2020 - 20:12:26) for TINY4412


CPU: S5PC220 [Samsung SOC on SMP Platform Base on ARM CortexA9]
APLL = 1400MHz, MPLL = 800MHz

Board: UPLOOKING4412
DRAM: 1023 MiB

vdd_arm: 1.2
vdd_int: 1.0
vdd_mif: 1.1

BL1 version: N/A (TrustZone Enabled BSP)


Checking Boot Mode ... SDMMC
REVISION: 1.1
MMC Device 0: 7580 MB
MMC Device 1: 3728 MB
MMC Device 2: N/A
*** Warning - using default environment

Net: No ethernet found.
Hit any key to stop autoboot: 0
DengJin #
DengJin #
DengJin #
DengJin #

04. 附录

4.1 【Tiny4412】Tiny4412编译和烧写uboot