PMSA Memory Model--1 Overview

PMSA(protected memory system architecture)
不用想这么多,简而言之
PMSA Memory Model就是
从架构的角度看怎么进行memory access,或者
从CPU的角度看怎么进行memory access

1. controlling memory accesses

首先为什么需要memory model?或者说为什么要控制memory access?
因为CPU去访问memory的时候,并不知道memory的实际情况。

举例说明:
CPU如果对0x2000_0000这个地址进行访问,他并不知道访问的这个地址到底是什么东西,可能是DDR,可能是FIFO,可能是控制寄存器等等
图1

不同类型的memory,对memory访问有不同的要求
因此cpu需要对memory access 的behaviour进行控制:

  • Ensure accesses happen in a particular order
  • Allow accesses to be combined
  • Allow read accesses to occur speculatively(投机访问)
  • Allow accesses to be cached
    在这里插入图片描述
    如何去做memory access的控制呢?memory map

2. memory map + mpu(memory protection unit)

将不同的memory分配到不同的物理地址空间,然后通过mpu控制memory access
在mpu中对不同的region配置不同的memory attributes,CPU对相应的region发起访问的时候,首先会做mpu的check,如果属性是满足要求的,才会发出访问

在这里插入图片描述
memory attributes有哪些呢?

3. memory attributes

  • Access permissions
    • No Access
    • RO
    • RW
  • Executable
    • Can instructions be fetched from this location
  • Shareable
    • Is the location accessed by more than one processor core
  • Memory Types
    • SRAM-Like
    • Control Registers
    • FIFO
  • 4
    点赞
  • 6
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值