ARM·MMU

Publisher:数字狂舞Latest update time:2015-11-17 Source: eefocusKeywords:ARM Reading articles on mobile phones Scan QR code
Read articles on your mobile phone anytime, anywhere
【MMU】
The main functions of MMU: 1) Setting permissions 2) Address mapping
(Here we mainly talk about address mapping)
 
[Mapping of virtual address to physical address]
Question 1: Why do we need virtual addresses?
Reason 1: Let's look at a problem first. Program A needs 10MB of memory, and program B needs 110MB of memory. If A and B run at the same time, 20MB of memory is needed. If there is only 10MB of memory left, what if program C needs 20MB of memory? Therefore, the capacity requirement of our physical memory is very large.
Reason 2: If some programs exit at this time, there is 20M memory, but this memory is not continuous, but randomly allocated, but the total is 20M, which can allow the C program to run, but the C program has no fixed running address;
Reason 3:
【ARM·MMU】
Here, the memory allocation of physical address is used. Imagine that if program B fails, accesses the address of program A, and modifies the memory of program A, then program A will also fail. In other words, the crash of one program will cause the crash of multiple programs, which will make the system very unstable.
 
Combining the above two reasons, we can see the necessity of the invention of virtual addresses.
 
【Virtual address improvements】
(1)
        【ARM·MMU】

Segmented memory mapping
 
 
Although this solves problems 2 and 3, the physical address and virtual address are in a one-to-one correspondence, the physical address has not been expanded, and the capacity is still very small.
 
 
(2) Paging method (page size in ARM is 1MB)
In the segmentation method, the entire program is always loaded into the memory each time the program is run; in the paging method, memory is allocated to the page to which the program runs.
Let's use an example to illustrate:
Assume that when a file A is executed in memory, the operating system will first create a 4GB process virtual address space for the program (not a real space, but a data structure, namely the page directory and page table)
The core idea of ​​the paging method is that when the executable file executes to page x, a memory page y is allocated for page x, and then this memory page is added to the mapping table of the process virtual address space. This mapping table is equivalent to a function y=f(x).
Keywords:ARM Reference address:ARM·MMU

Previous article:ARM SecureCRT connects Windows and Linux
Next article:ARM Nand Flash Control

Recommended ReadingLatest update time:2024-11-17 06:34

Design of Embedded Internet Radio Based on ARM
As a tool for receiving broadcasts, radio has gone through a long development process, from single-band to multi-band, from electron tubes and transistors to integrated circuits, from mechanical tuning to digital tuning functions, and its technology and quality have made great progress. Nowadays, new members ar
[Microcontroller]
Design of Embedded Internet Radio Based on ARM
[Embedded Development] Introduction to ARM chips (ARM chip types | ARM processor working modes | ARM registers | ARM addressing)
1. ARM chip type 1. ARM Classification (1) ARM classification type (chip | core | instruction architecture) ARM Category: -- ARM chip type: 6410, 2440, 210; -- ARM core type: arm11, arm9, CortexA9; -- Instruction architecture: armv7, armv6;
[Microcontroller]
[Embedded Development] Introduction to ARM chips (ARM chip types | ARM processor working modes | ARM registers | ARM addressing)
Design and Analysis of ARM Startup Code
ARM Architecture At present, the ARM series of general-purpose 32-bit RISC microprocessors include ARM7, ARM9, ARM9E, ARM10 and other products. These processors can work in 7 modes. All modes except User mode are called privileged modes, and the other 5 modes except User and System are called exception modes. M
[Microcontroller]
Design and Analysis of ARM Startup Code
Sondrel IP platform integrates Arm security subsystem to provide powerful edge computing
Sondrel has created a powerful quad-core IP platform, the SFA 200, which is ideally suited for ASIC (Application Specific Integrated Circuit) solutions for remote acquisition and processing of video and edge data, and for secure transmission of the results. The resulting single-channel ASIC can be arranged in series t
[Embedded]
Sondrel IP platform integrates Arm security subsystem to provide powerful edge computing
ARM Linux: Implementation principle of switching from usr mode to svc mode
Everyone knows that if a Linux application wants to access the kernel, it must use a system call to switch from usr mode to svc mode. Let's take a look at its implementation process. System call is a service provided by the OS operating system. User programs use various system calls to reference various services pro
[Microcontroller]
From PC bus to ARM internal bus
When I was studying Chapter 9 and Hardware Communication in "Linux Device Drivers (3rd Edition)", I was not very clear about the concept of IO bus, so I looked for relevant information. Now I summarize it as follows: References for this article: 1. "Introduction to AMBA, AHB, APB Buses" Author: adamzhao Date: 2006-11
[Microcontroller]
Wei Dongshan ARM bare metal learning notes - S3C2440 serial port driver programming principles
Preface Explain the serial port driver principle of Wei Dongshan JZ2440 development board, and supplement the serial port usage content in Wei Dongshan's Wiki tutorial. Click here to enter the serial port usage. Here we mainly talk about the programming ideas of the serial port driver, how to write the simplest serial
[Microcontroller]
Wei Dongshan ARM bare metal learning notes - S3C2440 serial port driver programming principles
ARM Assembly: Data Processing Instruction Set
The data processing instructions are: MOV, ADD, ADDS, ADC, SUB, SUBS, SBC, RSB, MUL, AND, ORR, EOR, BIC, CMP, TST, TEQ, LSL, LSR, ASR, RORV   Data processing instruction syntax Operation{ cond }{S} Rd , Rn , Operand2 Operation code Destination register Rd First operation register Rn Second operand Ope
[Microcontroller]
Latest Microcontroller Articles
  • Download from the Internet--ARM Getting Started Notes
    A brief introduction: From today on, the ARM notebook of the rookie is open, and it can be regarded as a place to store these notes. Why publish it? Maybe you are interested in it. In fact, the reason for these notes is ...
  • Learn ARM development(22)
    Turning off and on interrupts Interrupts are an efficient dialogue mechanism, but sometimes you don't want to interrupt the program while it is running. For example, when you are printing something, the program suddenly interrupts and another ...
  • Learn ARM development(21)
    First, declare the task pointer, because it will be used later. Task pointer volatile TASK_TCB* volatile g_pCurrentTask = NULL;volatile TASK_TCB* vol ...
  • Learn ARM development(20)
    With the previous Tick interrupt, the basic task switching conditions are ready. However, this "easterly" is also difficult to understand. Only through continuous practice can we understand it. ...
  • Learn ARM development(19)
    After many days of hard work, I finally got the interrupt working. But in order to allow RTOS to use timer interrupts, what kind of interrupts can be implemented in S3C44B0? There are two methods in S3C44B0. ...
  • Learn ARM development(14)
  • Learn ARM development(15)
  • Learn ARM development(16)
  • Learn ARM development(17)
Change More Related Popular Components

EEWorld
subscription
account

EEWorld
service
account

Automotive
development
circle

About Us Customer Service Contact Information Datasheet Sitemap LatestNews


Room 1530, 15th Floor, Building B, No.18 Zhongguancun Street, Haidian District, Beijing, Postal Code: 100190 China Telephone: 008610 8235 0740

Copyright © 2005-2024 EEWORLD.com.cn, Inc. All rights reserved 京ICP证060456号 京ICP备10001474号-1 电信业务审批[2006]字第258号函 京公网安备 11010802033920号