Arm Community
Site
Search
User
Site
Search
User
Groups
Arm Research
DesignStart
Education Hub
Graphics and Gaming
High Performance Computing
Innovation
Multimedia
Open Source Software and Platforms
Physical
Processors
Security
System
Software Tools
TrustZone for Armv8-M
中文社区
Blog
Announcements
Artificial Intelligence
Automotive
Healthcare
HPC
Infrastructure
Innovation
Internet of Things
Machine Learning
Mobile
Smart Homes
Wearables
Forums
All developer forums
IP Product forums
Tool & Software forums
Pelion IoT Platform
Support
Open a support case
Documentation
Downloads
Training
Arm Approved program
Arm Design Reviews
Community Help
More
Cancel
Developer Community
Tools and Software
Software Tools
Jump...
Cancel
Software Tools
Arm Development Studio forum
LDREX fails after MMU is enabled on Beagleboard xM
Tools, Software and IDEs blog
Forums
Videos & Files
Help
Jump...
Cancel
New
Replies
3 replies
Subscribers
127 subscribers
Views
2554 views
Users
0 members are here
Related
LDREX fails after MMU is enabled on Beagleboard xM
Offline
Robbie VanVossen
over 7 years ago
Note: This was originally posted on 30th October 2012 at http://forums.arm.com
I am attempting to port a build of xen-arm to work for the Beagleboard xM. This board uses TI's DM3730 processor, which is built on a Cortex A8 r3p2. My issue is that once the MMU is enabled, LDREX (and presumably STREX) instructions fail. I get a data abort exception when the LDREX instruction executes.
I know that the processor supports the LDREX/STREX instructions. The exclusive instruction support bits, [23:20], of c0, Instruction Set Attributes Register 4 is the expected 0x0. I also tested using LDREX before enabling the MMU and it doesn't cause an exception.
Setup:
Text is loaded to 0x8030_8000
Page Table:
Written from 0x8030_4000 to 0x8030_7FFF.
I am performing a 1 to 1 mapping at 0x8000_0000 for 1024 MB. The section descriptor format I am using is 0x8001_15EE + current page, where current page is 0x10_0000 to 0x4000_0000.
These values should give the following configuration:
Uses Sections
Bufferable: 1
Cacheable: 1
Execute-Never: 0
Domain: 0xF = Domain 15
Access Permissions[1:0]: 0x01
Access Permissions X: 0
Shareable: 1
Not Global: 0
Non-Secure: 0
Translation Table Base Registers (0,1) c1,c0, {0,1}:
0x8000_400B
This gives the following configuration:
Not Outer Shareable: 0 (Not Implemented SBZP)
Cacheable: 1
Shareable: 1
Region Bits: 0x1 = Normal memory, Outer Write-Back Write-Allocate Cacheable
Coprocessor Access Control Register c1,c0,2:
0x000F_0000
This gives the following configuration:
Priveledged and User mode access to CP10 and CP11.
Primary Region Remap Register c10, c2, 0:
0xff0a81a8
This gives the following configuration:
NOS7-0: 0xFF (Should be write ignored)
Mapping of S = 1 attribute for Normal Memory: 1 = Region is shareable
Mapping of S = 0 attribute for Normal Memory: 0 = Region is not shareable
Mapping of S = 1 attribute for Device Memory: 1 = Region is shareable
Mapping of S = 0 attribute for Device Memory: 0 = Region is not shareable
Primary TEX mapping for memory attributes (TRn):
TR0: 0x00 = Strongly Ordered
TR1: 0x10 = Normal Memory
TR2: 0x10 = Normal Memory
TR3: 0x10 = Normal Memory
TR4: 0x01 = Device Memory
TR5: 0x10 = Normal Memory
TR6: 0x00 = Strongly Ordered
TR7: 0x10 = Normal Memory
Normal Memory Remap Register c10, c2, 1:
0x40e040e0
This gives the following configuration:
Outer Cacheable property mapping for memory attributes n (ORn):
OR0: 0x00 = Region is Non-cacheable
OR1: 0x00 = Region is Non-cacheable
OR2: 0x10 = Region is WriteThrough, Non-WriteAllocate
OR3: 0x11 = Region is Write-Back, Non-WriteAllocate
OR4: 0x00 = Region is Non-cacheable
OR5: 0x00 = Region is Non-cacheable
OR6: 0x00 = Region is Non-cacheable
OR7: 0x01 = Region is Write-Back, WriteAllocate
Inner Cacheable property mapping for memory attributes n (IRn):
IR0: 0x00 = Region is Non-cacheable
IR1: 0x00 = Region is Non-cacheable
IR2: 0x10 = Region is WriteThrough, Non-WriteAllocate
IR3: 0x11 = Region is Write-Back, Non-WriteAllocate
IR4: 0x00 = Region is Non-cacheable
IR5: 0x00 = Region is Non-cacheable
IR6: 0x00 = Region is Non-cacheable
IR7: 0x01 = Region is Write-Back, WriteAllocate
Control Register c1, c0, 0:
0x10c53c7d
This gives the following configuration:
MMU Enable: 1
Enable Strict Alignment: 0
Data Caching Enabled: 1
Enable Program Flow prediction: 1
Instruction Caching Enabled: 1
Exception Vector Location: 1 = High Exception Vectors (0xFFFF_0000-0xFFFF_001C)
E-bit setting: 0
Non-Maskable Fast Interrupt enable: 0
Tex remap functionality: 1 = TEX remap enabled
Access Flag Enable: 0
Thumb Exception Enable: 0
Is there something I am missing or am I configuring something incorrectly?
Thanks,Robert VanVossen
More questions in this forum
By title
By date
By reply count
By view count
By most asked
By votes
By quality
Descending
Ascending
All recent questions
Unread questions
Questions you've participated in
Questions you've asked
Unanswered questions
Answered questions
Questions with suggested answers
Questions with no replies
Answered
Failed to read contents of Internal RAM L1-I_DATA in ARM DS
0
Arm Development Studio
Cache
Debug and Trace Services Layer (DTSL)
7909
views
23
replies
Latest
1 month ago
by
Boon Khai
Suggested Answer
DS-5 connect fail when cortex-r5 is in lock-step mode
0
6645
views
10
replies
Latest
1 month ago
by
Stuart Hirons
Suggested Answer
On Cortex-M4F microcontrollers: is fixed point math faster or floating point?
0
6305
views
10
replies
Latest
1 month ago
by
Ronan Synnott
Suggested Answer
Debugging kernel: OS support not working for Linux 5.4
0
Kernel Developers
External Hardware Debug
Debugger
5727
views
5
replies
Latest
2 months ago
by
sgoldschmidt
Suggested Answer
DS-5 bare metal wait error after run "debug"
0
DS-5 Development Studio
Debugging
Arm Compiler 5
Memory
27609
views
14
replies
Latest
2 months ago
by
prasadghole
<
>
View all questions in Arm Development Studio forum