arm archtecture
arm archtecture
ARMv8 架构与指令集.学习笔记
https://www.cnblogs.com/lvdongjie/p/6644821.html
arm registers
https://developer.arm.com/documentation/ddi0500/e/debug/memory-mapped-register-summary
stage 1 and stage2 address translation
https://yomostatic.oss-cn-shenzhen.aliyuncs.com/courses/10_arm_virtualization/chapter_4_Deep_in_Arm_Virtualization.pdf
linux kernel读写arm64系统寄存器
read_sysreg(r)
write_sysreg(v, r)
Introducing Cortex-A35: ARM's Most Efficient Application Processor(ARM technology blog)
https://community.arm.com/arm-community-blogs/b/architectures-and-processors-blog/posts/introducing-cortex-a35-arm-s-most-efficient-application-processor
PSTATE.M[3:0]
PSTATE.M[3:0] is AArch64 Exception level and selected Stack Pointer.
- M[3:2] is set to the value of PSTATE.EL on taking an exception to EL3 and copied to PSTATE.EL on executing an exception return operation in EL3.
- M[1] is unused and is 0 for all non-reserved values.
- M[0] is set to the value of PSTATE.SP on taking an exception to EL3 and copied to PSTATE.SP on executing an exception return operation in EL3.
/* * PSR bits */ #define PSR_MODE_EL0t 0x00000000 #define PSR_MODE_EL1t 0x00000004 #define PSR_MODE_EL1h 0x00000005 #define PSR_MODE_EL2t 0x00000008 #define PSR_MODE_EL2h 0x00000009 #define PSR_MODE_EL3t 0x0000000c #define PSR_MODE_EL3h 0x0000000d #define PSR_MODE_MASK 0x0000000f
- The t suffix indicates that the SP_EL0 stack pointer is selected.
- The h suffix indicates that the SP_ELn stack pointer is selected.
所以在用user_mode()判断当前是否是在user space exception level时,如果pstate[3:0]的值是PSR_MODE_EL0t时,表示是user space exception level:
#define user_mode(regs) \ (((regs)->pstate & PSR_MODE_MASK) == PSR_MODE_EL0t)
分类:
arm
【推荐】编程新体验,更懂你的AI,立即体验豆包MarsCode编程助手
【推荐】凌霞软件回馈社区,博客园 & 1Panel & Halo 联合会员上线
【推荐】抖音旗下AI助手豆包,你的智能百科全书,全免费不限次数
【推荐】博客园社区专享云产品让利特惠,阿里云新客6.5折上折
【推荐】轻量又高性能的 SSH 工具 IShell:AI 加持,快人一步
· 浏览器原生「磁吸」效果!Anchor Positioning 锚点定位神器解析
· 没有源码,如何修改代码逻辑?
· 一个奇形怪状的面试题:Bean中的CHM要不要加volatile?
· [.NET]调用本地 Deepseek 模型
· 一个费力不讨好的项目,让我损失了近一半的绩效!
· 在鹅厂做java开发是什么体验
· 百万级群聊的设计实践
· WPF到Web的无缝过渡:英雄联盟客户端的OpenSilver迁移实战
· 永远不要相信用户的输入:从 SQL 注入攻防看输入验证的重要性
· 浏览器原生「磁吸」效果!Anchor Positioning 锚点定位神器解析
2018-09-30 集合竞价的基本过程